diff --git a/README.md b/README.md index 0e9dce7..838f661 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,7 @@ Explanation: ### **WORK IN PROGRESS** --> ## Changelog -### **WORK IN PROGRESS** +### 1.0.11 (2024-12-06) * (bluefox) Updated packages ### 1.0.8 (2024-10-11) diff --git a/admin/custom/customComponents.js b/admin/custom/customComponents.js index eecfe1f..2c7f32d 100644 --- a/admin/custom/customComponents.js +++ b/admin/custom/customComponents.js @@ -1,5 +1,5 @@ -var AdminComponentEasyAccessSet;(()=>{"use strict";var A={3009:(a,l,t)=>{var m={"./Components":()=>Promise.all([t.e("webpack_sharing_consume_default_react_react-_7ec5"),t.e("webpack_sharing_consume_default_prop-types_prop-types"),t.e("webpack_sharing_consume_default_mui_material_mui_material"),t.e("webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5"),t.e("webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config"),t.e("src_Components_jsx")]).then(()=>()=>t(6128))},p=(u,v)=>(t.R=v,v=t.o(m,u)?m[u]():Promise.resolve().then(()=>{throw new Error('Module "'+u+'" does not exist in container.')}),t.R=void 0,v),f=(u,v)=>{if(t.S){var c="default",g=t.S[c];if(g&&g!==u)throw new Error("Container initialization failed as it has already been initialized with a different share scope");return t.S[c]=u,t.I(c,v)}};t.d(l,{get:()=>p,init:()=>f})}},M={};function e(a){var l=M[a];if(l!==void 0)return l.exports;var t=M[a]={id:a,loaded:!1,exports:{}};return A[a].call(t.exports,t,t.exports,e),t.loaded=!0,t.exports}e.m=A,e.c=M,e.amdD=function(){throw new Error("define cannot be used indirect")},e.n=a=>{var l=a&&a.__esModule?()=>a.default:()=>a;return e.d(l,{a:l}),l},e.d=(a,l)=>{for(var t in l)e.o(l,t)&&!e.o(a,t)&&Object.defineProperty(a,t,{enumerable:!0,get:l[t]})},e.f={},e.e=a=>Promise.all(Object.keys(e.f).reduce((l,t)=>(e.f[t](a,l),l),[])),e.u=a=>"static/js/"+a+"."+{"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js":"ae03ad4d","vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js":"26af7616","webpack_sharing_consume_default_react_react-_7ec5":"dac6eaa6",webpack_sharing_consume_default_emotion_react_emotion_react:"ed1a1e4b","node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0":"c5be9b49","vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec":"79a3675c","vendors-node_modules_react-color_es_index_js":"1328581e","vendors-node_modules_iobroker_adapter-react-v5_build_index_js":"75d0a05c","webpack_sharing_consume_default_prop-types_prop-types":"4852a01b","webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de":"e1fec510",webpack_sharing_consume_default_mui_material_mui_material:"ab9c362b","vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45":"30bb5363","vendors-node_modules_mui_material_FilledInput_FilledInput_js":"40a32235","vendors-node_modules_iobroker_json-config_build_index_js":"55662d8c",webpack_sharing_consume_default_emotion_styled_emotion_styled:"eb1afab6","webpack_sharing_consume_default_react_react-_32c5":"7c1c16c8","webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5":"42b535ab","webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-5817e9":"bff38712",_91570:"15bdbac4","vendors-node_modules_mui_icons-material_esm_index_js":"e5b40573","vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4":"b1f6684a","vendors-node_modules_mui_material_index_js":"d9f15176","webpack_sharing_consume_default_react-dom_react-dom":"b2e87ff7","vendors-node_modules_iobroker_json-config_node_modules_mui_x-date-pickers_index_js":"44d15ac4","node_modules_prop-types_index_js":"a765d8ae","vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js":"719602b6","vendors-node_modules_iobroker_json-config_node_modules_react-dom_index_js":"4140484d","node_modules_react-dom_index_js-_ef070":"9ecb0641","vendors-node_modules_react-dropzone_dist_es_index_js":"78412bd9","node_modules_iobroker_json-config_node_modules_react_index_js":"3c398e75",node_modules_react_index_js:"91c83a35","webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config":"3abdbb8e",src_Components_jsx:"744d937a","node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1":"bed85796","vendors-node_modules_react-qr-code_lib_index_js":"38e93c56","node_modules_react-dom_index_js-_ef071":"0e7912f8",_91571:"4da47066"}[a]+".chunk.js",e.miniCssF=a=>{},e.g=function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch(a){if(typeof window=="object")return window}}(),e.o=(a,l)=>Object.prototype.hasOwnProperty.call(a,l),(()=>{var a={},l="@iobroker/admin-component-easy-access:";e.l=(t,m,p,f)=>{if(a[t]){a[t].push(m);return}var u,v;if(p!==void 0)for(var c=document.getElementsByTagName("script"),g=0;g{u.onerror=u.onload=null,clearTimeout(k);var y=a[t];if(delete a[t],u.parentNode&&u.parentNode.removeChild(u),y&&y.forEach(b=>b(P)),C)return C(P)},k=setTimeout(j.bind(null,void 0,{type:"timeout",target:u}),12e4);u.onerror=j.bind(null,u.onerror),u.onload=j.bind(null,u.onload),v&&document.head.appendChild(u)}})(),e.r=a=>{typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(a,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(a,"__esModule",{value:!0})},e.nmd=a=>(a.paths=[],a.children||(a.children=[]),a),(()=>{e.S={};var a={},l={};e.I=(t,m)=>{m||(m=[]);var p=l[t];if(p||(p=l[t]={}),!(m.indexOf(p)>=0)){if(m.push(p),a[t])return a[t];e.o(e.S,t)||(e.S[t]={});var f=e.S[t],u=j=>{typeof console!="undefined"&&console.warn&&console.warn(j)},v="@iobroker/admin-component-easy-access",c=(j,k,C,P)=>{var y=f[j]=f[j]||{},b=y[k];(!b||!b.loaded&&(!P!=!b.eager?P:v>b.from))&&(y[k]={get:C,from:v,eager:!!P})},g=j=>{var k=b=>u("Initialization of sharing external failed: "+b);try{var C=e(j);if(!C)return;var P=b=>b&&b.init&&b.init(e.S[t],m);if(C.then)return h.push(C.then(P,k));var y=P(C);if(y&&y.then)return h.push(y.catch(k))}catch(b){k(b)}},h=[];switch(t){case"default":c("@emotion/react","11.13.5",()=>Promise.all([e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js"),e.e("webpack_sharing_consume_default_react_react-_7ec5")]).then(()=>()=>e(1468))),c("@emotion/styled","11.13.5",()=>Promise.all([e.e("webpack_sharing_consume_default_react_react-_7ec5"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0")]).then(()=>()=>e(4578))),c("@iobroker/adapter-react-v5","7.4.3",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_adapter-react-v5_build_index_js"),e.e("webpack_sharing_consume_default_react_react-_7ec5"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de"),e.e("webpack_sharing_consume_default_mui_material_mui_material")]).then(()=>()=>e(8734))),c("@iobroker/json-config","7.4.3",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_json-config_build_index_js"),e.e("webpack_sharing_consume_default_react_react-_7ec5"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react_react-_32c5"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de"),e.e("webpack_sharing_consume_default_mui_material_mui_material"),e.e("webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5"),e.e("webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-5817e9"),e.e("_91570")]).then(()=>()=>e(9388))),c("@mui/icons-material","6.1.10",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_icons-material_esm_index_js"),e.e("webpack_sharing_consume_default_react_react-_7ec5"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled")]).then(()=>()=>e(1636))),c("@mui/material","6.1.10",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_mui_material_index_js"),e.e("webpack_sharing_consume_default_react_react-_7ec5"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom")]).then(()=>()=>e(2578))),c("@mui/x-date-pickers","7.23.1",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_iobroker_json-config_node_modules_mui_x-date-pickers_index_js"),e.e("webpack_sharing_consume_default_react_react-_7ec5"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react_react-_32c5"),e.e("webpack_sharing_consume_default_react-dom_react-dom")]).then(()=>()=>e(4198))),c("prop-types","15.8.1",()=>e.e("node_modules_prop-types_index_js").then(()=>()=>e(5826))),c("react-ace","13.0.0",()=>Promise.all([e.e("vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_react_react-_32c5")]).then(()=>()=>e(9017))),c("react-dom","18.3.1",()=>Promise.all([e.e("vendors-node_modules_iobroker_json-config_node_modules_react-dom_index_js"),e.e("webpack_sharing_consume_default_react_react-_32c5")]).then(()=>()=>e(6410))),c("react-dom","19.0.0",()=>Promise.all([e.e("webpack_sharing_consume_default_react_react-_7ec5"),e.e("node_modules_react-dom_index_js-_ef070")]).then(()=>()=>e(2483))),c("react-dropzone","14.3.5",()=>Promise.all([e.e("vendors-node_modules_react-dropzone_dist_es_index_js"),e.e("webpack_sharing_consume_default_react_react-_7ec5"),e.e("webpack_sharing_consume_default_prop-types_prop-types")]).then(()=>()=>e(5479))),c("react","18.3.1",()=>e.e("node_modules_iobroker_json-config_node_modules_react_index_js").then(()=>()=>e(9407))),c("react","19.0.0",()=>e.e("node_modules_react_index_js").then(()=>()=>e(7810)));break}return h.length?a[t]=Promise.all(h).then(()=>a[t]=1):a[t]=1}}})(),(()=>{var a;e.g.importScripts&&(a=e.g.location+"");var l=e.g.document;if(!a&&l&&(l.currentScript&&(a=l.currentScript.src),!a)){var t=l.getElementsByTagName("script");if(t.length)for(var m=t.length-1;m>-1&&(!a||!/^http(s?):/.test(a));)a=t[m--].src}if(!a)throw new Error("Automatic publicPath is not supported in this browser");a=a.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),e.p=a})(),(()=>{var a=o=>{var r=n=>n.split(".").map(s=>+s==s?+s:s),_=/^([^-+]+)?(?:-([^+]+))?(?:\+(.+))?$/.exec(o),i=_[1]?r(_[1]):[];return _[2]&&(i.length++,i.push.apply(i,r(_[2]))),_[3]&&(i.push([]),i.push.apply(i,r(_[3]))),i},l=(o,r)=>{o=a(o),r=a(r);for(var _=0;;){if(_>=o.length)return _=r.length)return n=="u";var s=r[_],d=(typeof s)[0];if(n!=d)return n=="o"&&d=="n"||d=="s"||n=="u";if(n!="o"&&n!="u"&&i!=s)return i{var r=o[0],_="";if(o.length===1)return"*";if(r+.5){_+=r==0?">=":r==-1?"<":r==1?"^":r==2?"~":r>0?"=":"!=";for(var i=1,n=1;n0?".":"")+(i=2,d);return _}var s=[];for(n=1;n{if(0 in o){r=a(r);var _=o[0],i=_<0;i&&(_=-_-1);for(var n=0,s=1,d=!0;;s++,n++){var w,E,S=s=r.length||(E=(typeof(w=r[n]))[0])=="o")return!d||(S=="u"?s>_&&!i:S==""!=i);if(E=="u"){if(!d||S!="u")return!1}else if(d)if(S==E)if(s<=_){if(w!=o[s])return!1}else{if(i?w>o[s]:wo&&e.o(o,r),f=o=>(o.loaded=1,o.get()),u=o=>Object.keys(o).reduce((r,_)=>(o[_].eager&&(r[_]=o[_]),r),{}),v=(o,n,_)=>{var i=_?u(o[n]):o[n],n=Object.keys(i).reduce((s,d)=>!s||l(s,d)?d:s,0);return n&&i[n]},c=(o,s,_,i)=>{var n=i?u(o[s]):o[s],s=Object.keys(n).reduce((d,w)=>m(_,w)&&(!d||l(d,w))?w:d,0);return s&&n[s]},g=(o,r,_)=>{var i=_?u(o[r]):o[r];return Object.keys(i).reduce((n,s)=>!n||!i[n].loaded&&l(n,s)?s:n,0)},h=(o,r,_,i)=>"Unsatisfied version "+_+" from "+(_&&o[r][_].from)+" of shared singleton module "+r+" (required "+t(i)+")",j=(o,r,_,i,n)=>{var s=o[_];return"No satisfying version ("+t(i)+")"+(n?" for eager consumption":"")+" of shared module "+_+" found in shared scope "+r+`. -Available versions: `+Object.keys(s).map(d=>d+" from "+s[d].from).join(", ")},k=o=>{throw new Error(o)},C=(o,r)=>k("Shared module "+r+" doesn't exist in shared scope "+o),P=o=>{typeof console!="undefined"&&console.warn&&console.warn(o)},y=o=>function(r,_,i,n,s){var d=e.I(r);return d&&d.then&&!i?d.then(o.bind(o,r,e.S[r],_,!1,n,s)):o(r,e.S[r],_,i,n,s)},b=(o,r,_)=>_?_():C(o,r),$=y((o,r,_,i,n)=>p(r,_)?f(v(r,_,i)):b(o,_,n)),L=y((o,r,_,i,n,s)=>{if(!p(r,_))return b(o,_,s);var d=c(r,_,n,i);return d?f(d):(P(j(r,o,_,n,i)),f(v(r,_,i)))}),U=y((o,r,_,i,n,s)=>{if(!p(r,_))return b(o,_,s);var d=c(r,_,n,i);if(d)return f(d);if(s)return s();k(j(r,o,_,n,i))}),G=y((o,r,_,i,n)=>{if(!p(r,_))return b(o,_,n);var s=g(r,_,i);return f(r[_][s])}),x=y((o,r,_,i,n,s)=>{if(!p(r,_))return b(o,_,s);var d=g(r,_,i);return m(n,d)||P(h(r,_,d,n)),f(r[_][d])}),H=y((o,r,_,i,n,s)=>{if(!p(r,_))return b(o,_,s);var d=g(r,_,i);return m(n,d)||k(h(r,_,d,n)),f(r[_][d])}),D={},I={8437:()=>x("default","react",!1,[0],()=>e.e("node_modules_react_index_js").then(()=>()=>e(7810))),5746:()=>x("default","@emotion/react",!1,[0],()=>Promise.all([e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js")]).then(()=>()=>e(1468))),5973:()=>x("default","prop-types",!1,[0],()=>e.e("node_modules_prop-types_index_js").then(()=>()=>e(5826))),1839:()=>x("default","@mui/icons-material",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_icons-material_esm_index_js"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled")]).then(()=>()=>e(1636))),3683:()=>x("default","react-dropzone",!1,[0],()=>e.e("vendors-node_modules_react-dropzone_dist_es_index_js").then(()=>()=>e(5479))),7085:()=>x("default","@mui/material",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_mui_material_index_js"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom")]).then(()=>()=>e(2578))),9702:()=>x("default","@emotion/styled",!1,[0],()=>e.e("node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1").then(()=>()=>e(4578))),590:()=>x("default","react",!1,[0],()=>e.e("node_modules_iobroker_json-config_node_modules_react_index_js").then(()=>()=>e(9407))),5636:()=>x("default","@iobroker/adapter-react-v5",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_adapter-react-v5_build_index_js"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de")]).then(()=>()=>e(8734))),4550:()=>x("default","@mui/x-date-pickers",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_iobroker_json-config_node_modules_mui_x-date-pickers_index_js"),e.e("webpack_sharing_consume_default_react-dom_react-dom")]).then(()=>()=>e(4198))),1222:()=>x("default","react-dom",!1,[0],()=>e.e("vendors-node_modules_iobroker_json-config_node_modules_react-dom_index_js").then(()=>()=>e(6410))),2514:()=>x("default","react-ace",!1,[0],()=>e.e("vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js").then(()=>()=>e(9017))),3479:()=>x("default","react-dom",!1,[0],()=>e.e("node_modules_react-dom_index_js-_ef071").then(()=>()=>e(2483))),556:()=>x("default","@iobroker/json-config",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_json-config_build_index_js"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react_react-_32c5"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de"),e.e("webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-5817e9"),e.e("_91571")]).then(()=>()=>e(9388)))},B={"webpack_sharing_consume_default_react_react-_7ec5":[8437],webpack_sharing_consume_default_emotion_react_emotion_react:[5746],"webpack_sharing_consume_default_prop-types_prop-types":[5973],"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de":[1839,3683],webpack_sharing_consume_default_mui_material_mui_material:[7085],webpack_sharing_consume_default_emotion_styled_emotion_styled:[9702],"webpack_sharing_consume_default_react_react-_32c5":[590],"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5":[5636],"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-5817e9":[4550,1222,2514],"webpack_sharing_consume_default_react-dom_react-dom":[3479],"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config":[556]},V={};e.f.consumes=(o,r)=>{e.o(B,o)&&B[o].forEach(_=>{if(e.o(D,_))return r.push(D[_]);if(!V[_]){var i=d=>{D[_]=0,e.m[_]=w=>{delete e.c[_],w.exports=d()}};V[_]=!0;var n=d=>{delete D[_],e.m[_]=w=>{throw delete e.c[_],d}};try{var s=I[_]();s.then?r.push(D[_]=s.then(i).catch(n)):i(s)}catch(d){n(d)}}})}})(),(()=>{var a={AdminComponentEasyAccessSet:0};e.f.j=(m,p)=>{var f=e.o(a,m)?a[m]:void 0;if(f!==0)if(f)p.push(f[2]);else if(/^webpack_sharing_consume_default_(emotion_(react_emotion_react|styled_emotion_styled)|iobroker_(adapter\-react\-v5_iobroker_adapter\-react\-v5|json\-config_iobroker_json\-config)|mui_(icons\-material_mui_icons\-material\-webpack_sharing_consume\-80e7de|material_mui_material|x\-date\-pickers_mui_x\-date\-pickers\-webpack_sharing_consume\-5817e9)|react(_react\-_(32|7e)c5|\-dom_react\-dom)|prop\-types_prop\-types)$/.test(m))a[m]=0;else{var u=new Promise((h,j)=>f=a[m]=[h,j]);p.push(f[2]=u);var v=e.p+e.u(m),c=new Error,g=h=>{if(e.o(a,m)&&(f=a[m],f!==0&&(a[m]=void 0),f)){var j=h&&(h.type==="load"?"missing":h.type),k=h&&h.target&&h.target.src;c.message="Loading chunk "+m+` failed. -(`+j+": "+k+")",c.name="ChunkLoadError",c.type=j,c.request=k,f[1](c)}};e.l(v,g,"chunk-"+m,m)}};var l=(m,p)=>{var f=p[0],u=p[1],v=p[2],c,g,h=0;if(f.some(k=>a[k]!==0)){for(c in u)e.o(u,c)&&(e.m[c]=u[c]);if(v)var j=v(e)}for(m&&m(p);h{"use strict";var A={3009:(a,l,t)=>{var m={"./Components":()=>Promise.all([t.e("webpack_sharing_consume_default_react_react"),t.e("webpack_sharing_consume_default_prop-types_prop-types"),t.e("webpack_sharing_consume_default_mui_material_mui_material"),t.e("webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5"),t.e("webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config"),t.e("src_Components_jsx")]).then(()=>()=>t(6128))},p=(u,b)=>(t.R=b,b=t.o(m,u)?m[u]():Promise.resolve().then(()=>{throw new Error('Module "'+u+'" does not exist in container.')}),t.R=void 0,b),f=(u,b)=>{if(t.S){var c="default",g=t.S[c];if(g&&g!==u)throw new Error("Container initialization failed as it has already been initialized with a different share scope");return t.S[c]=u,t.I(c,b)}};t.d(l,{get:()=>p,init:()=>f})}},M={};function e(a){var l=M[a];if(l!==void 0)return l.exports;var t=M[a]={id:a,loaded:!1,exports:{}};return A[a].call(t.exports,t,t.exports,e),t.loaded=!0,t.exports}e.m=A,e.c=M,e.amdD=function(){throw new Error("define cannot be used indirect")},e.n=a=>{var l=a&&a.__esModule?()=>a.default:()=>a;return e.d(l,{a:l}),l},e.d=(a,l)=>{for(var t in l)e.o(l,t)&&!e.o(a,t)&&Object.defineProperty(a,t,{enumerable:!0,get:l[t]})},e.f={},e.e=a=>Promise.all(Object.keys(e.f).reduce((l,t)=>(e.f[t](a,l),l),[])),e.u=a=>"static/js/"+a+"."+{"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js":"ae03ad4d","vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js":"26af7616",webpack_sharing_consume_default_react_react:"a0714c8d",webpack_sharing_consume_default_emotion_react_emotion_react:"ed1a1e4b","node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0":"c5be9b49","vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec":"79a3675c","vendors-node_modules_react-color_es_index_js":"4d1bf1cc","vendors-node_modules_iobroker_adapter-react-v5_build_index_js":"75d0a05c","webpack_sharing_consume_default_prop-types_prop-types":"4852a01b","webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de":"e1fec510",webpack_sharing_consume_default_mui_material_mui_material:"ab9c362b","vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45":"ca314fb3","vendors-node_modules_mui_material_FilledInput_FilledInput_js":"40a32235","vendors-node_modules_iobroker_json-config_build_index_js":"4ef5c4a7",webpack_sharing_consume_default_emotion_styled_emotion_styled:"eb1afab6","webpack_sharing_consume_default_react-dom_react-dom":"b2e87ff7","webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5":"42b535ab","webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d":"88a09f42",_91570:"15bdbac4","vendors-node_modules_mui_icons-material_esm_index_js":"e5b40573","vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4":"b1f6684a","vendors-node_modules_mui_material_index_js":"d9f15176","vendors-node_modules_mui_x-date-pickers_index_js":"e89ab137","node_modules_prop-types_index_js":"a765d8ae","vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js":"3a2375c7","vendors-node_modules_react-dom_index_js":"52629eb8","vendors-node_modules_react-dropzone_dist_es_index_js":"78412bd9",node_modules_react_index_js:"c3e3d81a","webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config":"3abdbb8e",src_Components_jsx:"744d937a","node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1":"bed85796","vendors-node_modules_react-qr-code_lib_index_js":"38e93c56",_91571:"4da47066"}[a]+".chunk.js",e.miniCssF=a=>{},e.g=function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch(a){if(typeof window=="object")return window}}(),e.o=(a,l)=>Object.prototype.hasOwnProperty.call(a,l),(()=>{var a={},l="@iobroker/admin-component-easy-access:";e.l=(t,m,p,f)=>{if(a[t]){a[t].push(m);return}var u,b;if(p!==void 0)for(var c=document.getElementsByTagName("script"),g=0;g{u.onerror=u.onload=null,clearTimeout(j);var y=a[t];if(delete a[t],u.parentNode&&u.parentNode.removeChild(u),y&&y.forEach(v=>v(x)),C)return C(x)},j=setTimeout(w.bind(null,void 0,{type:"timeout",target:u}),12e4);u.onerror=w.bind(null,u.onerror),u.onload=w.bind(null,u.onload),b&&document.head.appendChild(u)}})(),e.r=a=>{typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(a,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(a,"__esModule",{value:!0})},e.nmd=a=>(a.paths=[],a.children||(a.children=[]),a),(()=>{e.S={};var a={},l={};e.I=(t,m)=>{m||(m=[]);var p=l[t];if(p||(p=l[t]={}),!(m.indexOf(p)>=0)){if(m.push(p),a[t])return a[t];e.o(e.S,t)||(e.S[t]={});var f=e.S[t],u=w=>{typeof console!="undefined"&&console.warn&&console.warn(w)},b="@iobroker/admin-component-easy-access",c=(w,j,C,x)=>{var y=f[w]=f[w]||{},v=y[j];(!v||!v.loaded&&(!x!=!v.eager?x:b>v.from))&&(y[j]={get:C,from:b,eager:!!x})},g=w=>{var j=v=>u("Initialization of sharing external failed: "+v);try{var C=e(w);if(!C)return;var x=v=>v&&v.init&&v.init(e.S[t],m);if(C.then)return h.push(C.then(x,j));var y=x(C);if(y&&y.then)return h.push(y.catch(j))}catch(v){j(v)}},h=[];switch(t){case"default":c("@emotion/react","11.13.5",()=>Promise.all([e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js"),e.e("webpack_sharing_consume_default_react_react")]).then(()=>()=>e(1468))),c("@emotion/styled","11.13.5",()=>Promise.all([e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0")]).then(()=>()=>e(4578))),c("@iobroker/adapter-react-v5","7.4.3",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_adapter-react-v5_build_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de"),e.e("webpack_sharing_consume_default_mui_material_mui_material")]).then(()=>()=>e(8734))),c("@iobroker/json-config","7.4.3",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_json-config_build_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de"),e.e("webpack_sharing_consume_default_mui_material_mui_material"),e.e("webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5"),e.e("webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d"),e.e("_91570")]).then(()=>()=>e(9388))),c("@mui/icons-material","6.1.10",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_icons-material_esm_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled")]).then(()=>()=>e(1636))),c("@mui/material","6.1.10",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_mui_material_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom")]).then(()=>()=>e(2578))),c("@mui/x-date-pickers","7.23.1",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_mui_x-date-pickers_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom")]).then(()=>()=>e(7352))),c("prop-types","15.8.1",()=>e.e("node_modules_prop-types_index_js").then(()=>()=>e(5826))),c("react-ace","13.0.0",()=>Promise.all([e.e("vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types")]).then(()=>()=>e(9017))),c("react-dom","18.3.1",()=>Promise.all([e.e("vendors-node_modules_react-dom_index_js"),e.e("webpack_sharing_consume_default_react_react")]).then(()=>()=>e(2483))),c("react-dropzone","14.3.5",()=>Promise.all([e.e("vendors-node_modules_react-dropzone_dist_es_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types")]).then(()=>()=>e(5479))),c("react","18.3.1",()=>e.e("node_modules_react_index_js").then(()=>()=>e(7810)));break}return h.length?a[t]=Promise.all(h).then(()=>a[t]=1):a[t]=1}}})(),(()=>{var a;e.g.importScripts&&(a=e.g.location+"");var l=e.g.document;if(!a&&l&&(l.currentScript&&(a=l.currentScript.src),!a)){var t=l.getElementsByTagName("script");if(t.length)for(var m=t.length-1;m>-1&&(!a||!/^http(s?):/.test(a));)a=t[m--].src}if(!a)throw new Error("Automatic publicPath is not supported in this browser");a=a.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),e.p=a})(),(()=>{var a=o=>{var r=n=>n.split(".").map(s=>+s==s?+s:s),_=/^([^-+]+)?(?:-([^+]+))?(?:\+(.+))?$/.exec(o),i=_[1]?r(_[1]):[];return _[2]&&(i.length++,i.push.apply(i,r(_[2]))),_[3]&&(i.push([]),i.push.apply(i,r(_[3]))),i},l=(o,r)=>{o=a(o),r=a(r);for(var _=0;;){if(_>=o.length)return _=r.length)return n=="u";var s=r[_],d=(typeof s)[0];if(n!=d)return n=="o"&&d=="n"||d=="s"||n=="u";if(n!="o"&&n!="u"&&i!=s)return i{var r=o[0],_="";if(o.length===1)return"*";if(r+.5){_+=r==0?">=":r==-1?"<":r==1?"^":r==2?"~":r>0?"=":"!=";for(var i=1,n=1;n0?".":"")+(i=2,d);return _}var s=[];for(n=1;n{if(0 in o){r=a(r);var _=o[0],i=_<0;i&&(_=-_-1);for(var n=0,s=1,d=!0;;s++,n++){var k,E,S=s=r.length||(E=(typeof(k=r[n]))[0])=="o")return!d||(S=="u"?s>_&&!i:S==""!=i);if(E=="u"){if(!d||S!="u")return!1}else if(d)if(S==E)if(s<=_){if(k!=o[s])return!1}else{if(i?k>o[s]:ko&&e.o(o,r),f=o=>(o.loaded=1,o.get()),u=o=>Object.keys(o).reduce((r,_)=>(o[_].eager&&(r[_]=o[_]),r),{}),b=(o,n,_)=>{var i=_?u(o[n]):o[n],n=Object.keys(i).reduce((s,d)=>!s||l(s,d)?d:s,0);return n&&i[n]},c=(o,s,_,i)=>{var n=i?u(o[s]):o[s],s=Object.keys(n).reduce((d,k)=>m(_,k)&&(!d||l(d,k))?k:d,0);return s&&n[s]},g=(o,r,_)=>{var i=_?u(o[r]):o[r];return Object.keys(i).reduce((n,s)=>!n||!i[n].loaded&&l(n,s)?s:n,0)},h=(o,r,_,i)=>"Unsatisfied version "+_+" from "+(_&&o[r][_].from)+" of shared singleton module "+r+" (required "+t(i)+")",w=(o,r,_,i,n)=>{var s=o[_];return"No satisfying version ("+t(i)+")"+(n?" for eager consumption":"")+" of shared module "+_+" found in shared scope "+r+`. +Available versions: `+Object.keys(s).map(d=>d+" from "+s[d].from).join(", ")},j=o=>{throw new Error(o)},C=(o,r)=>j("Shared module "+r+" doesn't exist in shared scope "+o),x=o=>{typeof console!="undefined"&&console.warn&&console.warn(o)},y=o=>function(r,_,i,n,s){var d=e.I(r);return d&&d.then&&!i?d.then(o.bind(o,r,e.S[r],_,!1,n,s)):o(r,e.S[r],_,i,n,s)},v=(o,r,_)=>_?_():C(o,r),$=y((o,r,_,i,n)=>p(r,_)?f(b(r,_,i)):v(o,_,n)),L=y((o,r,_,i,n,s)=>{if(!p(r,_))return v(o,_,s);var d=c(r,_,n,i);return d?f(d):(x(w(r,o,_,n,i)),f(b(r,_,i)))}),U=y((o,r,_,i,n,s)=>{if(!p(r,_))return v(o,_,s);var d=c(r,_,n,i);if(d)return f(d);if(s)return s();j(w(r,o,_,n,i))}),G=y((o,r,_,i,n)=>{if(!p(r,_))return v(o,_,n);var s=g(r,_,i);return f(r[_][s])}),P=y((o,r,_,i,n,s)=>{if(!p(r,_))return v(o,_,s);var d=g(r,_,i);return m(n,d)||x(h(r,_,d,n)),f(r[_][d])}),H=y((o,r,_,i,n,s)=>{if(!p(r,_))return v(o,_,s);var d=g(r,_,i);return m(n,d)||j(h(r,_,d,n)),f(r[_][d])}),D={},I={8437:()=>P("default","react",!1,[0],()=>e.e("node_modules_react_index_js").then(()=>()=>e(7810))),5746:()=>P("default","@emotion/react",!1,[0],()=>Promise.all([e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js")]).then(()=>()=>e(1468))),5973:()=>P("default","prop-types",!1,[0],()=>e.e("node_modules_prop-types_index_js").then(()=>()=>e(5826))),1839:()=>P("default","@mui/icons-material",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_icons-material_esm_index_js"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled")]).then(()=>()=>e(1636))),3683:()=>P("default","react-dropzone",!1,[0],()=>e.e("vendors-node_modules_react-dropzone_dist_es_index_js").then(()=>()=>e(5479))),7085:()=>P("default","@mui/material",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_mui_material_index_js"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom")]).then(()=>()=>e(2578))),9702:()=>P("default","@emotion/styled",!1,[0],()=>e.e("node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1").then(()=>()=>e(4578))),3479:()=>P("default","react-dom",!1,[0],()=>e.e("vendors-node_modules_react-dom_index_js").then(()=>()=>e(2483))),5636:()=>P("default","@iobroker/adapter-react-v5",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_adapter-react-v5_build_index_js"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de")]).then(()=>()=>e(8734))),8497:()=>P("default","@mui/x-date-pickers",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_mui_x-date-pickers_index_js")]).then(()=>()=>e(7352))),2514:()=>P("default","react-ace",!1,[0],()=>e.e("vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js").then(()=>()=>e(9017))),556:()=>P("default","@iobroker/json-config",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_json-config_build_index_js"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de"),e.e("webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d"),e.e("_91571")]).then(()=>()=>e(9388)))},B={webpack_sharing_consume_default_react_react:[8437],webpack_sharing_consume_default_emotion_react_emotion_react:[5746],"webpack_sharing_consume_default_prop-types_prop-types":[5973],"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de":[1839,3683],webpack_sharing_consume_default_mui_material_mui_material:[7085],webpack_sharing_consume_default_emotion_styled_emotion_styled:[9702],"webpack_sharing_consume_default_react-dom_react-dom":[3479],"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5":[5636],"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d":[8497,2514],"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config":[556]},V={};e.f.consumes=(o,r)=>{e.o(B,o)&&B[o].forEach(_=>{if(e.o(D,_))return r.push(D[_]);if(!V[_]){var i=d=>{D[_]=0,e.m[_]=k=>{delete e.c[_],k.exports=d()}};V[_]=!0;var n=d=>{delete D[_],e.m[_]=k=>{throw delete e.c[_],d}};try{var s=I[_]();s.then?r.push(D[_]=s.then(i).catch(n)):i(s)}catch(d){n(d)}}})}})(),(()=>{var a={AdminComponentEasyAccessSet:0};e.f.j=(m,p)=>{var f=e.o(a,m)?a[m]:void 0;if(f!==0)if(f)p.push(f[2]);else if(/^webpack_sharing_consume_default_(emotion_(react_emotion_react|styled_emotion_styled)|iobroker_(adapter\-react\-v5_iobroker_adapter\-react\-v5|json\-config_iobroker_json\-config)|mui_(icons\-material_mui_icons\-material\-webpack_sharing_consume\-80e7de|material_mui_material|x\-date\-pickers_mui_x\-date\-pickers\-webpack_sharing_consume\-9f1a2d)|react(\-dom_react\-dom|_react)|prop\-types_prop\-types)$/.test(m))a[m]=0;else{var u=new Promise((h,w)=>f=a[m]=[h,w]);p.push(f[2]=u);var b=e.p+e.u(m),c=new Error,g=h=>{if(e.o(a,m)&&(f=a[m],f!==0&&(a[m]=void 0),f)){var w=h&&(h.type==="load"?"missing":h.type),j=h&&h.target&&h.target.src;c.message="Loading chunk "+m+` failed. +(`+w+": "+j+")",c.name="ChunkLoadError",c.type=w,c.request=j,f[1](c)}};e.l(b,g,"chunk-"+m,m)}};var l=(m,p)=>{var f=p[0],u=p[1],b=p[2],c,g,h=0;if(f.some(j=>a[j]!==0)){for(c in u)e.o(u,c)&&(e.m[c]=u[c]);if(b)var w=b(e)}for(m&&m(p);h {\n\t\treturn Promise.all([__webpack_require__.e(\"webpack_sharing_consume_default_react_react-_7ec5\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_material_mui_material\"), __webpack_require__.e(\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\"), __webpack_require__.e(\"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config\"), __webpack_require__.e(\"src_Components_jsx\")]).then(() => (() => ((__webpack_require__(6128)))));\n\t}\n};\nvar get = (module, getScope) => {\n\t__webpack_require__.R = getScope;\n\tgetScope = (\n\t\t__webpack_require__.o(moduleMap, module)\n\t\t\t? moduleMap[module]()\n\t\t\t: Promise.resolve().then(() => {\n\t\t\t\tthrow new Error('Module \"' + module + '\" does not exist in container.');\n\t\t\t})\n\t);\n\t__webpack_require__.R = undefined;\n\treturn getScope;\n};\nvar init = (shareScope, initScope) => {\n\tif (!__webpack_require__.S) return;\n\tvar name = \"default\"\n\tvar oldScope = __webpack_require__.S[name];\n\tif(oldScope && oldScope !== shareScope) throw new Error(\"Container initialization failed as it has already been initialized with a different share scope\");\n\t__webpack_require__.S[name] = shareScope;\n\treturn __webpack_require__.I(name, initScope);\n};\n\n// This exports getters to disallow modifications\n__webpack_require__.d(exports, {\n\tget: () => (get),\n\tinit: () => (init)\n});","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// expose the module cache\n__webpack_require__.c = __webpack_module_cache__;\n\n","__webpack_require__.amdD = function () {\n\tthrow new Error('define cannot be used indirect');\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"static/js/\" + chunkId + \".\" + {\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\":\"ae03ad4d\",\"vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js\":\"26af7616\",\"webpack_sharing_consume_default_react_react-_7ec5\":\"dac6eaa6\",\"webpack_sharing_consume_default_emotion_react_emotion_react\":\"ed1a1e4b\",\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0\":\"c5be9b49\",\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\":\"79a3675c\",\"vendors-node_modules_react-color_es_index_js\":\"1328581e\",\"vendors-node_modules_iobroker_adapter-react-v5_build_index_js\":\"75d0a05c\",\"webpack_sharing_consume_default_prop-types_prop-types\":\"4852a01b\",\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\":\"e1fec510\",\"webpack_sharing_consume_default_mui_material_mui_material\":\"ab9c362b\",\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\":\"30bb5363\",\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\":\"40a32235\",\"vendors-node_modules_iobroker_json-config_build_index_js\":\"55662d8c\",\"webpack_sharing_consume_default_emotion_styled_emotion_styled\":\"eb1afab6\",\"webpack_sharing_consume_default_react_react-_32c5\":\"7c1c16c8\",\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\":\"42b535ab\",\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-5817e9\":\"bff38712\",\"_91570\":\"15bdbac4\",\"vendors-node_modules_mui_icons-material_esm_index_js\":\"e5b40573\",\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\":\"b1f6684a\",\"vendors-node_modules_mui_material_index_js\":\"d9f15176\",\"webpack_sharing_consume_default_react-dom_react-dom\":\"b2e87ff7\",\"vendors-node_modules_iobroker_json-config_node_modules_mui_x-date-pickers_index_js\":\"44d15ac4\",\"node_modules_prop-types_index_js\":\"a765d8ae\",\"vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js\":\"719602b6\",\"vendors-node_modules_iobroker_json-config_node_modules_react-dom_index_js\":\"4140484d\",\"node_modules_react-dom_index_js-_ef070\":\"9ecb0641\",\"vendors-node_modules_react-dropzone_dist_es_index_js\":\"78412bd9\",\"node_modules_iobroker_json-config_node_modules_react_index_js\":\"3c398e75\",\"node_modules_react_index_js\":\"91c83a35\",\"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config\":\"3abdbb8e\",\"src_Components_jsx\":\"744d937a\",\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1\":\"bed85796\",\"vendors-node_modules_react-qr-code_lib_index_js\":\"38e93c56\",\"node_modules_react-dom_index_js-_ef071\":\"0e7912f8\",\"_91571\":\"4da47066\"}[chunkId] + \".chunk.js\";\n};","// This function allow to reference async chunks\n__webpack_require__.miniCssF = (chunkId) => {\n\t// return url for filenames based on template\n\treturn undefined;\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var inProgress = {};\nvar dataWebpackPrefix = \"@iobroker/admin-component-easy-access:\";\n// loadScript function to load a script via script tag\n__webpack_require__.l = (url, done, key, chunkId) => {\n\tif(inProgress[url]) { inProgress[url].push(done); return; }\n\tvar script, needAttach;\n\tif(key !== undefined) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tfor(var i = 0; i < scripts.length; i++) {\n\t\t\tvar s = scripts[i];\n\t\t\tif(s.getAttribute(\"src\") == url || s.getAttribute(\"data-webpack\") == dataWebpackPrefix + key) { script = s; break; }\n\t\t}\n\t}\n\tif(!script) {\n\t\tneedAttach = true;\n\t\tscript = document.createElement('script');\n\n\t\tscript.charset = 'utf-8';\n\t\tscript.timeout = 120;\n\t\tif (__webpack_require__.nc) {\n\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n\t\t}\n\t\tscript.setAttribute(\"data-webpack\", dataWebpackPrefix + key);\n\n\t\tscript.src = url;\n\t}\n\tinProgress[url] = [done];\n\tvar onScriptComplete = (prev, event) => {\n\t\t// avoid mem leaks in IE.\n\t\tscript.onerror = script.onload = null;\n\t\tclearTimeout(timeout);\n\t\tvar doneFns = inProgress[url];\n\t\tdelete inProgress[url];\n\t\tscript.parentNode && script.parentNode.removeChild(script);\n\t\tdoneFns && doneFns.forEach((fn) => (fn(event)));\n\t\tif(prev) return prev(event);\n\t}\n\tvar timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000);\n\tscript.onerror = onScriptComplete.bind(null, script.onerror);\n\tscript.onload = onScriptComplete.bind(null, script.onload);\n\tneedAttach && document.head.appendChild(script);\n};","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.S = {};\nvar initPromises = {};\nvar initTokens = {};\n__webpack_require__.I = (name, initScope) => {\n\tif(!initScope) initScope = [];\n\t// handling circular init calls\n\tvar initToken = initTokens[name];\n\tif(!initToken) initToken = initTokens[name] = {};\n\tif(initScope.indexOf(initToken) >= 0) return;\n\tinitScope.push(initToken);\n\t// only runs once\n\tif(initPromises[name]) return initPromises[name];\n\t// creates a new share scope if needed\n\tif(!__webpack_require__.o(__webpack_require__.S, name)) __webpack_require__.S[name] = {};\n\t// runs all init snippets from all modules reachable\n\tvar scope = __webpack_require__.S[name];\n\tvar warn = (msg) => {\n\t\tif (typeof console !== \"undefined\" && console.warn) console.warn(msg);\n\t};\n\tvar uniqueName = \"@iobroker/admin-component-easy-access\";\n\tvar register = (name, version, factory, eager) => {\n\t\tvar versions = scope[name] = scope[name] || {};\n\t\tvar activeVersion = versions[version];\n\t\tif(!activeVersion || (!activeVersion.loaded && (!eager != !activeVersion.eager ? eager : uniqueName > activeVersion.from))) versions[version] = { get: factory, from: uniqueName, eager: !!eager };\n\t};\n\tvar initExternal = (id) => {\n\t\tvar handleError = (err) => (warn(\"Initialization of sharing external failed: \" + err));\n\t\ttry {\n\t\t\tvar module = __webpack_require__(id);\n\t\t\tif(!module) return;\n\t\t\tvar initFn = (module) => (module && module.init && module.init(__webpack_require__.S[name], initScope))\n\t\t\tif(module.then) return promises.push(module.then(initFn, handleError));\n\t\t\tvar initResult = initFn(module);\n\t\t\tif(initResult && initResult.then) return promises.push(initResult['catch'](handleError));\n\t\t} catch(err) { handleError(err); }\n\t}\n\tvar promises = [];\n\tswitch(name) {\n\t\tcase \"default\": {\n\t\t\tregister(\"@emotion/react\", \"11.13.5\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_7ec5\")]).then(() => (() => (__webpack_require__(1468))))));\n\t\t\tregister(\"@emotion/styled\", \"11.13.5\", () => (Promise.all([__webpack_require__.e(\"webpack_sharing_consume_default_react_react-_7ec5\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0\")]).then(() => (() => (__webpack_require__(4578))))));\n\t\t\tregister(\"@iobroker/adapter-react-v5\", \"7.4.3\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_adapter-react-v5_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_7ec5\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_material_mui_material\")]).then(() => (() => (__webpack_require__(8734))))));\n\t\t\tregister(\"@iobroker/json-config\", \"7.4.3\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_json-config_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_7ec5\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_32c5\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_material_mui_material\"), __webpack_require__.e(\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-5817e9\"), __webpack_require__.e(\"_91570\")]).then(() => (() => (__webpack_require__(9388))))));\n\t\t\tregister(\"@mui/icons-material\", \"6.1.10\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_icons-material_esm_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_7ec5\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\")]).then(() => (() => (__webpack_require__(1636))))));\n\t\t\tregister(\"@mui/material\", \"6.1.10\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_7ec5\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\")]).then(() => (() => (__webpack_require__(2578))))));\n\t\t\tregister(\"@mui/x-date-pickers\", \"7.23.1\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_iobroker_json-config_node_modules_mui_x-date-pickers_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_7ec5\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_32c5\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\")]).then(() => (() => (__webpack_require__(4198))))));\n\t\t\tregister(\"prop-types\", \"15.8.1\", () => (__webpack_require__.e(\"node_modules_prop-types_index_js\").then(() => (() => (__webpack_require__(5826))))));\n\t\t\tregister(\"react-ace\", \"13.0.0\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_32c5\")]).then(() => (() => (__webpack_require__(9017))))));\n\t\t\tregister(\"react-dom\", \"18.3.1\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_iobroker_json-config_node_modules_react-dom_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_32c5\")]).then(() => (() => (__webpack_require__(6410))))));\n\t\t\tregister(\"react-dom\", \"19.0.0\", () => (Promise.all([__webpack_require__.e(\"webpack_sharing_consume_default_react_react-_7ec5\"), __webpack_require__.e(\"node_modules_react-dom_index_js-_ef070\")]).then(() => (() => (__webpack_require__(2483))))));\n\t\t\tregister(\"react-dropzone\", \"14.3.5\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_react-dropzone_dist_es_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_7ec5\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\")]).then(() => (() => (__webpack_require__(5479))))));\n\t\t\tregister(\"react\", \"18.3.1\", () => (__webpack_require__.e(\"node_modules_iobroker_json-config_node_modules_react_index_js\").then(() => (() => (__webpack_require__(9407))))));\n\t\t\tregister(\"react\", \"19.0.0\", () => (__webpack_require__.e(\"node_modules_react_index_js\").then(() => (() => (__webpack_require__(7810))))));\n\t\t}\n\t\tbreak;\n\t}\n\tif(!promises.length) return initPromises[name] = 1;\n\treturn initPromises[name] = Promise.all(promises).then(() => (initPromises[name] = 1));\n};","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","var parseVersion = (str) => {\n\t// see webpack/lib/util/semver.js for original code\n\tvar p=p=>{return p.split(\".\").map((p=>{return+p==p?+p:p}))},n=/^([^-+]+)?(?:-([^+]+))?(?:\\+(.+))?$/.exec(str),r=n[1]?p(n[1]):[];return n[2]&&(r.length++,r.push.apply(r,p(n[2]))),n[3]&&(r.push([]),r.push.apply(r,p(n[3]))),r;\n}\nvar versionLt = (a, b) => {\n\t// see webpack/lib/util/semver.js for original code\n\ta=parseVersion(a),b=parseVersion(b);for(var r=0;;){if(r>=a.length)return r=b.length)return\"u\"==n;var t=b[r],f=(typeof t)[0];if(n!=f)return\"o\"==n&&\"n\"==f||(\"s\"==f||\"u\"==n);if(\"o\"!=n&&\"u\"!=n&&e!=t)return e {\n\t// see webpack/lib/util/semver.js for original code\n\tvar r=range[0],n=\"\";if(1===range.length)return\"*\";if(r+.5){n+=0==r?\">=\":-1==r?\"<\":1==r?\"^\":2==r?\"~\":r>0?\"=\":\"!=\";for(var e=1,a=1;a0?\".\":\"\")+(e=2,t)}return n}var g=[];for(a=1;a {\n\t// see webpack/lib/util/semver.js for original code\n\tif(0 in range){version=parseVersion(version);var e=range[0],r=e<0;r&&(e=-e-1);for(var n=0,i=1,a=!0;;i++,n++){var f,s,g=i=version.length||\"o\"==(s=(typeof(f=version[n]))[0]))return!a||(\"u\"==g?i>e&&!r:\"\"==g!=r);if(\"u\"==s){if(!a||\"u\"!=g)return!1}else if(a)if(g==s)if(i<=e){if(f!=range[i])return!1}else{if(r?f>range[i]:f {\n\treturn scope && __webpack_require__.o(scope, key);\n}\nvar get = (entry) => {\n\tentry.loaded = 1;\n\treturn entry.get()\n};\nvar eagerOnly = (versions) => {\n\treturn Object.keys(versions).reduce((filtered, version) => {\n\t\t\tif (versions[version].eager) {\n\t\t\t\tfiltered[version] = versions[version];\n\t\t\t}\n\t\t\treturn filtered;\n\t}, {});\n};\nvar findLatestVersion = (scope, key, eager) => {\n\tvar versions = eager ? eagerOnly(scope[key]) : scope[key];\n\tvar key = Object.keys(versions).reduce((a, b) => {\n\t\treturn !a || versionLt(a, b) ? b : a;\n\t}, 0);\n\treturn key && versions[key];\n};\nvar findSatisfyingVersion = (scope, key, requiredVersion, eager) => {\n\tvar versions = eager ? eagerOnly(scope[key]) : scope[key];\n\tvar key = Object.keys(versions).reduce((a, b) => {\n\t\tif (!satisfy(requiredVersion, b)) return a;\n\t\treturn !a || versionLt(a, b) ? b : a;\n\t}, 0);\n\treturn key && versions[key]\n};\nvar findSingletonVersionKey = (scope, key, eager) => {\n\tvar versions = eager ? eagerOnly(scope[key]) : scope[key];\n\treturn Object.keys(versions).reduce((a, b) => {\n\t\treturn !a || (!versions[a].loaded && versionLt(a, b)) ? b : a;\n\t}, 0);\n};\nvar getInvalidSingletonVersionMessage = (scope, key, version, requiredVersion) => {\n\treturn \"Unsatisfied version \" + version + \" from \" + (version && scope[key][version].from) + \" of shared singleton module \" + key + \" (required \" + rangeToString(requiredVersion) + \")\"\n};\nvar getInvalidVersionMessage = (scope, scopeName, key, requiredVersion, eager) => {\n\tvar versions = scope[key];\n\treturn \"No satisfying version (\" + rangeToString(requiredVersion) + \")\" + (eager ? \" for eager consumption\" : \"\") + \" of shared module \" + key + \" found in shared scope \" + scopeName + \".\\n\" +\n\t\t\"Available versions: \" + Object.keys(versions).map((key) => {\n\t\treturn key + \" from \" + versions[key].from;\n\t}).join(\", \");\n};\nvar fail = (msg) => {\n\tthrow new Error(msg);\n}\nvar failAsNotExist = (scopeName, key) => {\n\treturn fail(\"Shared module \" + key + \" doesn't exist in shared scope \" + scopeName);\n}\nvar warn = /*#__PURE__*/ (msg) => {\n\tif (typeof console !== \"undefined\" && console.warn) console.warn(msg);\n};\nvar init = (fn) => (function(scopeName, key, eager, c, d) {\n\tvar promise = __webpack_require__.I(scopeName);\n\tif (promise && promise.then && !eager) {\n\t\treturn promise.then(fn.bind(fn, scopeName, __webpack_require__.S[scopeName], key, false, c, d));\n\t}\n\treturn fn(scopeName, __webpack_require__.S[scopeName], key, eager, c, d);\n});\n\nvar useFallback = (scopeName, key, fallback) => {\n\treturn fallback ? fallback() : failAsNotExist(scopeName, key);\n}\nvar load = /*#__PURE__*/ init((scopeName, scope, key, eager, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\treturn get(findLatestVersion(scope, key, eager));\n});\nvar loadVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar satisfyingVersion = findSatisfyingVersion(scope, key, requiredVersion, eager);\n\tif (satisfyingVersion) return get(satisfyingVersion);\n\twarn(getInvalidVersionMessage(scope, scopeName, key, requiredVersion, eager))\n\treturn get(findLatestVersion(scope, key, eager));\n});\nvar loadStrictVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar satisfyingVersion = findSatisfyingVersion(scope, key, requiredVersion, eager);\n\tif (satisfyingVersion) return get(satisfyingVersion);\n\tif (fallback) return fallback();\n\tfail(getInvalidVersionMessage(scope, scopeName, key, requiredVersion, eager));\n});\nvar loadSingleton = /*#__PURE__*/ init((scopeName, scope, key, eager, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar version = findSingletonVersionKey(scope, key, eager);\n\treturn get(scope[key][version]);\n});\nvar loadSingletonVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar version = findSingletonVersionKey(scope, key, eager);\n\tif (!satisfy(requiredVersion, version)) {\n\t\twarn(getInvalidSingletonVersionMessage(scope, key, version, requiredVersion));\n\t}\n\treturn get(scope[key][version]);\n});\nvar loadStrictSingletonVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar version = findSingletonVersionKey(scope, key, eager);\n\tif (!satisfy(requiredVersion, version)) {\n\t\tfail(getInvalidSingletonVersionMessage(scope, key, version, requiredVersion));\n\t}\n\treturn get(scope[key][version]);\n});\nvar installedModules = {};\nvar moduleToHandlerMapping = {\n\t8437: () => (loadSingletonVersion(\"default\", \"react\", false, [0], () => (__webpack_require__.e(\"node_modules_react_index_js\").then(() => (() => (__webpack_require__(7810))))))),\n\t5746: () => (loadSingletonVersion(\"default\", \"@emotion/react\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js\")]).then(() => (() => (__webpack_require__(1468))))))),\n\t5973: () => (loadSingletonVersion(\"default\", \"prop-types\", false, [0], () => (__webpack_require__.e(\"node_modules_prop-types_index_js\").then(() => (() => (__webpack_require__(5826))))))),\n\t1839: () => (loadSingletonVersion(\"default\", \"@mui/icons-material\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_icons-material_esm_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\")]).then(() => (() => (__webpack_require__(1636))))))),\n\t3683: () => (loadSingletonVersion(\"default\", \"react-dropzone\", false, [0], () => (__webpack_require__.e(\"vendors-node_modules_react-dropzone_dist_es_index_js\").then(() => (() => (__webpack_require__(5479))))))),\n\t7085: () => (loadSingletonVersion(\"default\", \"@mui/material\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\")]).then(() => (() => (__webpack_require__(2578))))))),\n\t9702: () => (loadSingletonVersion(\"default\", \"@emotion/styled\", false, [0], () => (__webpack_require__.e(\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1\").then(() => (() => (__webpack_require__(4578))))))),\n\t590: () => (loadSingletonVersion(\"default\", \"react\", false, [0], () => (__webpack_require__.e(\"node_modules_iobroker_json-config_node_modules_react_index_js\").then(() => (() => (__webpack_require__(9407))))))),\n\t5636: () => (loadSingletonVersion(\"default\", \"@iobroker/adapter-react-v5\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_adapter-react-v5_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\")]).then(() => (() => (__webpack_require__(8734))))))),\n\t4550: () => (loadSingletonVersion(\"default\", \"@mui/x-date-pickers\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_iobroker_json-config_node_modules_mui_x-date-pickers_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\")]).then(() => (() => (__webpack_require__(4198))))))),\n\t1222: () => (loadSingletonVersion(\"default\", \"react-dom\", false, [0], () => (__webpack_require__.e(\"vendors-node_modules_iobroker_json-config_node_modules_react-dom_index_js\").then(() => (() => (__webpack_require__(6410))))))),\n\t2514: () => (loadSingletonVersion(\"default\", \"react-ace\", false, [0], () => (__webpack_require__.e(\"vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js\").then(() => (() => (__webpack_require__(9017))))))),\n\t3479: () => (loadSingletonVersion(\"default\", \"react-dom\", false, [0], () => (__webpack_require__.e(\"node_modules_react-dom_index_js-_ef071\").then(() => (() => (__webpack_require__(2483))))))),\n\t556: () => (loadSingletonVersion(\"default\", \"@iobroker/json-config\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_json-config_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react-_32c5\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-5817e9\"), __webpack_require__.e(\"_91571\")]).then(() => (() => (__webpack_require__(9388)))))))\n};\n// no consumes in initial chunks\nvar chunkMapping = {\n\t\"webpack_sharing_consume_default_react_react-_7ec5\": [\n\t\t8437\n\t],\n\t\"webpack_sharing_consume_default_emotion_react_emotion_react\": [\n\t\t5746\n\t],\n\t\"webpack_sharing_consume_default_prop-types_prop-types\": [\n\t\t5973\n\t],\n\t\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\": [\n\t\t1839,\n\t\t3683\n\t],\n\t\"webpack_sharing_consume_default_mui_material_mui_material\": [\n\t\t7085\n\t],\n\t\"webpack_sharing_consume_default_emotion_styled_emotion_styled\": [\n\t\t9702\n\t],\n\t\"webpack_sharing_consume_default_react_react-_32c5\": [\n\t\t590\n\t],\n\t\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\": [\n\t\t5636\n\t],\n\t\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-5817e9\": [\n\t\t4550,\n\t\t1222,\n\t\t2514\n\t],\n\t\"webpack_sharing_consume_default_react-dom_react-dom\": [\n\t\t3479\n\t],\n\t\"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config\": [\n\t\t556\n\t]\n};\nvar startedInstallModules = {};\n__webpack_require__.f.consumes = (chunkId, promises) => {\n\tif(__webpack_require__.o(chunkMapping, chunkId)) {\n\t\tchunkMapping[chunkId].forEach((id) => {\n\t\t\tif(__webpack_require__.o(installedModules, id)) return promises.push(installedModules[id]);\n\t\t\tif(!startedInstallModules[id]) {\n\t\t\tvar onFactory = (factory) => {\n\t\t\t\tinstalledModules[id] = 0;\n\t\t\t\t__webpack_require__.m[id] = (module) => {\n\t\t\t\t\tdelete __webpack_require__.c[id];\n\t\t\t\t\tmodule.exports = factory();\n\t\t\t\t}\n\t\t\t};\n\t\t\tstartedInstallModules[id] = true;\n\t\t\tvar onError = (error) => {\n\t\t\t\tdelete installedModules[id];\n\t\t\t\t__webpack_require__.m[id] = (module) => {\n\t\t\t\t\tdelete __webpack_require__.c[id];\n\t\t\t\t\tthrow error;\n\t\t\t\t}\n\t\t\t};\n\t\t\ttry {\n\t\t\t\tvar promise = moduleToHandlerMapping[id]();\n\t\t\t\tif(promise.then) {\n\t\t\t\t\tpromises.push(installedModules[id] = promise.then(onFactory)['catch'](onError));\n\t\t\t\t} else onFactory(promise);\n\t\t\t} catch(e) { onError(e); }\n\t\t\t}\n\t\t});\n\t}\n}","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"AdminComponentEasyAccessSet\": 0\n};\n\n__webpack_require__.f.j = (chunkId, promises) => {\n\t\t// JSONP chunk loading for javascript\n\t\tvar installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined;\n\t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n\t\t\t// a Promise means \"currently loading\".\n\t\t\tif(installedChunkData) {\n\t\t\t\tpromises.push(installedChunkData[2]);\n\t\t\t} else {\n\t\t\t\tif(!/^webpack_sharing_consume_default_(emotion_(react_emotion_react|styled_emotion_styled)|iobroker_(adapter\\-react\\-v5_iobroker_adapter\\-react\\-v5|json\\-config_iobroker_json\\-config)|mui_(icons\\-material_mui_icons\\-material\\-webpack_sharing_consume\\-80e7de|material_mui_material|x\\-date\\-pickers_mui_x\\-date\\-pickers\\-webpack_sharing_consume\\-5817e9)|react(_react\\-_(32|7e)c5|\\-dom_react\\-dom)|prop\\-types_prop\\-types)$/.test(chunkId)) {\n\t\t\t\t\t// setup Promise in chunk cache\n\t\t\t\t\tvar promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject]));\n\t\t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n\t\t\t\t\t// start chunk loading\n\t\t\t\t\tvar url = __webpack_require__.p + __webpack_require__.u(chunkId);\n\t\t\t\t\t// create error before stack unwound to get useful stacktrace later\n\t\t\t\t\tvar error = new Error();\n\t\t\t\t\tvar loadingEnded = (event) => {\n\t\t\t\t\t\tif(__webpack_require__.o(installedChunks, chunkId)) {\n\t\t\t\t\t\t\tinstalledChunkData = installedChunks[chunkId];\n\t\t\t\t\t\t\tif(installedChunkData !== 0) installedChunks[chunkId] = undefined;\n\t\t\t\t\t\t\tif(installedChunkData) {\n\t\t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n\t\t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n\t\t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n\t\t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n\t\t\t\t\t\t\t\terror.type = errorType;\n\t\t\t\t\t\t\t\terror.request = realSrc;\n\t\t\t\t\t\t\t\tinstalledChunkData[1](error);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t\t__webpack_require__.l(url, loadingEnded, \"chunk-\" + chunkId, chunkId);\n\t\t\t\t} else installedChunks[chunkId] = 0;\n\t\t\t}\n\t\t}\n};\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n// no on chunks loaded\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunk_iobroker_admin_component_easy_access\"] = self[\"webpackChunk_iobroker_admin_component_easy_access\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","__webpack_require__.nc = undefined;","// module cache are used so entry inlining is disabled\n// startup\n// Load entry module and return exports\nvar __webpack_exports__ = __webpack_require__(3009);\n"],"names":["moduleMap","__webpack_require__","get","module","getScope","init","shareScope","initScope","name","oldScope","exports","__webpack_module_cache__","moduleId","cachedModule","__webpack_modules__","getter","definition","key","chunkId","promises","e","obj","prop","inProgress","dataWebpackPrefix","url","done","script","needAttach","scripts","i","s","onScriptComplete","prev","event","timeout","doneFns","fn","initPromises","initTokens","initToken","scope","warn","msg","uniqueName","register","version","factory","eager","versions","activeVersion","initExternal","id","handleError","err","initFn","initResult","scriptUrl","document","parseVersion","str","p","n","r","versionLt","a","b","t","f","rangeToString","range","g","o","satisfy","u","exists","entry","eagerOnly","filtered","findLatestVersion","findSatisfyingVersion","requiredVersion","findSingletonVersionKey","getInvalidSingletonVersionMessage","getInvalidVersionMessage","scopeName","fail","failAsNotExist","c","d","promise","useFallback","fallback","load","loadVersion","satisfyingVersion","loadStrictVersion","loadSingleton","loadSingletonVersion","loadStrictSingletonVersion","installedModules","moduleToHandlerMapping","chunkMapping","startedInstallModules","onFactory","onError","error","installedChunks","installedChunkData","resolve","reject","loadingEnded","errorType","realSrc","webpackJsonpCallback","parentChunkLoadingFunction","data","chunkIds","moreModules","runtime","result","chunkLoadingGlobal","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"customComponents.js","mappings":"yEAAA,IAAIA,EAAY,CACf,eAAgB,IACR,QAAQ,IAAI,CAACC,EAAoB,EAAE,6CAA6C,EAAGA,EA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P,EAAM,KAAO,iBACbA,EAAM,KAAOM,EACbN,EAAM,QAAUO,EAChBL,EAAmB,CAAC,EAAEF,CAAK,CAC5B,CAEF,EACAzG,EAAoB,EAAEwB,EAAKsF,EAAc,SAAW7F,EAASA,CAAO,CACrE,CAGJ,EAaA,IAAIgG,EAAuB,CAACC,EAA4BC,IAAS,CAChE,IAAIC,EAAWD,EAAK,CAAC,EACjBE,EAAcF,EAAK,CAAC,EACpBG,EAAUH,EAAK,CAAC,EAGhBxG,EAAUM,EAASY,EAAI,EAC3B,GAAGuF,EAAS,KAAMjE,GAAQuD,EAAgBvD,CAAE,IAAM,CAAE,EAAG,CACtD,IAAIxC,KAAY0G,EACZrH,EAAoB,EAAEqH,EAAa1G,CAAQ,IAC7CX,EAAoB,EAAEW,CAAQ,EAAI0G,EAAY1G,CAAQ,GAGxD,GAAG2G,EAAS,IAAIC,EAASD,EAAQtH,CAAmB,CACrD,CAEA,IADGkH,GAA4BA,EAA2BC,CAAI,EACzDtF,EAAIuF,EAAS,OAAQvF,IACzBZ,EAAUmG,EAASvF,CAAC,EACjB7B,EAAoB,EAAE0G,EAAiBzF,CAAO,GAAKyF,EAAgBzF,CAAO,GAC5EyF,EAAgBzF,CAAO,EAAE,CAAC,EAAE,EAE7ByF,EAAgBzF,CAAO,EAAI,CAG7B,EAEIuG,EAAqB,KAAK,kDAAuD,KAAK,mDAAwD,CAAC,EACnJA,EAAmB,QAAQP,EAAqB,KAAK,KAAM,CAAC,CAAC,EAC7DO,EAAmB,KAAOP,EAAqB,KAAK,KAAMO,EAAmB,KAAK,KAAKA,CAAkB,CAAC,C,KCvF1GxH,EAAoB,GAAK,OCGzB,IAAIyH,EAAsBzH,EAAoB,IAAI,E","sources":["../webpack/container-entry","../webpack/bootstrap","../webpack/runtime/amd define","../webpack/runtime/compat get default export","../webpack/runtime/define property getters","../webpack/runtime/ensure chunk","../webpack/runtime/get javascript chunk filename","../webpack/runtime/get mini-css chunk filename","../webpack/runtime/global","../webpack/runtime/hasOwnProperty shorthand","../webpack/runtime/load script","../webpack/runtime/make namespace object","../webpack/runtime/node module decorator","../webpack/runtime/sharing","../webpack/runtime/publicPath","../webpack/runtime/consumes","../webpack/runtime/jsonp chunk loading","../webpack/runtime/nonce","../webpack/startup"],"sourcesContent":["var moduleMap = {\n\t\"./Components\": () => {\n\t\treturn Promise.all([__webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_material_mui_material\"), __webpack_require__.e(\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\"), __webpack_require__.e(\"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config\"), __webpack_require__.e(\"src_Components_jsx\")]).then(() => (() => ((__webpack_require__(6128)))));\n\t}\n};\nvar get = (module, getScope) => {\n\t__webpack_require__.R = getScope;\n\tgetScope = (\n\t\t__webpack_require__.o(moduleMap, module)\n\t\t\t? moduleMap[module]()\n\t\t\t: Promise.resolve().then(() => {\n\t\t\t\tthrow new Error('Module \"' + module + '\" does not exist in container.');\n\t\t\t})\n\t);\n\t__webpack_require__.R = undefined;\n\treturn getScope;\n};\nvar init = (shareScope, initScope) => {\n\tif (!__webpack_require__.S) return;\n\tvar name = \"default\"\n\tvar oldScope = __webpack_require__.S[name];\n\tif(oldScope && oldScope !== shareScope) throw new Error(\"Container initialization failed as it has already been initialized with a different share scope\");\n\t__webpack_require__.S[name] = shareScope;\n\treturn __webpack_require__.I(name, initScope);\n};\n\n// This exports getters to disallow modifications\n__webpack_require__.d(exports, {\n\tget: () => (get),\n\tinit: () => (init)\n});","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// expose the module cache\n__webpack_require__.c = __webpack_module_cache__;\n\n","__webpack_require__.amdD = function () {\n\tthrow new Error('define cannot be used indirect');\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"static/js/\" + chunkId + \".\" + {\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\":\"ae03ad4d\",\"vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js\":\"26af7616\",\"webpack_sharing_consume_default_react_react\":\"a0714c8d\",\"webpack_sharing_consume_default_emotion_react_emotion_react\":\"ed1a1e4b\",\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0\":\"c5be9b49\",\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\":\"79a3675c\",\"vendors-node_modules_react-color_es_index_js\":\"4d1bf1cc\",\"vendors-node_modules_iobroker_adapter-react-v5_build_index_js\":\"75d0a05c\",\"webpack_sharing_consume_default_prop-types_prop-types\":\"4852a01b\",\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\":\"e1fec510\",\"webpack_sharing_consume_default_mui_material_mui_material\":\"ab9c362b\",\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\":\"ca314fb3\",\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\":\"40a32235\",\"vendors-node_modules_iobroker_json-config_build_index_js\":\"4ef5c4a7\",\"webpack_sharing_consume_default_emotion_styled_emotion_styled\":\"eb1afab6\",\"webpack_sharing_consume_default_react-dom_react-dom\":\"b2e87ff7\",\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\":\"42b535ab\",\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d\":\"88a09f42\",\"_91570\":\"15bdbac4\",\"vendors-node_modules_mui_icons-material_esm_index_js\":\"e5b40573\",\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\":\"b1f6684a\",\"vendors-node_modules_mui_material_index_js\":\"d9f15176\",\"vendors-node_modules_mui_x-date-pickers_index_js\":\"e89ab137\",\"node_modules_prop-types_index_js\":\"a765d8ae\",\"vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js\":\"3a2375c7\",\"vendors-node_modules_react-dom_index_js\":\"52629eb8\",\"vendors-node_modules_react-dropzone_dist_es_index_js\":\"78412bd9\",\"node_modules_react_index_js\":\"c3e3d81a\",\"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config\":\"3abdbb8e\",\"src_Components_jsx\":\"744d937a\",\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1\":\"bed85796\",\"vendors-node_modules_react-qr-code_lib_index_js\":\"38e93c56\",\"_91571\":\"4da47066\"}[chunkId] + \".chunk.js\";\n};","// This function allow to reference async chunks\n__webpack_require__.miniCssF = (chunkId) => {\n\t// return url for filenames based on template\n\treturn undefined;\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var inProgress = {};\nvar dataWebpackPrefix = \"@iobroker/admin-component-easy-access:\";\n// loadScript function to load a script via script tag\n__webpack_require__.l = (url, done, key, chunkId) => {\n\tif(inProgress[url]) { inProgress[url].push(done); return; }\n\tvar script, needAttach;\n\tif(key !== undefined) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tfor(var i = 0; i < scripts.length; i++) {\n\t\t\tvar s = scripts[i];\n\t\t\tif(s.getAttribute(\"src\") == url || s.getAttribute(\"data-webpack\") == dataWebpackPrefix + key) { script = s; break; }\n\t\t}\n\t}\n\tif(!script) {\n\t\tneedAttach = true;\n\t\tscript = document.createElement('script');\n\n\t\tscript.charset = 'utf-8';\n\t\tscript.timeout = 120;\n\t\tif (__webpack_require__.nc) {\n\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n\t\t}\n\t\tscript.setAttribute(\"data-webpack\", dataWebpackPrefix + key);\n\n\t\tscript.src = url;\n\t}\n\tinProgress[url] = [done];\n\tvar onScriptComplete = (prev, event) => {\n\t\t// avoid mem leaks in IE.\n\t\tscript.onerror = script.onload = null;\n\t\tclearTimeout(timeout);\n\t\tvar doneFns = inProgress[url];\n\t\tdelete inProgress[url];\n\t\tscript.parentNode && script.parentNode.removeChild(script);\n\t\tdoneFns && doneFns.forEach((fn) => (fn(event)));\n\t\tif(prev) return prev(event);\n\t}\n\tvar timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000);\n\tscript.onerror = onScriptComplete.bind(null, script.onerror);\n\tscript.onload = onScriptComplete.bind(null, script.onload);\n\tneedAttach && document.head.appendChild(script);\n};","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.S = {};\nvar initPromises = {};\nvar initTokens = {};\n__webpack_require__.I = (name, initScope) => {\n\tif(!initScope) initScope = [];\n\t// handling circular init calls\n\tvar initToken = initTokens[name];\n\tif(!initToken) initToken = initTokens[name] = {};\n\tif(initScope.indexOf(initToken) >= 0) return;\n\tinitScope.push(initToken);\n\t// only runs once\n\tif(initPromises[name]) return initPromises[name];\n\t// creates a new share scope if needed\n\tif(!__webpack_require__.o(__webpack_require__.S, name)) __webpack_require__.S[name] = {};\n\t// runs all init snippets from all modules reachable\n\tvar scope = __webpack_require__.S[name];\n\tvar warn = (msg) => {\n\t\tif (typeof console !== \"undefined\" && console.warn) console.warn(msg);\n\t};\n\tvar uniqueName = \"@iobroker/admin-component-easy-access\";\n\tvar register = (name, version, factory, eager) => {\n\t\tvar versions = scope[name] = scope[name] || {};\n\t\tvar activeVersion = versions[version];\n\t\tif(!activeVersion || (!activeVersion.loaded && (!eager != !activeVersion.eager ? eager : uniqueName > activeVersion.from))) versions[version] = { get: factory, from: uniqueName, eager: !!eager };\n\t};\n\tvar initExternal = (id) => {\n\t\tvar handleError = (err) => (warn(\"Initialization of sharing external failed: \" + err));\n\t\ttry {\n\t\t\tvar module = __webpack_require__(id);\n\t\t\tif(!module) return;\n\t\t\tvar initFn = (module) => (module && module.init && module.init(__webpack_require__.S[name], initScope))\n\t\t\tif(module.then) return promises.push(module.then(initFn, handleError));\n\t\t\tvar initResult = initFn(module);\n\t\t\tif(initResult && initResult.then) return promises.push(initResult['catch'](handleError));\n\t\t} catch(err) { handleError(err); }\n\t}\n\tvar promises = [];\n\tswitch(name) {\n\t\tcase \"default\": {\n\t\t\tregister(\"@emotion/react\", \"11.13.5\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\")]).then(() => (() => (__webpack_require__(1468))))));\n\t\t\tregister(\"@emotion/styled\", \"11.13.5\", () => (Promise.all([__webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0\")]).then(() => (() => (__webpack_require__(4578))))));\n\t\t\tregister(\"@iobroker/adapter-react-v5\", \"7.4.3\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_adapter-react-v5_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_material_mui_material\")]).then(() => (() => (__webpack_require__(8734))))));\n\t\t\tregister(\"@iobroker/json-config\", \"7.4.3\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_json-config_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_material_mui_material\"), __webpack_require__.e(\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d\"), __webpack_require__.e(\"_91570\")]).then(() => (() => (__webpack_require__(9388))))));\n\t\t\tregister(\"@mui/icons-material\", \"6.1.10\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_icons-material_esm_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\")]).then(() => (() => (__webpack_require__(1636))))));\n\t\t\tregister(\"@mui/material\", \"6.1.10\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\")]).then(() => (() => (__webpack_require__(2578))))));\n\t\t\tregister(\"@mui/x-date-pickers\", \"7.23.1\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_mui_x-date-pickers_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\")]).then(() => (() => (__webpack_require__(7352))))));\n\t\t\tregister(\"prop-types\", \"15.8.1\", () => (__webpack_require__.e(\"node_modules_prop-types_index_js\").then(() => (() => (__webpack_require__(5826))))));\n\t\t\tregister(\"react-ace\", \"13.0.0\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\")]).then(() => (() => (__webpack_require__(9017))))));\n\t\t\tregister(\"react-dom\", \"18.3.1\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_react-dom_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\")]).then(() => (() => (__webpack_require__(2483))))));\n\t\t\tregister(\"react-dropzone\", \"14.3.5\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_react-dropzone_dist_es_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\")]).then(() => (() => (__webpack_require__(5479))))));\n\t\t\tregister(\"react\", \"18.3.1\", () => (__webpack_require__.e(\"node_modules_react_index_js\").then(() => (() => (__webpack_require__(7810))))));\n\t\t}\n\t\tbreak;\n\t}\n\tif(!promises.length) return initPromises[name] = 1;\n\treturn initPromises[name] = Promise.all(promises).then(() => (initPromises[name] = 1));\n};","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","var parseVersion = (str) => {\n\t// see webpack/lib/util/semver.js for original code\n\tvar p=p=>{return p.split(\".\").map((p=>{return+p==p?+p:p}))},n=/^([^-+]+)?(?:-([^+]+))?(?:\\+(.+))?$/.exec(str),r=n[1]?p(n[1]):[];return n[2]&&(r.length++,r.push.apply(r,p(n[2]))),n[3]&&(r.push([]),r.push.apply(r,p(n[3]))),r;\n}\nvar versionLt = (a, b) => {\n\t// see webpack/lib/util/semver.js for original code\n\ta=parseVersion(a),b=parseVersion(b);for(var r=0;;){if(r>=a.length)return r=b.length)return\"u\"==n;var t=b[r],f=(typeof t)[0];if(n!=f)return\"o\"==n&&\"n\"==f||(\"s\"==f||\"u\"==n);if(\"o\"!=n&&\"u\"!=n&&e!=t)return e {\n\t// see webpack/lib/util/semver.js for original code\n\tvar r=range[0],n=\"\";if(1===range.length)return\"*\";if(r+.5){n+=0==r?\">=\":-1==r?\"<\":1==r?\"^\":2==r?\"~\":r>0?\"=\":\"!=\";for(var e=1,a=1;a0?\".\":\"\")+(e=2,t)}return n}var g=[];for(a=1;a {\n\t// see webpack/lib/util/semver.js for original code\n\tif(0 in range){version=parseVersion(version);var e=range[0],r=e<0;r&&(e=-e-1);for(var n=0,i=1,a=!0;;i++,n++){var f,s,g=i=version.length||\"o\"==(s=(typeof(f=version[n]))[0]))return!a||(\"u\"==g?i>e&&!r:\"\"==g!=r);if(\"u\"==s){if(!a||\"u\"!=g)return!1}else if(a)if(g==s)if(i<=e){if(f!=range[i])return!1}else{if(r?f>range[i]:f {\n\treturn scope && __webpack_require__.o(scope, key);\n}\nvar get = (entry) => {\n\tentry.loaded = 1;\n\treturn entry.get()\n};\nvar eagerOnly = (versions) => {\n\treturn Object.keys(versions).reduce((filtered, version) => {\n\t\t\tif (versions[version].eager) {\n\t\t\t\tfiltered[version] = versions[version];\n\t\t\t}\n\t\t\treturn filtered;\n\t}, {});\n};\nvar findLatestVersion = (scope, key, eager) => {\n\tvar versions = eager ? eagerOnly(scope[key]) : scope[key];\n\tvar key = Object.keys(versions).reduce((a, b) => {\n\t\treturn !a || versionLt(a, b) ? b : a;\n\t}, 0);\n\treturn key && versions[key];\n};\nvar findSatisfyingVersion = (scope, key, requiredVersion, eager) => {\n\tvar versions = eager ? eagerOnly(scope[key]) : scope[key];\n\tvar key = Object.keys(versions).reduce((a, b) => {\n\t\tif (!satisfy(requiredVersion, b)) return a;\n\t\treturn !a || versionLt(a, b) ? b : a;\n\t}, 0);\n\treturn key && versions[key]\n};\nvar findSingletonVersionKey = (scope, key, eager) => {\n\tvar versions = eager ? eagerOnly(scope[key]) : scope[key];\n\treturn Object.keys(versions).reduce((a, b) => {\n\t\treturn !a || (!versions[a].loaded && versionLt(a, b)) ? b : a;\n\t}, 0);\n};\nvar getInvalidSingletonVersionMessage = (scope, key, version, requiredVersion) => {\n\treturn \"Unsatisfied version \" + version + \" from \" + (version && scope[key][version].from) + \" of shared singleton module \" + key + \" (required \" + rangeToString(requiredVersion) + \")\"\n};\nvar getInvalidVersionMessage = (scope, scopeName, key, requiredVersion, eager) => {\n\tvar versions = scope[key];\n\treturn \"No satisfying version (\" + rangeToString(requiredVersion) + \")\" + (eager ? \" for eager consumption\" : \"\") + \" of shared module \" + key + \" found in shared scope \" + scopeName + \".\\n\" +\n\t\t\"Available versions: \" + Object.keys(versions).map((key) => {\n\t\treturn key + \" from \" + versions[key].from;\n\t}).join(\", \");\n};\nvar fail = (msg) => {\n\tthrow new Error(msg);\n}\nvar failAsNotExist = (scopeName, key) => {\n\treturn fail(\"Shared module \" + key + \" doesn't exist in shared scope \" + scopeName);\n}\nvar warn = /*#__PURE__*/ (msg) => {\n\tif (typeof console !== \"undefined\" && console.warn) console.warn(msg);\n};\nvar init = (fn) => (function(scopeName, key, eager, c, d) {\n\tvar promise = __webpack_require__.I(scopeName);\n\tif (promise && promise.then && !eager) {\n\t\treturn promise.then(fn.bind(fn, scopeName, __webpack_require__.S[scopeName], key, false, c, d));\n\t}\n\treturn fn(scopeName, __webpack_require__.S[scopeName], key, eager, c, d);\n});\n\nvar useFallback = (scopeName, key, fallback) => {\n\treturn fallback ? fallback() : failAsNotExist(scopeName, key);\n}\nvar load = /*#__PURE__*/ init((scopeName, scope, key, eager, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\treturn get(findLatestVersion(scope, key, eager));\n});\nvar loadVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar satisfyingVersion = findSatisfyingVersion(scope, key, requiredVersion, eager);\n\tif (satisfyingVersion) return get(satisfyingVersion);\n\twarn(getInvalidVersionMessage(scope, scopeName, key, requiredVersion, eager))\n\treturn get(findLatestVersion(scope, key, eager));\n});\nvar loadStrictVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar satisfyingVersion = findSatisfyingVersion(scope, key, requiredVersion, eager);\n\tif (satisfyingVersion) return get(satisfyingVersion);\n\tif (fallback) return fallback();\n\tfail(getInvalidVersionMessage(scope, scopeName, key, requiredVersion, eager));\n});\nvar loadSingleton = /*#__PURE__*/ init((scopeName, scope, key, eager, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar version = findSingletonVersionKey(scope, key, eager);\n\treturn get(scope[key][version]);\n});\nvar loadSingletonVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar version = findSingletonVersionKey(scope, key, eager);\n\tif (!satisfy(requiredVersion, version)) {\n\t\twarn(getInvalidSingletonVersionMessage(scope, key, version, requiredVersion));\n\t}\n\treturn get(scope[key][version]);\n});\nvar loadStrictSingletonVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar version = findSingletonVersionKey(scope, key, eager);\n\tif (!satisfy(requiredVersion, version)) {\n\t\tfail(getInvalidSingletonVersionMessage(scope, key, version, requiredVersion));\n\t}\n\treturn get(scope[key][version]);\n});\nvar installedModules = {};\nvar moduleToHandlerMapping = {\n\t8437: () => (loadSingletonVersion(\"default\", \"react\", false, [0], () => (__webpack_require__.e(\"node_modules_react_index_js\").then(() => (() => (__webpack_require__(7810))))))),\n\t5746: () => (loadSingletonVersion(\"default\", \"@emotion/react\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js\")]).then(() => (() => (__webpack_require__(1468))))))),\n\t5973: () => (loadSingletonVersion(\"default\", \"prop-types\", false, [0], () => (__webpack_require__.e(\"node_modules_prop-types_index_js\").then(() => (() => (__webpack_require__(5826))))))),\n\t1839: () => (loadSingletonVersion(\"default\", \"@mui/icons-material\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_icons-material_esm_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\")]).then(() => (() => (__webpack_require__(1636))))))),\n\t3683: () => (loadSingletonVersion(\"default\", \"react-dropzone\", false, [0], () => (__webpack_require__.e(\"vendors-node_modules_react-dropzone_dist_es_index_js\").then(() => (() => (__webpack_require__(5479))))))),\n\t7085: () => (loadSingletonVersion(\"default\", \"@mui/material\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\")]).then(() => (() => (__webpack_require__(2578))))))),\n\t9702: () => (loadSingletonVersion(\"default\", \"@emotion/styled\", false, [0], () => (__webpack_require__.e(\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1\").then(() => (() => (__webpack_require__(4578))))))),\n\t3479: () => (loadSingletonVersion(\"default\", \"react-dom\", false, [0], () => (__webpack_require__.e(\"vendors-node_modules_react-dom_index_js\").then(() => (() => (__webpack_require__(2483))))))),\n\t5636: () => (loadSingletonVersion(\"default\", \"@iobroker/adapter-react-v5\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_adapter-react-v5_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\")]).then(() => (() => (__webpack_require__(8734))))))),\n\t8497: () => (loadSingletonVersion(\"default\", \"@mui/x-date-pickers\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_mui_x-date-pickers_index_js\")]).then(() => (() => (__webpack_require__(7352))))))),\n\t2514: () => (loadSingletonVersion(\"default\", \"react-ace\", false, [0], () => (__webpack_require__.e(\"vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js\").then(() => (() => (__webpack_require__(9017))))))),\n\t556: () => (loadSingletonVersion(\"default\", \"@iobroker/json-config\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_json-config_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d\"), __webpack_require__.e(\"_91571\")]).then(() => (() => (__webpack_require__(9388)))))))\n};\n// no consumes in initial chunks\nvar chunkMapping = {\n\t\"webpack_sharing_consume_default_react_react\": [\n\t\t8437\n\t],\n\t\"webpack_sharing_consume_default_emotion_react_emotion_react\": [\n\t\t5746\n\t],\n\t\"webpack_sharing_consume_default_prop-types_prop-types\": [\n\t\t5973\n\t],\n\t\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\": [\n\t\t1839,\n\t\t3683\n\t],\n\t\"webpack_sharing_consume_default_mui_material_mui_material\": [\n\t\t7085\n\t],\n\t\"webpack_sharing_consume_default_emotion_styled_emotion_styled\": [\n\t\t9702\n\t],\n\t\"webpack_sharing_consume_default_react-dom_react-dom\": [\n\t\t3479\n\t],\n\t\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\": [\n\t\t5636\n\t],\n\t\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d\": [\n\t\t8497,\n\t\t2514\n\t],\n\t\"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config\": [\n\t\t556\n\t]\n};\nvar startedInstallModules = {};\n__webpack_require__.f.consumes = (chunkId, promises) => {\n\tif(__webpack_require__.o(chunkMapping, chunkId)) {\n\t\tchunkMapping[chunkId].forEach((id) => {\n\t\t\tif(__webpack_require__.o(installedModules, id)) return promises.push(installedModules[id]);\n\t\t\tif(!startedInstallModules[id]) {\n\t\t\tvar onFactory = (factory) => {\n\t\t\t\tinstalledModules[id] = 0;\n\t\t\t\t__webpack_require__.m[id] = (module) => {\n\t\t\t\t\tdelete __webpack_require__.c[id];\n\t\t\t\t\tmodule.exports = factory();\n\t\t\t\t}\n\t\t\t};\n\t\t\tstartedInstallModules[id] = true;\n\t\t\tvar onError = (error) => {\n\t\t\t\tdelete installedModules[id];\n\t\t\t\t__webpack_require__.m[id] = (module) => {\n\t\t\t\t\tdelete __webpack_require__.c[id];\n\t\t\t\t\tthrow error;\n\t\t\t\t}\n\t\t\t};\n\t\t\ttry {\n\t\t\t\tvar promise = moduleToHandlerMapping[id]();\n\t\t\t\tif(promise.then) {\n\t\t\t\t\tpromises.push(installedModules[id] = promise.then(onFactory)['catch'](onError));\n\t\t\t\t} else onFactory(promise);\n\t\t\t} catch(e) { onError(e); }\n\t\t\t}\n\t\t});\n\t}\n}","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"AdminComponentEasyAccessSet\": 0\n};\n\n__webpack_require__.f.j = (chunkId, promises) => {\n\t\t// JSONP chunk loading for javascript\n\t\tvar installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined;\n\t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n\t\t\t// a Promise means \"currently loading\".\n\t\t\tif(installedChunkData) {\n\t\t\t\tpromises.push(installedChunkData[2]);\n\t\t\t} else {\n\t\t\t\tif(!/^webpack_sharing_consume_default_(emotion_(react_emotion_react|styled_emotion_styled)|iobroker_(adapter\\-react\\-v5_iobroker_adapter\\-react\\-v5|json\\-config_iobroker_json\\-config)|mui_(icons\\-material_mui_icons\\-material\\-webpack_sharing_consume\\-80e7de|material_mui_material|x\\-date\\-pickers_mui_x\\-date\\-pickers\\-webpack_sharing_consume\\-9f1a2d)|react(\\-dom_react\\-dom|_react)|prop\\-types_prop\\-types)$/.test(chunkId)) {\n\t\t\t\t\t// setup Promise in chunk cache\n\t\t\t\t\tvar promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject]));\n\t\t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n\t\t\t\t\t// start chunk loading\n\t\t\t\t\tvar url = __webpack_require__.p + __webpack_require__.u(chunkId);\n\t\t\t\t\t// create error before stack unwound to get useful stacktrace later\n\t\t\t\t\tvar error = new Error();\n\t\t\t\t\tvar loadingEnded = (event) => {\n\t\t\t\t\t\tif(__webpack_require__.o(installedChunks, chunkId)) {\n\t\t\t\t\t\t\tinstalledChunkData = installedChunks[chunkId];\n\t\t\t\t\t\t\tif(installedChunkData !== 0) installedChunks[chunkId] = undefined;\n\t\t\t\t\t\t\tif(installedChunkData) {\n\t\t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n\t\t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n\t\t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n\t\t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n\t\t\t\t\t\t\t\terror.type = errorType;\n\t\t\t\t\t\t\t\terror.request = realSrc;\n\t\t\t\t\t\t\t\tinstalledChunkData[1](error);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t\t__webpack_require__.l(url, loadingEnded, \"chunk-\" + chunkId, chunkId);\n\t\t\t\t} else installedChunks[chunkId] = 0;\n\t\t\t}\n\t\t}\n};\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n// no on chunks loaded\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunk_iobroker_admin_component_easy_access\"] = self[\"webpackChunk_iobroker_admin_component_easy_access\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","__webpack_require__.nc = undefined;","// module cache are used so entry inlining is disabled\n// startup\n// Load entry module and return exports\nvar __webpack_exports__ = __webpack_require__(3009);\n"],"names":["moduleMap","__webpack_require__","get","module","getScope","init","shareScope","initScope","name","oldScope","exports","__webpack_module_cache__","moduleId","cachedModule","__webpack_modules__","getter","definition","key","chunkId","promises","e","obj","prop","inProgress","dataWebpackPrefix","url","done","script","needAttach","scripts","i","s","onScriptComplete","prev","event","timeout","doneFns","fn","initPromises","initTokens","initToken","scope","warn","msg","uniqueName","register","version","factory","eager","versions","activeVersion","initExternal","id","handleError","err","initFn","initResult","scriptUrl","document","parseVersion","str","p","n","r","versionLt","a","b","t","f","rangeToString","range","g","o","satisfy","u","exists","entry","eagerOnly","filtered","findLatestVersion","findSatisfyingVersion","requiredVersion","findSingletonVersionKey","getInvalidSingletonVersionMessage","getInvalidVersionMessage","scopeName","fail","failAsNotExist","c","d","promise","useFallback","fallback","load","loadVersion","satisfyingVersion","loadStrictVersion","loadSingleton","loadSingletonVersion","loadStrictSingletonVersion","installedModules","moduleToHandlerMapping","chunkMapping","startedInstallModules","onFactory","onError","error","installedChunks","installedChunkData","resolve","reject","loadingEnded","errorType","realSrc","webpackJsonpCallback","parentChunkLoadingFunction","data","chunkIds","moreModules","runtime","result","chunkLoadingGlobal","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file diff --git a/admin/custom/static/js/main.2904a78f.js b/admin/custom/static/js/main.2904a78f.js new file mode 100644 index 0000000..d509605 --- /dev/null +++ b/admin/custom/static/js/main.2904a78f.js @@ -0,0 +1,5 @@ +(()=>{var M={6046:(a,u,n)=>{Promise.all([n.e("webpack_sharing_consume_default_react_react"),n.e("webpack_sharing_consume_default_prop-types_prop-types"),n.e("webpack_sharing_consume_default_react-dom_react-dom"),n.e("webpack_sharing_consume_default_mui_material_mui_material"),n.e("webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5"),n.e("webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config"),n.e("src_bootstrap_jsx")]).then(n.bind(n,67))}},O={};function e(a){var u=O[a];if(u!==void 0)return u.exports;var n=O[a]={id:a,loaded:!1,exports:{}};return M[a].call(n.exports,n,n.exports,e),n.loaded=!0,n.exports}e.m=M,e.c=O,e.amdD=function(){throw new Error("define cannot be used indirect")},e.n=a=>{var u=a&&a.__esModule?()=>a.default:()=>a;return e.d(u,{a:u}),u},e.d=(a,u)=>{for(var n in u)e.o(u,n)&&!e.o(a,n)&&Object.defineProperty(a,n,{enumerable:!0,get:u[n]})},e.f={},e.e=a=>Promise.all(Object.keys(e.f).reduce((u,n)=>(e.f[n](a,u),u),[])),e.u=a=>"static/js/"+a+"."+{webpack_sharing_consume_default_react_react:"a0714c8d","webpack_sharing_consume_default_prop-types_prop-types":"4852a01b","webpack_sharing_consume_default_react-dom_react-dom":"b2e87ff7",webpack_sharing_consume_default_mui_material_mui_material:"ab9c362b","webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5":"42b535ab","webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config":"3abdbb8e",src_bootstrap_jsx:"d4a881b8","vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js":"ae03ad4d","vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js":"26af7616",webpack_sharing_consume_default_emotion_react_emotion_react:"ed1a1e4b","node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0":"c5be9b49","vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec":"79a3675c","vendors-node_modules_react-color_es_index_js":"4d1bf1cc","vendors-node_modules_iobroker_adapter-react-v5_build_index_js":"75d0a05c","webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de":"e1fec510","vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45":"ca314fb3","vendors-node_modules_mui_material_FilledInput_FilledInput_js":"40a32235","vendors-node_modules_iobroker_json-config_build_index_js":"4ef5c4a7",webpack_sharing_consume_default_emotion_styled_emotion_styled:"eb1afab6","webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d":"88a09f42",_91570:"15bdbac4","vendors-node_modules_mui_icons-material_esm_index_js":"e5b40573","vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4":"b1f6684a","vendors-node_modules_mui_material_index_js":"d9f15176","vendors-node_modules_mui_x-date-pickers_index_js":"e89ab137","node_modules_prop-types_index_js":"a765d8ae","vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js":"3a2375c7","vendors-node_modules_react-dom_index_js":"52629eb8","vendors-node_modules_react-dropzone_dist_es_index_js":"78412bd9",node_modules_react_index_js:"c3e3d81a",_91571:"4da47066","node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1":"bed85796","vendors-node_modules_react-qr-code_lib_index_js":"38e93c56"}[a]+".chunk.js",e.miniCssF=a=>{},e.g=function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch(a){if(typeof window=="object")return window}}(),e.o=(a,u)=>Object.prototype.hasOwnProperty.call(a,u),(()=>{var a={},u="@iobroker/admin-component-easy-access:";e.l=(n,l,h,f)=>{if(a[n]){a[n].push(l);return}var m,y;if(h!==void 0)for(var c=document.getElementsByTagName("script"),k=0;k{m.onerror=m.onload=null,clearTimeout(g);var j=a[n];if(delete a[n],m.parentNode&&m.parentNode.removeChild(m),j&&j.forEach(b=>b(x)),S)return S(x)},g=setTimeout(v.bind(null,void 0,{type:"timeout",target:m}),12e4);m.onerror=v.bind(null,m.onerror),m.onload=v.bind(null,m.onload),y&&document.head.appendChild(m)}})(),e.r=a=>{typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(a,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(a,"__esModule",{value:!0})},e.nmd=a=>(a.paths=[],a.children||(a.children=[]),a),(()=>{e.S={};var a={},u={};e.I=(n,l)=>{l||(l=[]);var h=u[n];if(h||(h=u[n]={}),!(l.indexOf(h)>=0)){if(l.push(h),a[n])return a[n];e.o(e.S,n)||(e.S[n]={});var f=e.S[n],m=v=>{typeof console!="undefined"&&console.warn&&console.warn(v)},y="@iobroker/admin-component-easy-access",c=(v,g,S,x)=>{var j=f[v]=f[v]||{},b=j[g];(!b||!b.loaded&&(!x!=!b.eager?x:y>b.from))&&(j[g]={get:S,from:y,eager:!!x})},k=v=>{var g=b=>m("Initialization of sharing external failed: "+b);try{var S=e(v);if(!S)return;var x=b=>b&&b.init&&b.init(e.S[n],l);if(S.then)return p.push(S.then(x,g));var j=x(S);if(j&&j.then)return p.push(j.catch(g))}catch(b){g(b)}},p=[];switch(n){case"default":c("@emotion/react","11.13.5",()=>Promise.all([e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js"),e.e("webpack_sharing_consume_default_react_react")]).then(()=>()=>e(1468))),c("@emotion/styled","11.13.5",()=>Promise.all([e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0")]).then(()=>()=>e(4578))),c("@iobroker/adapter-react-v5","7.4.3",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_adapter-react-v5_build_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de"),e.e("webpack_sharing_consume_default_mui_material_mui_material")]).then(()=>()=>e(8734))),c("@iobroker/json-config","7.4.3",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_json-config_build_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de"),e.e("webpack_sharing_consume_default_mui_material_mui_material"),e.e("webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5"),e.e("webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d"),e.e("_91570")]).then(()=>()=>e(9388))),c("@mui/icons-material","6.1.10",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_icons-material_esm_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled")]).then(()=>()=>e(1636))),c("@mui/material","6.1.10",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_mui_material_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom")]).then(()=>()=>e(2578))),c("@mui/x-date-pickers","7.23.1",()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_mui_x-date-pickers_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom")]).then(()=>()=>e(7352))),c("prop-types","15.8.1",()=>e.e("node_modules_prop-types_index_js").then(()=>()=>e(5826))),c("react-ace","13.0.0",()=>Promise.all([e.e("vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types")]).then(()=>()=>e(9017))),c("react-dom","18.3.1",()=>Promise.all([e.e("vendors-node_modules_react-dom_index_js"),e.e("webpack_sharing_consume_default_react_react")]).then(()=>()=>e(2483))),c("react-dropzone","14.3.5",()=>Promise.all([e.e("vendors-node_modules_react-dropzone_dist_es_index_js"),e.e("webpack_sharing_consume_default_react_react"),e.e("webpack_sharing_consume_default_prop-types_prop-types")]).then(()=>()=>e(5479))),c("react","18.3.1",()=>e.e("node_modules_react_index_js").then(()=>()=>e(7810)));break}return p.length?a[n]=Promise.all(p).then(()=>a[n]=1):a[n]=1}}})(),(()=>{var a;e.g.importScripts&&(a=e.g.location+"");var u=e.g.document;if(!a&&u&&(u.currentScript&&(a=u.currentScript.src),!a)){var n=u.getElementsByTagName("script");if(n.length)for(var l=n.length-1;l>-1&&(!a||!/^http(s?):/.test(a));)a=n[l--].src}if(!a)throw new Error("Automatic publicPath is not supported in this browser");a=a.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),e.p=a+"../../"})(),(()=>{var a=o=>{var r=t=>t.split(".").map(s=>+s==s?+s:s),_=/^([^-+]+)?(?:-([^+]+))?(?:\+(.+))?$/.exec(o),i=_[1]?r(_[1]):[];return _[2]&&(i.length++,i.push.apply(i,r(_[2]))),_[3]&&(i.push([]),i.push.apply(i,r(_[3]))),i},u=(o,r)=>{o=a(o),r=a(r);for(var _=0;;){if(_>=o.length)return _=r.length)return t=="u";var s=r[_],d=(typeof s)[0];if(t!=d)return t=="o"&&d=="n"||d=="s"||t=="u";if(t!="o"&&t!="u"&&i!=s)return i{var r=o[0],_="";if(o.length===1)return"*";if(r+.5){_+=r==0?">=":r==-1?"<":r==1?"^":r==2?"~":r>0?"=":"!=";for(var i=1,t=1;t0?".":"")+(i=2,d);return _}var s=[];for(t=1;t{if(0 in o){r=a(r);var _=o[0],i=_<0;i&&(_=-_-1);for(var t=0,s=1,d=!0;;s++,t++){var w,E,T=s=r.length||(E=(typeof(w=r[t]))[0])=="o")return!d||(T=="u"?s>_&&!i:T==""!=i);if(E=="u"){if(!d||T!="u")return!1}else if(d)if(T==E)if(s<=_){if(w!=o[s])return!1}else{if(i?w>o[s]:wo&&e.o(o,r),f=o=>(o.loaded=1,o.get()),m=o=>Object.keys(o).reduce((r,_)=>(o[_].eager&&(r[_]=o[_]),r),{}),y=(o,t,_)=>{var i=_?m(o[t]):o[t],t=Object.keys(i).reduce((s,d)=>!s||u(s,d)?d:s,0);return t&&i[t]},c=(o,s,_,i)=>{var t=i?m(o[s]):o[s],s=Object.keys(t).reduce((d,w)=>l(_,w)&&(!d||u(d,w))?w:d,0);return s&&t[s]},k=(o,r,_)=>{var i=_?m(o[r]):o[r];return Object.keys(i).reduce((t,s)=>!t||!i[t].loaded&&u(t,s)?s:t,0)},p=(o,r,_,i)=>"Unsatisfied version "+_+" from "+(_&&o[r][_].from)+" of shared singleton module "+r+" (required "+n(i)+")",v=(o,r,_,i,t)=>{var s=o[_];return"No satisfying version ("+n(i)+")"+(t?" for eager consumption":"")+" of shared module "+_+" found in shared scope "+r+`. +Available versions: `+Object.keys(s).map(d=>d+" from "+s[d].from).join(", ")},g=o=>{throw new Error(o)},S=(o,r)=>g("Shared module "+r+" doesn't exist in shared scope "+o),x=o=>{typeof console!="undefined"&&console.warn&&console.warn(o)},j=o=>function(r,_,i,t,s){var d=e.I(r);return d&&d.then&&!i?d.then(o.bind(o,r,e.S[r],_,!1,t,s)):o(r,e.S[r],_,i,t,s)},b=(o,r,_)=>_?_():S(o,r),z=j((o,r,_,i,t)=>h(r,_)?f(y(r,_,i)):b(o,_,t)),L=j((o,r,_,i,t,s)=>{if(!h(r,_))return b(o,_,s);var d=c(r,_,t,i);return d?f(d):(x(v(r,o,_,t,i)),f(y(r,_,i)))}),U=j((o,r,_,i,t,s)=>{if(!h(r,_))return b(o,_,s);var d=c(r,_,t,i);if(d)return f(d);if(s)return s();g(v(r,o,_,t,i))}),G=j((o,r,_,i,t)=>{if(!h(r,_))return b(o,_,t);var s=k(r,_,i);return f(r[_][s])}),P=j((o,r,_,i,t,s)=>{if(!h(r,_))return b(o,_,s);var d=k(r,_,i);return l(t,d)||x(p(r,_,d,t)),f(r[_][d])}),H=j((o,r,_,i,t,s)=>{if(!h(r,_))return b(o,_,s);var d=k(r,_,i);return l(t,d)||g(p(r,_,d,t)),f(r[_][d])}),D={},I={8437:()=>P("default","react",!1,[0],()=>e.e("node_modules_react_index_js").then(()=>()=>e(7810))),5973:()=>P("default","prop-types",!1,[0],()=>e.e("node_modules_prop-types_index_js").then(()=>()=>e(5826))),3479:()=>P("default","react-dom",!1,[0],()=>e.e("vendors-node_modules_react-dom_index_js").then(()=>()=>e(2483))),7085:()=>P("default","@mui/material",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_mui_material_index_js"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom")]).then(()=>()=>e(2578))),5636:()=>P("default","@iobroker/adapter-react-v5",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_adapter-react-v5_build_index_js"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de")]).then(()=>()=>e(8734))),556:()=>P("default","@iobroker/json-config",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec"),e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_material_FilledInput_FilledInput_js"),e.e("vendors-node_modules_react-color_es_index_js"),e.e("vendors-node_modules_iobroker_json-config_build_index_js"),e.e("webpack_sharing_consume_default_emotion_react_emotion_react"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled"),e.e("webpack_sharing_consume_default_react-dom_react-dom"),e.e("webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de"),e.e("webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d"),e.e("_91571")]).then(()=>()=>e(9388))),5746:()=>P("default","@emotion/react",!1,[0],()=>Promise.all([e.e("vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js"),e.e("vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js")]).then(()=>()=>e(1468))),1839:()=>P("default","@mui/icons-material",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"),e.e("vendors-node_modules_mui_icons-material_esm_index_js"),e.e("webpack_sharing_consume_default_emotion_styled_emotion_styled")]).then(()=>()=>e(1636))),3683:()=>P("default","react-dropzone",!1,[0],()=>e.e("vendors-node_modules_react-dropzone_dist_es_index_js").then(()=>()=>e(5479))),9702:()=>P("default","@emotion/styled",!1,[0],()=>e.e("node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1").then(()=>()=>e(4578))),8497:()=>P("default","@mui/x-date-pickers",!1,[0],()=>Promise.all([e.e("vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4"),e.e("vendors-node_modules_mui_x-date-pickers_index_js")]).then(()=>()=>e(7352))),2514:()=>P("default","react-ace",!1,[0],()=>e.e("vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js").then(()=>()=>e(9017)))},V={webpack_sharing_consume_default_react_react:[8437],"webpack_sharing_consume_default_prop-types_prop-types":[5973],"webpack_sharing_consume_default_react-dom_react-dom":[3479],webpack_sharing_consume_default_mui_material_mui_material:[7085],"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5":[5636],"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config":[556],webpack_sharing_consume_default_emotion_react_emotion_react:[5746],"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de":[1839,3683],webpack_sharing_consume_default_emotion_styled_emotion_styled:[9702],"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d":[8497,2514]},A={};e.f.consumes=(o,r)=>{e.o(V,o)&&V[o].forEach(_=>{if(e.o(D,_))return r.push(D[_]);if(!A[_]){var i=d=>{D[_]=0,e.m[_]=w=>{delete e.c[_],w.exports=d()}};A[_]=!0;var t=d=>{delete D[_],e.m[_]=w=>{throw delete e.c[_],d}};try{var s=I[_]();s.then?r.push(D[_]=s.then(i).catch(t)):i(s)}catch(d){t(d)}}})}})(),(()=>{var a={main:0};e.f.j=(l,h)=>{var f=e.o(a,l)?a[l]:void 0;if(f!==0)if(f)h.push(f[2]);else if(/^webpack_sharing_consume_default_(emotion_(react_emotion_react|styled_emotion_styled)|iobroker_(adapter\-react\-v5_iobroker_adapter\-react\-v5|json\-config_iobroker_json\-config)|mui_(icons\-material_mui_icons\-material\-webpack_sharing_consume\-80e7de|material_mui_material|x\-date\-pickers_mui_x\-date\-pickers\-webpack_sharing_consume\-9f1a2d)|react(\-dom_react\-dom|_react)|prop\-types_prop\-types)$/.test(l))a[l]=0;else{var m=new Promise((p,v)=>f=a[l]=[p,v]);h.push(f[2]=m);var y=e.p+e.u(l),c=new Error,k=p=>{if(e.o(a,l)&&(f=a[l],f!==0&&(a[l]=void 0),f)){var v=p&&(p.type==="load"?"missing":p.type),g=p&&p.target&&p.target.src;c.message="Loading chunk "+l+` failed. +(`+v+": "+g+")",c.name="ChunkLoadError",c.type=v,c.request=g,f[1](c)}};e.l(y,k,"chunk-"+l,l)}};var u=(l,h)=>{var f=h[0],m=h[1],y=h[2],c,k,p=0;if(f.some(g=>a[g]!==0)){for(c in m)e.o(m,c)&&(e.m[c]=m[c]);if(y)var v=y(e)}for(l&&l(h);p {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"static/js/\" + chunkId + \".\" + {\"webpack_sharing_consume_default_react_react\":\"a0714c8d\",\"webpack_sharing_consume_default_prop-types_prop-types\":\"4852a01b\",\"webpack_sharing_consume_default_react-dom_react-dom\":\"b2e87ff7\",\"webpack_sharing_consume_default_mui_material_mui_material\":\"ab9c362b\",\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\":\"42b535ab\",\"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config\":\"3abdbb8e\",\"src_bootstrap_jsx\":\"d4a881b8\",\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\":\"ae03ad4d\",\"vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js\":\"26af7616\",\"webpack_sharing_consume_default_emotion_react_emotion_react\":\"ed1a1e4b\",\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0\":\"c5be9b49\",\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\":\"79a3675c\",\"vendors-node_modules_react-color_es_index_js\":\"4d1bf1cc\",\"vendors-node_modules_iobroker_adapter-react-v5_build_index_js\":\"75d0a05c\",\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\":\"e1fec510\",\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\":\"ca314fb3\",\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\":\"40a32235\",\"vendors-node_modules_iobroker_json-config_build_index_js\":\"4ef5c4a7\",\"webpack_sharing_consume_default_emotion_styled_emotion_styled\":\"eb1afab6\",\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d\":\"88a09f42\",\"_91570\":\"15bdbac4\",\"vendors-node_modules_mui_icons-material_esm_index_js\":\"e5b40573\",\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\":\"b1f6684a\",\"vendors-node_modules_mui_material_index_js\":\"d9f15176\",\"vendors-node_modules_mui_x-date-pickers_index_js\":\"e89ab137\",\"node_modules_prop-types_index_js\":\"a765d8ae\",\"vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js\":\"3a2375c7\",\"vendors-node_modules_react-dom_index_js\":\"52629eb8\",\"vendors-node_modules_react-dropzone_dist_es_index_js\":\"78412bd9\",\"node_modules_react_index_js\":\"c3e3d81a\",\"_91571\":\"4da47066\",\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1\":\"bed85796\",\"vendors-node_modules_react-qr-code_lib_index_js\":\"38e93c56\"}[chunkId] + \".chunk.js\";\n};","// This function allow to reference async chunks\n__webpack_require__.miniCssF = (chunkId) => {\n\t// return url for filenames based on template\n\treturn undefined;\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var inProgress = {};\nvar dataWebpackPrefix = \"@iobroker/admin-component-easy-access:\";\n// loadScript function to load a script via script tag\n__webpack_require__.l = (url, done, key, chunkId) => {\n\tif(inProgress[url]) { inProgress[url].push(done); return; }\n\tvar script, needAttach;\n\tif(key !== undefined) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tfor(var i = 0; i < scripts.length; i++) {\n\t\t\tvar s = scripts[i];\n\t\t\tif(s.getAttribute(\"src\") == url || s.getAttribute(\"data-webpack\") == dataWebpackPrefix + key) { script = s; break; }\n\t\t}\n\t}\n\tif(!script) {\n\t\tneedAttach = true;\n\t\tscript = document.createElement('script');\n\n\t\tscript.charset = 'utf-8';\n\t\tscript.timeout = 120;\n\t\tif (__webpack_require__.nc) {\n\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n\t\t}\n\t\tscript.setAttribute(\"data-webpack\", dataWebpackPrefix + key);\n\n\t\tscript.src = url;\n\t}\n\tinProgress[url] = [done];\n\tvar onScriptComplete = (prev, event) => {\n\t\t// avoid mem leaks in IE.\n\t\tscript.onerror = script.onload = null;\n\t\tclearTimeout(timeout);\n\t\tvar doneFns = inProgress[url];\n\t\tdelete inProgress[url];\n\t\tscript.parentNode && script.parentNode.removeChild(script);\n\t\tdoneFns && doneFns.forEach((fn) => (fn(event)));\n\t\tif(prev) return prev(event);\n\t}\n\tvar timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000);\n\tscript.onerror = onScriptComplete.bind(null, script.onerror);\n\tscript.onload = onScriptComplete.bind(null, script.onload);\n\tneedAttach && document.head.appendChild(script);\n};","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.S = {};\nvar initPromises = {};\nvar initTokens = {};\n__webpack_require__.I = (name, initScope) => {\n\tif(!initScope) initScope = [];\n\t// handling circular init calls\n\tvar initToken = initTokens[name];\n\tif(!initToken) initToken = initTokens[name] = {};\n\tif(initScope.indexOf(initToken) >= 0) return;\n\tinitScope.push(initToken);\n\t// only runs once\n\tif(initPromises[name]) return initPromises[name];\n\t// creates a new share scope if needed\n\tif(!__webpack_require__.o(__webpack_require__.S, name)) __webpack_require__.S[name] = {};\n\t// runs all init snippets from all modules reachable\n\tvar scope = __webpack_require__.S[name];\n\tvar warn = (msg) => {\n\t\tif (typeof console !== \"undefined\" && console.warn) console.warn(msg);\n\t};\n\tvar uniqueName = \"@iobroker/admin-component-easy-access\";\n\tvar register = (name, version, factory, eager) => {\n\t\tvar versions = scope[name] = scope[name] || {};\n\t\tvar activeVersion = versions[version];\n\t\tif(!activeVersion || (!activeVersion.loaded && (!eager != !activeVersion.eager ? eager : uniqueName > activeVersion.from))) versions[version] = { get: factory, from: uniqueName, eager: !!eager };\n\t};\n\tvar initExternal = (id) => {\n\t\tvar handleError = (err) => (warn(\"Initialization of sharing external failed: \" + err));\n\t\ttry {\n\t\t\tvar module = __webpack_require__(id);\n\t\t\tif(!module) return;\n\t\t\tvar initFn = (module) => (module && module.init && module.init(__webpack_require__.S[name], initScope))\n\t\t\tif(module.then) return promises.push(module.then(initFn, handleError));\n\t\t\tvar initResult = initFn(module);\n\t\t\tif(initResult && initResult.then) return promises.push(initResult['catch'](handleError));\n\t\t} catch(err) { handleError(err); }\n\t}\n\tvar promises = [];\n\tswitch(name) {\n\t\tcase \"default\": {\n\t\t\tregister(\"@emotion/react\", \"11.13.5\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\")]).then(() => (() => (__webpack_require__(1468))))));\n\t\t\tregister(\"@emotion/styled\", \"11.13.5\", () => (Promise.all([__webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c0\")]).then(() => (() => (__webpack_require__(4578))))));\n\t\t\tregister(\"@iobroker/adapter-react-v5\", \"7.4.3\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_adapter-react-v5_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_material_mui_material\")]).then(() => (() => (__webpack_require__(8734))))));\n\t\t\tregister(\"@iobroker/json-config\", \"7.4.3\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_json-config_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_material_mui_material\"), __webpack_require__.e(\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d\"), __webpack_require__.e(\"_91570\")]).then(() => (() => (__webpack_require__(9388))))));\n\t\t\tregister(\"@mui/icons-material\", \"6.1.10\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_icons-material_esm_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\")]).then(() => (() => (__webpack_require__(1636))))));\n\t\t\tregister(\"@mui/material\", \"6.1.10\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\")]).then(() => (() => (__webpack_require__(2578))))));\n\t\t\tregister(\"@mui/x-date-pickers\", \"7.23.1\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_mui_x-date-pickers_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\")]).then(() => (() => (__webpack_require__(7352))))));\n\t\t\tregister(\"prop-types\", \"15.8.1\", () => (__webpack_require__.e(\"node_modules_prop-types_index_js\").then(() => (() => (__webpack_require__(5826))))));\n\t\t\tregister(\"react-ace\", \"13.0.0\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\")]).then(() => (() => (__webpack_require__(9017))))));\n\t\t\tregister(\"react-dom\", \"18.3.1\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_react-dom_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\")]).then(() => (() => (__webpack_require__(2483))))));\n\t\t\tregister(\"react-dropzone\", \"14.3.5\", () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_react-dropzone_dist_es_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_react_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_prop-types_prop-types\")]).then(() => (() => (__webpack_require__(5479))))));\n\t\t\tregister(\"react\", \"18.3.1\", () => (__webpack_require__.e(\"node_modules_react_index_js\").then(() => (() => (__webpack_require__(7810))))));\n\t\t}\n\t\tbreak;\n\t}\n\tif(!promises.length) return initPromises[name] = 1;\n\treturn initPromises[name] = Promise.all(promises).then(() => (initPromises[name] = 1));\n};","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl + \"../../\";","var parseVersion = (str) => {\n\t// see webpack/lib/util/semver.js for original code\n\tvar p=p=>{return p.split(\".\").map((p=>{return+p==p?+p:p}))},n=/^([^-+]+)?(?:-([^+]+))?(?:\\+(.+))?$/.exec(str),r=n[1]?p(n[1]):[];return n[2]&&(r.length++,r.push.apply(r,p(n[2]))),n[3]&&(r.push([]),r.push.apply(r,p(n[3]))),r;\n}\nvar versionLt = (a, b) => {\n\t// see webpack/lib/util/semver.js for original code\n\ta=parseVersion(a),b=parseVersion(b);for(var r=0;;){if(r>=a.length)return r=b.length)return\"u\"==n;var t=b[r],f=(typeof t)[0];if(n!=f)return\"o\"==n&&\"n\"==f||(\"s\"==f||\"u\"==n);if(\"o\"!=n&&\"u\"!=n&&e!=t)return e {\n\t// see webpack/lib/util/semver.js for original code\n\tvar r=range[0],n=\"\";if(1===range.length)return\"*\";if(r+.5){n+=0==r?\">=\":-1==r?\"<\":1==r?\"^\":2==r?\"~\":r>0?\"=\":\"!=\";for(var e=1,a=1;a0?\".\":\"\")+(e=2,t)}return n}var g=[];for(a=1;a {\n\t// see webpack/lib/util/semver.js for original code\n\tif(0 in range){version=parseVersion(version);var e=range[0],r=e<0;r&&(e=-e-1);for(var n=0,i=1,a=!0;;i++,n++){var f,s,g=i=version.length||\"o\"==(s=(typeof(f=version[n]))[0]))return!a||(\"u\"==g?i>e&&!r:\"\"==g!=r);if(\"u\"==s){if(!a||\"u\"!=g)return!1}else if(a)if(g==s)if(i<=e){if(f!=range[i])return!1}else{if(r?f>range[i]:f {\n\treturn scope && __webpack_require__.o(scope, key);\n}\nvar get = (entry) => {\n\tentry.loaded = 1;\n\treturn entry.get()\n};\nvar eagerOnly = (versions) => {\n\treturn Object.keys(versions).reduce((filtered, version) => {\n\t\t\tif (versions[version].eager) {\n\t\t\t\tfiltered[version] = versions[version];\n\t\t\t}\n\t\t\treturn filtered;\n\t}, {});\n};\nvar findLatestVersion = (scope, key, eager) => {\n\tvar versions = eager ? eagerOnly(scope[key]) : scope[key];\n\tvar key = Object.keys(versions).reduce((a, b) => {\n\t\treturn !a || versionLt(a, b) ? b : a;\n\t}, 0);\n\treturn key && versions[key];\n};\nvar findSatisfyingVersion = (scope, key, requiredVersion, eager) => {\n\tvar versions = eager ? eagerOnly(scope[key]) : scope[key];\n\tvar key = Object.keys(versions).reduce((a, b) => {\n\t\tif (!satisfy(requiredVersion, b)) return a;\n\t\treturn !a || versionLt(a, b) ? b : a;\n\t}, 0);\n\treturn key && versions[key]\n};\nvar findSingletonVersionKey = (scope, key, eager) => {\n\tvar versions = eager ? eagerOnly(scope[key]) : scope[key];\n\treturn Object.keys(versions).reduce((a, b) => {\n\t\treturn !a || (!versions[a].loaded && versionLt(a, b)) ? b : a;\n\t}, 0);\n};\nvar getInvalidSingletonVersionMessage = (scope, key, version, requiredVersion) => {\n\treturn \"Unsatisfied version \" + version + \" from \" + (version && scope[key][version].from) + \" of shared singleton module \" + key + \" (required \" + rangeToString(requiredVersion) + \")\"\n};\nvar getInvalidVersionMessage = (scope, scopeName, key, requiredVersion, eager) => {\n\tvar versions = scope[key];\n\treturn \"No satisfying version (\" + rangeToString(requiredVersion) + \")\" + (eager ? \" for eager consumption\" : \"\") + \" of shared module \" + key + \" found in shared scope \" + scopeName + \".\\n\" +\n\t\t\"Available versions: \" + Object.keys(versions).map((key) => {\n\t\treturn key + \" from \" + versions[key].from;\n\t}).join(\", \");\n};\nvar fail = (msg) => {\n\tthrow new Error(msg);\n}\nvar failAsNotExist = (scopeName, key) => {\n\treturn fail(\"Shared module \" + key + \" doesn't exist in shared scope \" + scopeName);\n}\nvar warn = /*#__PURE__*/ (msg) => {\n\tif (typeof console !== \"undefined\" && console.warn) console.warn(msg);\n};\nvar init = (fn) => (function(scopeName, key, eager, c, d) {\n\tvar promise = __webpack_require__.I(scopeName);\n\tif (promise && promise.then && !eager) {\n\t\treturn promise.then(fn.bind(fn, scopeName, __webpack_require__.S[scopeName], key, false, c, d));\n\t}\n\treturn fn(scopeName, __webpack_require__.S[scopeName], key, eager, c, d);\n});\n\nvar useFallback = (scopeName, key, fallback) => {\n\treturn fallback ? fallback() : failAsNotExist(scopeName, key);\n}\nvar load = /*#__PURE__*/ init((scopeName, scope, key, eager, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\treturn get(findLatestVersion(scope, key, eager));\n});\nvar loadVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar satisfyingVersion = findSatisfyingVersion(scope, key, requiredVersion, eager);\n\tif (satisfyingVersion) return get(satisfyingVersion);\n\twarn(getInvalidVersionMessage(scope, scopeName, key, requiredVersion, eager))\n\treturn get(findLatestVersion(scope, key, eager));\n});\nvar loadStrictVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar satisfyingVersion = findSatisfyingVersion(scope, key, requiredVersion, eager);\n\tif (satisfyingVersion) return get(satisfyingVersion);\n\tif (fallback) return fallback();\n\tfail(getInvalidVersionMessage(scope, scopeName, key, requiredVersion, eager));\n});\nvar loadSingleton = /*#__PURE__*/ init((scopeName, scope, key, eager, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar version = findSingletonVersionKey(scope, key, eager);\n\treturn get(scope[key][version]);\n});\nvar loadSingletonVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar version = findSingletonVersionKey(scope, key, eager);\n\tif (!satisfy(requiredVersion, version)) {\n\t\twarn(getInvalidSingletonVersionMessage(scope, key, version, requiredVersion));\n\t}\n\treturn get(scope[key][version]);\n});\nvar loadStrictSingletonVersion = /*#__PURE__*/ init((scopeName, scope, key, eager, requiredVersion, fallback) => {\n\tif (!exists(scope, key)) return useFallback(scopeName, key, fallback);\n\tvar version = findSingletonVersionKey(scope, key, eager);\n\tif (!satisfy(requiredVersion, version)) {\n\t\tfail(getInvalidSingletonVersionMessage(scope, key, version, requiredVersion));\n\t}\n\treturn get(scope[key][version]);\n});\nvar installedModules = {};\nvar moduleToHandlerMapping = {\n\t8437: () => (loadSingletonVersion(\"default\", \"react\", false, [0], () => (__webpack_require__.e(\"node_modules_react_index_js\").then(() => (() => (__webpack_require__(7810))))))),\n\t5973: () => (loadSingletonVersion(\"default\", \"prop-types\", false, [0], () => (__webpack_require__.e(\"node_modules_prop-types_index_js\").then(() => (() => (__webpack_require__(5826))))))),\n\t3479: () => (loadSingletonVersion(\"default\", \"react-dom\", false, [0], () => (__webpack_require__.e(\"vendors-node_modules_react-dom_index_js\").then(() => (() => (__webpack_require__(2483))))))),\n\t7085: () => (loadSingletonVersion(\"default\", \"@mui/material\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_mui_material_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\")]).then(() => (() => (__webpack_require__(2578))))))),\n\t5636: () => (loadSingletonVersion(\"default\", \"@iobroker/adapter-react-v5\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_adapter-react-v5_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\")]).then(() => (() => (__webpack_require__(8734))))))),\n\t556: () => (loadSingletonVersion(\"default\", \"@iobroker/json-config\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_styles_defaultTheme_js-node_modules_mui_material_styles_ide-00a7ec\"), __webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_material_FilledInput_FilledInput_js\"), __webpack_require__.e(\"vendors-node_modules_react-color_es_index_js\"), __webpack_require__.e(\"vendors-node_modules_iobroker_json-config_build_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_react_emotion_react\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\"), __webpack_require__.e(\"webpack_sharing_consume_default_react-dom_react-dom\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\"), __webpack_require__.e(\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d\"), __webpack_require__.e(\"_91571\")]).then(() => (() => (__webpack_require__(9388))))))),\n\t5746: () => (loadSingletonVersion(\"default\", \"@emotion/react\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_emotion_cache_dist_emotion-cache_browser_esm_js\"), __webpack_require__.e(\"vendors-node_modules_emotion_react_dist_emotion-react_browser_esm_js\")]).then(() => (() => (__webpack_require__(1468))))))),\n\t1839: () => (loadSingletonVersion(\"default\", \"@mui/icons-material\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45\"), __webpack_require__.e(\"vendors-node_modules_mui_icons-material_esm_index_js\"), __webpack_require__.e(\"webpack_sharing_consume_default_emotion_styled_emotion_styled\")]).then(() => (() => (__webpack_require__(1636))))))),\n\t3683: () => (loadSingletonVersion(\"default\", \"react-dropzone\", false, [0], () => (__webpack_require__.e(\"vendors-node_modules_react-dropzone_dist_es_index_js\").then(() => (() => (__webpack_require__(5479))))))),\n\t9702: () => (loadSingletonVersion(\"default\", \"@emotion/styled\", false, [0], () => (__webpack_require__.e(\"node_modules_emotion_styled_dist_emotion-styled_browser_esm_js-_633c1\").then(() => (() => (__webpack_require__(4578))))))),\n\t8497: () => (loadSingletonVersion(\"default\", \"@mui/x-date-pickers\", false, [0], () => (Promise.all([__webpack_require__.e(\"vendors-node_modules_mui_material_Button_Button_js-node_modules_mui_material_Chip_Chip_js-nod-6544d4\"), __webpack_require__.e(\"vendors-node_modules_mui_x-date-pickers_index_js\")]).then(() => (() => (__webpack_require__(7352))))))),\n\t2514: () => (loadSingletonVersion(\"default\", \"react-ace\", false, [0], () => (__webpack_require__.e(\"vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js\").then(() => (() => (__webpack_require__(9017)))))))\n};\n// no consumes in initial chunks\nvar chunkMapping = {\n\t\"webpack_sharing_consume_default_react_react\": [\n\t\t8437\n\t],\n\t\"webpack_sharing_consume_default_prop-types_prop-types\": [\n\t\t5973\n\t],\n\t\"webpack_sharing_consume_default_react-dom_react-dom\": [\n\t\t3479\n\t],\n\t\"webpack_sharing_consume_default_mui_material_mui_material\": [\n\t\t7085\n\t],\n\t\"webpack_sharing_consume_default_iobroker_adapter-react-v5_iobroker_adapter-react-v5\": [\n\t\t5636\n\t],\n\t\"webpack_sharing_consume_default_iobroker_json-config_iobroker_json-config\": [\n\t\t556\n\t],\n\t\"webpack_sharing_consume_default_emotion_react_emotion_react\": [\n\t\t5746\n\t],\n\t\"webpack_sharing_consume_default_mui_icons-material_mui_icons-material-webpack_sharing_consume-80e7de\": [\n\t\t1839,\n\t\t3683\n\t],\n\t\"webpack_sharing_consume_default_emotion_styled_emotion_styled\": [\n\t\t9702\n\t],\n\t\"webpack_sharing_consume_default_mui_x-date-pickers_mui_x-date-pickers-webpack_sharing_consume-9f1a2d\": [\n\t\t8497,\n\t\t2514\n\t]\n};\nvar startedInstallModules = {};\n__webpack_require__.f.consumes = (chunkId, promises) => {\n\tif(__webpack_require__.o(chunkMapping, chunkId)) {\n\t\tchunkMapping[chunkId].forEach((id) => {\n\t\t\tif(__webpack_require__.o(installedModules, id)) return promises.push(installedModules[id]);\n\t\t\tif(!startedInstallModules[id]) {\n\t\t\tvar onFactory = (factory) => {\n\t\t\t\tinstalledModules[id] = 0;\n\t\t\t\t__webpack_require__.m[id] = (module) => {\n\t\t\t\t\tdelete __webpack_require__.c[id];\n\t\t\t\t\tmodule.exports = factory();\n\t\t\t\t}\n\t\t\t};\n\t\t\tstartedInstallModules[id] = true;\n\t\t\tvar onError = (error) => {\n\t\t\t\tdelete installedModules[id];\n\t\t\t\t__webpack_require__.m[id] = (module) => {\n\t\t\t\t\tdelete __webpack_require__.c[id];\n\t\t\t\t\tthrow error;\n\t\t\t\t}\n\t\t\t};\n\t\t\ttry {\n\t\t\t\tvar promise = moduleToHandlerMapping[id]();\n\t\t\t\tif(promise.then) {\n\t\t\t\t\tpromises.push(installedModules[id] = promise.then(onFactory)['catch'](onError));\n\t\t\t\t} else onFactory(promise);\n\t\t\t} catch(e) { onError(e); }\n\t\t\t}\n\t\t});\n\t}\n}","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"main\": 0\n};\n\n__webpack_require__.f.j = (chunkId, promises) => {\n\t\t// JSONP chunk loading for javascript\n\t\tvar installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined;\n\t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n\t\t\t// a Promise means \"currently loading\".\n\t\t\tif(installedChunkData) {\n\t\t\t\tpromises.push(installedChunkData[2]);\n\t\t\t} else {\n\t\t\t\tif(!/^webpack_sharing_consume_default_(emotion_(react_emotion_react|styled_emotion_styled)|iobroker_(adapter\\-react\\-v5_iobroker_adapter\\-react\\-v5|json\\-config_iobroker_json\\-config)|mui_(icons\\-material_mui_icons\\-material\\-webpack_sharing_consume\\-80e7de|material_mui_material|x\\-date\\-pickers_mui_x\\-date\\-pickers\\-webpack_sharing_consume\\-9f1a2d)|react(\\-dom_react\\-dom|_react)|prop\\-types_prop\\-types)$/.test(chunkId)) {\n\t\t\t\t\t// setup Promise in chunk cache\n\t\t\t\t\tvar promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject]));\n\t\t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n\t\t\t\t\t// start chunk loading\n\t\t\t\t\tvar url = __webpack_require__.p + __webpack_require__.u(chunkId);\n\t\t\t\t\t// create error before stack unwound to get useful stacktrace later\n\t\t\t\t\tvar error = new Error();\n\t\t\t\t\tvar loadingEnded = (event) => {\n\t\t\t\t\t\tif(__webpack_require__.o(installedChunks, chunkId)) {\n\t\t\t\t\t\t\tinstalledChunkData = installedChunks[chunkId];\n\t\t\t\t\t\t\tif(installedChunkData !== 0) installedChunks[chunkId] = undefined;\n\t\t\t\t\t\t\tif(installedChunkData) {\n\t\t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n\t\t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n\t\t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n\t\t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n\t\t\t\t\t\t\t\terror.type = errorType;\n\t\t\t\t\t\t\t\terror.request = realSrc;\n\t\t\t\t\t\t\t\tinstalledChunkData[1](error);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t\t__webpack_require__.l(url, loadingEnded, \"chunk-\" + chunkId, chunkId);\n\t\t\t\t} else installedChunks[chunkId] = 0;\n\t\t\t}\n\t\t}\n};\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n// no on chunks loaded\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunk_iobroker_admin_component_easy_access\"] = self[\"webpackChunk_iobroker_admin_component_easy_access\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","__webpack_require__.nc = undefined;","// module cache are used so entry inlining is disabled\n// startup\n// Load entry module and return exports\nvar __webpack_exports__ = __webpack_require__(6046);\n"],"names":["__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","module","__webpack_modules__","getter","exports","definition","key","chunkId","promises","e","obj","prop","inProgress","dataWebpackPrefix","url","done","script","needAttach","scripts","i","s","onScriptComplete","prev","event","timeout","doneFns","fn","initPromises","initTokens","name","initScope","initToken","scope","warn","msg","uniqueName","register","version","factory","eager","versions","activeVersion","initExternal","id","handleError","err","initFn","initResult","scriptUrl","document","parseVersion","str","p","n","r","versionLt","a","b","t","f","rangeToString","range","g","o","satisfy","u","exists","get","entry","eagerOnly","filtered","findLatestVersion","findSatisfyingVersion","requiredVersion","findSingletonVersionKey","getInvalidSingletonVersionMessage","getInvalidVersionMessage","scopeName","fail","failAsNotExist","init","c","d","promise","useFallback","fallback","load","loadVersion","satisfyingVersion","loadStrictVersion","loadSingleton","loadSingletonVersion","loadStrictSingletonVersion","installedModules","moduleToHandlerMapping","chunkMapping","startedInstallModules","onFactory","onError","error","installedChunks","installedChunkData","resolve","reject","loadingEnded","errorType","realSrc","webpackJsonpCallback","parentChunkLoadingFunction","data","chunkIds","moreModules","runtime","result","chunkLoadingGlobal","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file diff --git a/admin/custom/static/js/node_modules_react_index_js.c3e3d81a.chunk.js b/admin/custom/static/js/node_modules_react_index_js.c3e3d81a.chunk.js new file mode 100644 index 0000000..f23fb4f --- /dev/null +++ b/admin/custom/static/js/node_modules_react_index_js.c3e3d81a.chunk.js @@ -0,0 +1,11 @@ +"use strict";(self.webpackChunk_iobroker_admin_component_easy_access=self.webpackChunk_iobroker_admin_component_easy_access||[]).push([["node_modules_react_index_js"],{5677:(b,n)=>{/** + * @license React + * react.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var y=Symbol.for("react.element"),A=Symbol.for("react.portal"),D=Symbol.for("react.fragment"),U=Symbol.for("react.strict_mode"),q=Symbol.for("react.profiler"),F=Symbol.for("react.provider"),L=Symbol.for("react.context"),M=Symbol.for("react.forward_ref"),N=Symbol.for("react.suspense"),z=Symbol.for("react.memo"),B=Symbol.for("react.lazy"),E=Symbol.iterator;function H(e){return e===null||typeof e!="object"?null:(e=E&&e[E]||e["@@iterator"],typeof e=="function"?e:null)}var R={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},$=Object.assign,C={};function p(e,t,r){this.props=e,this.context=t,this.refs=C,this.updater=r||R}p.prototype.isReactComponent={},p.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},p.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function j(){}j.prototype=p.prototype;function m(e,t,r){this.props=e,this.context=t,this.refs=C,this.updater=r||R}var v=m.prototype=new j;v.constructor=m,$(v,p.prototype),v.isPureReactComponent=!0;var O=Array.isArray,g=Object.prototype.hasOwnProperty,S={current:null},P={key:!0,ref:!0,__self:!0,__source:!0};function I(e,t,r){var o,u={},i=null,l=null;if(t!=null)for(o in t.ref!==void 0&&(l=t.ref),t.key!==void 0&&(i=""+t.key),t)g.call(t,o)&&!P.hasOwnProperty(o)&&(u[o]=t[o]);var f=arguments.length-2;if(f===1)u.children=r;else if(1{b.exports=y(5677)}}]); + +//# sourceMappingURL=node_modules_react_index_js.c3e3d81a.chunk.js.map \ No newline at end of file diff --git a/admin/custom/static/js/node_modules_react_index_js.c3e3d81a.chunk.js.map b/admin/custom/static/js/node_modules_react_index_js.c3e3d81a.chunk.js.map new file mode 100644 index 0000000..f6c483b --- /dev/null +++ b/admin/custom/static/js/node_modules_react_index_js.c3e3d81a.chunk.js.map @@ -0,0 +1 @@ +{"version":3,"file":"static/js/node_modules_react_index_js.c3e3d81a.chunk.js","mappings":"qLAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,GASa,IAAIA,EAAE,OAAO,IAAI,eAAe,EAAEC,EAAE,OAAO,IAAI,cAAc,EAAEC,EAAE,OAAO,IAAI,gBAAgB,EAAEC,EAAE,OAAO,IAAI,mBAAmB,EAAEC,EAAE,OAAO,IAAI,gBAAgB,EAAEC,EAAE,OAAO,IAAI,gBAAgB,EAAEC,EAAE,OAAO,IAAI,eAAe,EAAEC,EAAE,OAAO,IAAI,mBAAmB,EAAEC,EAAE,OAAO,IAAI,gBAAgB,EAAEC,EAAE,OAAO,IAAI,Y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zd6B,EAAQ,QAAQ,SAASlC,EAAEK,EAAE,CAAC,OAAOyB,EAAE,QAAQ,QAAQ9B,EAAEK,CAAC,CAAC,EAAE6B,EAAQ,WAAW,SAASlC,EAAEK,EAAEC,EAAE,CAAC,OAAOwB,EAAE,QAAQ,WAAW9B,EAAEK,EAAEC,CAAC,CAAC,EAAE4B,EAAQ,OAAO,SAASlC,EAAE,CAAC,OAAO8B,EAAE,QAAQ,OAAO9B,CAAC,CAAC,EAAEkC,EAAQ,SAAS,SAASlC,EAAE,CAAC,OAAO8B,EAAE,QAAQ,SAAS9B,CAAC,CAAC,EAAEkC,EAAQ,qBAAqB,SAASlC,EAAEK,EAAEC,EAAE,CAAC,OAAOwB,EAAE,QAAQ,qBAAqB9B,EAAEK,EAAEC,CAAC,CAAC,EAAE4B,EAAQ,cAAc,UAAU,CAAC,OAAOJ,EAAE,QAAQ,cAAc,CAAC,EAAEI,EAAQ,QAAQ,Q,iBCtBlaC,EAAO,QAAU,EAAjB,K","sources":["../node_modules/react/cjs/react.production.min.js","../node_modules/react/index.js"],"sourcesContent":["/**\n * @license React\n * react.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var l=Symbol.for(\"react.element\"),n=Symbol.for(\"react.portal\"),p=Symbol.for(\"react.fragment\"),q=Symbol.for(\"react.strict_mode\"),r=Symbol.for(\"react.profiler\"),t=Symbol.for(\"react.provider\"),u=Symbol.for(\"react.context\"),v=Symbol.for(\"react.forward_ref\"),w=Symbol.for(\"react.suspense\"),x=Symbol.for(\"react.memo\"),y=Symbol.for(\"react.lazy\"),z=Symbol.iterator;function A(a){if(null===a||\"object\"!==typeof a)return null;a=z&&a[z]||a[\"@@iterator\"];return\"function\"===typeof a?a:null}\nvar B={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},C=Object.assign,D={};function E(a,b,e){this.props=a;this.context=b;this.refs=D;this.updater=e||B}E.prototype.isReactComponent={};\nE.prototype.setState=function(a,b){if(\"object\"!==typeof a&&\"function\"!==typeof a&&null!=a)throw Error(\"setState(...): takes an object of state variables to update or a function which returns an object of state variables.\");this.updater.enqueueSetState(this,a,b,\"setState\")};E.prototype.forceUpdate=function(a){this.updater.enqueueForceUpdate(this,a,\"forceUpdate\")};function F(){}F.prototype=E.prototype;function G(a,b,e){this.props=a;this.context=b;this.refs=D;this.updater=e||B}var H=G.prototype=new F;\nH.constructor=G;C(H,E.prototype);H.isPureReactComponent=!0;var I=Array.isArray,J=Object.prototype.hasOwnProperty,K={current:null},L={key:!0,ref:!0,__self:!0,__source:!0};\nfunction M(a,b,e){var d,c={},k=null,h=null;if(null!=b)for(d in void 0!==b.ref&&(h=b.ref),void 0!==b.key&&(k=\"\"+b.key),b)J.call(b,d)&&!L.hasOwnProperty(d)&&(c[d]=b[d]);var g=arguments.length-2;if(1===g)c.children=e;else if(1{var i=s(8437),e=s.n(i),g=s(4140),y=s(5973),o=s.n(y),t=s(7085),p=s(556),b=s(5636);const r={table:{minWidth:400},header:{fontSize:16,fontWeight:"bold"}};class h extends p.ConfigGeneric{componentDidMount(){super.componentDidMount(),this.props.oContext.socket.getAdapterInstances().then(m=>{m=m.filter(n=>{var c;return((c=n==null?void 0:n.common)==null?void 0:c.adminUI)&&(n.common.adminUI.config!=="none"||n.common.adminUI.tab)}).map(n=>({id:n._id.replace(/^system\.adapter\./,""),config:n.common.adminUI.config!=="none",adminTab:n.common.adminTab})).sort((n,c)=>n.id>c.id?1:n.ide().createElement(t.TableRow,{key:a.id},e().createElement(t.TableCell,{component:"th",scope:"row"},a.id),e().createElement(t.TableCell,null,a.config?e().createElement(t.Checkbox,{checked:f.includes(a.id),onClick:()=>{const l=[...f],d=l.indexOf(a.id);d!==-1?l.splice(d,1):(l.push(a.id),l.sort()),this.onChange("accessAllowedConfigs",l)}}):null),e().createElement(t.TableCell,null,a.adminTab?e().createElement(t.Checkbox,{checked:C.includes(a.id),onClick:()=>{const l=[...C],d=l.indexOf(a.id);d!==-1?l.splice(d,1):(l.push(a.id),l.sort()),this.onChange("accessAllowedTabs",l)}}):null))))))}}h.propTypes={socket:o().object.isRequired,themeType:o().string,themeName:o().string,style:o().object,data:o().object.isRequired,schema:o().object,onError:o().func,onChange:o().func};const T=h;var E=s(8437);function v(){return E.createElement(T,null)}const x=v;g.createRoot(document.getElementById("root")).render(e().createElement(e().StrictMode,null,e().createElement(x,null)))},4140:(_,u,s)=>{var i=s(3479);if(1)u.createRoot=i.createRoot,u.hydrateRoot=i.hydrateRoot;else var e}}]); + +//# sourceMappingURL=src_bootstrap_jsx.d4a881b8.chunk.js.map \ No newline at end of file diff --git a/admin/custom/static/js/src_bootstrap_jsx.d4a881b8.chunk.js.map b/admin/custom/static/js/src_bootstrap_jsx.d4a881b8.chunk.js.map new file mode 100644 index 0000000..3911845 --- /dev/null +++ b/admin/custom/static/js/src_bootstrap_jsx.d4a881b8.chunk.js.map @@ -0,0 +1 @@ +{"version":3,"file":"static/js/src_bootstrap_jsx.d4a881b8.chunk.js","mappings":"4PAYA,MAAMA,EAAS,CACX,MAAO,CACH,SAAU,GACd,EACA,OAAQ,CACJ,SAAU,GACV,WAAY,MAChB,CACJ,EAEA,MAAMC,UAA+B,eAAc,CAC/C,mBAAoB,CAChB,MAAM,kBAAkB,EAExB,KAAK,MAAM,SAAS,OAAO,oBAAoB,EAAE,KAAKC,GAAa,CAC/DA,EAAYA,EACP,OACGC,GAAS,CA7B7B,MA8BwB,UAAAA,GAAA,YAAAA,EAAU,SAAV,cAAkB,WACjBA,EAAS,OAAO,QAAQ,SAAW,QAAUA,EAAS,OAAO,QAAQ,KAC9E,EACC,IAAIA,IAAa,CACd,GAAIA,EAAS,IAAI,QAAQ,qBAAsB,EAAE,EACjD,OAAQA,EAAS,OAAO,QAAQ,SAAW,OAC3C,SAAUA,EAAS,OAAO,QAC9B,EAAE,EACD,KAAK,CAACC,EAAGC,IA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,EAAE,EAC1C,QAAS,IAAM,CACX,MAAMG,EAAqB,CAAC,GAAGJ,CAAiB,EAC1CG,EAAMC,EAAmB,QAAQH,EAAI,EAAE,EACzCE,IAAQ,GACRC,EAAmB,OAAOD,EAAK,CAAC,GAEhCC,EAAmB,KAAKH,EAAI,EAAE,EAC9BG,EAAmB,KAAK,GAE5B,KAAK,SAAS,oBAAqBA,CAAkB,CACzD,EACJ,EACA,IACR,CACJ,CACH,CACL,CACJ,CACJ,CAER,CACJ,CAEAb,EAAuB,UAAY,CAC/B,OAAQ,WAAiB,WACzB,UAAW,WACX,UAAW,WACX,MAAO,WACP,KAAM,WAAiB,WACvB,OAAQ,WACR,QAAS,SACT,SAAU,QACd,EAEA,QAAeA,E,cC/Hf,SAASc,GAAM,CACX,OAAO,gBAAC,EAAsB,IAAC,CACnC,CAEA,QAAeA,ECFf,aAAoB,SAAS,eAAe,MAAM,CAAC,EAAE,OACjD,kBAAC,oBACG,kBAAC,EAAG,IAAC,CACT,CACJ,C,iBCNA,IAAIC,EAAI,EAAQ,IAAW,EAC3B,GAAI,EACFC,EAAQ,WAAaD,EAAE,WACvBC,EAAQ,YAAcD,EAAE,gBACnB,M","sources":["ConfigCustomEasyAccess.jsx","App.jsx","bootstrap.jsx","../node_modules/react-dom/client.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\n\nimport { Table, TableBody, TableCell, TableContainer, TableHead, TableRow, Checkbox } from '@mui/material';\n\n// important to make from package and not from some children.\n// invalid\n// import ConfigGeneric from '@iobroker/adapter-react-v5/ConfigGeneric';\n// valid\nimport { ConfigGeneric } from '@iobroker/json-config';\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nconst styles = {\n table: {\n minWidth: 400,\n },\n header: {\n fontSize: 16,\n fontWeight: 'bold',\n },\n};\n\nclass ConfigCustomEasyAccess extends ConfigGeneric {\n componentDidMount() {\n super.componentDidMount();\n\n this.props.oContext.socket.getAdapterInstances().then(instances => {\n instances = instances\n .filter(\n instance =>\n instance?.common?.adminUI &&\n (instance.common.adminUI.config !== 'none' || instance.common.adminUI.tab),\n )\n .map(instance => ({\n id: instance._id.replace(/^system\\.adapter\\./, ''),\n config: instance.common.adminUI.config !== 'none',\n adminTab: instance.common.adminTab,\n }))\n .sort((a, b) => (a.id > b.id ? 1 : a.id < b.id ? -1 : 0));\n\n this.setState({ instances });\n });\n }\n\n renderItem(error, disabled, defaultValue) {\n if (!this.state.instances) {\n return null;\n }\n const accessAllowedConfigs = ConfigGeneric.getValue(this.props.data, 'accessAllowedConfigs') || [];\n const accessAllowedTabs = ConfigGeneric.getValue(this.props.data, 'accessAllowedTabs') || [];\n\n return (\n \n \n \n \n {I18n.t('custom_easy_Instance')}\n {I18n.t('custom_easy_Config')}\n {I18n.t('custom_easy_Tab')}\n \n \n \n {this.state.instances.map(row => (\n \n \n {row.id}\n \n \n {row.config ? (\n {\n const _accessAllowedConfigs = [...accessAllowedConfigs];\n const pos = _accessAllowedConfigs.indexOf(row.id);\n if (pos !== -1) {\n _accessAllowedConfigs.splice(pos, 1);\n } else {\n _accessAllowedConfigs.push(row.id);\n _accessAllowedConfigs.sort();\n }\n this.onChange('accessAllowedConfigs', _accessAllowedConfigs);\n }}\n />\n ) : null}\n \n \n {row.adminTab ? (\n {\n const _accessAllowedTabs = [...accessAllowedTabs];\n const pos = _accessAllowedTabs.indexOf(row.id);\n if (pos !== -1) {\n _accessAllowedTabs.splice(pos, 1);\n } else {\n _accessAllowedTabs.push(row.id);\n _accessAllowedTabs.sort();\n }\n this.onChange('accessAllowedTabs', _accessAllowedTabs);\n }}\n />\n ) : null}\n \n \n ))}\n \n \n \n );\n }\n}\n\nConfigCustomEasyAccess.propTypes = {\n socket: PropTypes.object.isRequired,\n themeType: PropTypes.string,\n themeName: PropTypes.string,\n style: PropTypes.object,\n data: PropTypes.object.isRequired,\n schema: PropTypes.object,\n onError: PropTypes.func,\n onChange: PropTypes.func,\n};\n\nexport default ConfigCustomEasyAccess;\n","import ConfigCustomEasyAccess from './ConfigCustomEasyAccess.jsx';\n\nfunction App() {\n return ;\n}\n\nexport default App;\n","import React from 'react';\nimport ReactDOM from 'react-dom/client';\nimport App from './App';\n\nReactDOM.createRoot(document.getElementById('root')).render(\n \n \n ,\n);\n","'use strict';\n\nvar m = require('react-dom');\nif (process.env.NODE_ENV === 'production') {\n exports.createRoot = m.createRoot;\n exports.hydrateRoot = m.hydrateRoot;\n} else {\n var i = m.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;\n exports.createRoot = function(c, o) {\n i.usingClientEntryPoint = true;\n try {\n return m.createRoot(c, o);\n } finally {\n i.usingClientEntryPoint = false;\n }\n };\n exports.hydrateRoot = function(c, h, o) {\n i.usingClientEntryPoint = true;\n try {\n return m.hydrateRoot(c, h, o);\n } finally {\n i.usingClientEntryPoint = false;\n }\n };\n}\n"],"names":["styles","ConfigCustomEasyAccess","instances","instance","a","b","error","disabled","defaultValue","accessAllowedConfigs","accessAllowedTabs","row","_accessAllowedConfigs","pos","_accessAllowedTabs","App","m","exports"],"sourceRoot":""} \ No newline at end of file diff --git a/admin/custom/static/js/vendors-node_modules_iobroker_json-config_build_index_js.4ef5c4a7.chunk.js b/admin/custom/static/js/vendors-node_modules_iobroker_json-config_build_index_js.4ef5c4a7.chunk.js new file mode 100644 index 0000000..07a95b7 --- /dev/null +++ b/admin/custom/static/js/vendors-node_modules_iobroker_json-config_build_index_js.4ef5c4a7.chunk.js @@ -0,0 +1,407 @@ +var Us=Object.defineProperty,Ws=Object.defineProperties;var Js=Object.getOwnPropertyDescriptors;var On=Object.getOwnPropertySymbols,Hs=Object.getPrototypeOf,zs=Object.prototype.hasOwnProperty,qs=Object.prototype.propertyIsEnumerable,Ks=Reflect.get;var mn=(V,ee,Y)=>ee in V?Us(V,ee,{enumerable:!0,configurable:!0,writable:!0,value:Y}):V[ee]=Y,q=(V,ee)=>{for(var Y in ee||(ee={}))zs.call(ee,Y)&&mn(V,Y,ee[Y]);if(On)for(var Y of On(ee))qs.call(ee,Y)&&mn(V,Y,ee[Y]);return V},Oe=(V,ee)=>Ws(V,Js(ee));var Q=(V,ee,Y)=>mn(V,typeof ee!="symbol"?ee+"":ee,Y);var nt=(V,ee,Y)=>Ks(Hs(V),Y,ee);var pe=(V,ee,Y)=>new Promise((T,n)=>{var C=v=>{try{D(Y.next(v))}catch(o){n(o)}},m=v=>{try{D(Y.throw(v))}catch(o){n(o)}},D=v=>v.done?T(v.value):Promise.resolve(v.value).then(C,m);D((Y=Y.apply(V,ee)).next())});(self.webpackChunk_iobroker_admin_component_easy_access=self.webpackChunk_iobroker_admin_component_easy_access||[]).push([["vendors-node_modules_iobroker_json-config_build_index_js"],{9388:(V,ee,Y)=>{"use strict";Y.r(ee),Y.d(ee,{ConfigGeneric:()=>f,ConfigPanel:()=>Ot,JsonConfig:()=>Vs,JsonConfigComponent:()=>Wt});var T=Y(8437),n=Y.n(T),C=Y(5589),m=Y.n(C),D=Y(1778),v=Y.n(D),o=Y(7085),u=Y(1839),l=Y(5636);const _=window.innerWidth<=600?12:void 0;function R(E){return Object.prototype.toString.call(E)==="[object Object]"}const Se=class Se extends T.Component{constructor(e){super(e);Q(this,"defaultValue");Q(this,"isError");Q(this,"lang");Q(this,"defaultSendToDone");Q(this,"sendToTimeout");Q(this,"noPlaceRequired");Q(this,"onUpdate",e=>{const t=Se.getValue(e||this.props.data,this.props.attr)||"";this.state.value!==t?this.setState({value:t}):this.forceUpdate()});this.state={confirmDialog:!1,confirmNewValue:null,confirmAttr:null,confirmData:null,confirmCallback:null},this.isError={},e.schema&&(e.custom?this.defaultValue=e.schema.defaultFunc?this.executeCustom(e.schema.defaultFunc,e.data,e.customObj,e.oContext.instanceObj,e.arrayIndex,e.globalData):e.schema.default:e.schema.type!=="state"&&(this.defaultValue=e.schema.defaultFunc?this.execute(e.schema.defaultFunc,e.schema.default,e.data,e.arrayIndex,e.globalData):e.schema.default)),this.lang=l.I18n.getLanguage()}componentDidMount(){this.props.oContext.registerOnForceUpdate&&this.props.oContext.registerOnForceUpdate(this.props.attr,this.onUpdate);const e=["select","autocomplete","autocompleteSendTo"];if(this.defaultValue!==void 0){const t=Se.getValue(this.props.data,this.props.attr);(t===void 0||e.includes(this.props.schema.type)&&(t===""||t===null))&&setTimeout(()=>{this.props.custom?this.props.onChange(this.props.attr,this.defaultValue,()=>setTimeout(()=>this.props.oContext.forceUpdate([this.props.attr],this.props.data),100)):(Se.setValue(this.props.data,this.props.attr,this.defaultValue),this.props.onChange(this.props.data,void 0,()=>this.props.oContext.forceUpdate([this.props.attr],this.props.data)))},100)}else this.props.schema.defaultSendTo&&this.sendTo()}sendTo(){if(this.props.alive){this.defaultSendToDone=!0;let e=this.props.schema.data;if(e===void 0&&this.props.schema.jsonData){const t=this.getPattern(this.props.schema.jsonData,null,!0);try{e=JSON.parse(t)}catch(s){console.error(`Cannot parse json data: ${t}`)}}else e={attr:this.props.attr,value:Se.getValue(this.props.data,this.props.attr)};e===void 0&&(e=null),this.props.oContext.socket.sendTo(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,this.props.schema.defaultSendTo,e).then(t=>{t!=null&&(this.props.custom?this.props.onChange(this.props.attr,t,()=>this.props.oContext.forceUpdate([this.props.attr],this.props.data)):(Se.setValue(this.props.data,this.props.attr,t),this.props.onChange(this.props.data,void 0,()=>this.props.oContext.forceUpdate([this.props.attr],this.props.data))))})}else this.defaultSendToDone=!1,this.props.schema.allowSaveWithError||this.onError(this.props.attr,l.I18n.t("ra_Instance %s is not alive",this.props.oContext.instance.toString()))}componentWillUnmount(){this.props.oContext.registerOnForceUpdate&&this.props.oContext.registerOnForceUpdate(this.props.attr),this.sendToTimeout&&(clearTimeout(this.sendToTimeout),this.sendToTimeout=null)}static getValue(e,t){if(typeof t=="string")return Se.getValue(e,t.split("."));if(t.length===1)return e[t[0]];const s=t.shift();if(typeof s=="string"&&typeof e[s]=="object")return Se.getValue(e[s],t)}static setValue(e,t,s){if(typeof t=="string"){Se.setValue(e,t.split("."),s);return}if(t.length===1)s===null?delete e[t[0]]:e[t[0]]=s;else{const i=t.shift();if(typeof i!="string")return;(!e[i]||typeof e[i]=="object")&&(e[i]=e[i]||{}),Se.setValue(e[i],t,s)}}getText(e,t){if(!e)return"";if(typeof e=="string"){const s=t?e:l.I18n.t(e);return s.includes("${")?this.getPattern(s,null,t):s}return R(e)?e.func?typeof e.func=="object"?this.getPattern(e.func[this.lang]||e.func.en||"",null,!0):this.getPattern(e.func,null,t):e[this.lang]||e.en||"":e.toString()}renderDialogConfirm(){if(!this.state.confirmDialog)return null;const e=this.state.confirmData||this.props.schema.confirm;let t=null;return e.type==="warning"?t=n().createElement(u.Warning,null):e.type==="error"?t=n().createElement(u.Error,null):e.type==="info"&&(t=n().createElement(u.Info,null)),n().createElement(l.DialogConfirm,{title:this.getText(e.title)||l.I18n.t("ra_Please confirm"),text:this.getText(e.text),ok:this.getText(e.ok)||l.I18n.t("ra_Ok"),cancel:this.getText(e.cancel)||l.I18n.t("ra_Cancel"),icon:t||void 0,onClose:s=>this.setState({confirmDialog:!1},()=>{if(s){if(this.state.confirmCallback){const r=this.state.confirmCallback;this.setState({confirmCallback:null},()=>r(!0));return}const i=JSON.parse(JSON.stringify(this.props.data));this.state.confirmDepAttr&&Se.setValue(i,this.state.confirmDepAttr,this.state.confirmDepNewValue),Se.setValue(i,this.state.confirmAttr,this.state.confirmNewValue),this.setState({confirmDialog:!1,confirmDepAttr:null,confirmDepNewValue:null,confirmNewValue:null,confirmAttr:null,confirmData:null},()=>this.props.onChange(i))}else{const i=this.state.confirmCallback;this.setState({confirmDialog:!1,confirmDepAttr:null,confirmDepNewValue:null,confirmNewValue:null,confirmAttr:null,confirmData:null,confirmCallback:null},()=>{i&&i(!1)})}})})}getIcon(e){e=e||this.props.schema.icon;let t=null;return e==="auth"?t=n().createElement(u.Key,null):e==="send"?t=n().createElement(u.Send,null):e==="web"?t=n().createElement(u.Public,null):e==="warning"?t=n().createElement(u.Warning,null):e==="error"?t=n().createElement(u.Error,null):e==="info"?t=n().createElement(u.Info,null):e==="search"?t=n().createElement(u.Search,null):e==="book"?t=n().createElement(u.MenuBook,null):e==="help"?t=n().createElement(u.Help,null):e==="upload"?t=n().createElement(u.UploadFile,null):e==="edit"?t=n().createElement(u.Edit,null):e==="user"?t=n().createElement(u.Person,null):e==="group"?t=n().createElement(u.Group,null):e==="delete"?t=n().createElement(u.Delete,null):e==="refresh"?t=n().createElement(u.Refresh,null):e==="add"?t=n().createElement(u.Add,null):e==="unpair"?t=n().createElement(u.LinkOff,null):e==="pair"?t=n().createElement(u.Link,null):e==="save"?t=n().createElement(u.Save,null):e==="open"?t=n().createElement(u.OpenInNew,null):e&&((e.endsWith(".png")||e.endsWith(".svg")||e.endsWith(".jpg"))&&!e.startsWith("http://")&&!e.startsWith("https://")&&(e=`./adapter/${this.props.oContext.adapterName}/${e}`),t=n().createElement(l.Icon,{src:e,style:{width:22,height:22}})),t}onChangeAsync(e,t){return new Promise(s=>{const i=this.onChange(e,t,s);i instanceof Promise&&i.catch(r=>console.error(`Cannot set value: ${r}`))})}onChange(e,t,s){const i=JSON.parse(JSON.stringify(this.props.data));if(Se.setValue(i,e,t),this.props.schema.confirm&&this.execute(this.props.schema.confirm.condition,!1,i,this.props.arrayIndex,this.props.globalData))return new Promise(a=>{this.setState({confirmDialog:!0,confirmNewValue:t,confirmAttr:e,confirmData:null},()=>{typeof s=="function"?s():a()})});if(this.props.schema.confirmDependsOn)for(let a=0;a{this.setState({confirmDialog:!0,confirmNewValue:t,confirmAttr:e,confirmDepNewValue:S,confirmDepAttr:h.attr,confirmData:h.confirm},()=>{typeof s=="function"?s():L()})})}}const r=[];if(this.props.schema.onChangeDependsOn)for(let a=0;as&&s()),r!=null&&r.length&&r.forEach((a,h)=>setTimeout(()=>this.props.onChange(a,Se.getValue(i,a)),h*50))):this.props.onChange(i,void 0,()=>{r.length&&this.props.oContext.forceUpdate(r,i),s&&s()}),Promise.resolve()}execute(e,t,s,i,r){let a;if(R(e))a=e.func;else if(typeof e=="string")a=e;else return e;if(!a)return t;try{return new Function("data","originalData","_system","_alive","_common","_socket","_instance","arrayIndex","globalData","_changed",a.includes("return")?a:`return ${a}`)(s||this.props.data,this.props.originalData,this.props.oContext.systemConfig,this.props.alive,this.props.common,this.props.oContext.socket,this.props.oContext.instance,i,r,this.props.changed)}catch(h){return console.error(`Cannot execute ${JSON.stringify(e)}: ${h}`),t}}executeCustom(e,t,s,i,r,a){let h;if(R(e))h=e.func;else if(typeof e=="string")h=e;else return e;if(!h)return null;try{return new Function("data","originalData","_system","instanceObj","customObj","_socket","arrayIndex","globalData","_changed",h.includes("return")?h:`return ${h}`)(t||this.props.data,this.props.originalData,this.props.oContext.systemConfig,i,s,this.props.oContext.socket,r,a,this.props.changed)}catch(S){return console.error(`Cannot execute ${h}: ${S}`),null}}calculate(e){let t,s,i,r;return this.props.custom?(t=e.validator?!this.executeCustom(e.validator,this.props.data,this.props.customObj,this.props.oContext.instanceObj,this.props.arrayIndex,this.props.globalData):!1,e.disabled===!0?s=!0:s=e.disabled?this.executeCustom(e.disabled,this.props.data,this.props.customObj,this.props.oContext.instanceObj,this.props.arrayIndex,this.props.globalData):!1,e.hidden===!0?i=!0:i=e.hidden?this.executeCustom(e.hidden,this.props.data,this.props.customObj,this.props.oContext.instanceObj,this.props.arrayIndex,this.props.globalData):!1,r=e.defaultFunc?this.executeCustom(e.defaultFunc,this.props.data,this.props.customObj,this.props.oContext.instanceObj,this.props.arrayIndex,this.props.globalData):e.default):(t=e.validator?!this.execute(e.validator,!1,this.props.data,this.props.arrayIndex,this.props.globalData):!1,e.disabled===!0?s=!0:s=e.disabled?this.execute(e.disabled,!1,this.props.data,this.props.arrayIndex,this.props.globalData):!1,e.hidden===!0?i=!0:i=e.hidden?this.execute(e.hidden,!1,this.props.data,this.props.arrayIndex,this.props.globalData):!1,r=e.defaultFunc?this.execute(e.defaultFunc,e.default,this.props.data,this.props.arrayIndex,this.props.globalData):e.default),{error:t,disabled:s,hidden:i,defaultValue:r}}onError(e,t){t?this.isError[e]=t:delete this.isError[e],this.props.onError&&this.props.onError(e,t)}renderItem(e,t,s){return this.getText(this.props.schema.label)||this.getText(this.props.schema.text)}renderHelp(e,t,s){return t?n().createElement("a",{href:t,target:"_blank",rel:"noreferrer",style:{color:this.props.oContext.themeType==="dark"?"#a147ff":"#5b238f",textDecoration:"underline"}},this.getText(e,s)):(e=this.getText(e,s)||"",e&&(e.includes("")||e.includes(""))?l.Utils.renderTextWithA(e):e)}static escapeString(e,t){return typeof e!="string"?"":(e=e.replace(/`/g,"\\`"),e=e.replace(/\${([^}]+)}/g,(s,i)=>{if(i&&typeof i=="string"&&i.startsWith("data.")){const r=Se.getValue(t,i.replace(/^data\./,""));if(typeof r=="string"&&r.includes('"'))return`\${${i}.replace(/"/g, '\\\\"')}`}return s}),e)}getPattern(e,t,s){if(t=t||this.props.data,!e)return"";let i;typeof e=="object"?e.func?i=e.func:(console.log(`Object must be stringified: ${JSON.stringify(e)}`),i=JSON.stringify(e)):i=e;try{if(this.props.custom)return new Function("data","originalData","arrayIndex","globalData","_system","instanceObj","customObj","_socket","_changed",`return \`${Se.escapeString(i,t)}\``)(t,this.props.originalData,this.props.arrayIndex,this.props.globalData,this.props.oContext.systemConfig,this.props.oContext.instanceObj,this.props.customObj,this.props.oContext.socket,this.props.changed);const a=new Function("data","originalData","arrayIndex","globalData","_system","_alive","_common","_socket","_changed",`return \`${Se.escapeString(i,t)}\``)(t,this.props.originalData,this.props.arrayIndex,this.props.globalData,this.props.oContext.systemConfig,this.props.alive,this.props.common,this.props.oContext.socket,this.props.changed);return s?a:l.I18n.t(a)}catch(r){return console.error(`Cannot execute ${i}: ${r}`),i}}render(){const e=this.props.schema;if(!e||this.props.oContext.expertMode===!1&&e.expertMode)return null;this.props.alive&&this.defaultSendToDone===!1&&(this.sendToTimeout=setTimeout(()=>{this.sendToTimeout=null,this.sendTo()},200));const{error:t,disabled:s,hidden:i,defaultValue:r}=this.calculate(e);if(i){if(Object.keys(this.isError).length&&(setTimeout(S=>Object.keys(S).forEach(L=>this.props.onError(L)),100,JSON.parse(JSON.stringify(this.isError))),this.isError={}),e.hideOnlyControl){const S=n().createElement(o.Grid2,{size:{xs:e.xs||_,sm:e.sm||void 0,md:e.md||void 0,lg:e.lg||void 0,xl:e.xl||void 0},style:q(q({marginBottom:0,textAlign:"left"},e.style),this.props.oContext.themeType==="dark"?e.darkStyle:{})});return e.newLine?n().createElement(n().Fragment,null,n().createElement("div",{style:{flexBasis:"100%",height:0}}),S):S}return null}e.validatorNoSaveOnError&&(t&&!Object.keys(this.isError).length?(this.isError={[this.props.attr]:e.validatorErrorText?l.I18n.t(e.validatorErrorText):!0},setTimeout(S=>Object.keys(S).forEach(L=>this.props.onError(L,S[L])),100,JSON.parse(JSON.stringify(this.isError)))):!t&&Object.keys(this.isError).length&&(setTimeout(S=>Object.keys(S).forEach(L=>this.props.onError(L)),100,JSON.parse(JSON.stringify(this.isError))),this.isError={}));const a=this.renderItem(t,s||this.props.commandRunning||this.props.disabled,r);if(this.noPlaceRequired)return a;const h=n().createElement(o.Grid2,{title:this.getText(e.tooltip),size:{xs:e.xs||12,sm:e.sm||void 0,md:e.md||void 0,lg:e.lg||void 0,xl:e.xl||void 0},style:q(q({marginBottom:0,textAlign:"left",width:e.type==="divider"||e.type==="header"?e.width||"100%":void 0},e.style),this.props.oContext.themeType==="dark"?e.darkStyle:{})},this.props.schema.defaultSendTo&&this.props.schema.button?n().createElement(o.Grid2,{container:!0,style:{width:"100%"}},n().createElement(o.Grid2,{flex:1},a),n().createElement(o.Grid2,null,n().createElement(o.Button,{disabled:s,variant:"outlined",onClick:()=>this.sendTo(),title:this.props.schema.buttonTooltip?this.getText(this.props.schema.buttonTooltip,this.props.schema.buttonTooltipNoTranslation):l.I18n.t("ra_Request data by instance")},this.getText(this.props.schema.button)))):a);return e.newLine?n().createElement(n().Fragment,null,n().createElement("div",{style:{flexBasis:"100%",height:0}}),this.renderDialogConfirm(),h):this.state.confirmDialog?n().createElement(n().Fragment,null,this.renderDialogConfirm(),h):h}};Q(Se,"DIFFERENT_VALUE","__different__"),Q(Se,"DIFFERENT_LABEL","ra___different__"),Q(Se,"NONE_VALUE",""),Q(Se,"NONE_LABEL","ra_none");let f=Se;const Z={fullWidth:{width:"100%"},accordionSummary:E=>({backgroundColor:E.palette.mode==="dark"?"rgba(255, 255, 255, 0.08)":"rgba(0, 0, 0, 0.08)"}),accordionTitle:{},toolbar:E=>({backgroundColor:E.palette.mode==="dark"?"rgba(255, 255, 255, 0.08)":"rgba(0, 0, 0, 0.08)",borderRadius:"3px"}),tooltip:{pointerEvents:"none"}};class j extends f{constructor(e){super(e);Q(this,"typingTimer",null);Q(this,"onDelete",e=>()=>{const t=JSON.parse(JSON.stringify(this.state.value));t.splice(e,1),this.setState({value:t,iteration:this.state.iteration+1e4},()=>this.onChangeWrapper(t))});Q(this,"onClone",e=>()=>{const t=JSON.parse(JSON.stringify(this.state.value)),s=JSON.parse(JSON.stringify(t[e]));if(typeof this.props.schema.clone=="string"&&typeof s[this.props.schema.clone]=="string"){let i=1,r=s[this.props.schema.clone];const a=r.match(/(\d+)$/);for(a?(r=r.replace(a[0],""),i=parseInt(a[0],10)+1):r+="_";t.find(h=>h[this.props.schema.clone]===r+i.toString());)i++;s[this.props.schema.clone]=`${s[this.props.schema.clone]}_${i}`}t.splice(e,0,s),this.setState({value:t,activeIndex:-1,iteration:this.state.iteration+1e4},()=>this.onChangeWrapper(t))});Q(this,"onChangeWrapper",e=>{this.typingTimer&&clearTimeout(this.typingTimer),this.typingTimer=setTimeout(t=>{this.typingTimer=null;const s=this.onChange(this.props.attr,t);s instanceof Promise&&s.catch(i=>this.onError(i))},300,e)});Q(this,"onAdd",()=>{const{schema:e}=this.props,t=JSON.parse(JSON.stringify(this.state.value)),s=e.items&&e.items.reduce((i,r)=>{let a;return r.defaultFunc?this.props.custom?a=r.defaultFunc?this.executeCustom(r.defaultFunc,this.props.data,this.props.customObj,this.props.oContext.instanceObj,t.length,this.props.data):this.props.schema.default:a=r.defaultFunc?this.execute(r.defaultFunc,this.props.schema.default,this.props.data,t.length,this.props.data):this.props.schema.default:a=r.default===void 0?null:r.default,i[r.attr]=a,i},{});t.push(s),this.setState({value:t,activeIndex:t.length-1},()=>this.onChangeWrapper(t))});this.props.schema.items=this.props.schema.items||[]}componentDidMount(){super.componentDidMount();let e=f.getValue(this.props.data,this.props.attr)||[];Array.isArray(e)||(e=[]),this.setState({value:e,activeIndex:-1,iteration:0})}componentWillUnmount(){this.typingTimer&&(clearTimeout(this.typingTimer),this.typingTimer=null),super.componentWillUnmount()}itemAccordion(e,t){const{value:s}=this.state,{schema:i}=this.props,r={type:"panel",items:i.items.reduce((a,h)=>(a[h.attr]=h,a),{}),style:{marginLeft:"-8px",marginTop:"10px",marginBottom:"10px"}};return n().createElement(Ot,{oContext:this.props.oContext,index:t+this.state.iteration,arrayIndex:t,changed:this.props.changed,globalData:this.props.data,common:this.props.common,alive:this.props.alive,themeName:this.props.themeName,data:e,custom:!0,schema:r,originalData:this.props.originalData,onChange:(a,h)=>{const S=JSON.parse(JSON.stringify(s));S[t][a]=h,this.setState({value:S},()=>this.onChangeWrapper(S))},onError:(a,h)=>this.onError(a,h),table:this.props.table})}onMoveUp(e){const t=JSON.parse(JSON.stringify(this.state.value)),s=t[e];t.splice(e,1),t.splice(e-1,0,s);const i=this.state.activeIndex-1;this.setState({value:t,activeIndex:i,iteration:this.state.iteration+1e4},()=>this.onChangeWrapper(t))}onMoveDown(e){const t=JSON.parse(JSON.stringify(this.state.value)),s=t[e];t.splice(e,1),t.splice(e+1,0,s);const i=this.state.activeIndex+1;this.setState({value:t,activeIndex:i,iteration:this.state.iteration+1e4},()=>this.onChangeWrapper(t))}renderItem(){const{schema:e}=this.props,{value:t}=this.state;return t?n().createElement(o.Paper,null,e.label||!e.noDelete?n().createElement(o.Toolbar,{variant:"dense"},e.label?n().createElement(o.Typography,{variant:"h6",id:"tableTitle",component:"div"},this.getText(e.label)):null,e.noDelete?null:n().createElement(o.IconButton,{size:"small",color:"primary",onClick:this.onAdd},n().createElement(u.Add,null))):null,t.map((s,i)=>n().createElement(o.Accordion,{key:`${s}_${i}`,expanded:this.state.activeIndex===i,onChange:(r,a)=>this.setState({activeIndex:a?i:-1})},n().createElement(o.AccordionSummary,{expandIcon:n().createElement(u.ExpandMore,null),sx:l.Utils.getStyle(this.props.oContext.theme,Z.fullWidth,Z.accordionSummary)},n().createElement(o.Typography,{style:Z.accordionTitle},s[e.titleAttr])),n().createElement(o.AccordionDetails,{style:q(q({},e.style),this.props.oContext.themeType?e.darkStyle:void 0)},this.itemAccordion(t[i],i),n().createElement(o.Toolbar,{sx:Z.toolbar},i?n().createElement(o.Tooltip,{title:l.I18n.t("ra_Move up"),slotProps:{popper:{sx:Z.tooltip}}},n().createElement(o.IconButton,{size:"small",onClick:()=>this.onMoveUp(i)},n().createElement(u.ArrowUpward,null))):n().createElement("div",{style:Z.buttonEmpty}),ithis.onMoveDown(i)},n().createElement(u.ArrowDownward,null))):n().createElement("div",{style:Z.buttonEmpty}),e.noDelete?null:n().createElement(o.Tooltip,{title:l.I18n.t("ra_Delete current row"),slotProps:{popper:{sx:Z.tooltip}}},n().createElement(o.IconButton,{size:"small",onClick:this.onDelete(i)},n().createElement(u.Delete,null))),e.clone?n().createElement(o.Tooltip,{title:l.I18n.t("ra_Clone current row"),slotProps:{popper:{sx:Z.tooltip}}},n().createElement(o.IconButton,{size:"small",onClick:this.onClone(i)},n().createElement(u.ContentCopy,null))):null)))),!e.noDelete&&t.length>0?n().createElement(o.Toolbar,{variant:"dense",sx:Z.rootTool},n().createElement(o.IconButton,{size:"small",color:"primary",onClick:this.onAdd},n().createElement(u.Add,null))):null,e.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null):null}}const H=j,ie={root:{width:"100%"},notAlive:{color:"#a30000"}};class le extends f{componentDidMount(){super.componentDidMount();const c=this.getInstance();this.props.oContext.socket.getState(`${c}.alive`).then(e=>this.setState({alive:!!(e&&e.val),instance:c}))}getInstance(){let c=this.props.schema.instance||`${this.props.oContext.adapterName}.${this.props.oContext.instance}`;return c.includes("${")&&(c=this.getPattern(c,null,!0)),c&&!c.startsWith("system.adapter.")&&(c=`system.adapter.${c}`),c}renderItem(){if(this.getInstance()!==this.state.instance&&setTimeout(()=>{const e=this.getInstance();e?this.props.oContext.socket.getState(`${e}.alive`).then(t=>this.setState({alive:!!(t&&t.val),instance:e})):this.setState({alive:null,instance:e})},200),this.state.alive!==!1&&this.state.alive!==!0)return null;const c=this.state.instance.replace(/^system.adapter./,"");return n().createElement("div",{style:q(q({},ie.root),this.state.alive?void 0:ie.notAlive)},this.state.alive?this.props.schema.textAlive!==void 0?this.props.schema.textAlive?l.I18n.t(this.props.schema.textAlive,c):"":l.I18n.t("ra_Instance %s is alive",c):this.props.schema.textNotAlive!==void 0?this.props.schema.textNotAlive?l.I18n.t(this.props.schema.textNotAlive,c):"":l.I18n.t("ra_Instance %s is not alive",c))}}const M=le;class w extends f{componentDidMount(){super.componentDidMount();const c=f.getValue(this.props.data,this.props.attr),e=this.props.schema.options.map(t=>typeof t=="string"?{label:t,value:t}:JSON.parse(JSON.stringify(t)));Array.isArray(c)?(e.unshift({label:l.I18n.t(f.DIFFERENT_LABEL),value:f.DIFFERENT_VALUE}),this.setState({value:f.DIFFERENT_VALUE,selectOptions:e})):this.setState({value:c,selectOptions:e})}renderItem(c,e){if(!this.state.selectOptions)return null;let t;const s=JSON.parse(JSON.stringify(this.state.selectOptions));return Array.isArray(this.state.value)||this.state.value===f.DIFFERENT_VALUE?([...this.state.value].filter(r=>!s.find(a=>typeof a=="object"?a.value===r:a===r)).forEach(r=>s.push({label:r.toString(),value:r})),t={label:l.I18n.t(f.DIFFERENT_LABEL),value:f.DIFFERENT_VALUE},s.unshift(t)):(t=this.state.value!==null&&this.state.value!==void 0&&s.find(r=>typeof r=="object"?r.value==this.state.value:r==this.state.value),this.state.value!==null&&this.state.value!==void 0&&!t&&this.props.schema.freeSolo&&(t={value:this.state.value,label:this.state.value},s.push(t))),n().createElement(o.Autocomplete,{fullWidth:!0,freeSolo:!!this.props.schema.freeSolo,value:t,options:s,isOptionEqualToValue:(r,a)=>r.value===a.value,filterOptions:(r,a)=>{const h=r.filter(S=>a.inputValue===""?!0:S.label.toLowerCase().includes(a.inputValue.toLowerCase())||S.value.toLowerCase().includes(a.inputValue.toLowerCase()));return this.props.schema.freeSolo&&a.inputValue!==""&&h.push({label:a.inputValue,value:a.inputValue}),h},onInputChange:r=>{if(!r||!this.props.schema.freeSolo)return;const a=r.target.value;a!==this.state.value&&this.setState({value:a},()=>this.onChange(this.props.attr,a))},onChange:(r,a)=>{const h=typeof a=="object"?a?a.value:"":a;h!==this.state.value&&this.setState({value:h},()=>this.onChange(this.props.attr,h))},getOptionLabel:r=>{var a;return typeof r=="object"&&(a=r==null?void 0:r.label)!=null?a:""},renderInput:r=>n().createElement(o.TextField,Oe(q({variant:"standard"},r),{error:!!c,placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation),disabled:e}))})}}const y=w;class p extends f{constructor(){super(...arguments);Q(this,"initialized",!1);Q(this,"localContext")}askInstance(){const e=f.getValue(this.props.data,this.props.attr),t=this.props.schema.options?this.props.schema.options.map(s=>typeof s=="string"?{label:s,value:s}:JSON.parse(JSON.stringify(s))):[];if(this.props.alive){let s=this.props.schema.data;if(s===void 0&&this.props.schema.jsonData){const i=this.getPattern(this.props.schema.jsonData,null,!0);try{typeof i=="string"&&(s=JSON.parse(i))}catch(r){console.error(`Cannot parse json data: ${JSON.stringify(s)}`)}}s===void 0&&(s=null),this.props.oContext.socket.sendTo(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,this.props.schema.command||"send",s).then(i=>{i&&Array.isArray(i)&&i.forEach(r=>t.push(typeof r=="string"?{label:r,value:r}:JSON.parse(JSON.stringify(r)))),Array.isArray(e)?(t.unshift({label:l.I18n.t(f.DIFFERENT_LABEL),value:f.DIFFERENT_VALUE}),this.setState({value:f.DIFFERENT_VALUE,selectOptions:t})):this.setState({value:e,selectOptions:t})})}else Array.isArray(e)?(t.unshift({label:l.I18n.t(f.DIFFERENT_LABEL),value:f.DIFFERENT_VALUE}),this.setState({value:f.DIFFERENT_VALUE,selectOptions:t})):this.setState({value:e,selectOptions:t})}getContext(){const e={};return Array.isArray(this.props.schema.alsoDependsOn)&&this.props.schema.alsoDependsOn.forEach(t=>e[t]=f.getValue(this.props.data,t)),JSON.stringify(e)}renderItem(e,t){if(this.props.alive){const a=this.getContext();(a!==this.localContext||!this.initialized)&&(this.localContext=a,setTimeout(()=>this.askInstance(),this.initialized?300:50),this.initialized=!0)}let s;const i=this.state.selectOptions?JSON.parse(JSON.stringify(this.state.selectOptions)):[];return Array.isArray(this.state.value)||this.state.value===f.DIFFERENT_LABEL?([...this.state.value].filter(a=>!i.find(h=>h.value===a)).forEach(a=>i.push({label:a.toString(),value:a})),s={label:l.I18n.t(f.DIFFERENT_LABEL),value:f.DIFFERENT_VALUE},i.unshift(s)):(s=this.state.value!==null&&this.state.value!==void 0&&i.find(a=>a.value==this.state.value),this.state.value!==null&&this.state.value!==void 0&&!s&&this.props.schema.freeSolo&&(s={value:this.state.value,label:this.state.value},i.push(s)),s=s||null),i.length?n().createElement(o.Autocomplete,{value:s,fullWidth:!0,freeSolo:!!this.props.schema.freeSolo,options:i,isOptionEqualToValue:(a,h)=>a.value===h.value,filterOptions:(a,h)=>{const S=a.filter(L=>h.inputValue===""?!0:L.label.toLowerCase().includes(h.inputValue.toLowerCase())||L.value.toLowerCase().includes(h.inputValue.toLowerCase()));return this.props.schema.freeSolo&&h.inputValue!==""&&S.push({label:h.inputValue,value:h.inputValue}),S},getOptionLabel:a=>{var h;return(h=a==null?void 0:a.label)!=null?h:""},onInputChange:a=>{if(!a||!this.props.schema.freeSolo)return;const h=a.target.value;h!==this.state.value&&this.setState({value:h},()=>this.onChange(this.props.attr,h))},onChange:(a,h)=>{const S=typeof h=="object"?h?h.value:"":h;S!==this.state.value&&this.setState({value:S},()=>this.onChange(this.props.attr,S))},renderInput:a=>n().createElement(o.TextField,Oe(q({variant:"standard"},a),{error:!!e,placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation),disabled:t}))}):n().createElement(o.TextField,{variant:"standard",fullWidth:!0,value:this.state.value===null||this.state.value===void 0?"":this.state.value,error:!!e,disabled:t,slotProps:{htmlInput:{maxLength:this.props.schema.maxLength||this.props.schema.max||void 0}},onChange:a=>{const h=a.target.value;this.setState({value:h},()=>this.onChange(this.props.attr,(h||"").trim()))},placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)})}}const g=p,d={fullWidth:{width:"100%"},flex:{display:"flex"},button:{height:48,marginLeft:4,minWidth:48}};class x extends f{componentDidMount(){super.componentDidMount();const{data:c,attr:e}=this.props,t=f.getValue(c,e)||"";this.setState({value:t,showDialog:!1})}renderItem(c,e){const{schema:t,attr:s}=this.props,{value:i,showDialog:r}=this.state;return n().createElement(o.FormControl,{style:d.fullWidth,variant:"standard"},t.label?n().createElement(o.InputLabel,{shrink:!0},this.getText(t.label)):null,n().createElement("div",{style:d.flex},n().createElement(o.TextField,{variant:"standard",fullWidth:!0,value:i!=null?i:"",error:!!c,disabled:e,placeholder:this.getText(t.placeholder),label:this.getText(t.label),helperText:this.renderHelp(t.help,t.helpLink,t.noTranslation),onChange:a=>{const h=a.target.value;this.setState({value:h},()=>this.onChange(s,h))}}),n().createElement(o.Button,{color:"grey",disabled:e,style:d.button,size:"small",variant:"outlined",onClick:()=>this.setState({showDialog:!0})},"...")),r?n().createElement(l.DialogCron,{title:l.I18n.t("ra_Define schedule"),simple:t.simple,complex:t.complex,cron:i,onClose:()=>this.setState({showDialog:!1}),cancel:l.I18n.t("ra_Cancel"),ok:l.I18n.t("ra_Ok"),theme:this.props.oContext.theme,onOk:a=>this.setState({showDialog:!1,value:a},()=>this.onChange(s,a))}):null)}}const b=x;class B extends f{componentDidMount(){return pe(this,null,function*(){nt(B.prototype,this,"componentDidMount").call(this);const c=f.getValue(this.props.data,this.props.attr),t=(yield this.props.oContext.socket.getCertificates()).filter(s=>{const i=this.props.attr.toLowerCase();return i.includes(s.type)||s.type==="public"&&i.includes("cert")||s.type==="private"&&(i.includes("priv")||i.includes("key"))?!0:!!(s.type==="chained"&&(i.includes("chain")||i.includes("ca")))}).map(s=>({label:s.name,value:s.name}));t.unshift({label:l.I18n.t(f.NONE_LABEL),value:f.NONE_VALUE}),this.setState({value:c,selectOptions:t})})}renderItem(c,e){var s,i;if(!this.state.selectOptions)return null;const t=(s=this.state.selectOptions)==null?void 0:s.find(r=>r.value===this.state.value);return n().createElement(o.FormControl,{style:{width:"100%"},variant:"standard"},this.props.schema.label?n().createElement(o.InputLabel,{shrink:!0},this.getText(this.props.schema.label)):null,n().createElement(o.Select,{variant:"standard",error:!!c,displayEmpty:!0,disabled:!!e,value:this.state.value,renderValue:()=>this.getText(t==null?void 0:t.label,this.props.schema.noTranslation!==!1),onChange:r=>this.setState({value:r.target.value},()=>this.onChange(this.props.attr,this.state.value))},(i=this.state.selectOptions)==null?void 0:i.map(r=>n().createElement(o.MenuItem,{key:r.value,value:r.value,style:r.value===f.NONE_VALUE?{opacity:.5}:{}},this.getText(r.label,this.props.schema.noTranslation!==!1)))),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const $=B,k={fullWidth:{width:"100%"},leWidth:{width:620,marginBottom:10},certWidth:{width:200,marginRight:10}};class F extends f{componentDidMount(){return pe(this,null,function*(){var a;nt(F.prototype,this,"componentDidMount").call(this);const c=yield this.props.oContext.socket.getCertificates(),e=[],t=[],s=[];let i=[];const r=yield this.props.oContext.socket.getObject("system.certificates");(a=r==null?void 0:r.native)!=null&&a.collections?i=Object.keys(r.native.collections):i=null,c.forEach(h=>{h.type==="public"?e.push({label:h.name,value:h.name}):h.type==="private"?t.push({label:h.name,value:h.name}):h.type==="chained"?s.push({label:h.name,value:h.name}):(e.push({label:h.name,value:h.name}),t.push({label:h.name,value:h.name}),s.push({label:h.name,value:h.name}))}),e.unshift({label:l.I18n.t(f.NONE_LABEL),value:f.NONE_VALUE}),t.unshift({label:l.I18n.t(f.NONE_LABEL),value:f.NONE_VALUE}),s.unshift({label:l.I18n.t(f.NONE_LABEL),value:f.NONE_VALUE}),this.setState({certsPublicOptions:e,certsChainOptions:s,certsPrivateOptions:t,collectionsOptions:i})})}renderItem(c,e){var L,O,N,te,ye,se,Ee;if(!this.state.certsPublicOptions||!this.state.certsPrivateOptions||!this.state.certsChainOptions)return null;const t=(f.getValue(this.props.data,this.props.schema.leCollectionName||"leCollection")||"false").toString(),s=f.getValue(this.props.data,this.props.schema.certPublicName||"certPublic"),i=f.getValue(this.props.data,this.props.schema.certPrivateName||"certPrivate"),r=f.getValue(this.props.data,this.props.schema.certChainedName||"certChained"),a=(L=this.state.certsPublicOptions)==null?void 0:L.find(me=>me.value===s),h=(O=this.state.certsPrivateOptions)==null?void 0:O.find(me=>me.value===i),S=(N=this.state.certsChainOptions)==null?void 0:N.find(me=>me.value===r);return n().createElement("div",{style:k.fullWidth},this.state.collectionsOptions?n().createElement(o.FormControl,{style:k.leWidth,variant:"standard"},n().createElement(o.InputLabel,{shrink:!0},"Let's encrypt"),n().createElement(o.Select,{variant:"standard",error:!!c,displayEmpty:!0,disabled:!!e,value:t,onChange:me=>this.onChange(this.props.schema.leCollectionName||"leCollection",me.target.value==="false"?!1:me.target.value==="true"?!0:me.target.value)},n().createElement(o.MenuItem,{key:"_false",value:"false",style:{fontWeight:"bold"}},l.I18n.t("ra_Do not use let's encrypt")),n().createElement(o.MenuItem,{key:"_true",value:"true",style:{fontWeight:"bold"}},l.I18n.t("ra_Use all available let's encrypt certificates")),(te=this.state.collectionsOptions)==null?void 0:te.map(me=>n().createElement(o.MenuItem,{key:me,value:me},me)))):null,this.state.collectionsOptions?n().createElement("br",null):null,this.state.collectionsOptions&&t!=="false"?n().createElement("div",null,l.I18n.t("ra_Fallback custom certificates")):null,n().createElement(o.FormControl,{style:k.certWidth,variant:"standard"},n().createElement(o.InputLabel,{shrink:!0},l.I18n.t("ra_Public certificate")),n().createElement(o.Select,{variant:"standard",error:!!c,displayEmpty:!0,disabled:!!e,value:s||"",renderValue:()=>this.getText(a==null?void 0:a.label),onChange:me=>this.onChange(this.props.schema.certPublicName||"certPublic",me.target.value)},(ye=this.state.certsPublicOptions)==null?void 0:ye.map((me,Me)=>n().createElement(o.MenuItem,{key:`${me.value}_${Me}`,value:me.value,style:me.value===f.NONE_VALUE?{opacity:.5}:{}},this.getText(me.label))))),n().createElement(o.FormControl,{style:k.certWidth,variant:"standard"},n().createElement(o.InputLabel,{shrink:!0},l.I18n.t("ra_Private certificate")),n().createElement(o.Select,{variant:"standard",error:!!c,displayEmpty:!0,disabled:!!e,value:i||"",renderValue:()=>this.getText(h==null?void 0:h.label),onChange:me=>this.onChange(this.props.schema.certPrivateName||"certPrivate",me.target.value)},(se=this.state.certsPrivateOptions)==null?void 0:se.map((me,Me)=>n().createElement(o.MenuItem,{key:`${me.value}_${Me}`,value:me.value,style:me.value===f.NONE_VALUE?{opacity:.5}:{}},this.getText(me.label))))),n().createElement(o.FormControl,{style:k.certWidth,variant:"standard"},n().createElement(o.InputLabel,{shrink:!0},l.I18n.t("ra_Chained certificate")),n().createElement(o.Select,{variant:"standard",error:!!c,displayEmpty:!0,disabled:!!e,value:r||"",renderValue:()=>this.getText(S==null?void 0:S.label),onChange:me=>this.onChange(this.props.schema.certChainedName||"certChained",me.target.value)},(Ee=this.state.certsChainOptions)==null?void 0:Ee.map((me,Me)=>n().createElement(o.MenuItem,{key:`${me.value}_${Me}`,value:me.value,style:me.value===f.NONE_VALUE?{opacity:.5}:{}},this.getText(me.label))))))}}const I=F;class U extends f{componentDidMount(){return pe(this,null,function*(){var t;nt(U.prototype,this,"componentDidMount").call(this);let c;const e=yield this.props.oContext.socket.getObject("system.certificates");(t=e==null?void 0:e.native)!=null&&t.collections?c=Object.keys(e.native.collections):c=[],this.setState({collectionsOptions:c})})}renderItem(c,e){var s;if(!this.state.collectionsOptions)return null;const t=(f.getValue(this.props.data,this.props.schema.leCollectionName||"leCollection")||"false").toString();return n().createElement(o.FormControl,{style:{width:"100%"},variant:"standard"},this.props.schema.label?n().createElement(o.InputLabel,{shrink:!0},this.getText(this.props.schema.label)):null,n().createElement(o.Select,{variant:"standard",error:!!c,displayEmpty:!0,disabled:!!e,value:t,onChange:i=>this.onChange(this.props.schema.leCollectionName||"leCollection",i.target.value==="false"?!1:i.target.value==="true"?!0:i.target.value)},n().createElement(o.MenuItem,{key:"_false",value:"false",style:{fontWeight:"bold"}},l.I18n.t("ra_Do not use let's encrypt")),n().createElement(o.MenuItem,{key:"_true",value:"true",style:{fontWeight:"bold"}},l.I18n.t("ra_Use all available let's encrypt certificates")),(s=this.state.collectionsOptions)==null?void 0:s.map(i=>n().createElement(o.MenuItem,{key:i,value:i},i))),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const re=U,X={fullWidth:{width:"100%"},icon:{width:24,height:24,marginRight:4},licLabel:{fontWeight:"bold",minWidth:100,marginRight:10,textTransform:"capitalize",display:"inline-block"},licValue:{fontWeight:"normal"},errorTitle:E=>({color:E.palette.mode==="dark"?"#e39191":"#b62020"}),okTitle:E=>({color:E.palette.mode==="dark"?"#6fd56f":"#007c00"}),errorText:E=>({color:E.palette.mode==="dark"?"#e39191":"#b62020",mb:"30px"})};class ae extends f{componentDidMount(){super.componentDidMount(),this.setState({_error:"",running:!1,showLicenseData:null,foundSuitableLicense:!1,licenseOfflineCheck:!1,result:null,allLicenses:null,askForUpdate:!1,showLinkToProfile:!1})}renderErrorDialog(){if(this.state._error&&!this.state.showLicenseData){let c=this.state._error;return this.state.allLicenses&&(c=[n().createElement("div",{key:"error"},c)],c.push(n().createElement(o.Button,{key:"button",variant:"contained",onClick:()=>window.open("https://iobroker.net/www/account/licenses","_blank")},l.I18n.t("iobroker.net"))),this.state.allLicenses.length?c.push(n().createElement(o.TableContainer,{key:"table"},n().createElement(o.Table,{size:"small"},n().createElement(o.TableHead,null,n().createElement(o.TableRow,null,n().createElement(o.TableCell,null,l.I18n.t("ra_Product")),n().createElement(o.TableCell,null,l.I18n.t("ra_Version")),n().createElement(o.TableCell,null,"UUID"),n().createElement(o.TableCell,null,l.I18n.t("ra_ValidTill")),n().createElement(o.TableCell,null,l.I18n.t("ra_Commercial")),n().createElement(o.TableCell,null,"ID"))),n().createElement(o.TableBody,null,this.state.allLicenses.map(e=>n().createElement(o.TableRow,{key:e.id},n().createElement(o.TableCell,{sx:e.validName?null:X.errorText},e.license.product),n().createElement(o.TableCell,{sx:e.validVersion?null:X.errorText},e.license.version),n().createElement(o.TableCell,{sx:e.validUuid?null:X.errorText},e.license.uuid||"--"),n().createElement(o.TableCell,{sx:e.validTill?null:X.errorText},e.license.validTill&&e.license.validTill!=="0000-00-00 00:00:00"?new Date(e.license.validTill).toLocaleDateString():"--"),n().createElement(o.TableCell,null,e.license.invoice!=="free"?e.license.invoice==="MANUALLY_CREATED"?"\u2713":e.license.invoice:"-"),n().createElement(o.TableCell,null,e.id))))))):(c.push(n().createElement("div",{key:"text1"},l.I18n.t("ra_No one license found in license manager"))),c.push(n().createElement("div",{key:"text2"},l.I18n.t("ra_Please create license"))))),n().createElement(o.Dialog,{open:!0,maxWidth:"xl",fullWidth:this.props.fullWidth!==void 0?this.props.fullWidth:!0,onClick:()=>this.setState({_error:"",allLicenses:null})},n().createElement(o.DialogTitle,null,l.I18n.t("ra_Error")),n().createElement(o.DialogContent,null,n().createElement(o.DialogContentText,null,c)),n().createElement(o.DialogActions,null,n().createElement(o.Button,{variant:"contained",onClick:()=>this.setState({_error:"",allLicenses:null}),color:"primary",autoFocus:!0,startIcon:n().createElement(u.Check,null)},l.I18n.t("ra_Ok"))))}return null}renderMessageDialog(){if(this.state.showLicenseData){const c=[],e=this.state.showLicenseData;return Object.keys(e).forEach(t=>{if(!(e[t]===null||e[t]===void 0))if(typeof e[t]=="object"){const s=e[t];Object.keys(s).forEach(i=>{s[i]!==null&&s[i]!==void 0&&(typeof s[i]=="object"?c.push(n().createElement("div",{key:i},n().createElement("div",{style:X.licLabel},i,":"),JSON.stringify(s[i],null,2))):c.push(n().createElement("div",{key:i},n().createElement("div",{style:X.licLabel},t," -",i,":"),s[i].toString())))})}else c.push(n().createElement("div",{key:t},n().createElement("div",{style:X.licLabel},t.replace(/_/g," "),":"),e[t].toString()))}),c.push(n().createElement("div",{key:"checked"},n().createElement("div",{style:X.licLabel},l.I18n.t("ra_Checked"),":"),this.state.licenseOfflineCheck?l.I18n.t("ra_locally"):l.I18n.t("ra_via internet"))),n().createElement(o.Dialog,{open:!0,onClose:()=>this.setState({showLicenseData:null})},n().createElement(o.DialogTitle,null,n().createElement(o.Box,{component:"span",sx:this.state.result?X.okTitle:X.errorTitle},l.I18n.t("ra_License %s",this.state.result?"OK":"INVALID"))),n().createElement(o.DialogContent,null,this.state.showLinkToProfile?n().createElement(o.Button,{variant:"contained",onClick:()=>window.open("https://iobroker.net/www/account/licenses","_blank")},"https://iobroker.net"):null,this.state._error?n().createElement(o.Box,{component:"div",sx:X.errorText},this.state._error):null,c),n().createElement(o.DialogActions,null,n().createElement(o.Button,{onClick:()=>this.setState({showLicenseData:null,_error:""}),color:"primary",variant:"contained"},l.I18n.t("ra_Close"))))}return null}static parseJwt(c){const t=c.split(".")[1].replace(/-/g,"+").replace(/_/g,"/"),s=decodeURIComponent(atob(t).split("").map(i=>`%${`00${i.charCodeAt(0).toString(16)}`.slice(-2)}`).join(""));try{return JSON.parse(s)}catch(i){return null}}static isVersionValid(c,e,t,s){if(!e||!c)return!0;let i=!0;const[r]=c.split(".");return e.startsWith(">=")?i=parseInt(r,10)>=parseInt(e.substring(2,10)):e.startsWith("<=")?i=parseInt(r,10)<=parseInt(e.substring(2,10)):e.startsWith(">")?i=parseInt(r,10)>parseInt(e.substring(1,10)):e.startsWith("<")?i=parseInt(r,10){const te=!N.validTill||N.validTill==="0000-00-00 00:00:00"||new Date(N.validTill).getTime()>S,ye=(N.product||"").split("."),se=ye[1]===c||c==="vis-2"&&ye[1]==="vis",Ee=!L||!N.uuid||N.uuid===L,me=ae.isVersionValid(O,N.version,N.invoice,c);(!h||N.invoice!=="free")&&te&&se&&Ee&&me&&(h=N),t.push({id:N.id,validName:se,validUuid:Ee,validVersion:me,validTill:te,license:N})}),h&&(t.find(N=>N.id===h.id).used=!0)}return t})}checkLicense(c,e){return pe(this,null,function*(){var a,h,S;let t;if(this.props.schema.uuid){const L=yield this.props.oContext.socket.getObject("system.meta.uuid");t=(a=L==null?void 0:L.native)==null?void 0:a.uuid}let s;if(this.props.schema.version){const L=yield this.props.oContext.socket.getObject(`system.adapter.${e}`);s=(h=L==null?void 0:L.common)==null?void 0:h.version}const i=new AbortController;let r=setTimeout(()=>{r=null,i.abort()},5e3);try{const L=yield window.fetch("https://iobroker.net/api/v1/public/cert/",{method:"POST",body:JSON.stringify({json:c,uuid:t}),headers:{"Content-Type":"text/plain"},signal:i.signal});r&&clearTimeout(r);const O=yield L.text();let N;try{N=JSON.parse(O)}catch(te){}if(N!=null&&N.error)try{const te=ae.parseJwt(c),ye=l.I18n.t(`ra_${te.error||N.error||"Unknown error"}`).replace(/^ra_/,"");return this.setState({_error:ye,licenseOfflineCheck:!1,showLicenseData:te,result:!1,running:!1})}catch(te){return console.log("Cannot parse license"),this.setState({_error:N.error,result:!1,running:!1})}else{let te=null;try{te=ae.parseJwt(c)}catch(ye){}if(N){const ye=N.validTill||N.valid_till;if(ye&&ye!=="0000-00-00 00:00:00"&&new Date(ye).getTime()pe(this,null,function*(){if(c){this.setState({askForUpdate:!1});try{yield this.props.oContext.socket.updateLicenses(null,null)}catch(e){window.alert(l.I18n.t("ra_Cannot read licenses: %s",e));return}yield this._onClick(!0)}else this.setState({askForUpdate:!1,running:!1})})}):null}_onClick(c){return pe(this,null,function*(){const e=this.props.oContext.adapterName==="vis-2"?"vis":this.props.oContext.adapterName;this.setState({running:!0});let t,s;if(this.props.data.useLicenseManager){if(s=yield this.findInLicenseManager(e),t=s.find(i=>i.used),t&&(t=t.license.json),!t&&!c){this.setState({askForUpdate:!0});return}}else t=this.props.data.license;t?yield this.checkLicense(t,e):this.props.data.useLicenseManager?this.setState({_error:l.I18n.t("ra_Suitable license not found in license manager"),result:!1,running:!1,allLicenses:s}):this.setState({_error:l.I18n.t("ra_Please enter the license"),result:!1,running:!1})})}renderItem(){return n().createElement("div",{style:X.fullWidth},n().createElement(o.Button,{variant:this.props.schema.variant||"outlined",color:this.props.schema.color||"primary",style:X.fullWidth,disabled:!this.props.data.license&&!this.props.data.useLicenseManager||this.state.running,startIcon:n().createElement(u.Send,null),onClick:()=>this._onClick()},this.state.running?n().createElement(o.CircularProgress,{size:20,style:{marginRight:8}}):null,this.getText(this.props.schema.label||"ra_Check license",this.props.schema.noTranslation)),this.renderMessageDialog(),this.renderErrorDialog(),this.renderAskForUpdate())}}const ce=ae;class W extends f{renderItem(c,e){const t=f.getValue(this.props.data,this.props.attr),s=Array.isArray(t);return n().createElement(o.FormControl,{style:{width:"100%"},variant:"standard"},n().createElement(o.FormControlLabel,{onClick:i=>{if(i.preventDefault(),i.stopPropagation(),!e){const r=this.onChange(this.props.attr,!t);r instanceof Promise&&r.catch(a=>console.error(`Cannot set value: ${a}`))}},control:n().createElement(o.Checkbox,{indeterminate:s,checked:!!t,onChange:i=>{let r;s?r=this.onChange(this.props.attr,!0):r=this.onChange(this.props.attr,i.target.checked),r instanceof Promise&&r.catch(a=>console.error(`Cannot set value: ${a}`))},disabled:e||this.props.schema.readOnly}),label:this.getText(this.props.schema.label)}),n().createElement(o.FormHelperText,{style:{color:"red"}},c?this.props.schema.validatorErrorText?l.I18n.t(this.props.schema.validatorErrorText):l.I18n.t("ra_Error"):null),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const K=W;var z=Y(3479),G=Y.n(z),Ve=Y(8625),ge=Y(4603);const _e={standard:o.Input,filled:Ve.A,outlined:o.OutlinedInput},ze=E=>{const c=E.palette.mode==="light",e=c?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return{root:{},inputRoot:{display:"inline-flex",flexWrap:"wrap",flex:1,marginTop:0,minWidth:70,"&.mui-variant-outlined,&.mui-variant-filled":{boxSizing:"border-box"},"&.mui-variant-outlined":{paddingTop:"14px"},"&.mui-variant-filled":{paddingTop:"28px"}},input:{display:"inline-block",textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap",appearance:"none",WebkitTapHighlightColor:"rgba(0,0,0,0)",float:"left",flex:1},chipContainer:{display:"flex",flexFlow:"row wrap",alignItems:"center",cursor:"text",marginBottom:"-2px",minHeight:40},outlined:{"& input":{height:16,paddingTop:"4px",paddingBottom:"12px",marginTop:"4px",marginBottom:"4px"}},standard:{marginTop:"18px"},filled:{"& input":{height:22,marginBottom:"4px",marginTop:"4px",paddingTop:0},"$marginDense & input":{height:26}},labeled:{},label:{top:4,"&$outlined&:not($labelShrink)":{top:2,"$marginDense &":{top:5}},"&$filled&:not($labelShrink)":{top:15,"$marginDense &":{top:20}}},labelShrink:{top:0},helperText:{marginBottom:-20},focused:{},disabled:{},underline:{"&:after":{borderBottom:`2px solid ${E.palette.primary[c?"dark":"light"]}`,left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:E.transitions.create("transform",{duration:E.transitions.duration.shorter,easing:E.transitions.easing.easeOut}),pointerEvents:"none"},"&$focused:after":{transform:"scaleX(1)"},"&$error:after":{borderBottomColor:E.palette.error.main,transform:"scaleX(1)"},"&:before":{borderBottom:`1px solid ${e}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:E.transitions.create("border-bottom-color",{duration:E.transitions.duration.shorter}),pointerEvents:"none"},"&:hover:not($disabled):not($focused):not($error):before":{borderBottom:`2px solid ${E.palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${e}`}},"&$disabled:before":{borderBottomStyle:"dotted"}},error:{"&:after":{backgroundColor:E.palette.error.main,transform:"scaleX(1)"}},chip:{margin:"0 8px 8px 0",float:"left"},marginDense:{}}},xe={BACKSPACE:8,DELETE:46,LEFT_ARROW:37,RIGHT_ARROW:39},at=({value:E,isFocused:c,isDisabled:e,isReadOnly:t,handleClick:s,handleDelete:i,style:r},a)=>n().createElement(o.Chip,{key:a,style:Oe(q({},r),{pointerEvents:e||t?"none":void 0,backgroundColor:c?ge.A[300]:void 0}),onClick:s,onDelete:i,label:E});class lt extends n().Component{constructor(e){super(e);Q(this,"labelRef");Q(this,"labelNode",null);Q(this,"input");Q(this,"newChipKeyCodes");Q(this,"newChipKeys");Q(this,"actualInput",null);Q(this,"inputBlurTimeout",null);Q(this,"_keyPressed");Q(this,"_preventChipCreation");Q(this,"styles",{});Q(this,"styleTheme",null);Q(this,"focus",()=>{var e;(e=this.actualInput)==null||e.focus(),this.state.focusedChip&&this.setState({focusedChip:null})});Q(this,"handleInputBlur",e=>{this.props.onBlur&&this.props.onBlur(e),this.setState({isFocused:!1}),this.state.focusedChip&&this.setState({focusedChip:null});const t=e.target.value;let s;switch(this.props.blurBehavior||"clear"){case"add-or-clear":s={clearInputOnFail:!0};case"add":if(this.props.delayBeforeAdd){const i=(this.props.value||this.state.chips).length;this.inputBlurTimeout=setTimeout(()=>{const r=(this.props.value||this.state.chips).length;i===r?this.handleAddChip(t,s):this.clearInput()},150)}else this.handleAddChip(t,s);break;case"clear":this.clearInput();break;default:break}});Q(this,"handleInputFocus",e=>{this.setState({isFocused:!0}),this.props.onFocus&&this.props.onFocus(e)});Q(this,"handleKeyDown",e=>{const{focusedChip:t}=this.state;if(this._keyPressed=!1,this._preventChipCreation=!1,this.props.onKeyDown&&(this.props.onKeyDown(e),e.isDefaultPrevented()))return;const s=this.props.value||this.state.chips;if(this.newChipKeyCodes.includes(e.keyCode)||this.newChipKeys.includes(e.key)){this.handleAddChip(e.target.value)!==!1&&e.preventDefault();return}switch(e.keyCode){case xe.BACKSPACE:e.target.value===""&&(t?(this.handleDeleteChip(s[t],t),t&&this.setState({focusedChip:t-1})):this.setState({focusedChip:s.length-1}));break;case xe.DELETE:e.target.value===""&&t&&(this.handleDeleteChip(s[t],t),t<=s.length-1&&this.setState({focusedChip:t}));break;case xe.LEFT_ARROW:t===null&&e.target.value===""&&s.length?this.setState({focusedChip:s.length-1}):t!==null&&t>0&&this.setState({focusedChip:t-1});break;case xe.RIGHT_ARROW:t!==null&&t{!this._preventChipCreation&&(this.newChipKeyCodes.includes(e.keyCode)||this.newChipKeys.includes(e.key))&&this._keyPressed?this.clearInput():this.updateInput(e.target.value),this.props.onKeyUp&&this.props.onKeyUp(e)});Q(this,"handleUpdateInput",e=>{(this.props.inputValue===null||this.props.inputValue===void 0)&&this.updateInput(e.target.value),this.props.onUpdateInput&&this.props.onUpdateInput(e)});Q(this,"setActualInputRef",e=>{this.actualInput=e,this.props.inputRef&&this.props.inputRef(e)});this.state={chips:e.defaultValue||[],focusedChip:null,inputValue:"",isFocused:!1,chipsUpdated:!1,prevPropsValue:[],variant:this.props.variant||"standard"},this.newChipKeyCodes=e.newChipKeyCodes||[13],this.newChipKeys=e.newChipKeys||["Enter"],this.labelRef=n().createRef(),this.input=n().createRef()}componentDidMount(){this.state.variant==="outlined"&&(this.labelNode=G().findDOMNode(this.labelRef.current),this.forceUpdate())}componentWillUnmount(){this.inputBlurTimeout&&clearTimeout(this.inputBlurTimeout)}static getDerivedStateFromProps(e,t){let s=null;return e.value&&e.value.length!==t.prevPropsValue.length&&(s={prevPropsValue:e.value},e.clearInputValueOnChange&&(s.inputValue="")),e.clearInputValueOnChange&&e.value&&e.value.length!==t.prevPropsValue.length&&(s={prevPropsValue:e.value,inputValue:""}),e.disabled&&(s=Oe(q({},s),{focusedChip:null})),!t.chipsUpdated&&e.defaultValue&&(s=Oe(q({},s),{chips:e.defaultValue})),s}handleAddChip(e,t){if(this.props.onBeforeAdd&&!this.props.onBeforeAdd(e))return this._preventChipCreation=!0,t&&t.clearInputOnFail&&this.clearInput(),!1;this.clearInput();const s=this.props.value||this.state.chips;return e.trim().length?((this.props.allowDuplicates||!s.includes(e))&&(this.props.value&&this.props.onAdd?this.props.onAdd(e):this.updateChips([...this.state.chips,e])),!0):!1}handleDeleteChip(e,t){if(this.props.value)this.props.onDelete&&this.props.onDelete(e,t);else{const s=this.state.chips.slice();if(s.splice(t,1)){let r=this.state.focusedChip;this.state.focusedChip===t?r=null:this.state.focusedChip>t&&(r=this.state.focusedChip-1),this.updateChips(s,{focusedChip:r})}}}updateChips(e,t={}){this.setState(q({chips:e,chipsUpdated:!0},t)),this.props.onChange&&this.props.onChange(e)}clearInput(){this.updateInput("")}updateInput(e){this.setState({inputValue:e})}render(){const{alwaysShowPlaceholder:e,chipRenderer:t=at,className:s,disabled:i,disableUnderline:r,error:a,FormHelperTextProps:h,fullWidth:S,fullWidthInput:L,helperText:O,id:N,InputProps:te={},InputLabelProps:ye={},inputValue:se,label:Ee,placeholder:me,readOnly:Me,required:yt,rootRef:Jt,value:pn,margin:_n}=this.props,tt=this.state.variant;this.styleTheme!==this.props.theme.palette.mode&&(this.styleTheme=this.props.theme.palette.mode,this.styles=l.Utils.getStyle(this.props.theme,ze));let Tt=pn||this.state.chips||[];Array.isArray(Tt)||(Tt=(Tt||"").toString().split(/[,\s]+/).map(qt=>qt.trim()));const dn=se!=null?se:this.state.inputValue,kn=(this.props.value||dn).length||dn.length,Ht=typeof ye.shrink=="boolean"?ye.shrink:Ee!==null&&(kn||this.state.isFocused||Tt.length),Bn=Tt.map((qt,Kt)=>t({value:qt,isDisabled:!!i,isReadOnly:Me,isFocused:this.state.focusedChip===Kt,handleClick:()=>this.setState({focusedChip:Kt}),handleDelete:()=>this.handleDeleteChip(qt,Kt),style:this.styles.chip},Kt.toString())),zt={};tt==="outlined"&&(zt.notched=!!Ht,zt.labelWidth=Ht&&this.labelNode&&this.labelNode.offsetWidth||0),tt!=="standard"?zt.startAdornment=Bn:te.disableUnderline=!0;const js=_e[tt];return n().createElement(o.FormControl,{ref:Jt,fullWidth:S,className:s,sx:q(q({},this.styles.root),_n==="dense"?this.styles.marginDense:{}),error:a,required:Tt.length>0?void 0:yt,onClick:this.focus,disabled:i,variant:tt,component:"div",margin:_n},Ee&&n().createElement(o.InputLabel,q({htmlFor:N,sx:{"&.MuiInputLabel-root":this.styles.label,"&.MuiInputLabel-shrink":this.styles.labelShrink},shrink:!!Ht,focused:this.state.isFocused,variant:tt,ref:this.labelRef,required:yt,component:"label"},ye),Ee),n().createElement(o.Box,{component:"div",id:"input-chip-container",sx:q(q(q(q(q(q(q({},this.styles[tt]),this.styles.chipContainer),this.state.isFocused?this.styles.focused:void 0),!r&&tt==="standard"?this.styles.underline:void 0),i?this.styles.disabled:void 0),Ee?this.styles.labeled:void 0),a?this.styles.error:void 0)},tt==="standard"&&Bn,n().createElement(js,q(q({ref:this.input,className:`mui-variant-${this.styles[tt]} ${Ee?"mui-chip-with-label":"mui-chip-no-label"}`,sx:{"&.MuiInputBase-input":q(q({},this.styles.input),this.styles[tt]),"&.MuiInputBase-root":q({},this.styles.inputRoot)},id:N,value:dn,onChange:this.handleUpdateInput,onKeyDown:this.handleKeyDown,onKeyUp:this.handleKeyUp,onFocus:this.handleInputFocus,onBlur:this.handleInputBlur,inputRef:this.setActualInputRef,disabled:i,fullWidth:L,placeholder:!kn&&(Ht||Ee===null||Ee===void 0)||e?me:null,readOnly:Me},te),zt))),O&&n().createElement(o.FormHelperText,Oe(q({},h),{className:h==null?void 0:h.className,style:this.styles.helperText}),O))}}const mt=lt;class Ie extends f{componentDidMount(){super.componentDidMount();const{data:c,attr:e}=this.props,t=f.getValue(c,e);if(this.props.schema.delimiter&&typeof t=="string"){const s=t.split(this.props.schema.delimiter).map(i=>i.trim()).filter(i=>i);this.setState({value:s})}else this.setState({value:t||[]})}renderItem(c,e){const{attr:t,schema:s}=this.props,{value:i}=this.state;return n().createElement(o.FormControl,{fullWidth:!0,variant:"standard"},n().createElement(mt,{value:i,disabled:!!e,label:this.getText(s.label),error:!!c,onAdd:r=>{const a=JSON.parse(JSON.stringify(i));a.push(r),this.setState({value:a},()=>{let h;this.props.schema.delimiter?h=this.onChange(t,a.join(`${this.props.schema.delimiter} `)):h=this.onChange(t,a),h instanceof Promise&&h.catch(S=>console.error(S))})},theme:this.props.oContext.theme,onDelete:(r,a)=>{const h=JSON.parse(JSON.stringify(i));h.splice(a,1),this.setState({value:h},()=>{let S;this.props.schema.delimiter?S=this.onChange(t,h.join(`${this.props.schema.delimiter} `)):S=this.onChange(t,h),S instanceof Promise&&S.catch(L=>console.error(L))})}}),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const Et=Ie;var Ne=Y(5385);class Ge extends f{renderColorDialog(){return!!this.state.showColorDialog&&n().createElement(o.Dialog,{onClose:()=>this.setState({showColorDialog:!1}),open:this.state.showColorDialog},n().createElement(Ne.xk,{color:this.state.colorDialogValue,onChange:c=>this.setState({colorDialogValue:c.hex},()=>this.onChange(this.props.attr,this.state.colorDialogValue))}))}renderItem(c,e){const t=f.getValue(this.props.data,this.props.attr);let s=l.Utils.isUseBright(t,null);return s===null&&(s=void 0),n().createElement(n().Fragment,null,this.renderColorDialog(),n().createElement(o.TextField,{variant:"standard",disabled:!!e,style:{minWidth:100,width:"calc(100% - 8px)"},label:this.getText(this.props.schema.label),value:t||"",onClick:()=>!this.props.schema.readOnly&&this.setState({showColorDialog:!0,colorDialogValue:t||""}),onChange:i=>{const r=i.target.value,a=this.onChange(this.props.attr,r);a instanceof Promise&&a.catch(h=>console.error(`Cannot set value: ${h}`))},slotProps:{htmlInput:{style:{backgroundColor:t,color:s?"#FFF":"#000"},readOnly:this.props.schema.readOnly||!1},input:{endAdornment:!this.props.schema.readOnly&&t&&!this.props.schema.noClearButton?n().createElement(o.IconButton,{size:"small",onClick:i=>{i.stopPropagation();const r=this.onChange(this.props.attr,"");r instanceof Promise&&r.catch(a=>console.error(`Cannot set value: ${a}`))}},n().createElement(u.Close,null)):void 0},inputLabel:{shrink:!0}}}))}}const bt=Ge,qe={width:{width:"calc(100% - 85px)"},width50:{width:120,marginRight:5}};class je extends f{componentDidMount(){super.componentDidMount();const c=f.getValue(this.props.data,this.props.attr);this.setState({value:c});const e={};this.props.schema.useSystemName&&(e.useSystem=!!f.getValue(this.props.data,this.props.schema.useSystemName)),this.props.schema.longitudeName&&this.props.schema.latitudeName?(e.longitude=f.getValue(this.props.data,this.props.schema.longitudeName),e.latitude=f.getValue(this.props.data,this.props.schema.latitudeName),!e.longitude&&!e.latitude&&this.props.schema.autoInit&&setTimeout(()=>this.getCoordinates(),300)):!f.getValue(this.props.data,this.props.attr)&&this.props.schema.autoInit&&setTimeout(()=>this.getCoordinates(),300),Object.keys(e).length&&setTimeout(()=>this.setState(e),50)}getSystemCoordinates(){return pe(this,null,function*(){const c=yield this.props.oContext.socket.getCompactSystemConfig();if(c!=null&&c.common&&(c.common.longitude||c.common.latitude))if(window.alert(l.I18n.t("ra_Used system settings")),this.props.schema.longitudeName&&this.props.schema.latitudeName)this.setState({longitude:c.common.longitude,latitude:c.common.latitude},()=>pe(this,null,function*(){yield this.onChange(this.props.schema.longitudeName,c.common.longitude),yield this.onChange(this.props.schema.latitudeName,c.common.latitude)}));else{const e=c.common.latitude+(this.props.schema.divider||",")+c.common.longitude;this.setState({value:e},()=>{const t=this.onChange(this.props.attr,e);t instanceof Promise&&t.catch(s=>console.error(`Cannot set value: ${s}`))})}else window.alert(l.I18n.t("ra_Cannot determine position: System settings are empty and GPS detection is disabled in browser"))})}getCoordinates(){navigator.geolocation?navigator.geolocation.getCurrentPosition(c=>pe(this,null,function*(){if(c!=null&&c.coords)if(this.props.schema.longitudeName&&this.props.schema.latitudeName)this.setState({longitude:c.coords.longitude,latitude:c.coords.latitude},()=>pe(this,null,function*(){yield this.onChange(this.props.schema.longitudeName,c.coords.longitude||""),yield this.onChange(this.props.schema.latitudeName,c.coords.latitude||"")}));else{const e=c.coords.latitude+(this.props.schema.divider||",")+c.coords.longitude;this.setState({value:e},()=>{const t=this.onChange(this.props.attr,e);t instanceof Promise&&t.catch(s=>console.error(`Cannot set value: ${s}`))})}else yield this.getSystemCoordinates()}),c=>pe(this,null,function*(){console.error(`Cannot determine coordinates from browser: ${c.message}`),yield this.getSystemCoordinates()})):this.getSystemCoordinates().catch(c=>{console.error(`Cannot determine coordinates: ${c}`)})}renderItem(c,e){var t,s;return n().createElement(n().Fragment,null,this.props.schema.useSystemName?n().createElement(o.FormControlLabel,{control:n().createElement(o.Checkbox,{checked:!!this.state.useSystem,onChange:i=>{const r=i.target.checked;r&&this.getSystemCoordinates().catch(a=>console.error(`Cannot determine coordinates: ${a}`)),this.setState({useSystem:r},()=>this.onChange(this.props.schema.useSystemName,r))}}),label:l.I18n.t("ra_Use system settings for position")}):null,this.props.schema.longitudeName&&this.props.schema.latitudeName?n().createElement(o.TextField,{variant:"standard",style:qe.width50,value:(t=this.state.longitude)!=null?t:"",error:!!c,disabled:this.state.useSystem||!!e,onChange:i=>{const r=i.target.value;this.setState({longitude:r},()=>{const a=this.onChange(this.props.schema.longitudeName,(r||"").trim());a instanceof Promise&&a.catch(h=>console.error(`Cannot set value: ${h}`))})},label:l.I18n.t("ra_Longitude")}):null,this.props.schema.longitudeName&&this.props.schema.latitudeName?n().createElement(o.TextField,{variant:"standard",style:qe.width50,value:(s=this.state.latitude)!=null?s:"",error:!!c,disabled:this.state.useSystem||!!e,onChange:i=>{const r=i.target.value;this.setState({latitude:r},()=>this.onChange(this.props.schema.latitudeName,(r||"").trim()))},label:l.I18n.t("ra_Latitude")}):null,!this.props.schema.longitudeName||!this.props.schema.latitudeName?n().createElement(o.TextField,{variant:"standard",style:qe.width,value:this.state.value===null||this.state.value===void 0?"":this.state.value,error:!!c,disabled:!!e,slotProps:{htmlInput:{maxLength:this.props.schema.maxLength||this.props.schema.max||void 0,readOnly:this.state.useSystem}},onChange:i=>{const r=i.target.value;this.setState({value:r},()=>this.onChange(this.props.attr,(r||"").trim()))},placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)}):null,this.state.useSystem?null:n().createElement(o.Fab,{size:"small",onClick:()=>this.getCoordinates(),title:l.I18n.t("ra_Take browser position"),style:{marginRight:4}},n().createElement(u.LocationOn,null)),this.state.useSystem?null:n().createElement(o.Fab,{size:"small",onClick:()=>this.getSystemCoordinates(),title:l.I18n.t("ra_Take position from system settings")},n().createElement(u.GpsFixed,null)))}}const ke=je,It=(E,c,e)=>new Promise((t,s)=>{if(window[E])t(window[E]);else{const i=document.querySelector(`script[data-webpack="${E}"]`),r=()=>pe(this,null,function*(){if(window[E])window[E].__initialized||(yield window[E].init(Y.S[c]),window[E].__initialized=!0);else{console.error(`Cannot load ${E}`),s(new Error(`Cannot load ${E}`));return}t(window[E])});if(i)i.onload=r,i.onerror=s;else if(e){const a=document,h=a.createElement("script");h.type="text/javascript",h.setAttribute("data-webpack",`${E}`),h.async=!0,h.onerror=s,h.onload=r,h.src=e,a.getElementsByTagName("head")[0].appendChild(h)}else s(new Error(`Cannot Find Remote ${E} to inject`))}});function ft(E,c,e,t){return()=>pe(this,null,function*(){return(yield(yield It(E,c,t)).get(e))()})}const Lt=class Lt extends f{constructor(c){super(c),Object.assign(this.state,{Component:null,error:""})}componentDidMount(){return pe(this,null,function*(){if(!this.props.schema.url){console.error("URL is empty. Cannot load custom component!"),this.setState({error:"URL is empty. Cannot load custom component!"});return}let c;this.props.schema.url.startsWith("./")?c=`${window.location.protocol}//${window.location.host}${this.props.schema.url.replace(/^\./,"")}`:c=`${window.location.protocol}//${window.location.host}/adapter/${this.props.oContext.adapterName}/${this.props.schema.url}`;const[e,t,...s]=this.props.schema.name.split("/"),i=s.join("/");if(!c){console.error('Cannot find URL for custom component! Please define "url" as "custom/customComponents.js" in the schema');return}if(!e||!t||!i){console.error('Invalid format of "name"! Please define "name" as "ConfigCustomBackItUpSet/Components/AdapterExist" in the schema');return}let r=Lt.runningLoads[`${c}!${t}`];if(!(r instanceof Promise)){let a;if(this.props.schema.i18n===!0){const h=c.lastIndexOf("/");let S;h!==-1?S=c.substring(0,h):S=c;const L=l.I18n.getLanguage(),O=`${S}/i18n/${L}.json`;a=fetch(O).then(N=>N.json()).then(N=>l.I18n.extendTranslations(N,L)).catch(N=>{if(L!=="en"){fetch(`${S}/i18n/en.json`).then(te=>te.json()).then(te=>l.I18n.extendTranslations(te,L)).catch(te=>console.log(`Cannot load i18n "${O}": ${te}`));return}console.log(`Cannot load i18n "${O}": ${N}`)})}else if(this.props.schema.i18n&&typeof this.props.schema.i18n=="object")try{l.I18n.extendTranslations(this.props.schema.i18n)}catch(h){console.error(`Cannot import i18n: ${h}`)}try{console.log(e,t,i),r=ft(e,"default",`./${t}`,c)(),a instanceof Promise&&(r=Promise.all([r,a]).then(h=>h[0])),Lt.runningLoads[`${c}!${t}`]=r}catch(h){this.setState({error:`Cannot import from ${this.props.schema.url}: ${h}`})}}try{const a=(yield r).default;if(a!=null&&a[i])this.setState({Component:a[i]});else{const h=Object.keys(a||{});console.error("URL is empty. Cannot load custom component!"),this.setState({error:`Component ${this.props.schema.name} not found in ${this.props.schema.url}. Found: ${h.join(", ")}`})}}catch(a){this.setState({error:`Cannot import from ${this.props.schema.url}: ${a}`})}})}render(){const c=this.state.Component;if(!c){const e=this.props.schema||{},t=n().createElement(o.Grid2,{size:{xs:e.xs||void 0,sm:e.sm||void 0,md:e.md||void 0,lg:e.lg||void 0,xl:e.xl||void 0},style:q(q({marginBottom:0,textAlign:"left"},e.style),this.props.oContext.themeType==="dark"?e.darkStyle:{})},this.state.error?n().createElement("div",null,this.state.error):n().createElement(o.LinearProgress,null));return e.newLine?n().createElement(n().Fragment,null,n().createElement("div",{style:{flexBasis:"100%",height:0}}),t):t}return n().createElement(c,q({},this.props))}};Q(Lt,"runningLoads",{});let xt=Lt;var wt=Y(8497);class fe extends f{componentDidMount(){super.componentDidMount();const c=f.getValue(this.props.data,this.props.attr);this.setState({value:c})}renderItem(c,e){return n().createElement(wt.DatePicker,{sx:t=>({width:"100%",borderBottom:`1px solid ${t.palette.text.primary}`,"& fieldset":{display:"none"},"& input":{padding:`${t.spacing(1.5)} 0 4px 0`},"& .MuiInputAdornment-root":{marginLeft:0,marginTop:1},"& label":{transform:"translate(0px, -9px) scale(0.75)"}}),format:this.props.oContext.systemConfig.dateFormat.toLowerCase().replace("mm","MM"),disabled:!!e,value:this.state.value,onChange:t=>{this.setState({value:t},()=>this.onChange(this.props.attr,this.state.value))},label:this.getText(this.props.schema.label)})}}class de extends f{renderItem(){if(!this.props.schema)return null;if(this.props.oContext.DeviceManager){const e=this.props.oContext.DeviceManager;return n().createElement(e,{uploadImagesToInstance:`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,title:this.getText(this.props.schema.label),socket:this.props.oContext.socket,selectedInstance:`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,themeName:this.props.themeName,themeType:this.props.oContext.themeType,isFloatComma:this.props.oContext.isFloatComma,dateFormat:this.props.oContext.dateFormat})}return n().createElement("div",null,"DeviceManager not found")}}const gt=de;var Xe=Y(3683),De=Y.n(Xe);const Ue={fullWidth:{width:"100%"},fullWidthOneButton:{width:"calc(100% - 42px)"},fullWidthTwoButtons:{width:"calc(100% - 84px)"},fullWidthThreeButtons:{width:"calc(100% - 126x)"},dropZone:{width:"100%",height:"100%",position:"absolute"},dropZoneEmpty:{},image:{objectFit:"contain",margin:"auto",display:"flex",width:"100%",height:"100%"},uploadDiv:{position:"relative",width:"100%"},uploadDivDragging:{opacity:1,background:"rgba(128,255,128,0.1)"},uploadCenterDiv:{margin:5,border:"3px dashed grey",borderRadius:5,width:"100%",height:"100%",position:"absolute",display:"flex"},uploadCenterIcon:{paddingTop:10,width:48,height:48},uploadCenterText:{fontSize:16},uploadCenterTextAndIcon:{textAlign:"center",position:"absolute",top:0,bottom:0,left:0,right:0,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center"},disabledOpacity:{opacity:.3,cursor:"default"},error:{border:"2px solid red"},deleteButton:{},selectedImage:{height:40,width:40,display:"inline-block",marginRight:8}},Ye=["jpg","jpeg","svg","png","webp","gif","apng","avif","webp"],J=["mp3","ogg","wav","aac"],$t=["avi","mp4","mov"],we=["txt","log","html","htm"],st=["json","js","ts"];class _t extends f{constructor(e){super(e);Q(this,"dropzoneRef");Q(this,"imagePrefix");Q(this,"objectID");Q(this,"path");this.dropzoneRef=n().createRef(),this.imagePrefix=this.props.oContext.imagePrefix===void 0?"./files":this.props.oContext.imagePrefix}componentDidMount(){super.componentDidMount(),this.objectID=(this.props.schema.objectID||"0_userdata.0").replace("%INSTANCE%",(this.props.oContext.instance||0).toString()),this.path=this.props.schema.upload,this.path&&(this.path==="/"?this.path="":this.path.endsWith("/")||(this.path=`${this.path}/`)),this.updateFiles().then(()=>{const e=f.getValue(this.props.data,this.props.attr);this.setState({value:e})})}updateFiles(){return this.readFiles(this.props.schema.pattern).then(e=>this.setState({files:e}))}readFolder(e,t,s){return pe(this,null,function*(){try{const i=yield this.props.oContext.socket.readDir(this.objectID,e.replace(/^\//,"")||null);for(let r=0;rconsole.log("file reading was aborted"),s.onerror=()=>console.log("file reading has failed"),s.onload=()=>{let r=`image/${t.name.split(".").pop().toLowerCase()}`;if(r==="image/jpg"?r="image/jpeg":r.includes("svg")&&(r="image/svg+xml"),t.size>i){window.alert(l.I18n.t("File is too big. Max %sk allowed. Try use SVG.",Math.round(i/1024)));return}const a=`data:${r};base64,${btoa(new Uint8Array(s.result).reduce((h,S)=>h+String.fromCharCode(S),""))}`;this.props.oContext.socket.writeFile64(this.objectID,this.path+t.name,a).then(()=>this.updateFiles()).catch(h=>window.alert(`Cannot upload file: ${h}`))},s.readAsArrayBuffer(t)}renderDeleteDialog(){return this.state.deleteFile?n().createElement(l.DialogConfirm,{title:l.I18n.t("ra_Are you sure?"),text:l.I18n.t("ra_File will be deleted"),ok:l.I18n.t("ra_Delete"),cancel:l.I18n.t("ra_Cancel"),onClose:e=>{const t=this.state.deleteFile;this.setState({deleteFile:""},()=>{e&&this.props.oContext.socket.deleteFile(this.objectID,t).then(()=>this.updateFiles()).catch(s=>window.alert(`Cannot delete file: ${s}`))})}}):null}static base64ToArrayBuffer(e){const t=window.atob(e),s=t.length,i=new Uint8Array(s);for(let r=0;r{if(typeof AudioContext!="undefined"){const t=new AudioContext,s=_t.base64ToArrayBuffer(e.file);t.decodeAudioData(s,i=>{const r=t.createBufferSource();r.buffer=i,r.connect(t.destination),r.start(0)},i=>window.alert(`Cannot play: ${i.message}`))}})}getFileIcon(e){return e!=null&&e.extension?Ye.includes(e.extension)?n().createElement("div",{style:Oe(q({},Ue.selectedImage),{backgroundImage:`url(${this.imagePrefix}/${this.objectID}/${e.value})`,backgroundSize:"contain",backgroundRepeat:"no-repeat"})}):J.includes(e.extension)?n().createElement(u.MusicNote,null):we.includes(e.extension)?n().createElement(u.Article,null):$t.includes(e.extension)?n().createElement(u.Videocam,null):st.includes(e.extension)?n().createElement(u.Code,null):null:null}renderItem(e,t){if(!this.state.files)return null;const s=[];this.props.schema.withFolder||this.state.files.forEach(O=>{const N=O.name.lastIndexOf("/");if(N===-1)s.includes("/")||s.push("/");else{const te=O.name.substring(0,N+1);s.includes(te)||s.push(te)}});const i=this.state.files.map(O=>({value:O.name,label:!this.props.schema.withFolder&&s.length===1?`${O.name.substring(s[0].length)}`:`${O.name}${this.props.schema.noSize?"":`(${O.size})`}`,extension:O.name.toLowerCase().split(".").pop()}));this.props.schema.noNone||i.unshift({label:l.I18n.t("ra_none"),value:""});const r=i.find(O=>O.value===this.state.value);let a=0;this.props.schema.upload&&a++,this.props.schema.refresh&&a++;const h=this.state.value&&(this.state.value.endsWith(".mp3")||this.state.value.endsWith(".ogg")||this.state.value.endsWith(".wav"));h&&a++;const S=n().createElement("div",{style:Ue.fullWidth},n().createElement(o.FormControl,{variant:"standard",style:{width:`calc(100% - ${a*42}px)`}},this.props.schema.label?n().createElement(o.InputLabel,null,this.getText(this.props.schema.label)):null,n().createElement(o.Select,{variant:"standard",error:!!e,disabled:!!t,value:this.state.value||"_",renderValue:()=>n().createElement(n().Fragment,null,this.getFileIcon(r),n().createElement("span",null,(r==null?void 0:r.label)||"")),onChange:O=>{this.setState({value:O.target.value==="_"?"":O.target.value},()=>this.onChange(this.props.attr,this.state.value))}},i.map(O=>n().createElement(o.MenuItem,{key:O.value,value:O.value},n().createElement(o.ListItemIcon,null,this.getFileIcon(O)),n().createElement(o.ListItemText,null,O.label),this.props.schema.delete&&r.value?n().createElement(o.IconButton,{style:Ue.deleteButton,size:"small",onClick:()=>this.setState({deleteFile:r.value})},n().createElement(u.Delete,null)):null))),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null),this.props.schema.refresh&&n().createElement(o.IconButton,{onClick:()=>this.updateFiles()},n().createElement(u.Refresh,null)),this.props.schema.upload&&n().createElement(o.IconButton,{onClick:()=>{var O;return(O=this.dropzoneRef.current)==null?void 0:O.open()}},n().createElement(u.UploadFile,null)),h&&n().createElement(o.IconButton,{style:{color:"#00FF00"},onClick:()=>this.play()},n().createElement(u.PlayArrow,null)));if(!this.props.schema.upload)return n().createElement(n().Fragment,null,S,this.renderDeleteDialog());let L={"*/*":[]};if(this.props.schema.fileTypes==="image"?L={"image/*":[".png",".jpg",".svg",".gif",".apng",".avif",".webp"]}:this.props.schema.fileTypes==="audio"?L={"audio/*":[".mp3",".ogg",".wav",".mp4"]}:this.props.schema.fileTypes==="text"&&(L={"text/plain":[".txt"]}),this.props.schema.pattern){const O=this.props.schema.pattern.split("/").pop().toLowerCase().replace(/.*\./,"");O==="png"||O==="jpg"||O==="svg"||O==="gif"||O==="apng"||O==="avif"||O==="webp"?L={"image/*":[".png",".jpg",".svg",".gif",".apng",".avif",".webp"]}:O==="mp3"||O==="ogg"||O==="wav"?L={"audio/*":[".mp3",".ogg",".wav",".mp4"]}:O==="ics"?L={"text/calendar":[".ics"]}:O==="txt"?L={"text/plain":[".txt"]}:O==="pem"?L={"text/plain":[".pem"]}:L={"*/*":[`.${O}`]}}return n().createElement(De(),{ref:this.dropzoneRef,multiple:!1,accept:L,noKeyboard:!0,noClick:!0,maxSize:this.props.schema.maxSize||2*1024*1024,onDragEnter:()=>{this.setState({uploadFile:"dragging"})},onDragLeave:()=>this.setState({uploadFile:!0}),onDrop:(O,N)=>{this.setState({uploadFile:!1}),O.length?this.onDrop(O):window.alert(N&&N[0]&&N[0].errors&&N[0].errors[0]&&N[0].errors[0].message||l.I18n.t("Cannot upload"))}},({getRootProps:O,getInputProps:N})=>n().createElement("div",q({style:q(q(q({},Ue.uploadDiv),this.state.uploadFile==="dragging"?Ue.uploadDivDragging:void 0),t?Ue.disabledOpacity:void 0)},O()),n().createElement("input",q({},N())),this.state.uploadFile==="dragging"?n().createElement("div",{style:q(q({},Ue.uploadCenterDiv),this.state.uploadError?Ue.error:void 0)},n().createElement("div",{style:Ue.uploadCenterTextAndIcon},n().createElement(u.UploadFile,{style:Ue.uploadCenterIcon}),n().createElement("div",{style:Ue.uploadCenterText},this.state.uploadFile==="dragging"?l.I18n.t("ra_Drop file here"):l.I18n.t("ra_Place your files here or click here to open the browse dialog")))):null,S,this.renderDeleteDialog()))}}const Nt=_t,ut={fullWidth:{width:"100%"},fullWidthOneButton:{width:"calc(100% - 69px)",marginRight:4},fullWidthIcon:{width:"calc(100% - 119px)",marginRight:4},selectedImage:{height:40,width:40,display:"inline-block",marginRight:8}},Gt=["jpg","jpeg","svg","png","webp","gif","apng","avif","webp"],kt=["mp3","ogg","wav","aac"],At=["avi","mp4","mov"],Ae=["txt","log","html","htm"],it=["json","js","ts"];class Pt extends f{constructor(){super(...arguments);Q(this,"imagePrefix","../..")}componentDidMount(){super.componentDidMount();const e=f.getValue(this.props.data,this.props.attr);this.imagePrefix=this.props.oContext.imagePrefix===void 0?"./files":this.props.oContext.imagePrefix,this.setState({value:e!=null?e:""})}static getDerivedStateFromProps(e,t){const s=f.getValue(e.data,e.attr);return s==null||s.toString().trim()!==(t.value||"").toString().trim()?{value:s!=null?s:""}:null}loadFile(){const e=this.state.value.indexOf("/");if(e!==-1){const t=this.state.value.substring(0,e),s=this.state.value.substring(e+1);return this.props.oContext.socket.readFile(t,s,!0)}return Promise.resolve(null)}play(){this.loadFile().then(e=>{if(typeof AudioContext!="undefined"&&(e!=null&&e.file)){const t=new AudioContext,s=Nt.base64ToArrayBuffer(e.file);t.decodeAudioData(s,i=>{const r=t.createBufferSource();r.buffer=i,r.connect(t.destination),r.start(0)},i=>window.alert(`Cannot play: ${i.message}`))}})}getIcon(){const e=this.state.value.split(".").pop().toLowerCase();return Gt.includes(e)?n().createElement("div",{style:Oe(q({},ut.selectedImage),{backgroundImage:`url(${this.imagePrefix}/${this.state.value})`,backgroundSize:"contain",backgroundRepeat:"no-repeat"})}):kt.includes(e)?n().createElement(o.IconButton,{style:{color:"#00FF00"},onClick:()=>this.play()},n().createElement(u.PlayArrow,null)):Ae.includes(e)?n().createElement(u.Article,null):At.includes(e)?n().createElement(u.Videocam,null):it.includes(e)?n().createElement(u.Code,null):null}renderFileBrowser(){return this.state.showFileBrowser?n().createElement(l.DialogSelectFile,{imagePrefix:this.props.oContext.imagePrefix,socket:this.props.oContext.socket,selected:this.state.value,onClose:()=>this.setState({showFileBrowser:!1}),onOk:e=>{const t=Array.isArray(e)?e[0]:e;this.setState({value:t},()=>this.onChange(this.props.attr,this.props.schema.trim===!1?t:(t||"").trim()))},selectOnlyFolders:this.props.schema.selectOnlyFolders,allowUpload:this.props.schema.allowUpload,allowDownload:this.props.schema.allowDownload,allowCreateFolder:this.props.schema.allowCreateFolder,allowView:this.props.schema.allowView,showToolbar:this.props.schema.showToolbar,limitPath:this.props.schema.limitPath,theme:this.props.oContext.theme}):null}renderItem(e,t){const s=this.getIcon();return n().createElement("div",{style:ut.fullWidth},s,n().createElement(o.TextField,{variant:"standard",style:s?ut.fullWidthIcon:ut.fullWidthOneButton,value:this.state.value===null||this.state.value===void 0?"":this.state.value,error:!!e,disabled:!!t,slotProps:{htmlInput:{maxLength:this.props.schema.maxLength||this.props.schema.max||void 0,readOnly:!!this.props.schema.disableEdit}},onChange:i=>{const r=i.target.value;this.setState({value:r},()=>this.onChange(this.props.attr,this.props.schema.trim===!1?r:(r||"").trim()))},placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)}),n().createElement(o.Button,{disabled:t,variant:"outlined",onClick:()=>this.setState({showFileBrowser:!0})},"..."),this.renderFileBrowser())}}const Xt=Pt;class Rt extends f{componentDidMount(){super.componentDidMount();const c=f.getValue(this.props.data,this.props.attr);this.props.oContext.socket.getEnums("functions").then(e=>{const t=Object.keys(e).map(s=>({value:this.props.schema.short?s.replace("enum.functions.",""):s,label:this.getText(e[s].common.name),obj:e[s]}));this.props.schema.allowDeactivate!==!1&&t.unshift({label:l.I18n.t(f.NONE_LABEL),value:f.NONE_VALUE}),this.setState({value:c,selectOptions:t})})}renderItem(c,e){if(!this.state.selectOptions)return null;const t=this.state.selectOptions.find(s=>s.value===this.state.value);return n().createElement(o.FormControl,{variant:"standard",fullWidth:!0},this.props.schema.label?n().createElement(o.InputLabel,null,this.getText(this.props.schema.label)):null,n().createElement(o.Select,{variant:"standard",error:!!c,disabled:!!e,value:this.state.value||"_",renderValue:()=>t?t.obj?n().createElement(l.TextWithIcon,{value:t.obj,themeType:this.props.oContext.themeType,lang:l.I18n.getLanguage()}):t.label:"",onChange:s=>{this.setState({value:s.target.value==="_"?"":s.target.value},()=>this.onChange(this.props.attr,this.state.value))}},this.state.selectOptions.map(s=>n().createElement(o.MenuItem,{key:s.value,value:s.value,style:s.value===f.DIFFERENT_VALUE?{opacity:.5}:{}},s.obj?n().createElement(l.TextWithIcon,{value:s.obj,themeType:this.props.oContext.themeType,lang:l.I18n.getLanguage()}):s.label))),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const Ft=Rt;class Yt extends f{componentDidMount(){super.componentDidMount(),this.props.oContext.socket.getHostByIp(this.props.common.host).then(c=>{this.props.schema.listenOnAllPorts||(c=c.filter(e=>e.address!=="0.0.0.0"&&e.address!=="::")),this.props.schema.onlyIp4?c=c.filter(e=>e.family==="ipv4"):this.props.schema.onlyIp6&&(c=c.filter(e=>e.family==="ipv6")),this.props.schema.noInternal&&(c=c.filter(e=>!e.internal)),c.forEach(e=>{e.address==="0.0.0.0"?e.name=`[IPv4] 0.0.0.0 - ${l.I18n.t("ra_Listen on all IPs")}`:e.address==="::"&&(e.name=`[IPv6] :: - ${l.I18n.t("ra_Listen on all IPs")}`)}),this.setState({ips:c})}).catch(c=>console.error(c))}renderItem(c,e){var i,r;const t=f.getValue(this.props.data,this.props.attr),s=(i=this.state.ips)==null?void 0:i.find(a=>a.address===t);return n().createElement(o.FormControl,{fullWidth:!0,variant:"standard"},this.state.ips&&this.props.schema.label?n().createElement(o.InputLabel,null,this.getText(this.props.schema.label)):null,this.state.ips?n().createElement(o.Select,{variant:"standard",error:!!c,disabled:!!e,value:t,renderValue:a=>(s==null?void 0:s.name)||a,onChange:a=>this.onChange(this.props.attr,a.target.value)},(r=this.state.ips)==null?void 0:r.map((a,h)=>n().createElement(o.MenuItem,{key:h,value:a.address},a.name))):n().createElement(o.TextField,{fullWidth:!0,variant:"standard",error:!!c,disabled:!!e,value:t,onChange:a=>this.onChange(this.props.attr,a.target.value),label:this.getText(this.props.schema.label)}),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const Zt=Yt;class Qt extends f{constructor(){super(...arguments);Q(this,"initialized",!1);Q(this,"localContext")}componentDidMount(){super.componentDidMount(),this.askInstance()}askInstance(){if(this.props.alive){let e=this.props.schema.data;if(e===void 0&&this.props.schema.jsonData){const t=this.getPattern(this.props.schema.jsonData,null,!0);if(t)try{e=JSON.parse(t)}catch(s){console.error(`Cannot parse json data: ${JSON.stringify(e)}`)}}e===void 0&&(e=null),this.props.oContext.socket.sendTo(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,this.props.schema.command||"send",e).then(t=>this.setState({image:t||""}))}}getContext(){const e={};return Array.isArray(this.props.schema.alsoDependsOn)&&this.props.schema.alsoDependsOn.forEach(t=>e[t]=f.getValue(this.props.data,t)),JSON.stringify(e)}renderItem(){if(this.props.alive){const e=this.getContext();(e!==this.localContext||!this.initialized)&&(this.localContext=e,setTimeout(()=>this.askInstance(),this.initialized?300:50),this.initialized=!0)}return this.state.image===void 0?null:n().createElement("img",{alt:"dynamic content",src:this.state.image,style:{width:this.props.schema.width||"100%",height:this.props.schema.height}})}}const en=Qt;class A extends f{constructor(e){super(e);Q(this,"index");this.index=Date.now()}componentDidMount(){if(super.componentDidMount(),this.props.schema.base64){const e=f.getValue(this.props.data,this.props.attr);this.setState({value:e})}else this.props.oContext.socket.fileExists(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,this.props.attr).then(e=>e&&this.loadImage())}_getUrl(e){e&&(this.index=Date.now());let t=`files/${this.props.oContext.adapterName}.${this.props.oContext.instance}/${this.props.attr}?t=${this.index}`;return window.location.port==="3000"&&(t=`${window.location.protocol}//${window.location.hostname}:8081/${t}`),t}loadImage(){fetch(this._getUrl()).then(e=>e.blob()).then(e=>{const t=new FileReader;t.onload=()=>{this.setState({value:t.result})},t.readAsDataURL(e)}).catch(e=>console.error(e))}renderItem(e,t){return n().createElement(o.FormControl,{fullWidth:!0,variant:"standard"},this.props.schema.label?n().createElement(o.InputLabel,{shrink:!0},this.getText(this.props.schema.label)):null,n().createElement(l.UploadImage,{error:!!e,disabled:t,accept:this.props.schema.accept,crop:this.props.schema.crop,maxSize:this.props.schema.maxSize||256*1024,icon:this.state.value||void 0,removeIconFunc:()=>this.setState({value:null},()=>{if(this.props.schema.base64){const s=this.onChange(this.props.attr,this.state.value);s instanceof Promise&&s.catch(i=>console.error(`Cannot set value: ${i}`))}else this.props.oContext.socket.deleteFile(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,this.props.attr).catch(s=>console.error(s))}),onChange:s=>this.setState({value:s},()=>{if(this.props.schema.base64){const i=this.onChange(this.props.attr,this.state.value);i instanceof Promise&&i.catch(r=>console.error(`Cannot set value: ${r}`))}else s.startsWith("data")&&(s=s.split(",")[1]);this.props.oContext.socket.writeFile64(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,this.props.attr,s).catch(i=>console.error(i))})}),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const P=A,oe={icon:{width:20,height:20,marginRight:4}};class ne extends f{constructor(){super(...arguments);Q(this,"onInstancesUpdate",(e,t)=>{if(!e.match(/^system\.adapter\.[-_a-z\d]+\.\d+$/))return;const s=this.props.schema.long?e:this.props.schema.short?e.split(".").pop():e.replace(/^system\.adapter\./,""),i=this.state.selectOptions.findIndex(r=>r.value===s);if(t){if(this.props.schema.adapter==="_dataSources"&&(!t.common||!t.common.getHistory))return;if(i===-1){const r=JSON.parse(JSON.stringify(this.state.selectOptions)),a=typeof t.common.name=="object"?t.common.name[l.I18n.getLanguage()]||t.common.name.en:t.common.name;r.push({value:this.props.schema.long?t._id:this.props.schema.short?t._id.split(".").pop():t._id.replace(/^system\.adapter\./,""),label:`${a} [${t._id.replace(/^system\.adapter\./,"")}]`,icon:`adapter/${a}/${t.common.icon}`}),r.sort((h,S)=>h.label>S.label?1:h.labelpe(this,null,function*(){this.props.schema.adapter==="_dataSources"?s=s.filter(r=>{var a;return(a=r==null?void 0:r.common)==null?void 0:a.getHistory}):this.props.schema.adapter?s=s.filter(r=>r==null?void 0:r._id.startsWith(`system.adapter.${this.props.schema.adapter}.`)):this.props.schema.adapters&&Array.isArray(this.props.schema.adapters)&&(s=s.filter(r=>{var a;return this.props.schema.adapters.includes((a=r==null?void 0:r.common)==null?void 0:a.name)})),this.props.schema.onlyEnabled&&(s=s.filter(r=>{var a;return(a=r==null?void 0:r.common)==null?void 0:a.enabled}));const i=s.map(r=>({value:this.props.schema.long?r._id:this.props.schema.short?r._id.split(".").pop():r._id.replace(/^system\.adapter\./,""),label:`${r.common.name} [${r._id.replace(/^system\.adapter\./,"")}]`,icon:`adapter/${r.common.name}/${r.common.icon}`}));i.sort((r,a)=>r.value>a.value?1:r.valueconsole.error(`Cannot get instances: ${s}`))}componentWillUnmount(){this.props.oContext.socket.unsubscribeObject("system.adapter.*",this.onInstancesUpdate).then(()=>{}),super.componentWillUnmount()}renderItem(e,t){var i;if(!this.state.selectOptions)return null;const s=(i=this.state.selectOptions)==null?void 0:i.find(r=>r.value===this.state.value);return n().createElement(o.FormControl,{fullWidth:!0,key:this.props.attr,variant:"standard"},this.props.schema.label?n().createElement(o.InputLabel,{shrink:!0},this.getText(this.props.schema.label)):null,n().createElement(o.Select,{variant:"standard",error:!!e,displayEmpty:!0,disabled:!!t,value:this.state.value,renderValue:()=>n().createElement("span",{style:{display:"flex"}},s!=null&&s.icon?n().createElement("img",{src:`./${s.icon}`,alt:s.value,style:oe.icon}):null,this.getText(s==null?void 0:s.label,!0)),onChange:r=>this.setState({value:r.target.value},()=>this.onChange(this.props.attr,this.state.value))},this.state.selectOptions.map(r=>n().createElement(o.MenuItem,{key:r.value,value:r.value,style:r.value===f.NONE_VALUE?{opacity:.5}:{}},r.icon?n().createElement("img",{src:`./${r.icon}`,alt:r.value,style:oe.icon}):null,this.getText(r.label,!0)))),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const ue=ne,Ce={address:{fontSize:"smaller",opacity:.5,marginLeft:8}};class ve extends f{componentDidMount(){super.componentDidMount(),this.props.oContext.socket.getObject(`system.host.${this.props.common.host}`).then(c=>{var t,s;const e=[];if((s=(t=c==null?void 0:c.native)==null?void 0:t.hardware)!=null&&s.networkInterfaces){const i=c.native.hardware.networkInterfaces;Object.keys(i).forEach(r=>{if(this.props.schema.ignoreInternal&&!i[r].find(h=>!h.internal)||this.props.schema.ignoreLoopback&&i[r].find(h=>h.address==="127.0.0.1"||h.address==="::1"))return;let a=i[r].find(h=>h.family==="IPv4");a=a||i[r].find(h=>h.family==="IPv6"),e.push({value:r,address:a.address})})}this.setState({interfaces:e})}).catch(c=>window.alert(`Cannot read interfaces: ${c}`))}renderItem(c,e){var i,r,a;const t=f.getValue(this.props.data,this.props.attr),s=(i=this.state.interfaces)==null?void 0:i.find(h=>h.value===t);return n().createElement(o.FormControl,{fullWidth:!0,variant:"standard"},(r=this.state.interfaces)!=null&&r.length&&this.props.schema.label?n().createElement(o.InputLabel,null,this.getText(this.props.schema.label)):null,(a=this.state.interfaces)!=null&&a.length?n().createElement(o.Select,{variant:"standard",error:!!c,disabled:!!e,value:t,renderValue:h=>s?n().createElement("span",null,s.value,n().createElement("span",{style:Ce.address},s.address)):h,onChange:h=>this.onChange(this.props.attr,h.target.value)},this.state.interfaces.map((h,S)=>n().createElement(o.MenuItem,{key:S,value:h.value},n().createElement("span",null,h.value,n().createElement("span",{style:Ce.address},h.address))))):n().createElement(o.TextField,{fullWidth:!0,variant:"standard",error:!!c,disabled:!!e,value:t,onChange:h=>this.onChange(this.props.attr,h.target.value),label:this.getText(this.props.schema.label)}),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const Pe=ve,Te={modalDialog:{minWidth:400,maxWidth:800},overflowHidden:{display:"flex",overflow:"hidden"},titleIcon:{marginRight:5},content:{fontSize:16},languageButton:{position:"absolute",right:8,top:8},languageButtonActive:{color:"primary.main"}},ht=({toggleTranslation:E,noTranslation:c,title:e,fullWidth:t,help:s,maxWidth:i,progress:r,icon:a,applyDisabled:h,applyButton:S,onClose:L,children:O,titleButtonApply:N,titleButtonClose:te,onApply:ye,textInput:se,defaultValue:Ee,overflowHidden:me})=>{const[Me,yt]=(0,T.useState)(Ee);(0,T.useEffect)(()=>{yt(Ee)},[Ee]);let Jt=null;return a&&(Jt=a),n().createElement(o.Dialog,{open:!0,maxWidth:i||"md",fullWidth:!!t,disableEscapeKeyDown:!1,onClose:L,sx:{"& .MuiPaper-root":Te.modalDialog}},e&&n().createElement(o.DialogTitle,null,a?n().createElement(Jt,{style:Te.titleIcon}):null,e,l.I18n.getLanguage()!=="en"&&E?n().createElement(o.IconButton,{size:"large",style:q(q({},Te.languageButton),c?Te.languageButtonActive:{}),onClick:()=>E(),title:l.I18n.t("Disable/Enable translation")},n().createElement(u.Language,null)):null),n().createElement(o.DialogContent,{sx:q(q({},me?Te.overflowHidden:{}),Te.content),style:{paddingTop:8}},se&&n().createElement(o.TextField,{autoComplete:"off",fullWidth:!0,autoFocus:!0,variant:"outlined",size:"medium",multiline:!0,value:Me,onChange:pn=>yt(pn.target.value)}),O,s?n().createElement("div",null,s):null),n().createElement(o.DialogActions,null,S!==!1&&n().createElement(o.Button,{startIcon:n().createElement(u.Check,null),disabled:r||h&&Ee===Me,onClick:()=>ye&&ye(se?Me:""),variant:"contained",color:"primary"},l.I18n.t(N||"Ok")),n().createElement(o.Button,{color:"grey",onClick:()=>L&&L(),disabled:r,variant:"contained",startIcon:n().createElement(u.Close,null)},l.I18n.t(te||"Cancel"))))};var We=Y(2514),Ke=Y.n(We),Re=Y(7726),Ct=Y(1197),Bt=Y(9285),fn=Y(4210),gn=Y(2292);const Mt={jsonError:{border:"1px solid red",minHeight:200},jsonNoError:{border:"1px solid #00000000",minHeight:200}};function be(E){return n().createElement(Ke(),{style:E.error===!0?Mt.jsonError:E.error===!1?Mt.jsonNoError:void 0,mode:E.mode||"json",width:"100%",height:"100%",showPrintMargin:E.editValueMode,showGutter:E.editValueMode,highlightActiveLine:E.editValueMode,defaultValue:E.defaultValue,theme:E.themeType==="dark"?"clouds_midnight":"chrome",value:E.value,readOnly:!E.onChange,onChange:c=>E.onChange(c),name:E.name||"UNIQUE_ID_OF_DIV1",fontSize:E.fontSize||14,setOptions:{enableBasicAutocompletion:!0,enableLiveAutocompletion:!0,enableSnippets:!0,showLineNumbers:E.editValueMode,tabSize:E.editValueMode?2:void 0},editorProps:{$blockScrolling:!0}})}const Le=be,he={fullWidth:{width:"100%"},flex:{display:"flex"},button:{height:48,minWidth:48},wrapper:{width:"calc(100vw - 40px)",height:"calc(100vh - 188px)"}};class Be extends f{componentDidMount(){super.componentDidMount();const{data:c,attr:e}=this.props,t=f.getValue(c,e)||{};this.setState({value:t,initialized:!0,jsonError:this.validateJson(t)})}validateJson(c){let e=!1;if(this.props.schema.validateJson!==!1&&(c||!this.props.schema.allowEmpty))try{JSON.parse(c)}catch(t){console.log("Error in JSON",t),e=!0}return e}renderItem(c,e){if(!this.state.initialized)return null;const{schema:t,data:s,attr:i}=this.props,{value:r,showSelectId:a}=this.state;return n().createElement(o.FormControl,{fullWidth:!0,variant:"standard"},n().createElement("div",{style:he.flex},n().createElement(o.Button,{color:"grey",disabled:e,style:he.button,size:"small",variant:"outlined",onClick:()=>this.setState({showSelectId:!0})},l.I18n.t("ra_JSON editor"))),a?n().createElement(ht,{title:this.getText(t.label),overflowHidden:!0,onClose:()=>this.setState({showSelectId:!1,value:f.getValue(s,i)||{}}),onApply:()=>this.setState({showSelectId:!1},()=>this.onChange(i,r))},n().createElement("div",{style:q(q({},he.wrapper),this.state.jsonError?{}:void 0)},n().createElement(Le,{value:typeof r=="object"?JSON.stringify(r):r,onChange:h=>this.setState({value:h,jsonError:this.validateJson(h)}),name:"ConfigJsonEditor",themeType:this.props.oContext.themeType}))):null,t.help||this.state.jsonError?n().createElement(o.FormHelperText,null,this.state.jsonError?l.I18n.t("ra_Invalid JSON"):this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const Je=Be,$e=[{value:"en",label:"English"},{value:"de",label:"Deutsch"},{value:"ru",label:"\u0440\u0443\u0441\u0441\u043A\u0438\u0439"},{value:"pt",label:"Portugues"},{value:"nl",label:"Nederlands"},{value:"fr",label:"fran\xE7ais"},{value:"it",label:"Italiano"},{value:"es",label:"Espanol"},{value:"pl",label:"Polski"},{value:"uk",label:"\u0423\u043A\u0440\u0430\u0457\u043D\u0441\u044C\u043A\u0438\u0439"},{value:"zh-ch",label:"\u7B80\u4F53\u4E2D\u6587"}];class ot extends f{componentDidMount(){super.componentDidMount();const c=f.getValue(this.props.data,this.props.attr),e=[...$e];this.props.schema.system?e.unshift({value:"",label:l.I18n.t("ra_System language")}):e.unshift({value:"",label:l.I18n.t("ra_none")}),this.setState({value:this.props.schema.system?c||"":c||l.I18n.getLanguage(),selectOptions:e})}renderItem(c,e){var s,i;if(!this.state.selectOptions)return null;const t=(s=this.state.selectOptions)==null?void 0:s.find(r=>r.value===this.state.value||!r.value&&!this.state.value);return n().createElement(o.FormControl,{fullWidth:!0,variant:"standard"},this.props.schema.label?n().createElement(o.InputLabel,null,this.getText(this.props.schema.label)):null,n().createElement(o.Select,{variant:"standard",error:!!c,disabled:e,value:this.state.value||"_",renderValue:()=>this.getText(t==null?void 0:t.label,this.props.schema.noTranslation),onChange:r=>{let{value:a}=r.target;a==="_"&&(a=""),this.setState({value:a},()=>{const h=this.onChange(this.props.attr,a);if(h instanceof Promise&&h.catch(S=>console.error(S)),this.props.schema.changeGuiLanguage)if(a){if(a===l.I18n.getLanguage())return;l.I18n.setLanguage(a),this.props.oContext.changeLanguage&&this.props.oContext.changeLanguage()}else this.props.oContext.socket.getSystemConfig().then(S=>{S.common.language!==l.I18n.getLanguage()&&S.common.language&&(l.I18n.setLanguage(S.common.language),this.props.oContext.changeLanguage&&this.props.oContext.changeLanguage())}).catch(S=>console.error(`Cannot read system config: ${S}`))})}},(i=this.state.selectOptions)==null?void 0:i.map(r=>n().createElement(o.MenuItem,{key:r.value,value:r.value},r.label))),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const Ze=ot;class Qe extends f{constructor(e){super(e);Q(this,"scrollRef");this.scrollRef=n().createRef()}scrolledDown(){return this.scrollRef.current?this.scrollRef.current.offsetHeight+this.scrollRef.current.scrollTop>=this.scrollRef.current.scrollHeight:!1}componentDidMount(){super.componentDidMount(),f.getValue(this.props.data,this.props.attr)||(this.props.schema.licenseUrl?(this.setState({showLicenseDialog:!0,loading:!0,scrolledDown:!1}),fetch(this.props.schema.licenseUrl).then(e=>e.text()).then(e=>this.setState({license:e,loading:!1})).catch(e=>this.setState({license:e.toString(),loading:!1,error:!0,scrolledDown:!1}))):this.setState({showLicenseDialog:!0,scrolledDown:!1}),setTimeout(()=>{this.scrollRef.current&&(this.scrolledDown()?this.setState({scrolledDown:!0}):this.scrollRef.current.addEventListener("scroll",()=>{!this.state.scrolledDown&&this.scrolledDown()&&this.setState({scrolledDown:!0})}))},1e3))}renderItem(e,t){return this.state.showLicenseDialog?n().createElement(o.Dialog,{maxWidth:"lg",open:!0,onClose:(s,i)=>{i!=="escapeKeyDown"&&i!=="backdropClick"&&this.setState({showLicenseDialog:!1})}},n().createElement(o.DialogTitle,null,this.props.schema.title?l.I18n.t(this.props.schema.title):l.I18n.t("ra_License agreement")),n().createElement(o.DialogContent,null,this.props.schema.licenseUrl?n().createElement(n().Fragment,null,this.state.loading?n().createElement(o.LinearProgress,null):null,n().createElement("pre",{ref:this.scrollRef,style:{width:"100%",height:"100%",overflowY:"auto",fontSize:14}},this.state.license)):null,!this.props.schema.licenseUrl&&this.props.schema.texts?n().createElement("div",{ref:this.scrollRef,style:{width:"100%",height:"100%",overflowY:"auto",fontSize:14}},this.props.schema.texts.map((s,i)=>this.props.schema.noTranslation?n().createElement("p",{key:i},s):n().createElement("p",{key:i},l.I18n.t(s)))):null),n().createElement(o.DialogActions,null,this.props.schema.checkBox?n().createElement(o.FormControlLabel,{control:n().createElement(o.Checkbox,{disabled:t,checked:!!this.state.licenseChecked,onClick:()=>this.setState({licenseChecked:!this.state.licenseChecked})}),label:l.I18n.t(this.props.schema.checkBox)}):null,n().createElement(o.Button,{disabled:t||this.state.loading||this.state.error||this.props.schema.checkBox&&!this.state.licenseChecked||!this.state.scrolledDown,onClick:()=>{this.setState({showLicenseDialog:!1});const s=this.onChange(this.props.attr,!0);s instanceof Promise&&s.catch(i=>console.error(`Cannot set value: ${i}`))},color:"primary",variant:"contained",startIcon:n().createElement(u.Check,null)},this.props.schema.agreeText?l.I18n.t(this.props.schema.agreeText):l.I18n.t("ra_Accept license")),n().createElement(o.Button,{onClick:()=>{this.setState({showLicenseDialog:!1}),setTimeout(()=>this.setState({showLicenseDialog:!0}),2e3)},color:"grey",variant:"contained",startIcon:n().createElement(u.Close,null)},l.I18n.t("ra_Close")))):null}}const rt=Qe,Dt={indeterminate:{opacity:.5},control:{flexDirection:"row",width:"100%"}};class tn extends f{constructor(){super(...arguments);Q(this,"updateTimeout")}componentDidMount(){super.componentDidMount();let e=f.getValue(this.props.data,this.props.attr);if(e==null&&(e=""),Array.isArray(e)&&this.props.oContext.multiEdit){e=f.DIFFERENT_VALUE,this.setState({_value:e,oldValue:e});return}this.setState({_value:e.toString(),oldValue:e.toString()})}static getDerivedStateFromProps(e,t){if(e.schema.min!==void 0&&e.schema.min<0||e.schema.max!==void 0&&e.schema.max<0)return null;const s=f.getValue(e.data,e.attr);return e.oContext.multiEdit&&t._value===f.DIFFERENT_VALUE?{_value:f.DIFFERENT_VALUE}:s==null||t.oldValue===null||t.oldValue===void 0||s.toString()!==parseFloat(t._value).toString()&&s.toString()!==t.oldValue.toString()?{_value:s}:null}checkValue(e){if(e==null)return null;e=e.toString().trim();const t=e===""?0:parseFloat(e);return e!==""&&Number.isNaN(t)?"ra_Not a number":e!==""&&window.isFinite(t)?this.props.schema.min!==void 0&&tthis.props.schema.max?"ra_Too big":e===""||e==="-"||Number.isNaN(t)?"ra_Not a number":null:"ra_Not a number"}renderItem(e,t){const s=Array.isArray(this.state._value)||this.state._value===f.DIFFERENT_VALUE;if(this.state.oldValue!==null&&this.state.oldValue!==void 0?(this.updateTimeout&&clearTimeout(this.updateTimeout),this.updateTimeout=setTimeout(()=>{this.updateTimeout=void 0,this.setState({oldValue:null})},30)):this.updateTimeout&&(clearTimeout(this.updateTimeout),this.updateTimeout=void 0),s){const i=f.getValue(this.props.data,this.props.attr),r=(i==null?void 0:i.filter(a=>a||a===0).map(a=>({label:a.toString(),value:a})))||[];return r.unshift({label:l.I18n.t(f.DIFFERENT_LABEL),value:f.DIFFERENT_VALUE}),n().createElement(o.Autocomplete,{style:Dt.indeterminate,fullWidth:!0,freeSolo:!0,value:r[0],getOptionSelected:(a,h)=>a.label===h.label,onChange:(a,h)=>{const S=this.onChange(this.props.attr,h==null?void 0:h.value,()=>{this.setState({_value:h==null?void 0:h.value,oldValue:this.state._value})});S instanceof Promise&&S.catch(L=>console.error(L))},options:r,getOptionLabel:a=>a.label,renderInput:a=>n().createElement(o.TextField,Oe(q({},a),{label:this.getText(this.props.schema.label),variant:"standard",slotProps:{htmlInput:Oe(q({},a.inputProps),{readOnly:this.props.schema.readOnly||!1})},error:!!e,placeholder:this.getText(this.props.schema.placeholder),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation),disabled:!!t}))})}return!e&&this.state._value!==null&&this.state._value!==void 0&&this.state._value&&(e=this.checkValue(this.state._value),e&&(e=l.I18n.t(e))),n().createElement(o.FormControl,{variant:"standard",style:Dt.control},n().createElement(o.TextField,{variant:"standard",type:"number",fullWidth:!0,slotProps:{htmlInput:{min:this.props.schema.min,max:this.props.schema.max,step:this.props.schema.step,readOnly:this.props.schema.readOnly||!1}},value:this.state._value===null||this.state._value===void 0?"":this.state._value,error:!!e,disabled:!!t,onChange:i=>{const r=i.target.value,a=this.checkValue(r);a?this.onError(this.props.attr,l.I18n.t(a)):this.onError(this.props.attr),this.setState({_value:r,oldValue:this.state._value},()=>this.onChange(this.props.attr,parseFloat(r)))},placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:e&&typeof e=="string"?e:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)}))}}const Ln=tn,Cn={flex:{display:"flex"},button:{height:48,marginLeft:4,minWidth:48}};class $n extends f{componentDidMount(){super.componentDidMount();const{data:c,attr:e}=this.props,t=f.getValue(c,e)||"";this.setState({value:t,initialized:!0})}renderItem(c,e){if(!this.state.initialized)return null;const t=this.props.oContext.socket,{schema:s,attr:i}=this.props,{value:r,showSelectId:a}=this.state;return n().createElement(o.FormControl,{fullWidth:!0,variant:"standard"},s.label?n().createElement(o.InputLabel,{shrink:!0},this.getText(s.label)):null,n().createElement("div",{style:Cn.flex},n().createElement(o.TextField,{variant:"standard",fullWidth:!0,value:r,error:!!c,disabled:e,placeholder:this.getText(s.placeholder),label:this.getText(s.label),helperText:this.renderHelp(s.help,s.helpLink,s.noTranslation),onChange:h=>{const S=h.target.value;this.setState({value:S},()=>this.onChange(i,S))}}),n().createElement(o.Button,{color:"grey",disabled:e,style:Cn.button,size:"small",variant:"outlined",onClick:()=>this.setState({showSelectId:!0})},"...")),a?n().createElement(l.DialogSelectID,{imagePrefix:this.props.oContext.imagePrefix===void 0?"../..":this.props.oContext.imagePrefix,dialogName:`admin.${this.props.oContext.adapterName}`,filterFunc:s.filterFunc,themeType:this.props.oContext.themeType,theme:this.props.oContext.theme,types:s.types?Array.isArray(s.types)?s.types:[s.types]:void 0,customFilter:s.customFilter,filters:s.filters,socket:t,selected:r,root:s.root,onClose:()=>this.setState({showSelectId:!1}),onOk:h=>this.setState({showSelectId:!1,value:h},()=>this.onChange(i,h))}):null)}}const Nn=$n,nn={fullWidth:{width:"100%",display:"inline-block"},halfWidth1:{width:"calc(50% - 5px)",display:"inline-block",marginRight:8},halfWidth2:{width:"calc(50% - 5px)",display:"inline-block"}},Vt="____ppp____";class Pn extends f{componentDidMount(){super.componentDidMount();const c=f.getValue(this.props.data,this.props.attr);this.setState({_repeat:c?Vt:"",_visible:!1,value:c?Vt:"",_notEqual:!1})}onChangePassword(c,e){c===void 0&&(c=this.state.value),e===void 0&&(e=this.state._repeat);const t=!!this.props.schema.repeat&&e!==c;this.setState({value:c,_repeat:e,_notEqual:t},()=>{if(t)this.onError(this.props.attr,l.I18n.t("ra_Passwords are not equal!"));else{this.onError(this.props.attr);const s=this.onChange(this.props.attr,c);s instanceof Promise&&s.catch(i=>this.onError(this.props.attr,i))}})}renderItem(c,e){if(this.state._notEqual===void 0)return null;const t=n().createElement(o.TextField,{variant:"standard",fullWidth:!0,type:this.state._visible&&this.state.value!==Vt?"text":"password",value:this.state.value,error:!!c||this.state._notEqual,disabled:!!e,onChange:s=>this.onChangePassword(s.target.value),label:this.getText(this.props.schema.label),slotProps:{input:{autoComplete:"new-password",endAdornment:this.state.value&&this.state.value!==Vt&&this.props.schema.visible&&!e&&!this.props.schema.readOnly?n().createElement(o.InputAdornment,{position:"end"},n().createElement(o.IconButton,{size:"large",tabIndex:-1,onClick:s=>{s.preventDefault(),s.stopPropagation(),this.setState({_visible:!this.state._visible})},edge:"end"},this.state._visible?n().createElement(u.VisibilityOff,null):n().createElement(u.Visibility,null))):void 0},htmlInput:{autoComplete:"new-password",form:{autoComplete:"off"},maxLength:this.props.schema.maxLength||this.props.schema.max||void 0,readOnly:this.props.schema.readOnly||!1}},helperText:this.state._notEqual?l.I18n.t("ra_Passwords are not equal!"):this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)});if(this.props.schema.repeat&&!this.props.schema.readOnly){const s=this.state._visible?null:n().createElement(o.TextField,{variant:"standard",fullWidth:!0,type:"password",value:this.state._repeat,error:!!c||this.state._notEqual,disabled:!!e,onChange:i=>this.onChangePassword(void 0,i.target.value),label:`${this.getText(this.props.schema.label)} (${l.I18n.t("ra_repeat")})`,slotProps:{input:{autoComplete:"new-password"},htmlInput:{autoComplete:"new-password",form:{autoComplete:"off"},maxLength:this.props.schema.maxLength||this.props.schema.max||void 0}},helperText:this.state._notEqual?l.I18n.t("ra_Passwords are not equal!"):this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)});return n().createElement("div",{style:nn.fullWidth},n().createElement("div",{style:nn.halfWidth1},t),n().createElement("div",{style:nn.halfWidth2},s))}return t}}const Rn=Pn;class Mn extends f{renderItem(c,e){return n().createElement(o.TextField,{variant:"standard",fullWidth:!0,disabled:!!e,slotProps:{input:{endAdornment:this.props.schema.copyToClipboard?n().createElement(o.IconButton,{size:"small",onClick:()=>{l.Utils.copyToClipboard(this.getPattern(this.props.schema.pattern,null,this.props.schema.noTranslation)),window.alert(l.I18n.t("ra_Copied"))}},n().createElement(l.IconCopy,null)):void 0}},value:this.getPattern(this.props.schema.pattern,null,!0),label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)})}}const Vn=Mn,jn={warning:{"& .Mui-error":{color:"orange"}}};class sn extends f{constructor(){super(...arguments);Q(this,"updateTimeout")}componentDidMount(){return pe(this,null,function*(){nt(sn.prototype,this,"componentDidMount").call(this);let e=f.getValue(this.props.data,this.props.attr);e==null&&(e=""),this.setState({_value:e.toString(),oldValue:e.toString()});const t=yield this.props.oContext.socket.getAdapterInstances(),s=`system.adapter.${this.props.oContext.adapterName}.${this.props.oContext.instance}`,i=yield this.props.oContext.socket.getObject(s),r=i==null?void 0:i.common.host,a=[];t.forEach(h=>{var L,O,N,te;if(!h||h._id===s||h.common.host!==r||!((L=h.native)!=null&&L.bind))return;if(h!=null&&h.native&&h.native.secure&&h.native.leEnabled&&h.native.leUpdate){const ye=parseInt(h.native.leCheckPort||h.native.lePort,10);ye&&a.push({name:`${h._id.replace("system.adapter.","")} (LE)`,port:ye,v6bind:h.native.bind.includes(":")?h.native.bind:h.native.v6bind,bind:h.native.bind,enabled:!!((O=h.common)!=null&&O.enabled)})}const S=parseInt((N=h==null?void 0:h.native)==null?void 0:N.port,10);S&&a.push({name:h._id.replace("system.adapter.",""),bind:h.native.bind,v6bind:h.native.bind.includes(":")?h.native.bind:h.native.v6bind,port:S,enabled:!!((te=h.common)!=null&&te.enabled)})}),this.setState({ports:a})})}static getDerivedStateFromProps(e,t){const s=f.getValue(e.data,e.attr);return s==null||t.oldValue===null||t.oldValue===void 0||s.toString()!==parseInt(t._value,10).toString()&&s.toString()!==t.oldValue.toString()?{_value:s}:null}checkValue(e){if(e==null)return null;const t=this.props.schema.min===void 0?20:this.props.schema.min,s=this.props.schema.max||65535;e=e.toString().trim();const i=e===""?0:parseInt(e,10);return e!==""&&Number.isNaN(i)?"ra_Not a number":e!==""&&window.isFinite(Number(e))?is?"ra_Too big":e===""||e==="-"||Number.isNaN(i)?"ra_Not a number":null:"ra_Not a number"}renderItem(e,t){this.state.oldValue!==null&&this.state.oldValue!==void 0?(this.updateTimeout&&clearTimeout(this.updateTimeout),this.updateTimeout=setTimeout(()=>{this.updateTimeout=void 0,this.setState({oldValue:null})},30)):this.updateTimeout&&(clearTimeout(this.updateTimeout),this.updateTimeout=void 0);const s=this.props.schema.min===void 0?20:this.props.schema.min,i=this.props.schema.max||65535;let r;if(this.state.ports){const a=parseInt(this.state._value,10);if(a){const h=this.state.ports.filter(L=>!this.props.data.bind||this.props.data.bind===L.bind||this.props.data.bind==="0.0.0.0"||L.bind==="0.0.0.0");let S=h.findIndex(L=>L.port===a&&L.enabled);S!==-1?e=l.I18n.t("ra_Port is already used by %s",this.state.ports[S].name):(S=h.findIndex(L=>L.port===a&&!L.enabled),S!==-1&&(r=!0,e=l.I18n.t("ra_Port could be used by %s",this.state.ports[S].name)))}}return!e&&this.state._value!==null&&this.state._value!==void 0&&(e=this.checkValue(this.state._value),typeof e=="string"&&(e=l.I18n.t(e))),n().createElement(o.TextField,{variant:"standard",type:"number",fullWidth:!0,slotProps:{htmlInput:{min:s,max:i,readOnly:this.props.schema.readOnly||!1}},value:this.state._value===null||this.state._value===void 0?"":this.state._value,error:!!e,disabled:!!t,sx:r?jn.warning:void 0,onChange:a=>{const h=Number(a.target.value.toString().replace(/[^0-9]/g,"")).toString(),S=this.checkValue(h);S?this.onError(this.props.attr,l.I18n.t(S)):this.onError(this.props.attr),this.setState({_value:h,oldValue:this.state._value},()=>{if(h.trim()===parseInt(h,10).toString()){const L=this.onChange(this.props.attr,parseInt(h,10)||0);L instanceof Promise&&L.catch(O=>{console.error(`Cannot set value for ${this.props.attr}: ${O}`)})}})},placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:e&&typeof e=="string"?e:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)})}}const Un=sn;class Wn extends f{componentDidMount(){super.componentDidMount();const c=f.getValue(this.props.data,this.props.attr);this.props.oContext.socket.getEnums("rooms").then(e=>{const t=Object.keys(e).map(s=>({value:this.props.schema.short?s.replace("enum.rooms.",""):s,label:this.getText(e[s].common.name),obj:e[s]}));this.props.schema.allowDeactivate!==!1&&t.unshift({label:l.I18n.t(f.NONE_LABEL),value:f.NONE_VALUE}),this.setState({value:c,selectOptions:t})}).catch(e=>console.error(`Cannot get enums: ${e}`))}renderItem(c,e){if(!this.state.selectOptions)return null;const t=this.state.selectOptions.find(s=>s.value===this.state.value);return n().createElement(o.FormControl,{variant:"standard",fullWidth:!0},this.props.schema.label?n().createElement(o.InputLabel,null,this.getText(this.props.schema.label)):null,n().createElement(o.Select,{variant:"standard",error:!!c,disabled:!!e,value:this.state.value||"_",renderValue:()=>t?t.obj?n().createElement(l.TextWithIcon,{value:t.obj,themeType:this.props.oContext.themeType,lang:l.I18n.getLanguage()}):t.label:"",onChange:s=>{this.setState({value:s.target.value==="_"?"":s.target.value},()=>this.onChange(this.props.attr,this.state.value))}},this.state.selectOptions.map(s=>n().createElement(o.MenuItem,{key:s.value,value:s.value,style:s.value===f.DIFFERENT_VALUE?{opacity:.5}:{}},s.obj?n().createElement(l.TextWithIcon,{value:s.obj,themeType:this.props.oContext.themeType,lang:l.I18n.getLanguage()}):s.label))),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const Jn=Wn,Hn={fullWidth:{width:"100%"},noMargin:{"&>div":{marginTop:0}}};class zn extends f{constructor(){super(...arguments);Q(this,"initialValue","")}componentDidMount(){super.componentDidMount();const e=f.getValue(this.props.data,this.props.attr),t=[];(this.props.schema.options||[]).forEach(s=>{const i=s;Array.isArray(i.items)?(t.push({label:this.getText(s.label),value:s.value,group:!0}),i.items.forEach(r=>t.push({label:this.getText(r.label),value:r.value,hidden:r.hidden}))):t.push({label:this.getText(s.label),value:s.value,hidden:s.hidden})}),Array.isArray(e)?(this.initialValue=[...e],t.unshift({label:l.I18n.t(f.DIFFERENT_LABEL),value:f.DIFFERENT_VALUE}),this.setState({value:f.DIFFERENT_VALUE,selectOptions:t})):this.setState({value:e,selectOptions:t})}renderItem(e,t){if(!this.state.selectOptions)return null;const s=(this.state.selectOptions||[]).filter(r=>r.hidden?this.props.custom?!this.executeCustom(r.hidden,this.props.data,this.props.customObj,this.props.oContext.instanceObj,this.props.arrayIndex,this.props.globalData):!this.execute(r.hidden,this.props.schema.default,this.props.data,this.props.arrayIndex,this.props.globalData):!0),i=s.find(r=>r.value==this.state.value);return n().createElement(o.FormControl,{variant:"standard",fullWidth:!0,sx:this.props.table!==void 0&&Hn.noMargin,id:`jsonSelect_${this.props.attr}_${this.props.index||this.props.index===0?this.props.index:""}`},this.props.schema.label?n().createElement(o.InputLabel,null,this.getText(this.props.schema.label)):null,n().createElement(o.Select,{variant:"standard",error:!!e,disabled:!!t,value:this.state.value||"_",renderValue:()=>this.getText(i==null?void 0:i.label,this.props.schema.noTranslation),onChange:r=>{this.setState({value:r.target.value==="_"?"":r.target.value},()=>{let a;this.state.value===f.DIFFERENT_VALUE?a=this.onChange(this.props.attr,this.initialValue):a=this.onChange(this.props.attr,this.state.value),a instanceof Promise&&a.catch(h=>console.error(h))})}},s.map((r,a)=>r.group?n().createElement(o.ListSubheader,{key:a},this.getText(r.label,this.props.schema.noTranslation)):n().createElement(o.MenuItem,{key:a,value:r.value,style:r.value===f.DIFFERENT_VALUE?{opacity:.5}:{}},this.getText(r.label,this.props.schema.noTranslation)))),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const qn=zn,Kn={menuPaper:{maxHeight:800}};class Gn extends f{constructor(){super(...arguments);Q(this,"initialized",!1);Q(this,"localContext")}askInstance(){if(this.props.alive){let e=this.props.schema.data;if(e===void 0&&this.props.schema.jsonData){const t=this.getPattern(this.props.schema.jsonData,null,!0);try{e=JSON.parse(t)}catch(s){console.error(`Cannot parse json data: ${t}`)}}e===void 0&&(e=null),this.setState({running:!0},()=>{this.props.oContext.socket.sendTo(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,this.props.schema.command||"send",e).then(t=>this.setState({list:t,running:!1})).catch(t=>{console.error(`Cannot send command: ${t}`)})})}else{const e=f.getValue(this.props.data,this.props.attr);this.setState({value:e,running:!1})}}getContext(){const e={};return Array.isArray(this.props.schema.alsoDependsOn)&&this.props.schema.alsoDependsOn.forEach(t=>e[t]=f.getValue(this.props.data,t)),JSON.stringify(e)}_getValue(){let e=this.state.value===null||this.state.value===void 0?f.getValue(this.props.data,this.props.attr):this.state.value;return this.props.schema.multiple&&(typeof e=="string"?e=[e]:e==null&&(e=[])),e}renderItem(e,t){var a;if(this.props.alive){const h=this.getContext();(h!==this.localContext||!this.initialized)&&(this.localContext=h,setTimeout(()=>this.askInstance(),this.initialized?300:50),this.initialized=!0)}const s=this._getValue();if(!this.props.alive||!this.state.running&&!((a=this.state.list)!=null&&a.length))return this.props.schema.multiple||this.props.schema.manual===!1?l.I18n.t("ra_Cannot retrieve options, as instance is offline"):n().createElement(o.TextField,{variant:"standard",fullWidth:!0,value:s,error:!!e,disabled:!!t,onChange:h=>{const S=h.target.value;this.setState({value:S},()=>this.onChange(this.props.attr,(S||"").trim()))},placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation),slotProps:{input:{endAdornment:this.state.value&&!this.props.schema.noClearButton?n().createElement(o.InputAdornment,{position:"end"},n().createElement(o.IconButton,{size:"small",onClick:()=>this.setState({value:""},()=>this.onChange(this.props.attr,""))},n().createElement(u.Close,null))):null}}});if(this.state.running)return n().createElement(o.CircularProgress,{size:"24"});const i=this.state.list.filter(h=>h.hidden?this.props.custom?!this.executeCustom(h.hidden,this.props.data,this.props.customObj,this.props.oContext.instanceObj,this.props.arrayIndex,this.props.globalData):!this.execute(h.hidden,this.props.schema.default,this.props.data,this.props.arrayIndex,this.props.globalData):!0),r=i.find(h=>h.value===s);return n().createElement(o.FormControl,{variant:"standard",fullWidth:!0},this.props.schema.label?n().createElement(o.InputLabel,null,this.getText(this.props.schema.label)):null,n().createElement(o.Select,{variant:"standard",error:!!e,multiple:this.props.schema.multiple,disabled:!!t,sx:{"&.MuiSelect-paper":this.props.schema.multiple?Kn.menuPaper:void 0},value:s,renderValue:h=>this.props.schema.multiple?n().createElement(o.Box,{sx:{display:"flex",flexWrap:"wrap",gap:.5}},h.map(S=>{const L=i.find(O=>O.value===S);if(L||this.props.schema.showAllValues!==!1){const O=(L==null?void 0:L.label)||S;return n().createElement(o.Chip,{key:S,label:O})}return null})):(r==null?void 0:r.label)||h,onChange:h=>{const S=this.onChange(this.props.attr,h.target.value);S instanceof Promise&&S.catch(L=>console.error(`Cannot set value: ${L}`))}},i.map((h,S)=>n().createElement(o.MenuItem,{key:S,value:h.value},this.props.schema.multiple?n().createElement(o.Checkbox,{checked:s.includes(h.value),onClick:()=>{const L=JSON.parse(JSON.stringify(this._getValue())),O=s.indexOf(h.value);O!==-1?L.splice(O,1):(L.push(h.value),L.sort()),this.setState({value:L},()=>this.onChange(this.props.attr,L))}}):null,n().createElement(o.ListItemText,{primary:h.label})))),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const Xn=Gn,Dn={fullWidth:{width:"100%"}};function pt(E){return E.split(".").reduce((c,e)=>(c<<8)+parseInt(e,10),0)>>>0}function Yn(E,c){var s,i;const e=(i=(s=E==null?void 0:E.native)==null?void 0:s.hardware)==null?void 0:i.networkInterfaces;if(!e)return null;let t;return Object.keys(e).forEach(r=>e[r].forEach(a=>{a.internal||c.includes(":")&&a.family!=="IPv6"||c.includes(".")&&!c.match(/[^.\d]/)&&a.family!=="IPv4"||(a.family==="IPv4"&&!a.address.startsWith("172")&&(c==="127.0.0.0"||c==="localhost"||c.match(/[^.\d]/))?t=a.address:t||(a.family==="IPv4"&&c.includes(".")&&(pt(c)&pt(a.netmask),pt(a.address)&pt(a.netmask)),t=a.address))})),t||Object.keys(e).forEach(r=>e[r].forEach(a=>{a.internal||c.includes(":")&&a.family!=="IPv6"||c.includes(".")&&!c.match(/[^.\d]/)&&a.family!=="IPv4"||(a.family==="IPv6"&&(c==="127.0.0.0"||c==="localhost"||c.match(/[^.\d]/))?t=a.address:t||(a.family==="IPv4"&&c.includes(".")&&(pt(c)&pt(a.netmask),pt(a.address)&pt(a.netmask)),t=a.address))})),t||Object.keys(e).forEach(r=>{e[r].forEach(a=>{a.internal||c.includes(":")&&a.family!=="IPv6"||c.includes(".")&&!c.match(/[^.\d]/)&&a.family!=="IPv4"||(c==="127.0.0.0"||c==="localhost"||c.match(/[^.\d]/),t=a.address)})}),t||Object.keys(e).forEach(r=>{e[r].forEach(a=>{a.internal||(t=a.address)})}),t}class on extends f{componentDidMount(){return pe(this,null,function*(){var e;nt(on.prototype,this,"componentDidMount").call(this);let c=window.location.hostname;if(this.props.schema.openUrl){const t=yield this.props.oContext.socket.getCurrentInstance(),s=yield this.props.oContext.socket.getObject(`system.adapter.${t}`);if(s){const i=yield this.props.oContext.socket.getObject(`system.host.${(e=s==null?void 0:s.common)==null?void 0:e.host}`);if(i){const r=Yn(i,window.location.hostname);if(r)c=`${r}:${window.location.port}`;else{console.warn(`Cannot find suitable IP in host ${s.common.host} for ${s._id}`);return}}}}yield new Promise(t=>{this.setState({_error:"",_message:"",hostname:c},t)}),this.props.schema.onLoaded&&this._onClick()})}renderErrorDialog(){return this.state._error?n().createElement(l.DialogError,{text:this.state._error,onClose:()=>this.setState({_error:""})}):null}renderMessageDialog(){return this.state._message?n().createElement(l.DialogMessage,{text:this.state._message,onClose:()=>this.setState({_message:""})}):null}_onClick(){this.props.oContext.onCommandRunning(!0),this.setState({running:!0});const c=`${window.location.protocol}//${window.location.host}${window.location.pathname.replace(/\/index\.html$/,"")}`,e=`${window.location.protocol}//${this.state.hostname.split(":").length>3?`[${this.state.hostname}]`:this.state.hostname}${window.location.pathname.replace(/\/index\.html$/,"")}`;let t=this.props.schema.data;if(t===void 0&&this.props.schema.jsonData){const i=this.getPattern(this.props.schema.jsonData,q({_origin:c,_originIp:e},this.props.data),!0);try{t=JSON.parse(i)}catch(r){console.error(`Cannot parse json data: ${i}`)}}t===void 0&&(t=null),this.props.schema.openUrl&&!t&&(t={_origin:c,_originIp:e});let s;this.props.schema.timeout&&(s=setTimeout(()=>{this.props.oContext.onCommandRunning(!1),this.setState({_error:l.I18n.t("ra_Request timed out"),running:!1})},parseInt(this.props.schema.timeout,10)||1e4)),this.props.oContext.socket.sendTo(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,this.props.schema.command||"send",t).then(i=>pe(this,null,function*(){if(s&&(clearTimeout(s),s=void 0),i!=null&&i.error)if(this.props.schema.error&&this.props.schema.error[i.error]){let r=this.getText(this.props.schema.error[i.error]);i.args&&i.args.forEach(a=>r=r.replace("%s",a)),this.setState({_error:r})}else this.setState({_error:i.error?l.I18n.t(i.error):l.I18n.t("ra_Error")});else{if(i!=null&&i.command){this.props.oContext.onBackEndCommand&&this.props.oContext.onBackEndCommand(i.command);return}if(i!=null&&i.reloadBrowser&&this.props.schema.reloadBrowser)window.location.reload();else if(i!=null&&i.openUrl&&this.props.schema.openUrl)window.open(i.openUrl,i.window||this.props.schema.window||"_blank");else if(i!=null&&i.result&&this.props.schema.result&&this.props.schema.result[i.result]){let r=this.getText(this.props.schema.result[i.result]);i.args&&i.args.forEach(a=>r=r.replace("%s",a)),window.alert(r)}if(i!=null&&i.native&&this.props.schema.useNative){for(const[r,a]of Object.entries(i.native))yield this.onChangeAsync(r,a);setTimeout(()=>this.props.oContext.forceUpdate(Object.keys(i.native),this.props.data),300)}else i!=null&&i.result?window.alert(typeof i.result=="object"?JSON.stringify(i.result):i.result):window.alert(l.I18n.t("ra_Ok"));i!=null&&i.saveConfig&&this.props.onChange(null,null,null,!0)}})).catch(i=>{this.props.schema.error&&this.props.schema.error[i.toString()]?this.setState({_error:this.getText(this.props.schema.error[i.toString()])}):this.setState({_error:l.I18n.t(i.toString())||l.I18n.t("ra_Error")})}).then(()=>{this.props.oContext.onCommandRunning(!1),this.setState({running:!1})})}renderDialogConfirm(){if(!this.state.confirmDialog)return null;const c=this.state.confirmData||this.props.schema.confirm;let e=null;return c.type==="warning"?e=n().createElement(u.Warning,null):c.type==="error"?e=n().createElement(u.Error,null):c.type==="info"&&(e=n().createElement(u.Info,null)),n().createElement(l.DialogConfirm,{title:this.getText(c.title)||l.I18n.t("ra_Please confirm"),text:this.getText(c.text),ok:this.getText(c.ok)||l.I18n.t("ra_Ok"),cancel:this.getText(c.cancel)||l.I18n.t("ra_Cancel"),icon:e||void 0,onClose:t=>this.setState({confirmDialog:!1},()=>t&&this._onClick())})}renderItem(c,e){const t=this.getIcon();return n().createElement("div",{style:Dn.fullWidth},n().createElement(o.Button,{variant:this.props.schema.variant||void 0,color:this.props.schema.color||"grey",style:q(q({},Dn.fullWidth),this.props.schema.controlStyle||void 0),disabled:e||!this.props.alive,startIcon:t,title:this.props.alive?this.getText(this.props.schema.title)||"":l.I18n.t("ra_Instance is not alive"),onClick:()=>{this.props.schema.confirm?this.setState({confirmDialog:!0}):this._onClick()}},this.props.schema.showProcess&&this.state.running?n().createElement(o.CircularProgress,{size:20,style:{marginRight:8}}):null,this.getText(this.props.schema.label,this.props.schema.noTranslation)),this.renderErrorDialog(),this.renderMessageDialog())}}const vn=on,yn={fullWidth:{width:"100%"},icon:{width:24,height:24,marginRight:4}};class Zn extends f{_onClick(){return pe(this,null,function*(){var t,s;let c=this.props.schema.val;if(typeof c=="string"&&c.includes("${")){c=this.getPattern(c,null,!0);const i=yield this.props.oContext.socket.getObject(this.props.schema.id);((t=i==null?void 0:i.common)==null?void 0:t.type)==="number"?c=parseFloat(c):((s=i==null?void 0:i.common)==null?void 0:s.type)==="boolean"&&(c=c==="true"||c===!0||c==="1"||c===1)}const e=(this.props.schema.id||"").replace(/%INSTANCE%/g,(this.props.oContext.instance||0).toString());try{yield this.props.oContext.socket.setState(e,{val:c,ack:!!this.props.schema.ack}),this.props.schema.okText&&window.alert(this.getText(this.props.schema.okText))}catch(i){this.props.schema.error&&this.props.schema.error[i.toString()]?window.alert(this.getText(this.props.schema.error[i.toString()])):window.alert(l.I18n.t(i.toString())||l.I18n.t("ra_Error"))}})}renderDialogConfirm(){if(!this.state.confirmDialog)return null;const c=this.state.confirmData||this.props.schema.confirm;let e=null;return c.type==="warning"?e=n().createElement(u.Warning,null):c.type==="error"?e=n().createElement(u.Error,null):c.type==="info"&&(e=n().createElement(u.Info,null)),n().createElement(l.DialogConfirm,{title:this.getText(c.title)||l.I18n.t("ra_Please confirm"),text:this.getText(c.text),ok:this.getText(c.ok)||l.I18n.t("ra_Ok"),cancel:this.getText(c.cancel)||l.I18n.t("ra_Cancel"),icon:e,onClose:t=>this.setState({confirmDialog:!1},()=>t&&this._onClick())})}renderItem(c,e){return n().createElement(o.Button,{variant:this.props.schema.variant||void 0,color:this.props.schema.color||"grey",style:yn.fullWidth,disabled:e,onClick:()=>pe(this,null,function*(){this.props.schema.confirm?this.setState({confirmDialog:!0}):yield this._onClick()})},this.props.schema.icon?n().createElement(l.Icon,{src:this.props.schema.icon,style:yn.icon}):null,this.getText(this.props.schema.label,this.props.schema.noTranslation))}}const Qn=Zn,En={fullWidth:{width:"100%"},slider:{marginLeft:10,marginRight:10,width:"calc(100% - 20px)"}};class es extends f{componentDidMount(){super.componentDidMount();const c=f.getValue(this.props.data,this.props.attr);this.setState({_value:c})}static getDerivedStateFromProps(c,e){if(c.schema.min!==void 0&&c.schema.min<0||c.schema.max!==void 0&&c.schema.max<0)return null;const t=f.getValue(c.data,c.attr);return t==null||t.toString()!==parseFloat(e._value).toString()?{_value:t}:null}renderItem(c,e){const t=this.props.schema.min||0,s=this.props.schema.max||100,i=this.props.schema.unit||"",r=[{value:t,label:t+i},{value:s,label:s+i}];return n().createElement(o.Box,{style:En.fullWidth},this.props.schema.label?n().createElement(o.Typography,{gutterBottom:!0},this.getText(this.props.schema.label)):null,n().createElement(o.Slider,{style:En.slider,value:this.state._value,getAriaValueText:a=>a+i,step:this.props.schema.step||(s-t)/100,valueLabelDisplay:"auto",marks:r,min:t,max:s,disabled:!!e,onChange:a=>{const h=a.target.value;this.setState({_value:h},()=>this.onChange(this.props.attr,h))}}),this.props.schema.help?n().createElement(o.Typography,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const ts=es;function dt(E,c){return E==="edit"||E==="rename"?n().createElement(u.Edit,{style:c}):E==="delete"?n().createElement(u.Delete,{style:c}):E==="refresh"?n().createElement(u.Refresh,{style:c}):E==="newDevice"||E==="new"||E==="add"?n().createElement(u.Add,{style:c}):E==="discover"||E==="search"?n().createElement(u.Search,{style:c}):E==="unpairDevice"||E==="unpair"?n().createElement(u.LinkOff,{style:c}):E==="pairDevice"||E==="pair"?n().createElement(u.Link,{style:c}):E==="identify"?n().createElement(u.NotListedLocation,{style:c}):E==="play"?n().createElement(u.PlayArrow,{style:c}):E==="stop"?n().createElement(u.Stop,{style:c}):E==="pause"?n().createElement(u.Pause,{style:c}):E==="forward"||E==="next"?n().createElement(u.FastForward,{style:c}):E==="rewind"||E==="previous"?n().createElement(u.FastRewind,{style:c}):E==="lamp"||E==="light"?n().createElement(u.Lightbulb,{style:c}):E==="backlight"?n().createElement(u.Fluorescent,{style:c}):E==="dimmer"?n().createElement(u.WbIncandescent,{style:c}):E==="socket"?n().createElement(u.Power,{style:c}):E==="settings"?n().createElement(u.Settings,{style:c}):E==="users"||E==="group"?n().createElement(u.Group,{style:c}):E==="user"?n().createElement(u.Person,{style:c}):E==="qrcode"?n().createElement(u.QrCode,{style:c}):E==="connection"?n().createElement(u.Wifi,{style:c}):E==="no-connection"?n().createElement(u.WifiOff,{style:c}):E==="visible"?n().createElement(u.Visibility,{style:c}):null}function ns(E,c){return typeof c=="string"?{"@keyframes newStateAnimationOnceColor":{"0%":{color:c},"100%":{color:E.palette.mode==="dark"?"#fff":"#000"}},animation:"newStateAnimationOnceColor 2s ease-in-out"}:{"@keyframes newStateAnimationOnce":{"0%":{color:"#00f900"},"80%":{color:E.palette.mode==="dark"?"#518851":"#008000"},"100%":{color:E.palette.mode==="dark"?"#fff":"#000"}},animation:"newStateAnimationOnce 2s ease-in-out"}}class rn extends f{constructor(){super(...arguments);Q(this,"controlTimeout",null);Q(this,"delayedUpdate",{timer:null,value:null});Q(this,"onStateChanged",(e,t)=>{let s=t?t.val:null;this.state.controlType==="button"||this.state.controlType==="switch"?(s=!!s,this.state.stateValue!==s&&this.setState({stateValue:s})):s!==null&&(this.state.controlType==="slider"||this.state.controlType==="number")?(s=parseFloat(s),console.log(`${Date.now()} Received new value: ${s}`),s!==this.state.stateValue?(this.delayedUpdate.timer&&(clearTimeout(this.delayedUpdate.timer),this.delayedUpdate.timer=null),this.delayedUpdate.value=s,this.delayedUpdate.timer=setTimeout(()=>{this.setState({stateValue:this.delayedUpdate.value})},500)):this.delayedUpdate.timer&&(clearTimeout(this.delayedUpdate.timer),this.delayedUpdate.timer=null)):this.state.stateValue.toString()!==s.toString()&&this.setState({stateValue:s})})}getObjectID(){return this.props.schema.foreign?this.props.schema.oid:`${this.props.schema.system?"system.adapter.":""}${this.props.oContext.adapterName}.${this.props.oContext.instance}.${this.props.schema.oid}`}componentDidMount(){return pe(this,null,function*(){nt(rn.prototype,this,"componentDidMount").call(this);const e=yield this.props.oContext.socket.getObject(this.getObjectID()),t=this.props.schema.control||this.detectType(e),s=yield this.props.oContext.socket.getState(this.getObjectID());this.setState({stateValue:s?s.val:null,controlType:t,obj:e},()=>pe(this,null,function*(){yield this.props.oContext.socket.subscribeState(this.getObjectID(),this.onStateChanged)}))})}componentWillUnmount(){super.componentWillUnmount(),this.props.oContext.socket.unsubscribeState(this.getObjectID(),this.onStateChanged),this.delayedUpdate.timer&&(clearTimeout(this.delayedUpdate.timer),this.delayedUpdate.timer=null),this.controlTimeout&&(clearTimeout(this.controlTimeout),this.controlTimeout=null,this.props.oContext.socket.setState(this.getObjectID(),this.state.stateValue,!1).catch(e=>console.error(`Cannot control value: ${e}`)))}detectType(e){if(e=e||{},e.common=e.common||{},e.common.type==="boolean"){if(this.props.schema.controlled!==!1){if(e.common.read===!1||this.props.schema.controlled===!0)return"button";if(e.common.write||this.props.schema.controlled===!0)return"switch"}return"text"}return e.common.type==="number"&&this.props.schema.controlled!==!1?e.common.write||this.props.schema.controlled===!0?e.common.max!==void 0?"slider":"input":"text":e.common.write&&this.props.schema.controlled!==!1?"input":"text"}renderItem(e,t){if(!this.state.obj)return null;let s;if(this.state.controlType==="button"){let i=null;this.props.schema.falseImage&&(i=dt(this.props.schema.falseImage));const r=this.getText(this.props.schema.falseText||this.props.schema.label,this.props.schema.noTranslation);!r&&i?s=n().createElement(o.IconButton,{style:this.props.schema.falseTextStyle,disabled:!!this.props.schema.readOnly,onClick:()=>pe(this,null,function*(){this.props.schema.confirm?this.setState({confirmDialog:!0,confirmCallback:a=>pe(this,null,function*(){a&&(yield this.props.oContext.socket.setState(this.getObjectID(),!0,!1))})}):yield this.props.oContext.socket.setState(this.getObjectID(),!0,!1)})},i):s=n().createElement(o.Button,{variant:this.props.schema.variant||"contained",startIcon:i,style:this.props.schema.falseTextStyle,disabled:t||!!this.props.schema.readOnly,onClick:()=>pe(this,null,function*(){this.props.schema.confirm?this.setState({confirmDialog:!0,confirmCallback:a=>pe(this,null,function*(){a&&(yield this.props.oContext.socket.setState(this.getObjectID(),!0,!1))})}):yield this.props.oContext.socket.setState(this.getObjectID(),!0,!1)})},r||this.getObjectID().split(".").pop())}else if(this.state.controlType==="input")s=n().createElement(o.TextField,{style:{width:"100%"},value:this.state.stateValue,variant:"standard",slotProps:{input:{endAdornment:this.getText(this.props.schema.unit,this.props.schema.noTranslation)||this.state.obj.common.unit||void 0},htmlInput:{readOnly:!!this.props.schema.readOnly}},onChange:i=>{this.setState({stateValue:i.target.value},()=>{this.controlTimeout&&clearTimeout(this.controlTimeout),this.controlTimeout=setTimeout(()=>pe(this,null,function*(){this.controlTimeout=null,yield this.props.oContext.socket.setState(this.getObjectID(),this.state.stateValue,!1)}),this.props.schema.controlDelay||0)})},label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)});else if(this.state.obj.common.type==="number"){const i=this.props.schema.min===void 0?this.state.obj.common.min||0:this.props.schema.min,r=this.props.schema.max===void 0?this.state.obj.common.max===void 0?100:this.state.obj.common.max:this.props.schema.max,a=this.props.schema.step===void 0?this.state.obj.common.step||1:this.props.schema.step;s=n().createElement(o.TextField,{variant:"standard",style:{width:"100%"},value:this.state.stateValue,type:"number",slotProps:{htmlInput:{min:i,max:r,step:a,readOnly:!!this.props.schema.readOnly},input:{endAdornment:this.getText(this.props.schema.unit,this.props.schema.noTranslation)||this.state.obj.common.unit||void 0}},onChange:h=>{this.setState({stateValue:h.target.value},()=>{this.controlTimeout&&clearTimeout(this.controlTimeout),this.controlTimeout=setTimeout(()=>pe(this,null,function*(){this.controlTimeout=null;const S=parseFloat(this.state.stateValue);yield this.props.oContext.socket.setState(this.getObjectID(),S,!1)}),this.props.schema.controlDelay||0)})},label:this.getText(this.props.schema.label,this.props.schema.noTranslation),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)})}else{let i;this.props.schema.size==="normal"?i=16:this.props.schema.size==="large"?i=20:typeof this.props.schema.size=="number"&&(i=this.props.schema.size);let r=this.getText(this.props.schema.label,this.props.schema.noTranslation);const a={display:"flex",alignItems:"center",fontSize:i||"1rem",gap:8};this.props.schema.narrow||(a.width="100%",a.justifyContent="space-between"),r.trim()&&!r.trim().endsWith(":")&&this.props.schema.addColon&&(r=`${r.trim()}:`);let h;this.props.schema.blinkOnUpdate&&(h=ns(this.props.oContext.theme,this.props.schema.blinkOnUpdate));let S;this.props.schema.labelIcon&&(S=n().createElement(l.Icon,{src:this.props.schema.labelIcon,style:{marginRight:4}}));let L;if(r&&S?L=n().createElement("div",{style:{whiteSpace:"nowrap"}},S,r):r?L=n().createElement("div",{style:{whiteSpace:"nowrap"}},r):S&&(L=S),this.state.controlType==="switch"){let O=null;const N=this.getText(this.props.schema.falseText,this.props.schema.noTranslation);this.props.schema.falseImage&&(O=dt(this.props.schema.falseImage,N?{marginLeft:8}:void 0));let te=null;const ye=this.getText(this.props.schema.trueText,this.props.schema.noTranslation);this.props.schema.trueImage&&(te=dt(this.props.schema.trueImage,ye?{marginRight:8}:void 0)),s=n().createElement(o.Switch,{checked:!!this.state.stateValue,disabled:!!this.props.schema.readOnly,onChange:()=>pe(this,null,function*(){this.props.schema.confirm?this.setState({confirmDialog:!0,confirmCallback:se=>pe(this,null,function*(){se&&(yield this.props.oContext.socket.setState(this.getObjectID(),!this.state.stateValue,!1))})}):yield this.props.oContext.socket.setState(this.getObjectID(),!this.state.stateValue,!1)})}),(N||O||ye||te)&&(s=n().createElement("div",{style:{display:"flex",alignItems:"center",fontSize:14}},n().createElement("span",{style:this.props.schema.falseTextStyle},N,O),s,n().createElement("span",{style:this.props.schema.trueTextStyle},te,ye))),L&&(s=n().createElement("div",{style:a},L,s))}else if(this.state.controlType==="slider"){let O=null;const N=this.getText(this.props.schema.falseText,this.props.schema.noTranslation);this.props.schema.falseImage&&(O=dt(this.props.schema.falseImage,N?{marginLeft:8}:void 0));let te=null;const ye=this.getText(this.props.schema.trueText,this.props.schema.noTranslation);this.props.schema.trueImage&&(te=dt(this.props.schema.trueImage,ye?{marginRight:8}:void 0));const se=this.props.schema.min===void 0?this.state.obj.common.min||0:this.props.schema.min,Ee=this.props.schema.max===void 0?this.state.obj.common.max===void 0?100:this.state.obj.common.max:this.props.schema.max,me=this.props.schema.step===void 0?this.state.obj.common.step||1:this.props.schema.step;s=n().createElement(o.Slider,{style:{width:"100%",flexGrow:1},min:se,max:Ee,disabled:!!this.props.schema.readOnly,step:me,value:this.state.stateValue,valueLabelDisplay:"auto",valueLabelFormat:Me=>`${Me}${this.getText(this.props.schema.unit,this.props.schema.noTranslation)||this.state.obj.common.unit||""}`,onChange:(Me,yt)=>{this.setState({stateValue:yt},()=>{this.controlTimeout&&clearTimeout(this.controlTimeout),this.controlTimeout=setTimeout(()=>pe(this,null,function*(){console.log(`${Date.now()} Send new value: ${this.state.stateValue}`),this.controlTimeout=null,yield this.props.oContext.socket.setState(this.getObjectID(),this.state.stateValue,!1)}),this.props.schema.controlDelay||0)})}}),(N||O||ye||te)&&(s=n().createElement("div",{style:{display:"flex",width:"100%",flexGrow:1,alignItems:"center"}},n().createElement("span",{style:q({marginRight:16},this.props.schema.falseTextStyle)},N,O),s,n().createElement("span",{style:q({marginLeft:16},this.props.schema.trueTextStyle)},te,ye))),L&&(s=n().createElement("div",{style:a},L,s))}else if(this.state.obj.common.type==="boolean"){let O=null,N,te;this.state.stateValue?(N=this.getText(this.props.schema.trueText,this.props.schema.noTranslation),this.props.schema.trueImage&&(O=dt(this.props.schema.falseImage,N?{marginRight:8}:void 0)),te=this.props.schema.trueTextStyle):(N=this.getText(this.props.schema.falseText,this.props.schema.noTranslation),this.props.schema.falseImage&&(O=dt(this.props.schema.falseImage,N?{marginLeft:8}:void 0)),te=this.props.schema.falseTextStyle),te=Object.assign(a,te),s=n().createElement("div",{style:te},L,n().createElement(o.Box,{style:{display:"flex",alignItems:"center",gap:8},sx:h,key:this.props.schema.blinkOnUpdate?N:void 0},O,N||(this.state.stateValue?l.I18n.t("ra_true"):l.I18n.t("ra_false"))))}else{const O=this.getText(this.props.schema.unit,this.props.schema.noTranslation)||this.state.obj.common.unit;let N,te;this.state.controlType==="html"?(te=(this.state.stateValue||"").toString(),N=n().createElement("span",{dangerouslySetInnerHTML:{__html:this.state.stateValue}})):this.state.stateValue===null?(N="null",te=N):this.state.stateValue===void 0?(N="undefined",te=N):(N=this.state.stateValue.toString(),te=N),s=n().createElement("div",{style:a},L,n().createElement("div",{style:{display:"flex",alignItems:"baseline",gap:4}},n().createElement(o.Box,{sx:h,key:this.props.schema.blinkOnUpdate?te:void 0},N),O?n().createElement("span",{style:{opacity:.7,fontSize:"smaller"}},O):null))}}return s}}const ss=rn,an={fullWidth:E=>({width:"100%",backgroundColor:E.palette.mode==="dark"?"#FFF":"#000",borderStyle:"hidden"}),primary:E=>({backgroundColor:E.palette.primary.main}),secondary:E=>({backgroundColor:E.palette.secondary.main})};class is extends f{renderItem(){return n().createElement(o.Box,{component:"hr",sx:l.Utils.getStyle(this.props.oContext.theme,an.fullWidth,this.props.schema.color==="primary"?an.primary:this.props.schema.color==="secondary"?an.secondary:{backgroundColor:this.props.schema.color||(this.props.oContext.themeType==="dark"?"#333":"#ddd")},{height:this.props.schema.color?this.props.schema.height||2:this.props.schema.height||1})})}}const os=is,rs={header:E=>({width:"100%",background:E.palette.primary.main,color:E.palette.primary.contrastText,padding:"4px !important",borderRadius:"3px",marginBlockEnd:0,marginBlockStart:0})};class as extends f{renderItem(){let c="h5";switch((this.props.schema.size||5).toString()){case"1":c="h1";break;case"2":c="h2";break;case"3":c="h3";break;case"4":c="h4";break;case"5":default:c="h5";break}return n().createElement(o.Box,{component:c,sx:rs.header},this.getText(this.props.schema.label||this.props.schema.text,this.props.schema.noTranslation))}}const ls=as;class us extends f{renderItem(){let c=this.props.schema.src;return c&&!c.startsWith(".")&&!c.startsWith("http")&&!c.startsWith(`adapter/${this.props.oContext.adapterName}/`)&&!c.startsWith(`./adapter/${this.props.oContext.adapterName}/`)&&(c=`adapter/${this.props.oContext.adapterName}/${c}`),n().createElement("img",{src:c,style:{cursor:this.props.schema.href?"pointer":void 0,width:"100%",height:"100%"},onClick:this.props.schema.href?()=>this.props.schema.href&&window.open(this.props.schema.href,"_blank"):null,alt:""})}}const cs=us;function bn(E,c,e){return typeof e=="string"?{"@keyframes newValueAnimationOnceColor":{"0%":{color:c?`${e} !important`:e},"100%":{color:E.palette.mode==="dark"?c?"#fff !important":"#fff":c?"#000 !important":"#000"}},animation:"newValueAnimationOnceColor 2s ease-in-out"}:{"@keyframes newValueAnimationOnce":{"0%":{color:c?"#00f900 !important":"#00f900"},"80%":{color:E.palette.mode==="dark"?c?"#518851 !important":"#518851":c?"#008000 !important":"#008000"},"100%":{color:E.palette.mode==="dark"?c?"#fff !important":"#fff":c?"#000 !important":"#000"}},animation:"newValueAnimationOnce 2s ease-in-out"}}function xn(E,c){return typeof c=="string"?{"@keyframes blinkAnimationColor":{"0%":{color:c},"100%":{color:E.palette.mode==="dark"?"#fff":"#000"}},animation:"blinkAnimationColor 2s ease-in-out infinite"}:{"@keyframes blinkAnimation":{"0%":{color:"#00f900"},"80%":{color:E.palette.mode==="dark"?"#518851":"#008000"},"100%":{color:E.palette.mode==="dark"?"#fff":"#000"}},animation:"blinkAnimation 2s ease-in-out infinite"}}const St={label:{fontWeight:"bold",whiteSpace:"nowrap"},valueImage:{maxHeight:"100%"},valueAndUnit:{display:"flex",gap:4,alignItems:"baseline"},value:{},unit:{fontSize:"smaller",opacity:.7}};class hs extends f{renderItem(c){let e=this.getText(this.props.schema.text||this.props.schema.label,this.props.schema.noTranslation);this.props.schema.addColon&&typeof e=="string"&&!e.trim().endsWith(":")&&(e=`${e.trim()}:`),e&&(e.includes("")||e.includes(""))&&(e=l.Utils.renderTextWithA(e));let t;this.props.schema.size==="normal"?t=16:this.props.schema.size==="large"?t=20:typeof this.props.schema.size=="number"&&(t=this.props.schema.size);const s={width:"100%",height:"100%",display:"flex",alignItems:"center",position:"relative",fontSize:t};this.props.schema.narrow?s.gap=8:s.justifyContent="space-between";let i,r;this.props.schema.data&&typeof this.props.schema.data=="object"&&this.props.schema.data.en?r=this.getText(this.props.schema.data):typeof this.props.schema.data=="object"||this.props.schema.data===void 0||this.props.schema.data===null?r=JSON.stringify(this.props.schema.data):typeof this.props.schema.data=="number"?(r=this.props.schema.data.toString(),this.props.oContext.isFloatComma&&(r=r.replace(".",","))):(!this.props.schema.booleanAsCheckbox||typeof this.props.schema.data!="boolean")&&(r=this.props.schema.data.toString());let a=!1;if(this.props.schema.booleanAsCheckbox&&typeof this.props.schema.data=="boolean")i=n().createElement(o.Checkbox,{checked:!!i,disabled:!0,size:this.props.schema.size==="small"?"small":this.props.schema.size==="large"?"large":void 0});else if(r.startsWith("data:image/"))i=n().createElement("div",{style:q(q(q({},St.value),St.valueImage),this.props.schema.styleValue||void 0)},n().createElement(l.Icon,{src:r}));else{const O=q(q({},St.value),this.props.schema.styleValue||void 0);this.props.schema.html?i=n().createElement("div",{style:O,dangerouslySetInnerHTML:{__html:r}}):Array.isArray(this.props.schema.data)?(a=!0,i=n().createElement("div",{style:O},this.props.schema.data.map((N,te)=>n().createElement("div",{key:te},typeof N=="object"||N===null||N===void 0?JSON.stringify(N):N)))):r.includes(` +`)?(a=!0,i=n().createElement("div",{style:O},l.Utils.renderTextWithA(r))):i=n().createElement("div",{style:O},r)}if(this.props.schema.blinkOnUpdate&&this.props.schema.blink){const O=bn(this.props.oContext.theme,!0,this.props.schema.blinkOnUpdate),N=xn(this.props.oContext.theme,this.props.schema.blink);i=n().createElement(o.Box,{key:r,sx:q(q({},O),N)},i)}else if(this.props.schema.blinkOnUpdate){const O=bn(this.props.oContext.theme,!1,this.props.schema.blinkOnUpdate);i=n().createElement(o.Box,{key:r,sx:O},i)}else if(this.props.schema.blink){const O=xn(this.props.oContext.theme,this.props.schema.blink);i=n().createElement(o.Box,{sx:O},i)}this.props.schema.unit&&(i=n().createElement("div",{style:St.valueAndUnit},i,n().createElement("div",{style:q(q({},St.unit),this.props.schema.styleUnit||void 0)},this.getText(this.props.schema.unit))));let h;this.props.schema.labelIcon&&(h=n().createElement(l.Icon,{src:this.props.schema.labelIcon,style:{marginRight:4}}));let S;this.props.schema.copyToClipboard&&(S=n().createElement(u.ContentCopy,{className:"staticCopyButton",style:{position:"absolute",top:"calc(50% - 12px)",right:0,cursor:"pointer"},onClick:()=>{l.Utils.copyToClipboard(r),window.alert(l.I18n.t("ra_Copied"))}}));const L={"& .staticCopyButton":{display:"none"},"& .staticCopyButton:action":{transform:"scale(0.9)"},"&:hover .staticCopyButton":{display:"block"}};return this.props.schema.highlight&&(L["&:hover"]={backgroundColor:this.props.oContext.themeType==="dark"?"#51515180":"#b8b8b880"}),a&&(s.alignItems="top"),n().createElement(o.Box,{component:"div",style:s,sx:L},n().createElement("div",{style:q(q({},St.label),this.props.schema.styleLabel||void 0)},h,e),i,S)}}const ps=hs,wn={fullWidth:{height:"100%",width:"100%"},link:E=>({textDecoration:"underline",color:E.palette.mode==="dark"?"#4dabf5":"#254e72",cursor:"pointer"})};function An(E,c,e){let t,s="";E?E.toString().startsWith("#")||E.toString().startsWith("/")?(t=c||"_self",s=E):E.startsWith("http://")||E.startsWith("https://")?(t=c||"_blank",s=E):(s=`#tab-instances/config/${e}/${E}`,t=c||"_self"):(s=`#tab-instances/config/${e}`,t=c||"_self"),t==="_self"?setTimeout(i=>{i.startsWith("#")?window.location.hash=i:i.startsWith("/")?s=`${window.location.protocol}:${window.location.host}${s}`:(i.startsWith("http://")||i.startsWith("https://"))&&(window.location.href=i)},100,s):(s.startsWith("#")?s=`${window.location.protocol}:${window.location.host}${window.location.pathname}${s}`:s.startsWith("/")&&(s=`${window.location.protocol}:${window.location.host}${s}`),window.open(s,t))}class ds extends f{renderItem(c,e){if(this.props.schema.button){const s=this.getIcon();return n().createElement(o.Button,{variant:this.props.schema.variant||void 0,color:this.props.schema.color||"grey",style:q(q({},wn.fullWidth),this.props.schema.controlStyle||void 0),disabled:e,startIcon:s,onClick:this.props.schema.href?()=>{const i=this.props.schema.href?this.getText(this.props.schema.href,!0):null;i&&(this.props.oContext.onBackEndCommand?this.props.oContext.onBackEndCommand({command:"link",url:i,target:this.props.schema.target,close:this.props.schema.close}):An(i,this.props.schema.target,`${this.props.oContext.adapterName}.${this.props.oContext.instance}`))}:null},this.getText(this.props.schema.text||this.props.schema.label,this.props.schema.noTranslation))}let t=this.getText(this.props.schema.text||this.props.schema.label,this.props.schema.noTranslation);return t&&(t.includes("")||t.includes(""))&&(t=l.Utils.renderTextWithA(t)),n().createElement(o.Box,{component:"span",style:q({},this.props.schema.controlStyle||void 0),sx:this.props.schema.href?wn.link:void 0,onClick:this.props.schema.href?()=>{const s=this.props.schema.href?this.getText(this.props.schema.href,!0):null;s&&(this.props.oContext.onBackEndCommand?this.props.oContext.onBackEndCommand({command:"link",url:s,target:this.props.schema.target||"_blank",close:this.props.schema.close}):An(s,this.props.schema.target||"_blank",`${this.props.oContext.adapterName}.${this.props.oContext.instance}`))}:null},t)}}const Fn=ds,ln=1024*1024,Fe={fullWidth:{width:"100%"},root:{width:"100%"},paper:{width:"100%",marginBottom:16,backgroundColor:"rgba(255, 255, 255, 0.1)"},headerText:{width:"100%"},table:{minWidth:750},visuallyHidden:{border:0,clip:"rect(0 0 0 0)",height:1,margin:-1,overflow:"hidden",padding:0,position:"absolute",top:20,width:1},label:{display:"flex",justifyContent:"space-between"},title:{flex:"1 1 100%"},rootTool:{paddingLeft:16,paddingRight:8},silver:{opacity:.2},flex:{display:"flex",alignItems:"baseline"},filteredOut:{padding:10,display:"flex",textAlign:"center"},buttonEmpty:{width:34,display:"inline-block"},buttonCell:{whiteSpace:"nowrap"},dropZone:{width:"100%",height:100,position:"relative"},dropZoneEmpty:{},uploadDiv:{position:"relative",width:"100%",minHeight:300,opacity:.9,marginTop:30,cursor:"pointer",outline:"none"},uploadDivDragging:{opacity:1,background:"rgba(128,255,128,0.1)"},image:{objectFit:"contain",margin:"auto",display:"flex",width:"100%",height:"100%"},uploadCenterDiv:{margin:5,border:"3px dashed grey",borderRadius:5,width:"calc(100% - 10px)",height:"calc(100% - 10px)",minHeight:300,position:"relative",display:"flex"},uploadCenterIcon:{paddingTop:10,width:48,height:48},uploadCenterText:{fontSize:16},uploadCenterTextAndIcon:{textAlign:"center",position:"absolute",top:0,bottom:0,left:0,right:0,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center"},buttonRemoveWrapper:{position:"absolute",zIndex:222,right:0},error:{border:"2px solid red",boxSizing:"border-box"},tooltip:{pointerEvents:"none"}};function ms(E,c,e){c=c||"key";const t=[];return Object.keys(E).forEach(s=>{const i={};i[c]=s,e?(i[e]=E[s],t.push(i)):t.push(Object.assign(i,E[s]))}),t}function Sn(E,c,e){c=c||"key";const t={};return E.forEach(s=>{let i=s[c];i==null&&(i=""),delete s[c],e?t[i]=s[e]:t[i]=s}),t}function fs(E,c){let e="";for(let t=0;t{const{order:s,orderBy:i}=this.state;if(i){const a=t?s:i===e&&s==="asc"?"desc":"asc",h=this.stableSort(a,e);this.setState({order:a,orderBy:e,iteration:this.state.iteration+1e4},()=>this.applyFilter(!1,h))}});Q(this,"stableSort",(e,t)=>{const{value:s}=this.state,i=He.getComparator(e,t),r=s.map((a,h)=>({el:a,index:h}));return r.sort((a,h)=>{const S=i(a.el,h.el);return S!==0?S:a.index-h.index}),r.map(a=>a.el)});Q(this,"onDelete",e=>()=>{const t=JSON.parse(JSON.stringify(this.state.value));t.splice(e,1),this.setState({value:t,iteration:this.state.iteration+1e4},()=>this.applyFilter(!1,null,()=>this.onChangeWrapper(t)))});Q(this,"onClone",e=>()=>{const t=JSON.parse(JSON.stringify(this.state.value)),s=JSON.parse(JSON.stringify(t[e]));if(typeof this.props.schema.clone=="string"&&typeof s[this.props.schema.clone]=="string"){let i=1,r=s[this.props.schema.clone];const a=r.match(/(\d+)$/);for(a?(r=r.replace(a[0],""),i=parseInt(a[0],10)+1):r+="_";t.find(h=>h[this.props.schema.clone]===r+i.toString());)i++;s[this.props.schema.clone]=`${s[this.props.schema.clone]}_${i}`}t.splice(e,0,s),this.setState({value:t,iteration:this.state.iteration+1e4},()=>this.applyFilter(!1,null,()=>this.onChangeWrapper(t)))});Q(this,"onChangeWrapper",(e,t)=>{this.typingTimer&&clearTimeout(this.typingTimer),this.typingTimer=setTimeout((s,i)=>{this.typingTimer=null;let r;if(this.props.schema.encryptedAttributes){const a=JSON.parse(JSON.stringify(s));if(a.forEach(h=>{this.props.schema.encryptedAttributes.forEach(S=>{h[S]&&(h[S]=fs(this.secret,h[S]))})}),this.props.schema.objKeyName){const h=Sn(a,this.props.schema.objKeyName,this.props.schema.objValueName);r=this.onChange(this.props.attr,h)}else r=this.onChange(this.props.attr,a)}else if(this.props.schema.objKeyName){const a=Sn(JSON.parse(JSON.stringify(s)),this.props.schema.objKeyName,this.props.schema.objValueName);r=this.onChange(this.props.attr,a)}else r=this.onChange(this.props.attr,s);r instanceof Promise&&r.catch(a=>console.error(`Cannot save: ${a}`)),i&&(this.applyFilter(!1,s),this.handleRequestSort(this.state.orderBy,!0))},300,e,t)});Q(this,"onAdd",()=>{var i;const{schema:e}=this.props,t=JSON.parse(JSON.stringify(this.state.value)),s=(i=e.items)==null?void 0:i.reduce((r,a)=>{let h;return a.defaultFunc?this.props.custom?h=a.defaultFunc?this.executeCustom(a.defaultFunc,this.props.data,this.props.customObj,this.props.oContext.instanceObj,t.length,this.props.data):this.props.schema.default:h=a.defaultFunc?this.execute(a.defaultFunc,this.props.schema.default,this.props.data,t.length,this.props.data):this.props.schema.default:h=a.default===void 0?null:a.default,r[a.attr]=h,r},{});t.push(s),this.setState({value:t},()=>this.applyFilter(!1,null,()=>this.onChangeWrapper(t)))});Q(this,"applyFilter",(e,t,s)=>{t=t||this.state.value;let i=t.map((r,a)=>a);if(Object.keys(this.filterRefs).forEach(r=>{let a=He.getFilterValue(this.filterRefs[r]);!e&&a?(a=a.toLowerCase(),i=i.filter(h=>t[h]&&t[h][r]&&t[h][r].toLowerCase().includes(a))):this.filterRefs[r].current&&He.setFilterValue(this.filterRefs[r],"")}),i.length===t.length&&(i=null),i===null&&this.state.visibleValue===null){s&&s();return}JSON.stringify(i)!==JSON.stringify(this.state.visibleValue)?this.setState({visibleValue:i},()=>s&&s()):s&&s()});this.filterRefs={},this.props.schema.items=this.props.schema.items||[],this.props.schema.items.forEach(t=>{t.filter&&(this.filterRefs[t.attr]=(0,T.createRef)())})}componentDidMount(){return pe(this,null,function*(){nt(He.prototype,this,"componentDidMount").call(this);const e=f.getValue(this.props.data,this.props.attr)||[];let t;if(this.props.schema.objKeyName?t=ms(e,this.props.schema.objKeyName,this.props.schema.objValueName):t=e,Array.isArray(t)||(t=[]),this.props.schema.encryptedAttributes){const s=yield this.props.oContext.socket.getCompactSystemConfig();this.secret=(s==null?void 0:s.native.secret)||this.secret,e.forEach(i=>{this.props.schema.encryptedAttributes.forEach(r=>{i[r]&&(i[r]=gs(this.secret,i[r]))})})}this.setState({value:t,visibleValue:null,orderBy:"",order:"asc",iteration:0,filterOn:[]},()=>this.validateUniqueProps())})}componentWillUnmount(){this.typingTimer&&(clearTimeout(this.typingTimer),this.typingTimer=null),super.componentWillUnmount()}itemTable(e,t,s){const{schema:i}=this.props,r=i.items&&i.items.find(h=>h.attr===e);if(!r)return null;const a={items:{[e]:r}};return n().createElement(Ot,{oContext:this.props.oContext,alive:this.props.alive,arrayIndex:s,changed:this.props.changed,common:this.props.common,custom:!0,data:t,globalData:this.props.data,index:s+this.state.iteration,onChange:(h,S)=>{const L=JSON.parse(JSON.stringify(this.state.value));L[s][h]=S,this.setState({value:L},()=>{this.validateUniqueProps(),this.onChangeWrapper(L,!0)})},onError:(h,S)=>this.onError(h,S),originalData:this.props.originalData,schema:a,table:!0,themeName:this.props.themeName})}validateUniqueProps(){if(this.props.schema.uniqueColumns)for(const e of this.props.schema.uniqueColumns){const t=[];this.state.value.find(i=>{const r=i[e];return t.includes(r)?(this.onError(e,"is not unique"),this.setState({errorMessage:l.I18n.t('Non-allowed duplicate entry "%s" in column "%s"',r,e)}),!0):(t.push(r),!1)})||(this.onError(e,null),this.setState({errorMessage:""}))}}static descendingComparator(e,t,s){return t[s]e[s]?1:0}static getComparator(e,t){return e==="desc"?(s,i)=>He.descendingComparator(s,i,t):(s,i)=>-He.descendingComparator(s,i,t)}static getFilterValue(e){var t,s,i;return(i=(s=(t=e==null?void 0:e.current)==null?void 0:t.children[0])==null?void 0:s.children[0])==null?void 0:i.value}static setFilterValue(e,t){return e.current.children[0].children[0].value=t}enhancedTableHead(e,t){const{schema:s}=this.props,{order:i,orderBy:r}=this.state;return n().createElement(o.TableHead,null,n().createElement(o.TableRow,null,s.items&&s.items.map((a,h)=>n().createElement(o.TableCell,{style:{width:(typeof a.width=="string"&&a.width.endsWith("%"),a.width)},key:`${a.attr}_${h}`,align:"left",sortDirection:r===a.attr?i:!1},n().createElement("div",{style:q(q({},Fe.flex),s.showFirstAddOnTop?{flexDirection:"column"}:void 0)},!h&&!s.noDelete?n().createElement(o.Tooltip,{title:t?l.I18n.t("ra_Cannot add items with set filter"):l.I18n.t("ra_Add row"),slotProps:{popper:{sx:Fe.tooltip}}},n().createElement("span",null,n().createElement(o.IconButton,{size:"small",color:"primary",disabled:!!t&&!this.props.schema.allowAddByFilter,onClick:this.onAdd},n().createElement(u.Add,null)))):null,a.sort&&n().createElement(o.TableSortLabel,{active:!0,style:r!==a.attr?Fe.silver:void 0,direction:r===a.attr?i:"asc",onClick:()=>this.handleRequestSort(a.attr)}),a.filter&&this.state.filterOn.includes(a.attr)?n().createElement(o.TextField,{variant:"standard",ref:this.filterRefs[a.attr],onChange:()=>this.applyFilter(),title:l.I18n.t("ra_You can filter entries by entering here some text"),slotProps:{input:{endAdornment:He.getFilterValue(this.filterRefs[a.attr])&&n().createElement(o.InputAdornment,{position:"end"},n().createElement(o.IconButton,{size:"small",onClick:()=>{He.setFilterValue(this.filterRefs[a.attr],""),this.applyFilter()}},n().createElement(u.Close,null)))}},fullWidth:!0,placeholder:this.getText(a.title)}):n().createElement("span",{style:Fe.headerText},this.getText(a.title)),a.filter?n().createElement(o.IconButton,{title:l.I18n.t("ra_Show/hide filter input"),size:"small",onClick:()=>{const S=[...this.state.filterOn],L=this.state.filterOn.indexOf(a.attr);L===-1?S.push(a.attr):S.splice(L,1),this.setState({filterOn:S},()=>{L&&He.getFilterValue(this.filterRefs[a.attr])&&(He.setFilterValue(this.filterRefs[a.attr],""),this.applyFilter())})}},this.state.filterOn.includes(a.attr)?n().createElement(u.FilterAltOff,null):n().createElement(u.FilterAlt,null)):null))),!s.noDelete&&n().createElement(o.TableCell,{style:{paddingLeft:20,paddingRight:20,width:e,textAlign:"right"},padding:"checkbox"},s.import?n().createElement(o.IconButton,{style:{marginRight:10},size:"small",onClick:()=>this.setState({showImportDialog:!0}),title:l.I18n.t("ra_import data from %s file","CSV")},n().createElement(u.UploadFile,null)):null,s.export?n().createElement(o.IconButton,{style:{marginRight:10},size:"small",onClick:()=>this.onExport(),title:l.I18n.t("ra_Export data to %s file","CSV")},n().createElement(u.Download,null)):null,n().createElement(o.IconButton,{disabled:!0,size:"small"},n().createElement(u.Delete,null)))))}onExport(){const{schema:e}=this.props,{value:t}=this.state,i=[e.items.map(h=>h.attr).join(";")];t.forEach(h=>{const S=[];e.items.forEach(L=>{var O;(O=h[L.attr])!=null&&O.includes(";")?S.push(`"${h[L.attr]}"`):S.push(h[L.attr]===void 0||h[L.attr]===null?"":h[L.attr])}),i.push(S.join(";"))});const r=document.createElement("a");r.setAttribute("href",`data:text/csv;charset=utf-8,${encodeURIComponent(i.join(` +`))}`);const a=new Date;r.setAttribute("download",`${a.getFullYear()}_${(a.getMonth()+1).toString().padStart(2,"0")}_${a.getDate().toString().padStart(2,"0")}_${this.props.oContext.adapterName}.${this.props.oContext.instance}_${this.props.attr}.csv`),r.style.display="none",document.body.appendChild(r),r.click(),document.body.removeChild(r)}onImport(e){var a;const t=e.split(` +`).map(h=>h.replace("\r","").trim()),{schema:s}=this.props,i=t.shift().split(";").filter(h=>h&&s.items.find(S=>S.attr===h)),r=[];t.forEach(h=>{const S=h.split(";"),L={};for(let O=0;Ose.attr===i[O]);ye&&ye.type==="number"?te=parseFloat(N):te=N}else te=N;L[i[O]]=te}r.push(L)}),r.length?(a=this.state.value)!=null&&a.length?this.setState({showTypeOfImportDialog:r,showImportDialog:!1}):this.setState({value:r,showImportDialog:!1}):window.alert("ra_No data found in file")}isAnyFilterSet(){return!!Object.keys(this.filterRefs).find(e=>He.getFilterValue(this.filterRefs[e]))}onMoveUp(e){const t=JSON.parse(JSON.stringify(this.state.value)),s=t[e];t.splice(e,1),t.splice(e-1,0,s),this.setState({value:t,iteration:this.state.iteration+1e4},()=>this.applyFilter(!1,null,()=>this.onChangeWrapper(t)))}onMoveDown(e){const t=JSON.parse(JSON.stringify(this.state.value)),s=t[e];t.splice(e,1),t.splice(e+1,0,s),this.setState({value:t,iteration:this.state.iteration+1e4},()=>this.applyFilter(!1,null,()=>this.onChangeWrapper(t)))}onDrop(e){const t=e[0],s=new FileReader;s.onabort=()=>console.log("file reading was aborted"),s.onerror=()=>console.log("file reading has failed"),s.onload=()=>{if(t.size>ln){window.alert(l.I18n.t("ra_File is too big. Max %sk allowed. Try use SVG.",Math.round(ln/1024)));return}const i=new Uint8Array(s.result).reduce((r,a)=>r+String.fromCharCode(a),"");this.onImport(i)},s.readAsArrayBuffer(t)}showTypeOfImportDialog(){return this.state.showTypeOfImportDialog?n().createElement(o.Dialog,{open:!0,onClose:()=>this.setState({showTypeOfImportDialog:!1}),maxWidth:"md"},n().createElement(o.DialogTitle,null,l.I18n.t("ra_Append or replace?")),n().createElement(o.DialogContent,null,l.I18n.t("ra_Append %s entries or replace existing?",this.state.showTypeOfImportDialog.length)),n().createElement(o.DialogActions,null,n().createElement(o.Button,{variant:"contained",color:"primary",autoFocus:!0,onClick:()=>{const e=JSON.parse(JSON.stringify(this.state.value));this.state.showTypeOfImportDialog.forEach(t=>e.push(t)),this.setState({value:e,iteration:this.state.iteration+1e4,showTypeOfImportDialog:!1},()=>this.applyFilter(!1,null,()=>this.onChangeWrapper(e)))}},l.I18n.t("ra_Append")),n().createElement(o.Button,{variant:"contained",color:"secondary",autoFocus:!0,onClick:()=>{const e=this.state.showTypeOfImportDialog;this.setState({value:e,iteration:this.state.iteration+1e4,showTypeOfImportDialog:!1},()=>this.applyFilter(!1,null,()=>this.onChangeWrapper(e)))}},l.I18n.t("ra_Replace")))):null}showImportDialog(){return this.state.showImportDialog?n().createElement(o.Dialog,{open:!0,onClose:()=>this.setState({showImportDialog:!1}),sx:{"& .MuiDialog-paper":{minHeight:500}},maxWidth:"md",fullWidth:!0},n().createElement(o.DialogTitle,null,l.I18n.t("ra_Import from %s","CSV")),n().createElement(o.DialogContent,null,n().createElement(De(),{multiple:!1,accept:{"text/csv":[".csv"]},maxSize:ln,onDragEnter:()=>this.setState({uploadFile:"dragging"}),onDragLeave:()=>this.setState({uploadFile:!0}),onDrop:(e,t)=>{this.setState({uploadFile:!1}),e.length?this.onDrop(e):window.alert(t&&t[0]&&t[0].errors&&t[0].errors[0]&&t[0].errors[0].message||l.I18n.t("ra_Cannot upload"))}},({getRootProps:e,getInputProps:t})=>n().createElement("div",q({style:q(q(q(q({},Fe.uploadDiv),this.state.uploadFile==="dragging"?Fe.uploadDivDragging:void 0),Fe.dropZone),this.state.icon?void 0:Fe.dropZoneEmpty)},e()),n().createElement("input",q({},t())),n().createElement("div",{style:Fe.uploadCenterDiv},n().createElement("div",{style:Fe.uploadCenterTextAndIcon},n().createElement(u.UploadFile,{style:Fe.uploadCenterIcon}),n().createElement("div",{style:Fe.uploadCenterText},this.state.uploadFile==="dragging"?l.I18n.t("ra_Drop file here"):l.I18n.t("ra_Place your files here or click here to open the browse dialog"))))))),n().createElement(o.DialogActions,null,n().createElement(o.Button,{variant:"contained",onClick:()=>this.setState({showImportDialog:!1}),color:"primary",startIcon:n().createElement(u.Close,null)},l.I18n.t("Cancel")))):null}renderItem(){const{schema:e}=this.props;let{visibleValue:t}=this.state;if(!this.state.value||!Array.isArray(this.state.value))return null;t=t||this.state.value.map((r,a)=>a);const s=this.isAnyFilterSet();let i;return this.props.schema.compact&&(i={paddingTop:1,paddingBottom:1}),n().createElement(o.Paper,{style:Fe.paper},this.showImportDialog(),this.showTypeOfImportDialog(),e.label?n().createElement("div",{style:Fe.label},n().createElement(o.Toolbar,{variant:"dense",style:Fe.rootTool},n().createElement(o.Typography,{style:Fe.title,variant:"h6",id:"tableTitle",component:"div"},this.getText(e.label)))):null,n().createElement(o.TableContainer,null,n().createElement(o.Table,{style:Fe.table,size:"small"},this.enhancedTableHead(!s&&!this.state.orderBy?120:64,s),n().createElement(o.TableBody,null,t.map((r,a)=>n().createElement(o.TableRow,{hover:!0,key:`${r}_${a}`},e.items&&e.items.map(h=>n().createElement(o.TableCell,{key:`${h.attr}_${r}`,align:"left",style:i},this.itemTable(h.attr,this.state.value[r],r))),!e.noDelete&&n().createElement(o.TableCell,{align:"left",style:q(q({},i),Fe.buttonCell)},!s&&!this.state.orderBy?a?n().createElement(o.Tooltip,{title:l.I18n.t("ra_Move up"),slotProps:{popper:{sx:Fe.tooltip}}},n().createElement(o.IconButton,{size:"small",onClick:()=>this.onMoveUp(r)},n().createElement(u.ArrowUpward,null))):n().createElement("div",{style:Fe.buttonEmpty}):null,!s&&!this.state.orderBy?athis.onMoveDown(r)},n().createElement(u.ArrowDownward,null))):n().createElement("div",{style:Fe.buttonEmpty}):null,n().createElement(o.Tooltip,{title:l.I18n.t("ra_Delete current row"),slotProps:{popper:{sx:Fe.tooltip}}},n().createElement(o.IconButton,{size:"small",onClick:this.onDelete(r)},n().createElement(u.Delete,null))),this.props.schema.clone?n().createElement(o.Tooltip,{title:l.I18n.t("ra_Clone current row"),slotProps:{popper:{sx:Fe.tooltip}}},n().createElement(o.IconButton,{size:"small",onClick:this.onClone(r)},n().createElement(u.ContentCopy,null))):null))),!e.noDelete&&t.length>=(e.showSecondAddAt||5)?n().createElement(o.TableRow,null,n().createElement(o.TableCell,{colSpan:e.items.length+1,style:q({},i)},n().createElement(o.Tooltip,{title:s?l.I18n.t("ra_Cannot add items with set filter"):l.I18n.t("ra_Add row"),slotProps:{popper:{sx:Fe.tooltip}}},n().createElement("span",null,n().createElement(o.IconButton,{size:"small",color:"primary",disabled:!!s&&!this.props.schema.allowAddByFilter,onClick:this.onAdd},n().createElement(u.Add,null)))))):null)),!t.length&&this.state.value.length?n().createElement("div",{style:Fe.filteredOut},n().createElement(o.Typography,{style:Fe.title,variant:"h6",id:"tableTitle",component:"div"},l.I18n.t("ra_All items are filtered out"),n().createElement(o.IconButton,{size:"small",onClick:()=>this.applyFilter(!0)},n().createElement(u.Close,null)))):null),e.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null,this.state.errorMessage?n().createElement("div",{style:{display:"flex",padding:"5px"}},n().createElement(u.Warning,{color:"error"}),n().createElement("span",{style:{color:"red",alignSelf:"center"}},this.state.errorMessage)):null)}}const Cs=He,jt={indeterminate:{opacity:.5},label:{width:"100%",fontSize:14,marginBottom:2},helper:{width:"100%",fontSize:12},error:{width:"100%",fontSize:12,color:"#FF0000"}};class Ds extends f{constructor(){super(...arguments);Q(this,"updateTimeout",null)}componentDidMount(){super.componentDidMount();let e=f.getValue(this.props.data,this.props.attr);if(Array.isArray(e)&&this.props.oContext.multiEdit){e=f.DIFFERENT_VALUE,this.setState({value:e,oldValue:e,jsonError:!1});return}this.setState({value:e,oldValue:e,jsonError:this.validateJson(e)})}validateJson(e){let t=!1;if(this.props.schema.validateJson&&(e||!this.props.schema.allowEmpty))try{JSON.parse(e)}catch(s){console.log("Error in JSON",s),t=!0}return t}static getDerivedStateFromProps(e,t){if(e.oContext.multiEdit&&t.value===f.DIFFERENT_VALUE)return{value:f.DIFFERENT_VALUE};let s=f.getValue(e.data,e.attr);return s!=null&&(s=s.toString()),s==null||s!==t.value&&s!==t.oldValue?{value:s}:null}renderItem(e,t){const s=Array.isArray(this.state.value)||this.state.value===f.DIFFERENT_VALUE;if(this.props.schema.time){let a="";return typeof this.state.value=="number"?this.state.value&&this.state.value<9466596e5?a=new Date(this.state.value*1e3).toLocaleString():a=new Date(this.state.value).toLocaleString():typeof this.state.value=="string"&&(a=new Date(this.state.value).toLocaleString()),n().createElement(o.TextField,{variant:"standard",fullWidth:!0,value:a,error:!!e||!!this.state.jsonError,disabled:!!t,slotProps:{htmlInput:{readOnly:!0}},placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)})}if(this.state.oldValue!==null&&this.state.oldValue!==void 0?(this.updateTimeout&&clearTimeout(this.updateTimeout),this.updateTimeout=setTimeout(()=>{this.updateTimeout=null,this.setState({oldValue:null})},30)):this.updateTimeout&&(clearTimeout(this.updateTimeout),this.updateTimeout=null),s){const a=f.getValue(this.props.data,this.props.attr),h=(a==null?void 0:a.filter(S=>S||S===0).map(S=>({label:S.toString()||"",value:S})))||[];return h.unshift({label:l.I18n.t(f.DIFFERENT_LABEL),value:f.DIFFERENT_VALUE}),n().createElement(o.Autocomplete,{style:jt.indeterminate,fullWidth:!0,value:h[0],onChange:(S,L)=>{const O=L?L.value:"",N=this.onChange(this.props.attr,O,()=>{this.setState({value:O,oldValue:O,jsonError:this.validateJson(L)})});N instanceof Promise&&N.catch(te=>console.error(`Cannot set value: ${te}`))},options:h,getOptionLabel:S=>S.label,renderInput:S=>n().createElement(o.TextField,Oe(q({variant:"standard"},S),{error:!!e,placeholder:this.getText(this.props.schema.placeholder),slotProps:{htmlInput:Oe(q({},S.inputProps),{maxLength:this.props.schema.maxLength||this.props.schema.max||void 0,readOnly:this.props.schema.readOnly||!1})},label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation),disabled:!!t}))})}let i,r;if((this.props.schema.readOnly||t)&&this.props.schema.copyToClipboard?(this.props.schema.minRows>1&&(r={position:"absolute",right:3,top:20,zIndex:1e3}),i=n().createElement(o.IconButton,{style:r,size:"small",onClick:()=>{l.Utils.copyToClipboard(this.state.value),window.alert(l.I18n.t("ra_Copied"))}},n().createElement(l.IconCopy,null))):!this.props.schema.readOnly&&!t&&this.state.value&&!this.props.schema.noClearButton&&(this.props.schema.minRows>1&&(r={position:"absolute",right:3,top:20,zIndex:1e3}),i=n().createElement(o.IconButton,{style:r,size:"small",onClick:()=>this.setState({value:"",oldValue:this.state.value},()=>this.onChange(this.props.attr,""))},n().createElement(u.Close,null)),this.props.schema.minRows<=1&&(i=n().createElement(o.InputAdornment,{position:"end"},i))),this.props.schema.minRows>1){const a=this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation);return n().createElement("div",{style:{width:"100%",position:"relative"}},this.props.schema.label?n().createElement("div",{style:jt.label},this.getText(this.props.schema.label)):null,n().createElement(o.TextareaAutosize,{style:{width:"100%",resize:"vertical",backgroundColor:this.props.oContext.themeType==="dark"?"#363636":"#cccccc",color:this.props.oContext.themeType==="dark"?"#fff":"#111"},minRows:this.props.schema.minRows,maxRows:this.props.schema.maxRows,value:this.state.value===null||this.state.value===void 0?"":this.state.value,disabled:!!t,readOnly:this.props.schema.readOnly||!1,onChange:h=>{const S=h.target.value;this.setState({value:S,oldValue:this.state.value,jsonError:this.validateJson(S)},()=>this.onChange(this.props.attr,S||""))},placeholder:this.getText(this.props.schema.placeholder)}),a||e||this.state.jsonError?n().createElement("div",{style:e?jt.error:jt.helper},e||(this.state.jsonError?l.I18n.t("ra_Invalid JSON"):a)):null)}return n().createElement(o.TextField,{variant:"standard",fullWidth:!0,value:this.state.value===null||this.state.value===void 0?"":this.state.value,error:!!e||!!this.state.jsonError,disabled:!!t,slotProps:{htmlInput:{maxLength:this.props.schema.maxLength||this.props.schema.max||void 0,readOnly:this.props.schema.readOnly||!1},input:{endAdornment:i}},onChange:a=>{const h=a.target.value;this.setState({value:h,oldValue:this.state.value,jsonError:this.validateJson(h)},()=>this.onChange(this.props.attr,h))},placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:this.state.jsonError?l.I18n.t("ra_Invalid JSON"):this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)})}}const vs=Ds,ys={fullWidth:{width:"100%"}};class Es extends f{constructor(){super(...arguments);Q(this,"initialized",!1);Q(this,"localContext")}askInstance(){if(this.props.alive){let e=this.props.schema.data;if(e===void 0&&this.props.schema.jsonData){const t=this.getPattern(this.props.schema.jsonData,null,!0);try{e=JSON.parse(t)}catch(s){console.error(`Cannot parse json data: ${t}`)}}e===void 0&&(e=null),this.props.oContext.socket.sendTo(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`,this.props.schema.command||"send",e).then(t=>{if(typeof t=="object"){const s=t;this.setState({text:s.text||"",style:s.style,icon:s.icon,iconStyle:s.iconStyle})}else typeof t=="string"&&this.setState({text:t||""})}).catch(t=>console.error(`Cannot send command: ${t}`))}}getLocalContext(){const e={};return Array.isArray(this.props.schema.alsoDependsOn)&&this.props.schema.alsoDependsOn.forEach(t=>e[t]=f.getValue(this.props.data,t)),JSON.stringify(e)}renderItem(){if(this.props.alive){const t=this.getLocalContext();(t!==this.localContext||!this.initialized)&&(this.localContext=t,setTimeout(()=>this.askInstance(),this.initialized?300:50),this.initialized=!0)}if(this.state.text===void 0)return null;let e=null;return this.state.icon&&(e=dt(this.state.icon,q({marginRight:this.state.text?8:void 0},this.state.iconStyle||void 0)),e||(e=n().createElement(l.Icon,{src:this.state.icon,style:q({marginRight:this.state.text?8:void 0},this.state.iconStyle||void 0)}))),this.props.schema.container==="text"?n().createElement(o.TextField,{variant:"standard",fullWidth:!0,slotProps:{input:{endAdornment:this.props.schema.copyToClipboard?n().createElement(o.IconButton,{size:"small",onClick:()=>{l.Utils.copyToClipboard(this.state.text),window.alert(l.I18n.t("ra_Copied"))}},n().createElement(l.IconCopy,null)):void 0}},value:this.state.text,label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)}):n().createElement("div",{style:q(q({},ys.fullWidth),this.state.style||void 0)},e,this.props.schema.container==="html"?n().createElement("span",{dangerouslySetInnerHTML:{__html:this.state.text||""}}):this.state.text)}}const bs=Es;class xs extends f{componentDidMount(){super.componentDidMount();const c=f.getValue(this.props.data,this.props.attr);this.setState({value:c})}renderItem(c,e){const t=this.props.schema.returnFormat!=="HH:mm:ss",s=new Date(Date.parse(`Thu, 01 Jan 1970 ${this.state.value||"00:00:00"}`));return n().createElement(wt.TimePicker,{sx:i=>({width:"100%",borderBottom:`1px solid ${i.palette.text.primary}`,"& fieldset":{display:"none"},"& input":{padding:`${i.spacing(1.5)} 0 4px 0`},"& .MuiInputAdornment-root":{marginLeft:0,marginTop:1},"& label":{transform:"translate(0px, -9px) scale(0.75)"}}),ampm:this.props.oContext.systemConfig.dateFormat.includes("/"),timeSteps:this.props.schema.timeSteps||this.props.schema.timesteps||{hours:1,minutes:5,seconds:5},format:this.props.schema.format||"HH:mm:ss",disabled:!!e,value:s,onChange:i=>{let r;r=i instanceof Date?i.toTimeString().split(" ")[0]:i.toTimeString(),t&&(r=r.split(":").slice(0,2).join(":")),this.setState({value:r},()=>this.onChange(this.props.attr,this.state.value))},views:this.props.schema.views||["hours","minutes","seconds"],label:this.getText(this.props.schema.label)})}}function ws(E,c){let e;return c&&E.substring(0,c.length)===c?e=E.substring(c.length+1):e=E,e=e.replace(/\./g,"/").replace(/_/g," "),e}class As extends f{componentDidMount(){var e;super.componentDidMount();const c=f.getValue(this.props.data,this.props.attr);if(!c&&((e=this.props.customObj)!=null&&e._id)){const t=ws(this.props.customObj._id,`${this.props.oContext.adapterName}.${this.props.oContext.instance}`);this.setState({value:t})}else this.setState({value:c||""})}renderItem(c,e){return n().createElement(o.TextField,{variant:"standard",fullWidth:!0,slotProps:{htmlInput:{maxLength:this.props.schema.maxLength||this.props.schema.max||void 0}},value:this.state.value,error:!!c,disabled:e,placeholder:this.getText(this.props.schema.placeholder),label:this.getText(this.props.schema.label),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation),onChange:t=>{const s=t.target.value;this.setState({value:s},()=>this.onChange(this.props.attr,s))}})}}const Fs=As;class un extends f{componentDidMount(){return pe(this,null,function*(){var e;nt(un.prototype,this,"componentDidMount").call(this);const c=yield this.props.oContext.socket.getObject("system.meta.uuid");this.setState({uuid:((e=c==null?void 0:c.native)==null?void 0:e.uuid)||"unknown"})})}renderItem(c,e){return n().createElement(o.TextField,{variant:"standard",fullWidth:!0,error:!!c,disabled:!!e,slotProps:{htmlInput:{readOnly:!0},input:{endAdornment:n().createElement(o.IconButton,{onClick:()=>{l.Utils.copyToClipboard(this.state.uuid),window.alert(l.I18n.t("ra_Copied %s",this.state.uuid))}},n().createElement(u.ContentCopy,null))}},value:this.state.uuid||"",label:this.getText(this.props.schema.label)||l.I18n.t("ra_Serial number (UUID)"),helperText:this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)})}}const Ss=un,Tn={icon:{width:16,height:16,marginRight:8}};class Ts extends f{componentDidMount(){super.componentDidMount(),this.props.oContext.socket.getUsers().then(c=>{const e={},t=l.I18n.getLanguage();this.props.schema.short?c.forEach(s=>{var i,r;return e[s._id]={color:(i=s.common)==null?void 0:i.color,icon:(r=s.common)==null?void 0:r.icon,name:l.Utils.getObjectNameFromObj(s,t)}}):c.forEach(s=>{var i,r;return e[s._id.replace(/^system\.user\./,"")]={color:(i=s.common)==null?void 0:i.color,icon:(r=s.common)==null?void 0:r.icon,name:l.Utils.getObjectNameFromObj(s,t)}}),this.setState({users:e})}).catch(c=>console.error(`Cannot get users: ${c}`))}renderItem(c,e){var s,i;const t=f.getValue(this.props.data,this.props.attr);return n().createElement(o.FormControl,{variant:"standard",fullWidth:!0},this.state.users&&this.props.schema.label?n().createElement(o.InputLabel,null,this.getText(this.props.schema.label)):null,this.state.users?n().createElement(o.Select,{variant:"standard",error:!!c,disabled:!!e,value:t,renderValue:r=>{var a,h,S;return n().createElement("span",null,this.state.users&&((a=this.state.users[r])!=null&&a.icon)?n().createElement(l.Icon,{src:this.state.users&&((h=this.state.users[r])==null?void 0:h.icon),style:Tn.icon}):null,this.state.users&&((S=this.state.users[r])==null?void 0:S.name)||r||"")},style:{color:this.state.users&&((s=this.state.users[t])==null?void 0:s.color)||void 0,backgroundColor:l.Utils.getInvertedColor(this.state.users&&((i=this.state.users[t])==null?void 0:i.color),this.props.oContext.themeType)},onChange:r=>this.onChange(this.props.attr,r.target.value)},this.state.users&&Object.keys(this.state.users).map(r=>n().createElement(o.MenuItem,{style:{color:this.state.users[r].color||void 0,backgroundColor:l.Utils.getInvertedColor(this.state.users[r].color,this.props.oContext.themeType)},key:r,value:r},this.state.users[r].icon?n().createElement(l.Icon,{src:this.state.users[r].icon,style:Tn.icon}):null,this.state.users[r].name))):n().createElement(o.TextField,{variant:"standard",error:!!c,disabled:!!e,value:t,onChange:r=>this.onChange(this.props.attr,r.target.value),label:this.getText(this.props.schema.label)}),this.props.schema.help?n().createElement(o.FormHelperText,null,this.renderHelp(this.props.schema.help,this.props.schema.helpLink,this.props.schema.noTranslation)):null)}}const Is=Ts;class cn extends f{componentDidMount(){return pe(this,null,function*(){nt(cn.prototype,this,"componentDidMount").call(this);const c=yield Y.e("vendors-node_modules_react-qr-code_lib_index_js").then(Y.bind(Y,732));this.setState({QRCode:c.default})})}renderItem(){const c=this.state.QRCode;return c?n().createElement(c,{value:this.props.schema.data,size:this.props.schema.size,fgColor:this.props.schema.fgColor,bgColor:this.props.schema.bgColor,level:this.props.schema.level}):null}}const _s={accordion:H,alive:M,autocomplete:y,autocompleteSendTo:g,certCollection:re,certificate:$,certificates:I,checkbox:K,checkLicense:ce,chip:Et,chips:Et,color:bt,coordinates:ke,cron:b,custom:xt,datePicker:fe,deviceManager:gt,divider:os,file:Xt,fileSelector:Nt,func:Ft,header:ls,image:P,imageSendTo:en,instance:ue,interface:Pe,ip:Zt,jsonEditor:Je,language:Ze,license:rt,number:Ln,objectId:Nn,password:Rn,pattern:Vn,port:Un,qrCode:cn,room:Jn,select:qn,selectSendTo:Xn,sendto:vn,sendTo:vn,setState:Qn,slider:ts,state:ss,staticImage:cs,staticInfo:ps,staticLink:Fn,staticText:Fn,table:Cs,text:vs,textSendTo:bs,timePicker:xs,topic:Fs,uuid:Ss,user:Is},et={fullWidth:{width:"100%"},paper:{margin:1,width:"auto !important",overflowY:"auto",paddingBottom:1},paperWithIcons:{height:"calc(100vh - 259px) !important"},paperWithoutIcons:{height:"calc(100vh - 235px) !important"},padding:{padding:"10px"},heading:{},primary:E=>({backgroundColor:E.palette.primary.main,color:E.palette.mode==="dark"?"inherit":"#FFF"}),secondary:E=>({backgroundColor:E.palette.secondary.main})};class hn extends f{componentDidMount(){super.componentDidMount(),this.props.schema&&this.props.schema.collapsable&&this.setState({expanded:(window._localStorage||window.localStorage).getItem(`${this.props.oContext.adapterName}.${this.props.attr}`)==="true"})}renderItems(c,e){return c?Object.keys(c).map(t=>{if(this.props.oContext.multiEdit&&c[t].noMultiEdit)return null;const s=c[t].type||"panel";let i;return s==="custom"?c[t].url?i=xt:this.props.oContext.customs&&this.props.oContext.customs[c[t].component]?i=this.props.oContext.customs[c[t].component]:(console.error(`Cannot find custom component: ${c[t].component}`),i=f):s==="panel"?i=hn:i=_s[s]||f,n().createElement(i,{oContext:this.props.oContext,key:`${t}_${this.props.index===void 0?"":this.props.index}`,index:this.props.index,changed:this.props.changed,arrayIndex:this.props.arrayIndex,commandRunning:this.props.commandRunning,style:et.panel,common:this.props.common,alive:this.props.alive,themeName:this.props.themeName,data:this.props.data,originalData:this.props.originalData,onError:this.props.onError,onChange:this.props.onChange,disabled:e,customObj:this.props.customObj,custom:this.props.custom,schema:c[t],attr:t,table:this.props.table})}):null}render(){const c=this.props.schema;if(!c)return null;const{disabled:e,hidden:t}=this.calculate(c),s=this.props.schema.items,i=this.props.schema.style||{};if(t){if(c.hideOnlyControl){const a=n().createElement(o.Grid2,{size:{xs:c.xs||void 0,sm:c.sm||void 0,md:c.md||void 0,lg:c.lg||void 0,xl:c.xl||void 0},sx:l.Utils.getStyle(this.props.oContext.theme,{marginBottom:0,textAlign:"left"},i,this.props.oContext.themeType==="dark"&&c.darkStyle)});return c.newLine?n().createElement(n().Fragment,null,n().createElement("div",{style:{flexBasis:"100%",height:0}}),a):a}return null}if(this.props.table)return this.renderItems(s,e);if(this.props.custom)return n().createElement(o.Grid2,{key:`${this.props.attr}_${this.props.index}`,container:!0,style:et.fullWidth,columnSpacing:2,rowSpacing:1,sx:i},this.renderItems(s,e));let r;if(c.collapsable?r=n().createElement(o.Accordion,{key:`${this.props.attr}_${this.props.index}`,style:et.fullWidth,expanded:!!this.state.expanded,onChange:()=>{(window._localStorage||window.localStorage).setItem(`${this.props.oContext.adapterName}.${this.props.attr}`,this.state.expanded?"false":"true"),this.setState({expanded:!this.state.expanded})}},n().createElement(o.AccordionSummary,{expandIcon:n().createElement(u.ExpandMore,null),sx:l.Utils.getStyle(this.props.oContext.theme,i,this.props.oContext.themeType&&c.darkStyle,c.color==="primary"?et.primary:c.color==="secondary"&&et.secondary,{width:"100%"})},n().createElement(o.Typography,{style:et.heading},this.getText(c.label))),n().createElement(o.AccordionDetails,null,n().createElement(o.Grid2,{container:!0,columnSpacing:2,rowSpacing:1,sx:Oe(q({},i),{width:"100%",padding:"10px"})},this.renderItems(s,e)))):r=n().createElement(o.Box,{component:"div",key:`${this.props.attr}_${this.props.index}`,className:this.props.className,sx:l.Utils.getStyle(this.props.oContext.theme,this.props.style,i,{width:"100%"},this.props.isParentTab&&et.paper,this.props.isParentTab&&(this.props.withIcons?et.paperWithIcons:et.paperWithoutIcons))},n().createElement(o.Grid2,{container:!0,columnSpacing:2,rowSpacing:1,sx:l.Utils.getStyle(this.props.oContext.theme,{width:"100%"},this.props.isParentTab&&et.padding,this.props.schema.innerStyle)},this.renderItems(s,e))),!this.props.isParentTab){const a=n().createElement(o.Grid2,{title:this.getText(c.tooltip),size:{xs:c.xs||void 0,sm:c.sm||void 0,md:c.md||void 0,lg:c.lg||void 0,xl:c.xl||void 0},sx:q({marginBottom:0,textAlign:"left"},i)},r);return c.newLine?n().createElement(n().Fragment,null,n().createElement("div",{style:{flexBasis:"100%",height:0}}),a):a}return r}}const Ot=hn,Ut={tabs:{height:"100%",width:"100%"},panel:{width:"100%",display:"block"},panelWithIcons:{height:"calc(100% - 72px)"},panelWithoutIcons:{height:"calc(100% - 48px)"}};class ks extends f{constructor(e){super(e);Q(this,"onHashTabsChanged",()=>{const e=(window.location.hash||"").replace(/^#/,"").split("/");if(e.length>3&&e[1]==="config"){const t=e[3],s=parseInt(t,10);let i;s.toString()===t?s>=0&&s=3&&s[1]==="config"){const i=s[3],r=parseInt(i,10);i&&r.toString()===i?r>=0&&r{(window._localStorage||window.localStorage).setItem(`${this.props.dialogName||"App"}.${this.props.oContext.adapterName}`,i),this.setState({tab:i},()=>{if(this.props.root){const r=(window.location.hash||"").split("/");r.length>=3&&r[1]==="config"&&(r[3]=this.state.tab,window.location.hash=r.join("/"))}})}},Object.keys(e).map(s=>{let i;if(this.props.custom){if(this.executeCustom(e[s].hidden,this.props.data,this.props.customObj,this.props.oContext.instanceObj,this.props.index,this.props.globalData))return null;i=this.executeCustom(e[s].disabled,this.props.data,this.props.customObj,this.props.oContext.instanceObj,this.props.index,this.props.globalData)}else{if(this.execute(e[s].hidden,!1,this.props.data,this.props.index,this.props.globalData))return null;i=this.execute(e[s].disabled,!1,this.props.data,this.props.index,this.props.globalData)}const r=this.getIcon(e[s].icon);return t=t||!!r,n().createElement(o.Tab,{id:s,wrapped:!0,disabled:i,key:s,value:s,iconPosition:this.props.schema.iconPosition||"start",icon:r,label:this.getText(e[s].label)})})),n().createElement(Ot,{oContext:this.props.oContext,isParentTab:!0,changed:this.props.changed,key:this.state.tab,index:1001,arrayIndex:this.props.arrayIndex,globalData:this.props.globalData,commandRunning:this.props.commandRunning,style:q(q({},Ut.panel),t?Ut.panelWithIcons:Ut.panelWithoutIcons),common:this.props.common,alive:this.props.alive,themeName:this.props.themeName,data:this.props.data,originalData:this.props.originalData,onChange:this.props.onChange,onError:this.props.onError,customObj:this.props.customObj,custom:this.props.custom,schema:e[this.state.tab],table:this.props.table,withIcons:t}))}}const Bs=ks,Os={root:{width:"100%",height:"100%"}};class Ls extends T.Component{constructor(e){super(e);Q(this,"forceUpdateHandlers");Q(this,"errorTimeout",null);Q(this,"errorCached",null);Q(this,"oContext");Q(this,"onCommandRunning",e=>this.setState({commandRunning:e}));Q(this,"onAlive",(e,t)=>{!!(t!=null&&t.val)!==this.state.alive&&this.setState({alive:!!(t!=null&&t.val)})});Q(this,"onChange",(e,t,s,i)=>{if(this.props.onValueChange)this.props.onValueChange(e,t,i),s&&s();else if(e&&this.props.onChange){const r={changed:JSON.stringify(e)!==this.state.originalData};this.setState(r,()=>{this.props.onChange(e,r.changed,i),s&&s()})}else i&&this.props.onChange(null,null,i)});Q(this,"onError",(e,t)=>{this.errorCached=this.errorCached||JSON.parse(JSON.stringify(this.state.errors));const s=this.errorCached;t?s[e]=t:delete s[e],this.errorTimeout&&clearTimeout(this.errorTimeout),JSON.stringify(s)!==JSON.stringify(this.state.errors)?this.errorTimeout=setTimeout(()=>this.setState({errors:this.errorCached},()=>{this.errorTimeout=null,this.errorCached=null,this.props.onError(!!Object.keys(this.state.errors).length)}),50):this.errorCached=null});Q(this,"changeLanguage",()=>{this.forceUpdate()});Q(this,"forceAttrUpdate",(e,t)=>{Array.isArray(e)?e.forEach(s=>this.forceUpdateHandlers[s]&&this.forceUpdateHandlers[s](t)):this.forceUpdateHandlers[e]&&this.forceUpdateHandlers[e](t)});Q(this,"registerOnForceUpdate",(e,t)=>{t?this.forceUpdateHandlers[e]=t:this.forceUpdateHandlers[e]&&delete this.forceUpdateHandlers[e]});this.state={originalData:JSON.stringify(this.props.data),changed:!1,errors:{},updateData:this.props.updateData||0,systemConfig:null,alive:!1,commandRunning:!1,schema:JSON.parse(JSON.stringify(this.props.schema))},this.forceUpdateHandlers={},this.buildDependencies(this.state.schema),this.readData()}static getDerivedStateFromProps(e,t){return e.updateData!==t.updateData?{updateData:e.updateData,originalData:JSON.stringify(e.data),schema:JSON.parse(JSON.stringify(e.schema))}:null}static loadI18n(e,t,s){return pe(this,null,function*(){if(t===!0||t&&typeof t=="string"){const i=l.I18n.getLanguage(),r=typeof t=="string"?t:"i18n";let a=yield e.fileExists(`${s}.admin`,`${r}/${i}.json`),h;if(a?h=`${r}/${i}.json`:(a=yield e.fileExists(`${s}.admin`,`${r}/${i}/translations.json`),a?h=`${r}/${i}/translations.json`:i!=="en"&&(a=yield e.fileExists(`${s}.admin`,`${r}/en.json`),a?h=`${r}/en.json`:(a=yield e.fileExists(`${s}.admin`,`${r}/en/translations.json`),a&&(h=`${r}/en/translations.json`)))),h){const S=yield e.readFile(`${s}.admin`,h);let L;S.file!==void 0?L=S.file:L=S;try{const O=JSON.parse(L);l.I18n.extendTranslations(O,i)}catch(O){return console.error(`Cannot parse language file "${s}.admin/${h}: ${O}`),""}return h}return console.warn(`Cannot find i18n for ${s} / ${h}`),""}return t&&typeof t=="object"&&l.I18n.extendTranslations(t),""})}readData(){this.props.socket.getCompactSystemConfig().then(e=>this.props.socket.getState(`system.adapter.${this.props.adapterName}.${this.props.instance}.alive`).then(t=>this.setState({systemConfig:e.common,alive:!!(t&&t.val)},()=>{this.updateContext(!0),this.props.custom||this.props.socket.subscribeState(`system.adapter.${this.props.adapterName}.${this.props.instance}.alive`,this.onAlive)}))).catch(e=>console.error(`Cannot read system config: ${e}`))}flatten(e,t){return t=t||{},e.items&&Object.keys(e.items).forEach(s=>{t[s]=e.items[s],this.flatten(e.items[s],t)}),t}buildDependencies(e){const t=this.flatten(e);Object.keys(t).forEach(s=>{var i,r,a,h,S,L,O,N,te,ye;(i=t[s].confirm)!=null&&i.alsoDependsOn&&((r=t[s].confirm)==null||r.alsoDependsOn.forEach(se=>{if(!t[se])console.error(`[JsonConfigComponent] Attribute ${se} does not exist!`),se.startsWith("data.")&&console.warn(`[JsonConfigComponent] please use "${se.replace(/^data\./,"")}" instead of "${se}"`);else{t[se].confirmDependsOn=t[se].confirmDependsOn||[];const Ee=Oe(q({},t[s]),{attr:s});Ee.confirm&&(Ee.confirm.cancel="Undo"),t[se].confirmDependsOn.push(Ee)}})),(a=t[s].onChange)!=null&&a.alsoDependsOn&&((h=t[s].onChange)==null||h.alsoDependsOn.forEach(se=>{if(!t[se])console.error(`[JsonConfigComponent] Attribute ${se} does not exist!`),se.startsWith("data.")&&console.warn(`[JsonConfigComponent] please use "${se.replace(/^data\./,"")}" instead of "${se}"`);else{t[se].onChangeDependsOn=t[se].onChangeDependsOn||[];const Ee=Oe(q({},t[s]),{attr:s});t[se].onChangeDependsOn.push(Ee)}})),(S=t[s].hidden)!=null&&S.alsoDependsOn&&((L=t[s].hidden)==null||L.alsoDependsOn.forEach(se=>{if(!t[se])console.error(`[JsonConfigComponent] Attribute ${se} does not exist!`),se.startsWith("data.")&&console.warn(`[JsonConfigComponent] please use "${se.replace(/^data\./,"")}" instead of "${se}"`);else{t[se].hiddenDependsOn=t[se].hiddenDependsOn||[];const Ee=Oe(q({},t[s]),{attr:s});t[se].hiddenDependsOn.push(Ee)}})),(O=t[s].label)!=null&&O.alsoDependsOn&&((N=t[s].label)==null||N.alsoDependsOn.forEach(se=>{if(!t[se])console.error(`[JsonConfigComponent] Attribute ${se} does not exist!`),se.startsWith("data.")&&console.warn(`[JsonConfigComponent] please use "${se.replace(/^data\./,"")}" instead of "${se}"`);else{t[se].labelDependsOn=t[se].labelDependsOn||[];const Ee=Oe(q({},t[s]),{attr:s});t[se].labelDependsOn.push(Ee)}})),(te=t[s].help)!=null&&te.alsoDependsOn&&((ye=t[s].help)==null||ye.alsoDependsOn.forEach(se=>{if(!t[se])console.error(`[JsonConfigComponent] Attribute ${se} does not exist!`),se.startsWith("data.")&&console.warn(`[JsonConfigComponent] please use "${se.replace(/^data\./,"")}" instead of "${se}"`);else{t[se].helpDependsOn=t[se].helpDependsOn||[];const Ee=Oe(q({},t[s]),{attr:s});t[se].helpDependsOn.push(Ee)}}))})}updateContext(e){this.oContext={DeviceManager:this.props.DeviceManager,adapterName:this.props.adapterName,changeLanguage:this.changeLanguage,common:this.props.common,customs:this.props.customs,dateFormat:this.props.dateFormat,embedded:this.props.embedded,expertMode:this.props.expertMode,forceUpdate:this.forceAttrUpdate,imagePrefix:this.props.imagePrefix,instance:this.props.instance,instanceObj:this.props.instanceObj,isFloatComma:this.props.isFloatComma,multiEdit:this.props.multiEdit,onBackEndCommand:this.props.onBackEndCommand,onCommandRunning:this.onCommandRunning,onValueChange:this.props.onValueChange,registerOnForceUpdate:this.registerOnForceUpdate,socket:this.props.socket,systemConfig:this.state.systemConfig,theme:this.props.theme,themeType:this.props.themeType,_themeName:this.props.themeName,updateData:this.state.updateData},e&&this.forceUpdate()}renderItem(e){return e.type==="tabs"?n().createElement(Bs,{oContext:this.oContext,alive:this.state.alive,changed:this.state.changed,commandRunning:this.state.commandRunning,common:this.props.common,custom:this.props.custom,customObj:this.props.customObj,data:this.props.data,onChange:this.onChange,onError:(t,s)=>this.onError(t,s),originalData:JSON.parse(this.state.originalData),root:!0,schema:e,themeName:this.props.themeName}):e.type==="panel"||!e.type?n().createElement(Ot,{oContext:this.oContext,alive:this.state.alive,changed:this.state.changed,commandRunning:this.state.commandRunning,common:this.props.common,custom:this.props.custom,customObj:this.props.customObj,data:this.props.data,index:1e3,isParentTab:!this.props.embedded,onChange:this.onChange,onError:(t,s)=>this.onError(t,s),originalData:JSON.parse(this.state.originalData),root:!0,schema:e,themeName:this.props.themeName}):(console.error(`Unknown item type in root: ${JSON.stringify(e)}`),null)}render(){return!this.state.systemConfig||!this.oContext?n().createElement(o.LinearProgress,null):(this.oContext._themeName!==this.props.themeName&&(this.oContext._themeName=this.props.themeName,setTimeout(()=>this.updateContext(!0),0)),n().createElement("div",{style:q(q(q({},this.props.embedded?void 0:Os.root),this.props.style),this.state.schema.style)},this.renderItem(this.state.schema)))}}const Wt=Ls,vt={root:{width:"100%",height:"100%",overflow:"hidden",position:"relative"},scroll:{height:"calc(100% - 48px)",overflowY:"auto"},exportImportButtons:{position:"absolute",top:5,right:0,zIndex:3},button:{marginRight:"5px"},tooltip:{pointerEvents:"none"}};function $s(E,c){let e="";for(let t=0;t{const s=document.createElement("script");s.setAttribute("id",c),s.onload=t,s.src=E,document.getElementsByTagName("head")[0].appendChild(s)}):(e=document.getElementById(c))==null?void 0:e.onload}class Ms extends l.Router{constructor(e){super(e);Q(this,"fileSubscribed",[]);Q(this,"fileLangSubscribed","");Q(this,"secret");Q(this,"handleFileSelect",e=>{const t=e.target.files[0];if(t){const s=new FileReader;s.onload=i=>{if(!i.target)return;const r=i.target.result;try{const a=JSON.parse(r);this.setState({data:a,changed:JSON.stringify(a)!==JSON.stringify(this.state.originalData)})}catch(a){window.alert(l.I18n.t("[JsonConfig] Failed to parse JSON file"))}},s.readAsText(t)}else window.alert(l.I18n.t("[JsonConfig] Failed to open JSON File"))});Q(this,"onFileChange",(e,t,s)=>pe(this,null,function*(){var i;if(e===`${this.props.adapterName}.admin`&&s){if(t===this.fileLangSubscribed)try{yield Wt.loadI18n(this.props.socket,(i=this.state.schema)==null?void 0:i.i18n,this.props.adapterName),this.setState({hash:`${this.state.hash}1`})}catch(r){}else if(this.fileSubscribed.includes(t))try{const r=yield this.getConfigFile(this.fileSubscribed[0]);this.setState({schema:r,hash:v()(JSON.stringify(r)).toString()})}catch(r){}}}));this.state={updateData:0,changed:!1,confirmDialog:!1,theme:(0,l.Theme)(e.themeName),saveConfigDialog:!1,hash:"_"},this.secret=e.secret||"",this.getInstanceObject().then(t=>this.getConfigFile().then(s=>Wt.loadI18n(this.props.socket,s==null?void 0:s.i18n,this.props.adapterName).then(i=>{i&&(this.fileLangSubscribed||(this.fileLangSubscribed=i,this.props.socket.subscribeFiles(`${this.props.adapterName}.admin`,this.fileLangSubscribed,this.onFileChange))),t?this.setState({schema:s,data:t.native,common:t.common,hash:v()(JSON.stringify(s)).toString()}):window.alert(`Instance system.adapter.${this.props.adapterName}.${this.props.instance} not found!`)})))}componentWillUnmount(){super.componentWillUnmount(),this.fileSubscribed.length&&(this.props.socket.unsubscribeFiles(`${this.props.adapterName}.admin`,this.fileSubscribed,this.onFileChange),this.fileSubscribed=[]),this.fileLangSubscribed&&(this.props.socket.unsubscribeFiles(`${this.props.adapterName}.admin`,this.fileLangSubscribed,this.onFileChange),this.fileLangSubscribed="")}getExportImportButtons(){return n().createElement("div",{style:vt.exportImportButtons},n().createElement(o.Tooltip,{title:this.props.t("Import settings from JSON file"),slotProps:{popper:{sx:vt.tooltip}}},n().createElement(o.Fab,{size:"small",sx:{"&.MuiFab-root":vt.button},onClick:()=>{const e=document.createElement("input");e.setAttribute("type","file"),e.setAttribute("id","files"),e.setAttribute("opacity",0),e.addEventListener("change",t=>this.handleFileSelect(t),!1),e.click()}},n().createElement(u.Publish,null))),n().createElement(o.Tooltip,{title:this.props.t("Export setting to JSON file"),slotProps:{popper:{sx:vt.tooltip}}},n().createElement(o.Fab,{size:"small",sx:{"&.MuiFab-root":vt.button},onClick:()=>{this.state.data&&l.Utils.generateFile(`${this.props.adapterName}.${this.props.instance}.json`,this.state.data)}},n().createElement(u.Publish,{style:{transform:"rotate(180deg)"}}))))}getInstanceObject(){return pe(this,null,function*(){var e;try{const t=yield this.props.socket.getObject(`system.adapter.${this.props.adapterName}.${this.props.instance}`);if(Array.isArray(t.encryptedNative)){if(!this.secret){const s=yield this.props.socket.getSystemConfig();yield In("../../lib/js/crypto-js/crypto-js.js","crypto-js"),this.secret=s.native.secret}return(e=t.encryptedNative)==null||e.forEach(s=>{t.native[s]&&(t.native[s]=Ps(this.secret,t.native[s]))}),t}return t}catch(t){window.alert(`[JsonConfig] Cannot read instance object: ${t}`)}return null})}renderDialogConfirm(){return this.state.confirmDialog?n().createElement(l.DialogConfirm,{title:l.I18n.t("ra_Please confirm"),text:l.I18n.t("ra_Some data are not stored. Discard?"),ok:l.I18n.t("ra_Discard"),cancel:l.I18n.t("ra_Cancel"),onClose:e=>this.setState({confirmDialog:!1},()=>e&&l.Router.doNavigate(null))}):null}scanForInclude(e,t){return pe(this,null,function*(){if(typeof e["#include"]=="string"){const i=yield this._getConfigFile(e["#include"],[...t]);return delete e["#include"],i&&(e=q(q({},e),i)),e}const s=Object.keys(e);for(let i=0;i ${t.join(" => ")}`),null;t.push(e);try{(yield this.props.socket.fileExists(`${this.props.adapterName}.admin`,e))||(e="jsonConfig.json");const i=yield this.props.socket.readFile(`${this.props.adapterName}.admin`,e);let r="",a="";if(i.file!==void 0&&(a=i.file),typeof a=="string")r=a;else if(a.type==="Buffer"){let h="";const S=new Uint8Array(a.data),L=S.byteLength;for(let O=0;Othis.setState({saveConfigDialog:!1},()=>e&&this.onSave(!0))}):null}findAttr(e,t){if(t=t||this.state.schema,t!=null&&t.items){if(e in t.items)return t.items[e];for(const s of Object.values(t.items)){const i=this.findAttr(e,s);if(i)return i}}return null}postProcessing(e,t,s){if(s=s||this.state.schema,!e){console.error(`Data is empty in postProcessing: ${t}, ${JSON.stringify(s)}`);return}const i=e[t];if(s.items)if(s.type==="table"){const r=i;if(!Array.isArray(r))return;for(const a of r)for(const h of s.items)this.postProcessing(a,h.attr,h)}else for(const[r,a]of Object.entries(s.items)){if(a.type==="panel"||a.type==="tabs"||a.type==="accordion")return;this.postProcessing(e,r,a)}else if(t&&typeof i=="string")if(s.type==="text")s.trim!==!1&&(e[t]=i.trim());else if(s.type==="ip")e[t]=i.trim();else if(s.type==="number"){const r=parseFloat(i.toString().replace(",","."));s.min!==void 0&&rs.max?e[t]=s.max:e[t]=r}else if(s.type==="port"){const r=parseInt(i.toString(),10);s.min!==void 0&&rs.max&&(e[t]=s.max),e[t]!==0&&r<20?e[t]=20:r>65535?e[t]=65535:e[t]=r}else s.type==="checkbox"&&(e[t]=e[t]===!0||e[t]==="true"||e[t]==="on"||e[t]===1||e[t]==="1")}onSave(e,t){return pe(this,null,function*(){if(e){const s=yield this.getInstanceObject();if(!s){console.error("Something went wrong: may be no connection?"),window.alert("Something went wrong: may be no connection?");return}if(!this.state.data||!this.state.schema)return;const i={};for(const a of Object.keys(this.state.data)){const h=this.findAttr(a);(!h||!h.doNotSave||h.type==="state")&&!a.startsWith("_")?f.setValue(s.native,a,this.state.data[a]):(f.setValue(s.native,a,null),i[a]=this.state.data[a])}try{const a=JSON.parse(JSON.stringify(s));if(Array.isArray(a.encryptedNative)){yield In("../../lib/js/crypto-js/crypto-js.js","crypto-js");for(const h of a.encryptedNative)a.native[h]&&(a.native[h]=Rs(this.secret,a.native[h]))}yield this.props.socket.setObject(a._id,a)}catch(a){window.alert(`[JsonConfig] Cannot set object: ${a}`)}const r=q(q({},s.native),i);console.log(r),this.setState({changed:!1,data:r,updateData:this.state.updateData+1,originalData:r},()=>t&&l.Router.doNavigate(null))}else this.state.changed?this.setState({confirmDialog:!0}):l.Router.doNavigate(null)})}componentDidUpdate(e,t){t.changed!==this.state.changed&&this.props.configStored(!this.state.changed)}componentDidMount(){return pe(this,null,function*(){const e=`${window.location.protocol}//${window.location.host}${window.location.pathname}validate_config/${this.props.adapterName}`;console.log(`fetch ${e}`),yield fetch(e)})}render(){return!this.state.data||!this.state.schema?n().createElement(o.LinearProgress,null):n().createElement("div",{style:vt.root},this.renderDialogConfirm(),this.getExportImportButtons(),this.renderSaveConfigDialog(),n().createElement(Wt,{key:this.state.hash,style:vt.scroll,socket:this.props.socket,themeName:this.props.themeName,themeType:this.props.themeType,adapterName:this.props.adapterName,instance:this.props.instance,isFloatComma:this.props.isFloatComma,dateFormat:this.props.dateFormat,schema:this.state.schema,common:this.state.common,expertMode:this.props.expertMode,data:this.state.data,updateData:this.state.updateData,onError:e=>this.setState({error:e}),onChange:(e,t,s)=>{s&&this.state.error&&(window.alert(l.I18n.t("Cannot save configuration because of error in configuration")),s=!1),s&&!this.state.changed&&!t&&(s=!1),e?this.setState({data:e,changed:t,saveConfigDialog:s}):s!==void 0&&this.setState({saveConfigDialog:s})},DeviceManager:this.props.DeviceManager,theme:this.state.theme}),n().createElement(l.SaveCloseButtons,{isIFrame:!1,dense:!0,paddingLeft:0,newReact:!0,theme:this.state.theme,noTextOnButtons:this.props.width==="xs"||this.props.width==="sm"||this.props.width==="md",changed:!!(this.state.error||this.state.changed),error:!!this.state.error,onSave:e=>this.onSave(!0,e),onClose:()=>this.onSave(!1)}))}}const Vs=Ms},2292:(V,ee,Y)=>{V=Y.nmd(V),ace.define("ace/snippets",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/range_list","ace/keyboard/hash_handler","ace/tokenizer","ace/clipboard","ace/editor"],function(T,n,C){"use strict";function m(p){var g=new Date().toLocaleString("en-us",p);return g.length==1?"0"+g:g}var D=T("./lib/dom"),v=T("./lib/oop"),o=T("./lib/event_emitter").EventEmitter,u=T("./lib/lang"),l=T("./range").Range,_=T("./range_list").RangeList,R=T("./keyboard/hash_handler").HashHandler,f=T("./tokenizer").Tokenizer,Z=T("./clipboard"),j={CURRENT_WORD:function(p){return p.session.getTextRange(p.session.getWordRange())},SELECTION:function(p,g,d){var x=p.session.getTextRange();return d?x.replace(/\n\r?([ \t]*\S)/g,` +`+d+"$1"):x},CURRENT_LINE:function(p){return p.session.getLine(p.getCursorPosition().row)},PREV_LINE:function(p){return p.session.getLine(p.getCursorPosition().row-1)},LINE_INDEX:function(p){return p.getCursorPosition().row},LINE_NUMBER:function(p){return p.getCursorPosition().row+1},SOFT_TABS:function(p){return p.session.getUseSoftTabs()?"YES":"NO"},TAB_SIZE:function(p){return p.session.getTabSize()},CLIPBOARD:function(p){return Z.getText&&Z.getText()},FILENAME:function(p){return/[^/\\]*$/.exec(this.FILEPATH(p))[0]},FILENAME_BASE:function(p){return/[^/\\]*$/.exec(this.FILEPATH(p))[0].replace(/\.[^.]*$/,"")},DIRECTORY:function(p){return this.FILEPATH(p).replace(/[^/\\]*$/,"")},FILEPATH:function(p){return"/not implemented.txt"},WORKSPACE_NAME:function(){return"Unknown"},FULLNAME:function(){return"Unknown"},BLOCK_COMMENT_START:function(p){var g=p.session.$mode||{};return g.blockComment&&g.blockComment.start||""},BLOCK_COMMENT_END:function(p){var g=p.session.$mode||{};return g.blockComment&&g.blockComment.end||""},LINE_COMMENT:function(p){var g=p.session.$mode||{};return g.lineCommentStart||""},CURRENT_YEAR:m.bind(null,{year:"numeric"}),CURRENT_YEAR_SHORT:m.bind(null,{year:"2-digit"}),CURRENT_MONTH:m.bind(null,{month:"numeric"}),CURRENT_MONTH_NAME:m.bind(null,{month:"long"}),CURRENT_MONTH_NAME_SHORT:m.bind(null,{month:"short"}),CURRENT_DATE:m.bind(null,{day:"2-digit"}),CURRENT_DAY_NAME:m.bind(null,{weekday:"long"}),CURRENT_DAY_NAME_SHORT:m.bind(null,{weekday:"short"}),CURRENT_HOUR:m.bind(null,{hour:"2-digit",hour12:!1}),CURRENT_MINUTE:m.bind(null,{minute:"2-digit"}),CURRENT_SECOND:m.bind(null,{second:"2-digit"})};j.SELECTED_TEXT=j.SELECTION;var H=function(){function p(){this.snippetMap={},this.snippetNameMap={},this.variables=j}return p.prototype.getTokenizer=function(){return p.$tokenizer||this.createTokenizer()},p.prototype.createTokenizer=function(){function g(b){return b=b.substr(1),/^\d+$/.test(b)?[{tabstopId:parseInt(b,10)}]:[{text:b}]}function d(b){return"(?:[^\\\\"+b+"]|\\\\.)"}var x={regex:"/("+d("/")+"+)/",onMatch:function(b,B,$){var k=$[0];return k.fmtString=!0,k.guard=b.slice(1,-1),k.flag="",""},next:"formatString"};return p.$tokenizer=new f({start:[{regex:/\\./,onMatch:function(b,B,$){var k=b[1];return(k=="}"&&$.length||"`$\\".indexOf(k)!=-1)&&(b=k),[b]}},{regex:/}/,onMatch:function(b,B,$){return[$.length?$.shift():b]}},{regex:/\$(?:\d+|\w+)/,onMatch:g},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(b,B,$){var k=g(b.substr(1));return $.unshift(k[0]),k},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+d("\\|")+"*\\|",onMatch:function(b,B,$){var k=b.slice(1,-1).replace(/\\[,|\\]|,/g,function(F){return F.length==2?F[1]:"\0"}).split("\0").map(function(F){return{value:F}});return $[0].choices=k,[k[0]]},next:"start"},x,{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:/:/,onMatch:function(b,B,$){return $.length&&$[0].expectElse?($[0].expectElse=!1,$[0].ifEnd={elseEnd:$[0]},[$[0].ifEnd]):":"}},{regex:/\\./,onMatch:function(b,B,$){var k=b[1];return k=="}"&&$.length||"`$\\".indexOf(k)!=-1?b=k:k=="n"?b=` +`:k=="t"?b=" ":"ulULE".indexOf(k)!=-1&&(b={changeCase:k,local:k>"a"}),[b]}},{regex:"/\\w*}",onMatch:function(b,B,$){var k=$.shift();return k&&(k.flag=b.slice(1,-1)),this.next=k&&k.tabstopId?"start":"",[k||b]},next:"start"},{regex:/\$(?:\d+|\w+)/,onMatch:function(b,B,$){return[{text:b.slice(1)}]}},{regex:/\${\w+/,onMatch:function(b,B,$){var k={text:b.slice(2)};return $.unshift(k),[k]},next:"formatStringVar"},{regex:/\n/,token:"newline",merge:!1},{regex:/}/,onMatch:function(b,B,$){var k=$.shift();return this.next=k&&k.tabstopId?"start":"",[k||b]},next:"start"}],formatStringVar:[{regex:/:\/\w+}/,onMatch:function(b,B,$){var k=$[0];return k.formatFunction=b.slice(2,-1),[$.shift()]},next:"formatString"},x,{regex:/:[\?\-+]?/,onMatch:function(b,B,$){b[1]=="+"&&($[0].ifEnd=$[0]),b[1]=="?"&&($[0].expectElse=!0)},next:"formatString"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"formatString"}]}),p.$tokenizer},p.prototype.tokenizeTmSnippet=function(g,d){return this.getTokenizer().getLineTokens(g,d).tokens.map(function(x){return x.value||x})},p.prototype.getVariableValue=function(g,d,x){if(/^\d+$/.test(d))return(this.variables.__||{})[d]||"";if(/^[A-Z]\d+$/.test(d))return(this.variables[d[0]+"__"]||{})[d.substr(1)]||"";if(d=d.replace(/^TM_/,""),!this.variables.hasOwnProperty(d))return"";var b=this.variables[d];return typeof b=="function"&&(b=this.variables[d](g,d,x)),b==null?"":b},p.prototype.tmStrFormat=function(g,d,x){if(!d.fmt)return g;var b=d.flag||"",B=d.guard;B=new RegExp(B,b.replace(/[^gim]/g,""));var $=typeof d.fmt=="string"?this.tokenizeTmSnippet(d.fmt,"formatString"):d.fmt,k=this,F=g.replace(B,function(){var I=k.variables.__;k.variables.__=[].slice.call(arguments);for(var U=k.resolveVariables($,x),re="E",X=0;X=0&&F.splice(I,1)}}var b=this.snippetMap,B=this.snippetNameMap;g.content?x(g):Array.isArray(g)&&g.forEach(x)},p.prototype.parseSnippetFile=function(g){g=g.replace(/\r/g,"");for(var d=[],x={},b=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm,B;B=b.exec(g);){if(B[1])try{x=JSON.parse(B[1]),d.push(x)}catch(I){}if(B[4])x.content=B[4].replace(/^\t/gm,""),d.push(x),x={};else{var $=B[2],k=B[3];if($=="regex"){var F=/\/((?:[^\/\\]|\\.)*)|$/g;x.guard=F.exec(k)[1],x.trigger=F.exec(k)[1],x.endTrigger=F.exec(k)[1],x.endGuard=F.exec(k)[1]}else $=="snippet"?(x.tabTrigger=k.match(/^\S*/)[0],x.name||(x.name=k)):$&&(x[$]=k)}}return d},p.prototype.getSnippetByName=function(g,d){var x=this.snippetNameMap,b;return this.getActiveScopes(d).some(function(B){var $=x[B];return $&&(b=$[g]),!!b},this),b},p}();v.implement(H.prototype,o);var ie=function(p,g,d){function x(ge){for(var _e=[],ze=0;ze1?(G=_e[_e.length-1].length,z+=_e.length-1):G+=ge.length,Ve+=ge}else ge&&(ge.start?ge.end={row:z,column:G}:ge.start={row:z,column:G})}),{text:Ve,tabstops:I,tokens:F}},le=function(){function p(g){if(this.index=0,this.ranges=[],this.tabstops=[],g.tabstopManager)return g.tabstopManager;g.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=u.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(g)}return p.prototype.attach=function(g){this.$openTabstops=null,this.selectedTabstop=null,this.editor=g,this.session=g.session,this.editor.on("change",this.$onChange),this.editor.on("changeSelection",this.$onChangeSelection),this.editor.on("changeSession",this.$onChangeSession),this.editor.commands.on("afterExec",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},p.prototype.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges.length=0,this.tabstops.length=0,this.selectedTabstop=null,this.editor.off("change",this.$onChange),this.editor.off("changeSelection",this.$onChangeSelection),this.editor.off("changeSession",this.$onChangeSession),this.editor.commands.off("afterExec",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.session=null,this.editor=null},p.prototype.onChange=function(g){for(var d=g.action[0]=="r",x=this.selectedTabstop||{},b=x.parents||{},B=this.tabstops.slice(),$=0;$2&&(this.tabstops.length&&k.push(k.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,k))},p.prototype.addTabstopMarkers=function(g){var d=this.session;g.forEach(function(x){x.markerId||(x.markerId=d.addMarker(x,"ace_snippet-marker","text"))})},p.prototype.removeTabstopMarkers=function(g){var d=this.session;g.forEach(function(x){d.removeMarker(x.markerId),x.markerId=null})},p.prototype.updateTabstopMarkers=function(){if(this.selectedTabstop){var g=this.selectedTabstop.snippetId;this.selectedTabstop.index===0&&g--,this.tabstops.forEach(function(d){d.snippetId===g?this.addTabstopMarkers(d):this.removeTabstopMarkers(d)},this)}},p.prototype.removeRange=function(g){var d=g.tabstop.indexOf(g);d!=-1&&g.tabstop.splice(d,1),d=this.ranges.indexOf(g),d!=-1&&this.ranges.splice(d,1),d=g.tabstop.rangeList.ranges.indexOf(g),d!=-1&&g.tabstop.splice(d,1),this.session.removeMarker(g.markerId),g.tabstop.length||(d=this.tabstops.indexOf(g.tabstop),d!=-1&&this.tabstops.splice(d,1),this.tabstops.length||this.detach())},p}();le.prototype.keyboardHandler=new R,le.prototype.keyboardHandler.bindKeys({Tab:function(p){n.snippetManager&&n.snippetManager.expandWithTab(p)||(p.tabstopManager.tabNext(1),p.renderer.scrollCursorIntoView())},"Shift-Tab":function(p){p.tabstopManager.tabNext(-1),p.renderer.scrollCursorIntoView()},Esc:function(p){p.tabstopManager.detach()}});var M=function(p,g){p.row==0&&(p.column+=g.column),p.row+=g.row},w=function(p,g){p.row==g.row&&(p.column-=g.column),p.row-=g.row};D.importCssString(` +.ace_snippet-marker { + -moz-box-sizing: border-box; + box-sizing: border-box; + background: rgba(194, 193, 208, 0.09); + border: 1px dotted rgba(211, 208, 235, 0.62); + position: absolute; +}`,"snippets.css",!1),n.snippetManager=new H;var y=T("./editor").Editor;(function(){this.insertSnippet=function(p,g){return n.snippetManager.insertSnippet(this,p,g)},this.expandSnippet=function(p){return n.snippetManager.expandWithTab(this,p)}}).call(y.prototype)}),ace.define("ace/autocomplete/popup",["require","exports","module","ace/virtual_renderer","ace/editor","ace/range","ace/lib/event","ace/lib/lang","ace/lib/dom","ace/config","ace/lib/useragent"],function(T,n,C){"use strict";var m=T("../virtual_renderer").VirtualRenderer,D=T("../editor").Editor,v=T("../range").Range,o=T("../lib/event"),u=T("../lib/lang"),l=T("../lib/dom"),_=T("../config").nls,R=T("./../lib/useragent"),f=function(M){return"suggest-aria-id:".concat(M)},Z=R.isSafari?"menu":"listbox",j=R.isSafari?"menuitem":"option",H=R.isSafari?"aria-current":"aria-selected",ie=function(M){var w=new m(M);w.$maxLines=4;var y=new D(w);return y.setHighlightActiveLine(!1),y.setShowPrintMargin(!1),y.renderer.setShowGutter(!1),y.renderer.setHighlightGutterLine(!1),y.$mouseHandler.$focusTimeout=0,y.$highlightTagPending=!0,y},le=function(){function M(w){var y=l.createElement("div"),p=ie(y);w&&w.appendChild(y),y.style.display="none",p.renderer.content.style.cursor="default",p.renderer.setStyle("ace_autocomplete"),p.renderer.$textLayer.element.setAttribute("role",Z),p.renderer.$textLayer.element.setAttribute("aria-roledescription",_("autocomplete.popup.aria-roledescription","Autocomplete suggestions")),p.renderer.$textLayer.element.setAttribute("aria-label",_("autocomplete.popup.aria-label","Autocomplete suggestions")),p.renderer.textarea.setAttribute("aria-hidden","true"),p.setOption("displayIndentGuides",!1),p.setOption("dragDelay",150);var g=function(){};p.focus=g,p.$isFocused=!0,p.renderer.$cursorLayer.restartTimer=g,p.renderer.$cursorLayer.element.style.opacity="0",p.renderer.$maxLines=8,p.renderer.$keepTextAreaAtCursor=!1,p.setHighlightActiveLine(!1),p.session.highlight(""),p.session.$searchHighlight.clazz="ace_highlight-marker",p.on("mousedown",function(F){var I=F.getDocumentPosition();p.selection.moveToPosition(I),b.start.row=b.end.row=I.row,F.stop()});var d,x=new v(-1,0,-1,1/0),b=new v(-1,0,-1,1/0);b.id=p.session.addMarker(b,"ace_active-line","fullLine"),p.setSelectOnHover=function(F){F?x.id&&(p.session.removeMarker(x.id),x.id=null):x.id=p.session.addMarker(x,"ace_line-hover","fullLine")},p.setSelectOnHover(!1),p.on("mousemove",function(F){if(!d){d=F;return}if(!(d.x==F.x&&d.y==F.y)){d=F,d.scrollTop=p.renderer.scrollTop,p.isMouseOver=!0;var I=d.getDocumentPosition().row;x.start.row!=I&&(x.id||p.setRow(I),$(I))}}),p.renderer.on("beforeRender",function(){if(d&&x.start.row!=-1){d.$pos=null;var F=d.getDocumentPosition().row;x.id||p.setRow(F),$(F,!0)}}),p.renderer.on("afterRender",function(){var F=p.getRow(),I=p.renderer.$textLayer,U=I.element.childNodes[F-I.config.firstRow],re=document.activeElement;if(U!==p.selectedNode&&p.selectedNode&&(l.removeCssClass(p.selectedNode,"ace_selected"),re.removeAttribute("aria-activedescendant"),p.selectedNode.removeAttribute(H),p.selectedNode.removeAttribute("id")),p.selectedNode=U,U){l.addCssClass(U,"ace_selected");var X=f(F);U.id=X,I.element.setAttribute("aria-activedescendant",X),re.setAttribute("aria-activedescendant",X),U.setAttribute("role",j),U.setAttribute("aria-roledescription",_("autocomplete.popup.item.aria-roledescription","item")),U.setAttribute("aria-label",p.getData(F).caption||p.getData(F).value),U.setAttribute("aria-setsize",p.data.length),U.setAttribute("aria-posinset",F+1),U.setAttribute("aria-describedby","doc-tooltip"),U.setAttribute(H,"true")}});var B=function(){$(-1)},$=function(F,I){F!==x.start.row&&(x.start.row=x.end.row=F,I||p.session._emit("changeBackMarker"),p._emit("changeHoverMarker"))};p.getHoveredRow=function(){return x.start.row},o.addListener(p.container,"mouseout",function(){p.isMouseOver=!1,B()}),p.on("hide",B),p.on("changeSelection",B),p.session.doc.getLength=function(){return p.data.length},p.session.doc.getLine=function(F){var I=p.data[F];return typeof I=="string"?I:I&&I.value||""};var k=p.session.bgTokenizer;return k.$tokenizeRow=function(F){function I(ge,_e){ge&&re.push({type:(U.className||"")+(_e||""),value:ge})}var U=p.data[F],re=[];if(!U)return re;typeof U=="string"&&(U={value:U});for(var X=U.caption||U.value||U.name,ae=X.toLowerCase(),ce=(p.filterText||"").toLowerCase(),W=0,K=0,z=0;z<=ce.length;z++)if(z!=K&&(U.matchMask&1<=K?U="bottom":U="top"),U==="top"?(z.bottom=F.top-this.$borderSize,z.top=z.bottom-K):U==="bottom"&&(z.top=F.top+I+this.$borderSize,z.bottom=z.top+K);var ge=z.top>=0&&z.bottom<=ae;if(!re&&!ge)return!1;ge?W.$maxPixelHeight=null:U==="top"?W.$maxPixelHeight=Ve:W.$maxPixelHeight=G,U==="top"?(X.style.top="",X.style.bottom=ae-z.bottom+"px",p.isTopdown=!1):(X.style.top=z.top+"px",X.style.bottom="",p.isTopdown=!0),X.style.display="";var _e=F.left;return _e+X.offsetWidth>ce&&(_e=ce-X.offsetWidth),X.style.left=_e+"px",X.style.right="",p.isOpen||(p.isOpen=!0,this._signal("show"),d=null),p.anchorPos=F,p.anchor=U,!0},p.show=function(F,I,U){this.tryShow(F,I,U?"bottom":void 0,!0)},p.goTo=function(F){var I=this.getRow(),U=this.session.getLength()-1;switch(F){case"up":I=I<=0?U:I-1;break;case"down":I=I>=U?-1:I+1;break;case"start":I=0;break;case"end":I=U}this.setRow(I)},p.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},p.$imageSize=0,p.$borderSize=1,p}return M}();l.importCssString(` +.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line { + background-color: #CAD6FA; + z-index: 1; +} +.ace_dark.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line { + background-color: #3a674e; +} +.ace_editor.ace_autocomplete .ace_line-hover { + border: 1px solid #abbffe; + margin-top: -1px; + background: rgba(233,233,253,0.4); + position: absolute; + z-index: 2; +} +.ace_dark.ace_editor.ace_autocomplete .ace_line-hover { + border: 1px solid rgba(109, 150, 13, 0.8); + background: rgba(58, 103, 78, 0.62); +} +.ace_completion-meta { + opacity: 0.5; + margin-left: 0.9em; +} +.ace_completion-message { + margin-left: 0.9em; + color: blue; +} +.ace_editor.ace_autocomplete .ace_completion-highlight{ + color: #2d69c7; +} +.ace_dark.ace_editor.ace_autocomplete .ace_completion-highlight{ + color: #93ca12; +} +.ace_editor.ace_autocomplete { + width: 300px; + z-index: 200000; + border: 1px lightgray solid; + position: fixed; + box-shadow: 2px 3px 5px rgba(0,0,0,.2); + line-height: 1.4; + background: #fefefe; + color: #111; +} +.ace_dark.ace_editor.ace_autocomplete { + border: 1px #484747 solid; + box-shadow: 2px 3px 5px rgba(0, 0, 0, 0.51); + line-height: 1.4; + background: #25282c; + color: #c1c1c1; +} +.ace_autocomplete .ace_text-layer { + width: calc(100% - 8px); +} +.ace_autocomplete .ace_line { + display: flex; + align-items: center; +} +.ace_autocomplete .ace_line > * { + min-width: 0; + flex: 0 0 auto; +} +.ace_autocomplete .ace_line .ace_ { + flex: 0 1 auto; + overflow: hidden; + text-overflow: ellipsis; +} +.ace_autocomplete .ace_completion-spacer { + flex: 1; +} +.ace_autocomplete.ace_loading:after { + content: ""; + position: absolute; + top: 0px; + height: 2px; + width: 8%; + background: blue; + z-index: 100; + animation: ace_progress 3s infinite linear; + animation-delay: 300ms; + transform: translateX(-100%) scaleX(1); +} +@keyframes ace_progress { + 0% { transform: translateX(-100%) scaleX(1) } + 50% { transform: translateX(625%) scaleX(2) } + 100% { transform: translateX(1500%) scaleX(3) } +} +@media (prefers-reduced-motion) { + .ace_autocomplete.ace_loading:after { + transform: translateX(625%) scaleX(2); + animation: none; + } +} +`,"autocompletion.css",!1),n.AcePopup=le,n.$singleLineEditor=ie,n.getAriaId=f}),ace.define("ace/autocomplete/inline_screenreader",["require","exports","module"],function(T,n,C){"use strict";var m=function(){function D(v){this.editor=v,this.screenReaderDiv=document.createElement("div"),this.screenReaderDiv.classList.add("ace_screenreader-only"),this.editor.container.appendChild(this.screenReaderDiv)}return D.prototype.setScreenReaderContent=function(v){for(!this.popup&&this.editor.completer&&this.editor.completer.popup&&(this.popup=this.editor.completer.popup,this.popup.renderer.on("afterRender",function(){var u=this.popup.getRow(),l=this.popup.renderer.$textLayer,_=l.element.childNodes[u-l.config.firstRow];if(_){for(var R="doc-tooltip ",f=0;f=0&&o.test(D[l]);l--)u.push(D[l]);return u.reverse().join("")},n.retrieveFollowingIdentifier=function(D,v,o){o=o||m;for(var u=[],l=v;l0)for(var p=this.popup.getFirstVisibleRow();p<=this.popup.getLastVisibleRow();p++){var g=this.popup.getData(p);g&&(!y||g.hideInlinePreview)&&this.$seen(g)}},w.prototype.$onPopupShow=function(y){this.$onPopupChange(y),this.stickySelection=!1,this.stickySelectionDelay>=0&&this.stickySelectionTimer.schedule(this.stickySelectionDelay)},w.prototype.observeLayoutChanges=function(){if(!(this.$elements||!this.editor)){window.addEventListener("resize",this.onLayoutChange,{passive:!0}),window.addEventListener("wheel",this.mousewheelListener);for(var y=this.editor.container.parentNode,p=[];y;)p.push(y),y.addEventListener("scroll",this.onLayoutChange,{passive:!0}),y=y.parentNode;this.$elements=p}},w.prototype.unObserveLayoutChanges=function(){var y=this;window.removeEventListener("resize",this.onLayoutChange,{passive:!0}),window.removeEventListener("wheel",this.mousewheelListener),this.$elements&&this.$elements.forEach(function(p){p.removeEventListener("scroll",y.onLayoutChange,{passive:!0})}),this.$elements=null},w.prototype.onLayoutChange=function(){if(!this.popup.isOpen)return this.unObserveLayoutChanges();this.$updatePopupPosition(),this.updateDocTooltip()},w.prototype.$updatePopupPosition=function(){var y=this.editor,p=y.renderer,g=p.layerConfig.lineHeight,d=p.$cursorLayer.getPixelPosition(this.base,!0);d.left-=this.popup.getTextLeftOffset();var x=y.container.getBoundingClientRect();d.top+=x.top-p.layerConfig.offset,d.left+=x.left-y.renderer.scrollLeft,d.left+=p.gutterWidth;var b={top:d.top,left:d.left};p.$ghostText&&p.$ghostTextWidget&&this.base.row===p.$ghostText.position.row&&(b.top+=p.$ghostTextWidget.el.offsetHeight);var B=y.container.getBoundingClientRect().bottom-g,$=Bthis.filterText&&y.lastIndexOf(this.filterText,0)===0)var p=this.filtered;else var p=this.all;this.filterText=y,p=this.filterCompletions(p,this.filterText),p=p.sort(function(d,x){return x.exactMatch-d.exactMatch||x.$score-d.$score||(d.caption||d.value).localeCompare(x.caption||x.value)});var g=null;p=p.filter(function(d){var x=d.snippet||d.caption||d.value;return x===g?!1:(g=x,!0)}),this.filtered=p},w.prototype.filterCompletions=function(y,p){var g=[],d=p.toUpperCase(),x=p.toLowerCase();e:for(var b=0,B;B=y[b];b++){var $=!this.ignoreCaption&&B.caption||B.value||B.snippet;if($){var k=-1,F=0,I=0,U,re;if(this.exactMatch){if(p!==$.substr(0,p.length))continue e}else{var X=$.toLowerCase().indexOf(x);if(X>-1)I=X;else for(var ae=0;ae=0&&(W<0||ce0&&(k===-1&&(I+=10),I+=re,F|=1<",o.escapeHTML(d.caption),"","
",o.escapeHTML(R(d.snippet))].join(""))},id:"snippetCompleter"},Z=[f,l,_];n.setCompleters=function(d){Z.length=0,d&&Z.push.apply(Z,d)},n.addCompleter=function(d){Z.push(d)},n.textCompleter=l,n.keyWordCompleter=_,n.snippetCompleter=f;var j={name:"expandSnippet",exec:function(d){return m.expandWithTab(d)},bindKey:"Tab"},H=function(d,x){ie(x.session.$mode)},ie=function(d){typeof d=="string"&&(d=v.$modes[d]),d&&(m.files||(m.files={}),le(d.$id,d.snippetFileId),d.modes&&d.modes.forEach(ie))},le=function(d,x){!x||!d||m.files[d]||(m.files[d]={},v.loadModule(x,function(b){b&&(m.files[d]=b,!b.snippets&&b.snippetText&&(b.snippets=m.parseSnippetFile(b.snippetText)),m.register(b.snippets||[],b.scope),b.includeScopes&&(m.snippetMap[b.scope].includeScopes=b.includeScopes,b.includeScopes.forEach(function(B){ie("ace/mode/"+B)})))}))},M=function(d){var x=d.editor,b=x.completer&&x.completer.activated;if(d.command.name==="backspace")b&&!u.getCompletionPrefix(x)&&x.completer.detach();else if(d.command.name==="insertstring"&&!b){w=d;var B=d.editor.$liveAutocompletionDelay;B?y.delay(B):p(d)}},w,y=o.delayedCall(function(){p(w)},0),p=function(d){var x=d.editor,b=u.getCompletionPrefix(x),B=d.args,$=u.triggerAutocomplete(x,B);if(b&&b.length>=x.$liveAutocompletionThreshold||$){var k=D.for(x);k.autoShown=!0,k.showPopup(x)}},g=T("../editor").Editor;T("../config").defineOptions(g.prototype,"editor",{enableBasicAutocompletion:{set:function(d){d?(this.completers||(this.completers=Array.isArray(d)?d:Z),this.commands.addCommand(D.startCommand)):this.commands.removeCommand(D.startCommand)},value:!1},enableLiveAutocompletion:{set:function(d){d?(this.completers||(this.completers=Array.isArray(d)?d:Z),this.commands.on("afterExec",M)):this.commands.off("afterExec",M)},value:!1},liveAutocompletionDelay:{initialValue:0},liveAutocompletionThreshold:{initialValue:0},enableSnippets:{set:function(d){d?(this.commands.addCommand(j),this.on("changeMode",H),H(null,this)):(this.commands.removeCommand(j),this.off("changeMode",H))},value:!1}})}),function(){ace.require(["ace/ext/language_tools"],function(T){V&&(V.exports=T)})}()},7726:(V,ee,Y)=>{V=Y.nmd(V),ace.define("ace/mode/json_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(T,n,C){"use strict";var m=T("../lib/oop"),D=T("./text_highlight_rules").TextHighlightRules,v=function(){this.$rules={start:[{token:"variable",regex:'["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]\\s*(?=:)'},{token:"string",regex:'"',next:"string"},{token:"constant.numeric",regex:"0[xX][0-9a-fA-F]+\\b"},{token:"constant.numeric",regex:"[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"},{token:"constant.language.boolean",regex:"(?:true|false)\\b"},{token:"text",regex:"['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"},{token:"comment",regex:"\\/\\/.*$"},{token:"comment.start",regex:"\\/\\*",next:"comment"},{token:"paren.lparen",regex:"[[({]"},{token:"paren.rparen",regex:"[\\])}]"},{token:"punctuation.operator",regex:/[,]/},{token:"text",regex:"\\s+"}],string:[{token:"constant.language.escape",regex:/\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|["\\\/bfnrt])/},{token:"string",regex:'"|$',next:"start"},{defaultToken:"string"}],comment:[{token:"comment.end",regex:"\\*\\/",next:"start"},{defaultToken:"comment"}]}};m.inherits(v,D),n.JsonHighlightRules=v}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(T,n,C){"use strict";var m=T("../range").Range,D=function(){};(function(){this.checkOutdent=function(v,o){return/^\s+$/.test(v)?/^\s*\}/.test(o):!1},this.autoOutdent=function(v,o){var u=v.getLine(o),l=u.match(/^(\s*\})/);if(!l)return 0;var _=l[1].length,R=v.findMatchingBracket({row:o,column:_});if(!R||R.row==o)return 0;var f=this.$getIndent(v.getLine(R.row));v.replace(new m(o,0,o,_-1),f)},this.$getIndent=function(v){return v.match(/^\s*/)[0]}}).call(D.prototype),n.MatchingBraceOutdent=D}),ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(T,n,C){"use strict";var m=T("../../lib/oop"),D=T("../../range").Range,v=T("./fold_mode").FoldMode,o=n.FoldMode=function(u){u&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+u.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+u.end)))};m.inherits(o,v),function(){this.foldingStartMarker=/([\{\[\(])[^\}\]\)]*$|^\s*(\/\*)/,this.foldingStopMarker=/^[^\[\{\(]*([\}\]\)])|^[\s\*]*(\*\/)/,this.singleLineBlockCommentRe=/^\s*(\/\*).*\*\/\s*$/,this.tripleStarBlockCommentRe=/^\s*(\/\*\*\*).*\*\/\s*$/,this.startRegionRe=/^\s*(\/\*|\/\/)#?region\b/,this._getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(u,l,_){var R=u.getLine(_);if(this.singleLineBlockCommentRe.test(R)&&!this.startRegionRe.test(R)&&!this.tripleStarBlockCommentRe.test(R))return"";var f=this._getFoldWidgetBase(u,l,_);return!f&&this.startRegionRe.test(R)?"start":f},this.getFoldWidgetRange=function(u,l,_,R){var f=u.getLine(_);if(this.startRegionRe.test(f))return this.getCommentRegionBlock(u,f,_);var H=f.match(this.foldingStartMarker);if(H){var Z=H.index;if(H[1])return this.openingBracketBlock(u,H[1],_,Z);var j=u.getCommentFoldRange(_,Z+H[0].length,1);return j&&!j.isMultiLine()&&(R?j=this.getSectionRange(u,_):l!="all"&&(j=null)),j}if(l!=="markbegin"){var H=f.match(this.foldingStopMarker);if(H){var Z=H.index+H[0].length;return H[1]?this.closingBracketBlock(u,H[1],_,Z):u.getCommentFoldRange(_,Z,-1)}}},this.getSectionRange=function(u,l){var _=u.getLine(l),R=_.search(/\S/),f=l,Z=_.length;l+=1;for(var j=l,H=u.getLength();++lie)break;var le=this.getFoldWidgetRange(u,"all",l);if(le){if(le.start.row<=f)break;if(le.isMultiLine())l=le.end.row;else if(R==ie)break}j=l}}return new D(f,Z,j,u.getLine(j).length)},this.getCommentRegionBlock=function(u,l,_){for(var R=l.search(/\s*$/),f=u.getLength(),Z=_,j=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/,H=1;++_Z)return new D(Z,R,le,l.length)}}.call(o.prototype)}),ace.define("ace/mode/json",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/json_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/folding/cstyle","ace/worker/worker_client"],function(T,n,C){"use strict";var m=T("../lib/oop"),D=T("./text").Mode,v=T("./json_highlight_rules").JsonHighlightRules,o=T("./matching_brace_outdent").MatchingBraceOutdent,u=T("./folding/cstyle").FoldMode,l=T("../worker/worker_client").WorkerClient,_=function(){this.HighlightRules=v,this.$outdent=new o,this.$behaviour=this.$defaultBehaviour,this.foldingRules=new u};m.inherits(_,D),function(){this.lineCommentStart="//",this.blockComment={start:"/*",end:"*/"},this.getNextLineIndent=function(R,f,Z){var j=this.$getIndent(f);if(R=="start"){var H=f.match(/^.*[\{\(\[]\s*$/);H&&(j+=Z)}return j},this.checkOutdent=function(R,f,Z){return this.$outdent.checkOutdent(f,Z)},this.autoOutdent=function(R,f,Z){this.$outdent.autoOutdent(f,Z)},this.createWorker=function(R){var f=new l(["ace"],"ace/mode/json_worker","JsonWorker");return f.attachToDocument(R.getDocument()),f.on("annotate",function(Z){R.setAnnotations(Z.data)}),f.on("terminate",function(){R.clearAnnotations()}),f},this.$id="ace/mode/json"}.call(_.prototype),n.Mode=_}),function(){ace.require(["ace/mode/json"],function(T){V&&(V.exports=T)})}()},4210:(V,ee,Y)=>{V=Y.nmd(V),ace.define("ace/theme/chrome-css",["require","exports","module"],function(T,n,C){C.exports=`.ace-chrome .ace_gutter { + background: #ebebeb; + color: #333; + overflow : hidden; +} + +.ace-chrome .ace_print-margin { + width: 1px; + background: #e8e8e8; +} + +.ace-chrome { + background-color: #FFFFFF; + color: black; +} + +.ace-chrome .ace_cursor { + color: black; +} + +.ace-chrome .ace_invisible { + color: rgb(191, 191, 191); +} + +.ace-chrome .ace_constant.ace_buildin { + color: rgb(88, 72, 246); +} + +.ace-chrome .ace_constant.ace_language { + color: rgb(88, 92, 246); +} + +.ace-chrome .ace_constant.ace_library { + color: rgb(6, 150, 14); +} + +.ace-chrome .ace_invalid { + background-color: rgb(153, 0, 0); + color: white; +} + +.ace-chrome .ace_fold { +} + +.ace-chrome .ace_support.ace_function { + color: rgb(60, 76, 114); +} + +.ace-chrome .ace_support.ace_constant { + color: rgb(6, 150, 14); +} + +.ace-chrome .ace_support.ace_type, +.ace-chrome .ace_support.ace_class +.ace-chrome .ace_support.ace_other { + color: rgb(109, 121, 222); +} + +.ace-chrome .ace_variable.ace_parameter { + font-style:italic; + color:#FD971F; +} +.ace-chrome .ace_keyword.ace_operator { + color: rgb(104, 118, 135); +} + +.ace-chrome .ace_comment { + color: #236e24; +} + +.ace-chrome .ace_comment.ace_doc { + color: #236e24; +} + +.ace-chrome .ace_comment.ace_doc.ace_tag { + color: #236e24; +} + +.ace-chrome .ace_constant.ace_numeric { + color: rgb(0, 0, 205); +} + +.ace-chrome .ace_variable { + color: rgb(49, 132, 149); +} + +.ace-chrome .ace_xml-pe { + color: rgb(104, 104, 91); +} + +.ace-chrome .ace_entity.ace_name.ace_function { + color: #0000A2; +} + + +.ace-chrome .ace_heading { + color: rgb(12, 7, 255); +} + +.ace-chrome .ace_list { + color:rgb(185, 6, 144); +} + +.ace-chrome .ace_marker-layer .ace_selection { + background: rgb(181, 213, 255); +} + +.ace-chrome .ace_marker-layer .ace_step { + background: rgb(252, 255, 0); +} + +.ace-chrome .ace_marker-layer .ace_stack { + background: rgb(164, 229, 101); +} + +.ace-chrome .ace_marker-layer .ace_bracket { + margin: -1px 0 0 -1px; + border: 1px solid rgb(192, 192, 192); +} + +.ace-chrome .ace_marker-layer .ace_active-line { + background: rgba(0, 0, 0, 0.07); +} + +.ace-chrome .ace_gutter-active-line { + background-color : #dcdcdc; +} + +.ace-chrome .ace_marker-layer .ace_selected-word { + background: rgb(250, 250, 255); + border: 1px solid rgb(200, 200, 250); +} + +.ace-chrome .ace_storage, +.ace-chrome .ace_keyword, +.ace-chrome .ace_meta.ace_tag { + color: rgb(147, 15, 128); +} + +.ace-chrome .ace_string.ace_regex { + color: rgb(255, 0, 0) +} + +.ace-chrome .ace_string { + color: #1A1AA6; +} + +.ace-chrome .ace_entity.ace_other.ace_attribute-name { + color: #994409; +} + +.ace-chrome .ace_indent-guide { + background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y; +} + +.ace-chrome .ace_indent-guide-active { + background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAAZSURBVHjaYvj///9/hivKyv8BAAAA//8DACLqBhbvk+/eAAAAAElFTkSuQmCC") right repeat-y; +} +`}),ace.define("ace/theme/chrome",["require","exports","module","ace/theme/chrome-css","ace/lib/dom"],function(T,n,C){n.isDark=!1,n.cssClass="ace-chrome",n.cssText=T("./chrome-css");var m=T("../lib/dom");m.importCssString(n.cssText,n.cssClass,!1)}),function(){ace.require(["ace/theme/chrome"],function(T){V&&(V.exports=T)})}()},9285:(V,ee,Y)=>{V=Y.nmd(V),ace.define("ace/theme/clouds_midnight-css",["require","exports","module"],function(T,n,C){C.exports=`.ace-clouds-midnight .ace_gutter { + background: #232323; + color: #929292 +} + +.ace-clouds-midnight .ace_print-margin { + width: 1px; + background: #232323 +} + +.ace-clouds-midnight { + background-color: #191919; + color: #929292 +} + +.ace-clouds-midnight .ace_cursor { + color: #7DA5DC +} + +.ace-clouds-midnight .ace_marker-layer .ace_selection { + background: #000000 +} + +.ace-clouds-midnight.ace_multiselect .ace_selection.ace_start { + box-shadow: 0 0 3px 0px #191919; +} + +.ace-clouds-midnight .ace_marker-layer .ace_step { + background: rgb(102, 82, 0) +} + +.ace-clouds-midnight .ace_marker-layer .ace_bracket { + margin: -1px 0 0 -1px; + border: 1px solid #BFBFBF +} + +.ace-clouds-midnight .ace_marker-layer .ace_active-line { + background: rgba(215, 215, 215, 0.031) +} + +.ace-clouds-midnight .ace_gutter-active-line { + background-color: rgba(215, 215, 215, 0.031) +} + +.ace-clouds-midnight .ace_marker-layer .ace_selected-word { + border: 1px solid #000000 +} + +.ace-clouds-midnight .ace_invisible { + color: #666 +} + +.ace-clouds-midnight .ace_keyword, +.ace-clouds-midnight .ace_meta, +.ace-clouds-midnight .ace_support.ace_constant.ace_property-value { + color: #927C5D +} + +.ace-clouds-midnight .ace_keyword.ace_operator { + color: #4B4B4B +} + +.ace-clouds-midnight .ace_keyword.ace_other.ace_unit { + color: #366F1A +} + +.ace-clouds-midnight .ace_constant.ace_language { + color: #39946A +} + +.ace-clouds-midnight .ace_constant.ace_numeric { + color: #46A609 +} + +.ace-clouds-midnight .ace_constant.ace_character.ace_entity { + color: #A165AC +} + +.ace-clouds-midnight .ace_invalid { + color: #FFFFFF; + background-color: #E92E2E +} + +.ace-clouds-midnight .ace_fold { + background-color: #927C5D; + border-color: #929292 +} + +.ace-clouds-midnight .ace_storage, +.ace-clouds-midnight .ace_support.ace_class, +.ace-clouds-midnight .ace_support.ace_function, +.ace-clouds-midnight .ace_support.ace_other, +.ace-clouds-midnight .ace_support.ace_type { + color: #E92E2E +} + +.ace-clouds-midnight .ace_string { + color: #5D90CD +} + +.ace-clouds-midnight .ace_comment { + color: #3C403B +} + +.ace-clouds-midnight .ace_entity.ace_name.ace_tag, +.ace-clouds-midnight .ace_entity.ace_other.ace_attribute-name { + color: #606060 +} + +.ace-clouds-midnight .ace_indent-guide { + background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYHB3d/8PAAOIAdULw8qMAAAAAElFTkSuQmCC) right repeat-y +} + +.ace-clouds-midnight .ace_indent-guide-active { + background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQIW2PQ1dX9zzBz5sz/ABCcBFFentLlAAAAAElFTkSuQmCC) right repeat-y; +} +`}),ace.define("ace/theme/clouds_midnight",["require","exports","module","ace/theme/clouds_midnight-css","ace/lib/dom"],function(T,n,C){n.isDark=!0,n.cssClass="ace-clouds-midnight",n.cssText=T("./clouds_midnight-css");var m=T("../lib/dom");m.importCssString(n.cssText,n.cssClass,!1)}),function(){ace.require(["ace/theme/clouds_midnight"],function(T){V&&(V.exports=T)})}()},1197:function(){"no use strict";(function(V){function ee(n,C){for(var m=n,D="";m;){var v=C[m];if(typeof v=="string")return v+D;if(v)return v.location.replace(/\/*$/,"/")+(D||v.main||v.name);if(v===!1)return"";var o=m.lastIndexOf("/");if(o===-1)break;D=m.substr(o)+D,m=m.slice(0,o)}return n}if(!(typeof V.window!="undefined"&&V.document)&&!(V.require&&V.define)){V.console||(V.console=function(){var n=Array.prototype.slice.call(arguments,0);postMessage({type:"log",data:n})},V.console.error=V.console.warn=V.console.log=V.console.trace=V.console),V.window=V,V.ace=V,V.onerror=function(n,C,m,D,v){postMessage({type:"error",data:{message:n,data:v&&v.data,file:C,line:m,col:D,stack:v&&v.stack}})},V.normalizeModule=function(n,C){if(C.indexOf("!")!==-1){var m=C.split("!");return V.normalizeModule(n,m[0])+"!"+V.normalizeModule(n,m[1])}if(C.charAt(0)=="."){var D=n.split("/").slice(0,-1).join("/");for(C=(D?D+"/":"")+C;C.indexOf(".")!==-1&&v!=C;){var v=C;C=C.replace(/^\.\//,"").replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return C},V.require=function(n,C){if(C||(C=n,n=null),!C.charAt)throw new Error("worker.js require() accepts only (parentId, id) as arguments");C=V.normalizeModule(n,C);var m=V.require.modules[C];if(m)return m.initialized||(m.initialized=!0,m.exports=m.factory().exports),m.exports;if(!V.require.tlns)return console.log("unable to load "+C);var D=ee(C,V.require.tlns);return D.slice(-3)!=".js"&&(D+=".js"),V.require.id=C,V.require.modules[C]={},importScripts(D),V.require(n,C)},V.require.modules={},V.require.tlns={},V.define=function(n,C,m){if(arguments.length==2?(m=C,typeof n!="string"&&(C=n,n=V.require.id)):arguments.length==1&&(m=n,C=[],n=V.require.id),typeof m!="function"){V.require.modules[n]={exports:m,initialized:!0};return}C.length||(C=["require","exports","module"]);var D=function(v){return V.require(n,v)};V.require.modules[n]={exports:{},factory:function(){var v=this,o=m.apply(this,C.slice(0,m.length).map(function(u){switch(u){case"require":return D;case"exports":return v.exports;case"module":return v;default:return D(u)}}));return o&&(v.exports=o),v}}},V.define.amd={},V.require.tlns={},V.initBaseUrls=function(n){for(var C in n)this.require.tlns[C]=n[C]},V.initSender=function(){var n=V.require("ace/lib/event_emitter").EventEmitter,C=V.require("ace/lib/oop"),m=function(){};return function(){C.implement(this,n),this.callback=function(D,v){postMessage({type:"call",id:v,data:D})},this.emit=function(D,v){postMessage({type:"event",name:D,data:v})}}.call(m.prototype),new m};var Y=V.main=null,T=V.sender=null;V.onmessage=function(n){var C=n.data;if(C.event&&T)T._signal(C.event,C.data);else if(C.command)if(Y[C.command])Y[C.command].apply(Y,C.args);else{if(!V[C.command])throw new Error("Unknown command:"+C.command);V[C.command].apply(V,C.args)}else if(C.init){V.initBaseUrls(C.tlns),T=V.sender=V.initSender();var m=this.require(C.module)[C.classname];Y=V.main=new m(T)}}}})(this),ace.define("ace/lib/oop",[],function(V,ee,Y){"use strict";ee.inherits=function(T,n){T.super_=n,T.prototype=Object.create(n.prototype,{constructor:{value:T,enumerable:!1,writable:!0,configurable:!0}})},ee.mixin=function(T,n){for(var C in n)T[C]=n[C];return T},ee.implement=function(T,n){ee.mixin(T,n)}}),ace.define("ace/apply_delta",[],function(V,ee,Y){"use strict";function T(m,D){throw console.log("Invalid Delta:",m),"Invalid Delta: "+D}function n(m,D){return D.row>=0&&D.row=0&&D.column<=m[D.row].length}function C(m,D){D.action!="insert"&&D.action!="remove"&&T(D,"delta.action must be 'insert' or 'remove'"),D.lines instanceof Array||T(D,"delta.lines must be an Array"),(!D.start||!D.end)&&T(D,"delta.start/end must be an present");var v=D.start;n(m,D.start)||T(D,"delta.start must be contained in document");var o=D.end;D.action=="remove"&&!n(m,o)&&T(D,"delta.end must contained in document for 'remove' actions");var u=o.row-v.row,l=o.column-(u==0?v.column:0);(u!=D.lines.length-1||D.lines[u].length!=l)&&T(D,"delta.range must match delta lines")}ee.applyDelta=function(m,D,v){var o=D.start.row,u=D.start.column,l=m[o]||"";switch(D.action){case"insert":var _=D.lines;if(_.length===1)m[o]=l.substring(0,u)+D.lines[0]+l.substring(u);else{var R=[o,1].concat(D.lines);m.splice.apply(m,R),m[o]=l.substring(0,u)+m[o],m[o+D.lines.length-1]+=l.substring(u)}break;case"remove":var f=D.end.column,Z=D.end.row;o===Z?m[o]=l.substring(0,u)+l.substring(f):m.splice(o,Z-o+1,l.substring(0,u)+m[Z].substring(f))}}}),ace.define("ace/lib/event_emitter",[],function(V,ee,Y){"use strict";var T={},n=function(){this.propagationStopped=!0},C=function(){this.defaultPrevented=!0};T._emit=T._dispatchEvent=function(m,D){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var v=this._eventRegistry[m]||[],o=this._defaultHandlers[m];if(!(!v.length&&!o)){(typeof D!="object"||!D)&&(D={}),D.type||(D.type=m),D.stopPropagation||(D.stopPropagation=n),D.preventDefault||(D.preventDefault=C),v=v.slice();for(var u=0;u ["+this.end.row+"/"+this.end.column+"]"},n.prototype.contains=function(C,m){return this.compare(C,m)==0},n.prototype.compareRange=function(C){var m,D=C.end,v=C.start;return m=this.compare(D.row,D.column),m==1?(m=this.compare(v.row,v.column),m==1?2:m==0?1:0):m==-1?-2:(m=this.compare(v.row,v.column),m==-1?-1:m==1?42:0)},n.prototype.comparePoint=function(C){return this.compare(C.row,C.column)},n.prototype.containsRange=function(C){return this.comparePoint(C.start)==0&&this.comparePoint(C.end)==0},n.prototype.intersects=function(C){var m=this.compareRange(C);return m==-1||m==0||m==1},n.prototype.isEnd=function(C,m){return this.end.row==C&&this.end.column==m},n.prototype.isStart=function(C,m){return this.start.row==C&&this.start.column==m},n.prototype.setStart=function(C,m){typeof C=="object"?(this.start.column=C.column,this.start.row=C.row):(this.start.row=C,this.start.column=m)},n.prototype.setEnd=function(C,m){typeof C=="object"?(this.end.column=C.column,this.end.row=C.row):(this.end.row=C,this.end.column=m)},n.prototype.inside=function(C,m){return this.compare(C,m)==0?!(this.isEnd(C,m)||this.isStart(C,m)):!1},n.prototype.insideStart=function(C,m){return this.compare(C,m)==0?!this.isEnd(C,m):!1},n.prototype.insideEnd=function(C,m){return this.compare(C,m)==0?!this.isStart(C,m):!1},n.prototype.compare=function(C,m){return!this.isMultiLine()&&C===this.start.row?mthis.end.column?1:0:Cthis.end.row?1:this.start.row===C?m>=this.start.column?0:-1:this.end.row===C?m<=this.end.column?0:1:0},n.prototype.compareStart=function(C,m){return this.start.row==C&&this.start.column==m?-1:this.compare(C,m)},n.prototype.compareEnd=function(C,m){return this.end.row==C&&this.end.column==m?1:this.compare(C,m)},n.prototype.compareInside=function(C,m){return this.end.row==C&&this.end.column==m?1:this.start.row==C&&this.start.column==m?-1:this.compare(C,m)},n.prototype.clipRows=function(C,m){if(this.end.row>m)var D={row:m+1,column:0};else if(this.end.rowm)var v={row:m+1,column:0};else if(this.start.rowthis.row)){var u=n(o,{row:this.row,column:this.column},this.$insertRight);this.setPosition(u.row,u.column,!0)}},v.prototype.setPosition=function(o,u,l){var _;if(l?_={row:o,column:u}:_=this.$clipPositionToDocument(o,u),!(this.row==_.row&&this.column==_.column)){var R={row:this.row,column:this.column};this.row=_.row,this.column=_.column,this._signal("change",{old:R,value:_})}},v.prototype.detach=function(){this.document.off("change",this.$onChange)},v.prototype.attach=function(o){this.document=o||this.document,this.document.on("change",this.$onChange)},v.prototype.$clipPositionToDocument=function(o,u){var l={};return o>=this.document.getLength()?(l.row=Math.max(0,this.document.getLength()-1),l.column=this.document.getLine(l.row).length):o<0?(l.row=0,l.column=0):(l.row=o,l.column=Math.min(this.document.getLine(l.row).length,Math.max(0,u))),u<0&&(l.column=0),l},v}();D.prototype.$insertRight=!1,C.implement(D.prototype,m),ee.Anchor=D}),ace.define("ace/document",[],function(V,ee,Y){"use strict";var T=V("./lib/oop"),n=V("./apply_delta").applyDelta,C=V("./lib/event_emitter").EventEmitter,m=V("./range").Range,D=V("./anchor").Anchor,v=function(){function o(u){this.$lines=[""],u.length===0?this.$lines=[""]:Array.isArray(u)?this.insertMergedLines({row:0,column:0},u):this.insert({row:0,column:0},u)}return o.prototype.setValue=function(u){var l=this.getLength()-1;this.remove(new m(0,0,l,this.getLine(l).length)),this.insert({row:0,column:0},u||"")},o.prototype.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},o.prototype.createAnchor=function(u,l){return new D(this,u,l)},o.prototype.$detectNewLine=function(u){var l=u.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=l?l[1]:` +`,this._signal("changeNewLineMode")},o.prototype.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return`\r +`;case"unix":return` +`;default:return this.$autoNewLine||` +`}},o.prototype.setNewLineMode=function(u){this.$newLineMode!==u&&(this.$newLineMode=u,this._signal("changeNewLineMode"))},o.prototype.getNewLineMode=function(){return this.$newLineMode},o.prototype.isNewLine=function(u){return u==`\r +`||u=="\r"||u==` +`},o.prototype.getLine=function(u){return this.$lines[u]||""},o.prototype.getLines=function(u,l){return this.$lines.slice(u,l+1)},o.prototype.getAllLines=function(){return this.getLines(0,this.getLength())},o.prototype.getLength=function(){return this.$lines.length},o.prototype.getTextRange=function(u){return this.getLinesForRange(u).join(this.getNewLineCharacter())},o.prototype.getLinesForRange=function(u){var l;if(u.start.row===u.end.row)l=[this.getLine(u.start.row).substring(u.start.column,u.end.column)];else{l=this.getLines(u.start.row,u.end.row),l[0]=(l[0]||"").substring(u.start.column);var _=l.length-1;u.end.row-u.start.row==_&&(l[_]=l[_].substring(0,u.end.column))}return l},o.prototype.insertLines=function(u,l){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(u,l)},o.prototype.removeLines=function(u,l){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(u,l)},o.prototype.insertNewLine=function(u){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(u,["",""])},o.prototype.insert=function(u,l){return this.getLength()<=1&&this.$detectNewLine(l),this.insertMergedLines(u,this.$split(l))},o.prototype.insertInLine=function(u,l){var _=this.clippedPos(u.row,u.column),R=this.pos(u.row,u.column+l.length);return this.applyDelta({start:_,end:R,action:"insert",lines:[l]},!0),this.clonePos(R)},o.prototype.clippedPos=function(u,l){var _=this.getLength();u===void 0?u=_:u<0?u=0:u>=_&&(u=_-1,l=void 0);var R=this.getLine(u);return l==null&&(l=R.length),l=Math.min(Math.max(l,0),R.length),{row:u,column:l}},o.prototype.clonePos=function(u){return{row:u.row,column:u.column}},o.prototype.pos=function(u,l){return{row:u,column:l}},o.prototype.$clipPosition=function(u){var l=this.getLength();return u.row>=l?(u.row=Math.max(0,l-1),u.column=this.getLine(l-1).length):(u.row=Math.max(0,u.row),u.column=Math.min(Math.max(u.column,0),this.getLine(u.row).length)),u},o.prototype.insertFullLines=function(u,l){u=Math.min(Math.max(u,0),this.getLength());var _=0;u0,R=l=0&&this.applyDelta({start:this.pos(u,this.getLine(u).length),end:this.pos(u+1,0),action:"remove",lines:["",""]})},o.prototype.replace=function(u,l){if(u instanceof m||(u=m.fromPoints(u.start,u.end)),l.length===0&&u.isEmpty())return u.start;if(l==this.getTextRange(u))return u.end;this.remove(u);var _;return l?_=this.insert(u.start,l):_=u.start,_},o.prototype.applyDeltas=function(u){for(var l=0;l=0;l--)this.revertDelta(u[l])},o.prototype.applyDelta=function(u,l){var _=u.action=="insert";(_?u.lines.length<=1&&!u.lines[0]:!m.comparePoints(u.start,u.end))||(_&&u.lines.length>2e4?this.$splitAndapplyLargeDelta(u,2e4):(n(this.$lines,u,l),this._signal("change",u)))},o.prototype.$safeApplyDelta=function(u){var l=this.$lines.length;(u.action=="remove"&&u.start.row0;)m&1&&(D+=C),(m>>=1)&&(C+=C);return D};var T=/^\s\s*/,n=/\s\s*$/;ee.stringTrimLeft=function(C){return C.replace(T,"")},ee.stringTrimRight=function(C){return C.replace(n,"")},ee.copyObject=function(C){var m={};for(var D in C)m[D]=C[D];return m},ee.copyArray=function(C){for(var m=[],D=0,v=C.length;D65535?2:1}}),ace.define("ace/worker/mirror",[],function(V,ee,Y){"use strict";var T=V("../document").Document,n=V("../lib/lang"),C=ee.Mirror=function(m){this.sender=m;var D=this.doc=new T(""),v=this.deferredUpdate=n.delayedCall(this.onUpdate.bind(this)),o=this;m.on("change",function(u){var l=u.data;if(l[0].start)D.applyDeltas(l);else for(var _=0;_=D.$lines.length)throw f=new Error("Invalid delta"),f.data={path:o.$path,linesLength:D.$lines.length,start:R.start,end:R.end},f;D.applyDelta(R,!0)}if(o.$timeout)return v.schedule(o.$timeout);o.onUpdate()})};(function(){this.$timeout=500,this.setTimeout=function(m){this.$timeout=m},this.setValue=function(m){this.doc.setValue(m),this.deferredUpdate.schedule(this.$timeout)},this.getValue=function(m){this.sender.callback(this.doc.getValue(),m)},this.onUpdate=function(){},this.isPending=function(){return this.deferredUpdate.isPending()}}).call(C.prototype)}),ace.define("ace/mode/json/json_parse",[],function(V,ee,Y){"use strict";var T,n,C={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:` +`,r:"\r",t:" "},m,D=function(j){throw{name:"SyntaxError",message:j,at:T,text:m}},v=function(j){return j&&j!==n&&D("Expected '"+j+"' instead of '"+n+"'"),n=m.charAt(T),T+=1,n},o=function(){var j,H="";for(n==="-"&&(H="-",v("-"));n>="0"&&n<="9";)H+=n,v();if(n===".")for(H+=".";v()&&n>="0"&&n<="9";)H+=n;if(n==="e"||n==="E")for(H+=n,v(),(n==="-"||n==="+")&&(H+=n,v());n>="0"&&n<="9";)H+=n,v();if(j=+H,!isNaN(j))return j;D("Bad number")},u=function(){var j,H,ie="",le;if(n==='"')for(;v();){if(n==='"')return v(),ie;if(n==="\\")if(v(),n==="u"){for(le=0,H=0;H<4&&(j=parseInt(v(),16),!!isFinite(j));H+=1)le=le*16+j;ie+=String.fromCharCode(le)}else{if(typeof C[n]!="string")break;ie+=C[n]}else{if(n==` +`||n=="\r")break;ie+=n}}D("Bad string")},l=function(){for(;n&&n<=" ";)v()},_=function(){switch(n){case"t":return v("t"),v("r"),v("u"),v("e"),!0;case"f":return v("f"),v("a"),v("l"),v("s"),v("e"),!1;case"n":return v("n"),v("u"),v("l"),v("l"),null}D("Unexpected '"+n+"'")},R,f=function(){var j=[];if(n==="["){if(v("["),l(),n==="]")return v("]"),j;for(;n;){if(j.push(R()),l(),n==="]")return v("]"),j;v(","),l()}}D("Bad array")},Z=function(){var j,H={};if(n==="{"){if(v("{"),l(),n==="}")return v("}"),H;for(;n;){if(j=u(),l(),v(":"),Object.hasOwnProperty.call(H,j)&&D('Duplicate key "'+j+'"'),H[j]=R(),l(),n==="}")return v("}"),H;v(","),l()}}D("Bad object")};return R=function(){switch(l(),n){case"{":return Z();case"[":return f();case'"':return u();case"-":return o();default:return n>="0"&&n<="9"?o():_()}},function(j,H){var ie;return m=j,T=0,n=" ",ie=R(),l(),n&&D("Syntax error"),typeof H=="function"?function le(M,w){var y,p,g=M[w];if(g&&typeof g=="object")for(y in g)Object.hasOwnProperty.call(g,y)&&(p=le(g,y),p!==void 0?g[y]=p:delete g[y]);return H.call(M,w,g)}({"":ie},""):ie}}),ace.define("ace/mode/json_worker",[],function(V,ee,Y){"use strict";var T=V("../lib/oop"),n=V("../worker/mirror").Mirror,C=V("./json/json_parse"),m=ee.JsonWorker=function(D){n.call(this,D),this.setTimeout(200)};T.inherits(m,n),function(){this.onUpdate=function(){var D=this.doc.getValue(),v=[];try{D&&C(D)}catch(u){var o=this.doc.indexToPosition(u.at-1);v.push({row:o.row,column:o.column,text:u.message,type:"error"})}this.sender.emit("annotate",v)}}.call(m.prototype)})},7051:function(V,ee,Y){(function(T,n){V.exports=ee=n()})(this,function(){var T=T||function(n,C){var m;if(typeof window!="undefined"&&window.crypto&&(m=window.crypto),typeof self!="undefined"&&self.crypto&&(m=self.crypto),typeof globalThis!="undefined"&&globalThis.crypto&&(m=globalThis.crypto),!m&&typeof window!="undefined"&&window.msCrypto&&(m=window.msCrypto),!m&&typeof Y.g!="undefined"&&Y.g.crypto&&(m=Y.g.crypto),!m)try{m=Y(477)}catch(M){}var D=function(){if(m){if(typeof m.getRandomValues=="function")try{return m.getRandomValues(new Uint32Array(1))[0]}catch(M){}if(typeof m.randomBytes=="function")try{return m.randomBytes(4).readInt32LE()}catch(M){}}throw new Error("Native crypto module could not be used to get secure random number.")},v=Object.create||function(){function M(){}return function(w){var y;return M.prototype=w,y=new M,M.prototype=null,y}}(),o={},u=o.lib={},l=u.Base=function(){return{extend:function(M){var w=v(this);return M&&w.mixIn(M),(!w.hasOwnProperty("init")||this.init===w.init)&&(w.init=function(){w.$super.init.apply(this,arguments)}),w.init.prototype=w,w.$super=this,w},create:function(){var M=this.extend();return M.init.apply(M,arguments),M},init:function(){},mixIn:function(M){for(var w in M)M.hasOwnProperty(w)&&(this[w]=M[w]);M.hasOwnProperty("toString")&&(this.toString=M.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),_=u.WordArray=l.extend({init:function(M,w){M=this.words=M||[],w!=C?this.sigBytes=w:this.sigBytes=M.length*4},toString:function(M){return(M||f).stringify(this)},concat:function(M){var w=this.words,y=M.words,p=this.sigBytes,g=M.sigBytes;if(this.clamp(),p%4)for(var d=0;d>>2]>>>24-d%4*8&255;w[p+d>>>2]|=x<<24-(p+d)%4*8}else for(var b=0;b>>2]=y[b>>>2];return this.sigBytes+=g,this},clamp:function(){var M=this.words,w=this.sigBytes;M[w>>>2]&=4294967295<<32-w%4*8,M.length=n.ceil(w/4)},clone:function(){var M=l.clone.call(this);return M.words=this.words.slice(0),M},random:function(M){for(var w=[],y=0;y>>2]>>>24-g%4*8&255;p.push((d>>>4).toString(16)),p.push((d&15).toString(16))}return p.join("")},parse:function(M){for(var w=M.length,y=[],p=0;p>>3]|=parseInt(M.substr(p,2),16)<<24-p%8*4;return new _.init(y,w/2)}},Z=R.Latin1={stringify:function(M){for(var w=M.words,y=M.sigBytes,p=[],g=0;g>>2]>>>24-g%4*8&255;p.push(String.fromCharCode(d))}return p.join("")},parse:function(M){for(var w=M.length,y=[],p=0;p>>2]|=(M.charCodeAt(p)&255)<<24-p%4*8;return new _.init(y,w)}},j=R.Utf8={stringify:function(M){try{return decodeURIComponent(escape(Z.stringify(M)))}catch(w){throw new Error("Malformed UTF-8 data")}},parse:function(M){return Z.parse(unescape(encodeURIComponent(M)))}},H=u.BufferedBlockAlgorithm=l.extend({reset:function(){this._data=new _.init,this._nDataBytes=0},_append:function(M){typeof M=="string"&&(M=j.parse(M)),this._data.concat(M),this._nDataBytes+=M.sigBytes},_process:function(M){var w,y=this._data,p=y.words,g=y.sigBytes,d=this.blockSize,x=d*4,b=g/x;M?b=n.ceil(b):b=n.max((b|0)-this._minBufferSize,0);var B=b*d,$=n.min(B*4,g);if(B){for(var k=0;k>>24)&16711935|(M<<24|M>>>8)&4278255360}var w=this._hash.words,y=j[H+0],p=j[H+1],g=j[H+2],d=j[H+3],x=j[H+4],b=j[H+5],B=j[H+6],$=j[H+7],k=j[H+8],F=j[H+9],I=j[H+10],U=j[H+11],re=j[H+12],X=j[H+13],ae=j[H+14],ce=j[H+15],W=w[0],K=w[1],z=w[2],G=w[3];W=_(W,K,z,G,y,7,u[0]),G=_(G,W,K,z,p,12,u[1]),z=_(z,G,W,K,g,17,u[2]),K=_(K,z,G,W,d,22,u[3]),W=_(W,K,z,G,x,7,u[4]),G=_(G,W,K,z,b,12,u[5]),z=_(z,G,W,K,B,17,u[6]),K=_(K,z,G,W,$,22,u[7]),W=_(W,K,z,G,k,7,u[8]),G=_(G,W,K,z,F,12,u[9]),z=_(z,G,W,K,I,17,u[10]),K=_(K,z,G,W,U,22,u[11]),W=_(W,K,z,G,re,7,u[12]),G=_(G,W,K,z,X,12,u[13]),z=_(z,G,W,K,ae,17,u[14]),K=_(K,z,G,W,ce,22,u[15]),W=R(W,K,z,G,p,5,u[16]),G=R(G,W,K,z,B,9,u[17]),z=R(z,G,W,K,U,14,u[18]),K=R(K,z,G,W,y,20,u[19]),W=R(W,K,z,G,b,5,u[20]),G=R(G,W,K,z,I,9,u[21]),z=R(z,G,W,K,ce,14,u[22]),K=R(K,z,G,W,x,20,u[23]),W=R(W,K,z,G,F,5,u[24]),G=R(G,W,K,z,ae,9,u[25]),z=R(z,G,W,K,d,14,u[26]),K=R(K,z,G,W,k,20,u[27]),W=R(W,K,z,G,X,5,u[28]),G=R(G,W,K,z,g,9,u[29]),z=R(z,G,W,K,$,14,u[30]),K=R(K,z,G,W,re,20,u[31]),W=f(W,K,z,G,b,4,u[32]),G=f(G,W,K,z,k,11,u[33]),z=f(z,G,W,K,U,16,u[34]),K=f(K,z,G,W,ae,23,u[35]),W=f(W,K,z,G,p,4,u[36]),G=f(G,W,K,z,x,11,u[37]),z=f(z,G,W,K,$,16,u[38]),K=f(K,z,G,W,I,23,u[39]),W=f(W,K,z,G,X,4,u[40]),G=f(G,W,K,z,y,11,u[41]),z=f(z,G,W,K,d,16,u[42]),K=f(K,z,G,W,B,23,u[43]),W=f(W,K,z,G,F,4,u[44]),G=f(G,W,K,z,re,11,u[45]),z=f(z,G,W,K,ce,16,u[46]),K=f(K,z,G,W,g,23,u[47]),W=Z(W,K,z,G,y,6,u[48]),G=Z(G,W,K,z,$,10,u[49]),z=Z(z,G,W,K,ae,15,u[50]),K=Z(K,z,G,W,b,21,u[51]),W=Z(W,K,z,G,re,6,u[52]),G=Z(G,W,K,z,d,10,u[53]),z=Z(z,G,W,K,I,15,u[54]),K=Z(K,z,G,W,p,21,u[55]),W=Z(W,K,z,G,k,6,u[56]),G=Z(G,W,K,z,ce,10,u[57]),z=Z(z,G,W,K,B,15,u[58]),K=Z(K,z,G,W,X,21,u[59]),W=Z(W,K,z,G,x,6,u[60]),G=Z(G,W,K,z,U,10,u[61]),z=Z(z,G,W,K,g,15,u[62]),K=Z(K,z,G,W,F,21,u[63]),w[0]=w[0]+W|0,w[1]=w[1]+K|0,w[2]=w[2]+z|0,w[3]=w[3]+G|0},_doFinalize:function(){var j=this._data,H=j.words,ie=this._nDataBytes*8,le=j.sigBytes*8;H[le>>>5]|=128<<24-le%32;var M=n.floor(ie/4294967296),w=ie;H[(le+64>>>9<<4)+15]=(M<<8|M>>>24)&16711935|(M<<24|M>>>8)&4278255360,H[(le+64>>>9<<4)+14]=(w<<8|w>>>24)&16711935|(w<<24|w>>>8)&4278255360,j.sigBytes=(H.length+1)*4,this._process();for(var y=this._hash,p=y.words,g=0;g<4;g++){var d=p[g];p[g]=(d<<8|d>>>24)&16711935|(d<<24|d>>>8)&4278255360}return y},clone:function(){var j=v.clone.call(this);return j._hash=this._hash.clone(),j}});function _(j,H,ie,le,M,w,y){var p=j+(H&ie|~H&le)+M+y;return(p<>>32-w)+H}function R(j,H,ie,le,M,w,y){var p=j+(H&le|ie&~le)+M+y;return(p<>>32-w)+H}function f(j,H,ie,le,M,w,y){var p=j+(H^ie^le)+M+y;return(p<>>32-w)+H}function Z(j,H,ie,le,M,w,y){var p=j+(ie^(H|~le))+M+y;return(p<>>32-w)+H}C.MD5=v._createHelper(l),C.HmacMD5=v._createHmacHelper(l)}(Math),T.MD5})},5589:function(V){(function(ee,Y){V.exports=Y()})(this,function(){"use strict";function ee(A,P){return P={exports:{}},A(P,P.exports),P.exports}var Y=ee(function(A){var P=A.exports=typeof window!="undefined"&&window.Math==Math?window:typeof self!="undefined"&&self.Math==Math?self:Function("return this")();typeof __g=="number"&&(__g=P)}),T=ee(function(A){var P=A.exports={version:"2.6.5"};typeof __e=="number"&&(__e=P)}),n=T.version,C=function(A){return typeof A=="object"?A!==null:typeof A=="function"},m=function(A){if(!C(A))throw TypeError(A+" is not an object!");return A},D=function(A){try{return!!A()}catch(P){return!0}},v=!D(function(){return Object.defineProperty({},"a",{get:function(){return 7}}).a!=7}),o=Y.document,u=C(o)&&C(o.createElement),l=function(A){return u?o.createElement(A):{}},_=!v&&!D(function(){return Object.defineProperty(l("div"),"a",{get:function(){return 7}}).a!=7}),R=function(A,P){if(!C(A))return A;var oe,ne;if(P&&typeof(oe=A.toString)=="function"&&!C(ne=oe.call(A))||typeof(oe=A.valueOf)=="function"&&!C(ne=oe.call(A))||!P&&typeof(oe=A.toString)=="function"&&!C(ne=oe.call(A)))return ne;throw TypeError("Can't convert object to primitive value")},f=Object.defineProperty,Z=v?Object.defineProperty:function(P,oe,ne){if(m(P),oe=R(oe,!0),m(ne),_)try{return f(P,oe,ne)}catch(ue){}if("get"in ne||"set"in ne)throw TypeError("Accessors not supported!");return"value"in ne&&(P[oe]=ne.value),P},j={f:Z},H=function(A,P){return{enumerable:!(A&1),configurable:!(A&2),writable:!(A&4),value:P}},ie=v?function(A,P,oe){return j.f(A,P,H(1,oe))}:function(A,P,oe){return A[P]=oe,A},le={}.hasOwnProperty,M=function(A,P){return le.call(A,P)},w=0,y=Math.random(),p=function(A){return"Symbol(".concat(A===void 0?"":A,")_",(++w+y).toString(36))},g=!1,d=ee(function(A){var P="__core-js_shared__",oe=Y[P]||(Y[P]={});(A.exports=function(ne,ue){return oe[ne]||(oe[ne]=ue!==void 0?ue:{})})("versions",[]).push({version:T.version,mode:g?"pure":"global",copyright:"\xA9 2019 Denis Pushkarev (zloirock.ru)"})}),x=d("native-function-to-string",Function.toString),b=ee(function(A){var P=p("src"),oe="toString",ne=(""+x).split(oe);T.inspectSource=function(ue){return x.call(ue)},(A.exports=function(ue,Ce,ve,Pe){var Te=typeof ve=="function";Te&&(M(ve,"name")||ie(ve,"name",Ce)),ue[Ce]!==ve&&(Te&&(M(ve,P)||ie(ve,P,ue[Ce]?""+ue[Ce]:ne.join(String(Ce)))),ue===Y?ue[Ce]=ve:Pe?ue[Ce]?ue[Ce]=ve:ie(ue,Ce,ve):(delete ue[Ce],ie(ue,Ce,ve)))})(Function.prototype,oe,function(){return typeof this=="function"&&this[P]||x.call(this)})}),B=function(A){if(typeof A!="function")throw TypeError(A+" is not a function!");return A},$=function(A,P,oe){if(B(A),P===void 0)return A;switch(oe){case 1:return function(ne){return A.call(P,ne)};case 2:return function(ne,ue){return A.call(P,ne,ue)};case 3:return function(ne,ue,Ce){return A.call(P,ne,ue,Ce)}}return function(){return A.apply(P,arguments)}},k="prototype",F=function(A,P,oe){var ne=A&F.F,ue=A&F.G,Ce=A&F.S,ve=A&F.P,Pe=A&F.B,Te=ue?Y:Ce?Y[P]||(Y[P]={}):(Y[P]||{})[k],ct=ue?T:T[P]||(T[P]={}),ht=ct[k]||(ct[k]={}),We,Ke,Re,Ct;ue&&(oe=P);for(We in oe)Ke=!ne&&Te&&Te[We]!==void 0,Re=(Ke?Te:oe)[We],Ct=Pe&&Ke?$(Re,Y):ve&&typeof Re=="function"?$(Function.call,Re):Re,Te&&b(Te,We,Re,A&F.U),ct[We]!=Re&&ie(ct,We,Ct),ve&&ht[We]!=Re&&(ht[We]=Re)};Y.core=T,F.F=1,F.G=2,F.S=4,F.P=8,F.B=16,F.W=32,F.U=64,F.R=128;var I=F,U=Math.ceil,re=Math.floor,X=function(A){return isNaN(A=+A)?0:(A>0?re:U)(A)},ae=function(A){if(A==null)throw TypeError("Can't call method on "+A);return A},ce=function(A){return function(P,oe){var ne=String(ae(P)),ue=X(oe),Ce=ne.length,ve,Pe;return ue<0||ue>=Ce?A?"":void 0:(ve=ne.charCodeAt(ue),ve<55296||ve>56319||ue+1===Ce||(Pe=ne.charCodeAt(ue+1))<56320||Pe>57343?A?ne.charAt(ue):ve:A?ne.slice(ue,ue+2):(ve-55296<<10)+(Pe-56320)+65536)}},W=ce(!1);I(I.P,"String",{codePointAt:function(P){return W(this,P)}});var K=T.String.codePointAt,z=Math.max,G=Math.min,Ve=function(A,P){return A=X(A),A<0?z(A+P,0):G(A,P)},ge=String.fromCharCode,_e=String.fromCodePoint;I(I.S+I.F*(!!_e&&_e.length!=1),"String",{fromCodePoint:function(P){for(var oe=arguments,ne=[],ue=arguments.length,Ce=0,ve;ue>Ce;){if(ve=+oe[Ce++],Ve(ve,1114111)!==ve)throw RangeError(ve+" is not a valid code point");ne.push(ve<65536?ge(ve):ge(((ve-=65536)>>10)+55296,ve%1024+56320))}return ne.join("")}});var ze=T.String.fromCodePoint,xe=/[\u1680\u2000-\u200A\u202F\u205F\u3000]/,at=/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uA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83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE83\uDE86-\uDE89\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]/,lt=/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u08D4-\u08E1\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u09FC\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9-\u0AFF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C80-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D00-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D54-\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19D9\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1C80-\u1C88\u1CD0-\u1CD2\u1CD4-\u1CF9\u1D00-\u1DF9\u1DFB-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\u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E9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC00-\uDC4A\uDC50-\uDC59\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDE00-\uDE3E\uDE47\uDE50-\uDE83\uDE86-\uDE99\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC36\uDC38-\uDC40\uDC50-\uDC59\uDC72-\uDC8F\uDC92-\uDCA7\uDCA9-\uDCB6\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD47\uDD50-\uDD59]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDE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uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/,mt={Space_Separator:xe,ID_Start:at,ID_Continue:lt},Ie={isSpaceSeparator:function(P){return typeof P=="string"&&mt.Space_Separator.test(P)},isIdStartChar:function(P){return typeof P=="string"&&(P>="a"&&P<="z"||P>="A"&&P<="Z"||P==="$"||P==="_"||mt.ID_Start.test(P))},isIdContinueChar:function(P){return typeof P=="string"&&(P>="a"&&P<="z"||P>="A"&&P<="Z"||P>="0"&&P<="9"||P==="$"||P==="_"||P==="\u200C"||P==="\u200D"||mt.ID_Continue.test(P))},isDigit:function(P){return typeof P=="string"&&/[0-9]/.test(P)},isHexDigit:function(P){return typeof P=="string"&&/[0-9A-Fa-f]/.test(P)}},Et,Ne,Ge,bt,qe,je,ke,It,ft,xt=function(P,oe){Et=String(P),Ne="start",Ge=[],bt=0,qe=1,je=0,ke=void 0,It=void 0,ft=void 0;do ke=Ue(),Gt[Ne]();while(ke.type!=="eof");return typeof oe=="function"?wt({"":ft},"",oe):ft};function wt(A,P,oe){var ne=A[P];if(ne!=null&&typeof ne=="object")if(Array.isArray(ne))for(var ue=0;ue0;){var oe=Ye();if(!Ie.isHexDigit(oe))throw Ae(J());A+=J()}return String.fromCodePoint(parseInt(A,16))}var Gt={start:function(){if(ke.type==="eof")throw it();kt()},beforePropertyName:function(){switch(ke.type){case"identifier":case"string":It=ke.value,Ne="afterPropertyName";return;case"punctuator":At();return;case"eof":throw it()}},afterPropertyName:function(){if(ke.type==="eof")throw it();Ne="beforePropertyValue"},beforePropertyValue:function(){if(ke.type==="eof")throw it();kt()},beforeArrayValue:function(){if(ke.type==="eof")throw it();if(ke.type==="punctuator"&&ke.value==="]"){At();return}kt()},afterPropertyValue:function(){if(ke.type==="eof")throw it();switch(ke.value){case",":Ne="beforePropertyName";return;case"}":At()}},afterArrayValue:function(){if(ke.type==="eof")throw it();switch(ke.value){case",":Ne="beforeArrayValue";return;case"]":At()}},end:function(){}};function kt(){var A;switch(ke.type){case"punctuator":switch(ke.value){case"{":A={};break;case"[":A=[];break}break;case"null":case"boolean":case"numeric":case"string":A=ke.value;break}if(ft===void 0)ft=A;else{var P=Ge[Ge.length-1];Array.isArray(P)?P.push(A):Object.defineProperty(P,It,{value:A,writable:!0,enumerable:!0,configurable:!0})}if(A!==null&&typeof A=="object")Ge.push(A),Array.isArray(A)?Ne="beforeArrayValue":Ne="beforePropertyName";else{var oe=Ge[Ge.length-1];oe==null?Ne="end":Array.isArray(oe)?Ne="afterArrayValue":Ne="afterPropertyValue"}}function At(){Ge.pop();var A=Ge[Ge.length-1];A==null?Ne="end":Array.isArray(A)?Ne="afterArrayValue":Ne="afterPropertyValue"}function Ae(A){return Ft(A===void 0?"JSON5: invalid end of input at "+qe+":"+je:"JSON5: invalid character '"+Rt(A)+"' at "+qe+":"+je)}function it(){return Ft("JSON5: invalid end of input at "+qe+":"+je)}function Pt(){return je-=5,Ft("JSON5: invalid identifier character at "+qe+":"+je)}function Xt(A){console.warn("JSON5: '"+Rt(A)+"' in strings is not valid ECMAScript; consider escaping")}function Rt(A){var P={"'":"\\'",'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r"," ":"\\t","\v":"\\v","\0":"\\0","\u2028":"\\u2028","\u2029":"\\u2029"};if(P[A])return P[A];if(A<" "){var oe=A.charCodeAt(0).toString(16);return"\\x"+("00"+oe).substring(oe.length)}return A}function Ft(A){var P=new SyntaxError(A);return P.lineNumber=qe,P.columnNumber=je,P}var Yt=function(P,oe,ne){var ue=[],Ce="",ve,Pe,Te="",ct;if(oe!=null&&typeof oe=="object"&&!Array.isArray(oe)&&(ne=oe.space,ct=oe.quote,oe=oe.replacer),typeof oe=="function")Pe=oe;else if(Array.isArray(oe)){ve=[];for(var ht=0,We=oe;ht0&&(ne=Math.min(10,Math.floor(ne)),Te=" ".substr(0,ne)):typeof ne=="string"&&(Te=ne.substr(0,10)),Ct("",{"":P});function Ct(be,Le){var he=Le[be];switch(he!=null&&(typeof he.toJSON5=="function"?he=he.toJSON5(be):typeof he.toJSON=="function"&&(he=he.toJSON(be))),Pe&&(he=Pe.call(Le,be,he)),he instanceof Number?he=Number(he):he instanceof String?he=String(he):he instanceof Boolean&&(he=he.valueOf()),he){case null:return"null";case!0:return"true";case!1:return"false"}if(typeof he=="string")return Bt(he,!1);if(typeof he=="number")return String(he);if(typeof he=="object")return Array.isArray(he)?Mt(he):fn(he)}function Bt(be){for(var Le={"'":.1,'"':.2},he={"'":"\\'",'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r"," ":"\\t","\v":"\\v","\0":"\\0","\u2028":"\\u2028","\u2029":"\\u2029"},Be="",Je=0;Je=0)throw TypeError("Converting circular structure to JSON5");ue.push(be);var Le=Ce;Ce=Ce+Te;for(var he=ve||Object.keys(be),Be=[],Je=0,$e=he;Je<$e.length;Je+=1){var ot=$e[Je],Ze=Ct(ot,be);if(Ze!==void 0){var Qe=gn(ot)+":";Te!==""&&(Qe+=" "),Qe+=Ze,Be.push(Qe)}}var rt;if(Be.length===0)rt="{}";else{var Dt;if(Te==="")Dt=Be.join(","),rt="{"+Dt+"}";else{var tn=`, +`+Ce;Dt=Be.join(tn),rt=`{ +`+Ce+Dt+`, +`+Le+"}"}}return ue.pop(),Ce=Le,rt}function gn(be){if(be.length===0)return Bt(be,!0);var Le=String.fromCodePoint(be.codePointAt(0));if(!Ie.isIdStartChar(Le))return Bt(be,!0);for(var he=Le.length;he=0)throw TypeError("Converting circular structure to JSON5");ue.push(be);var Le=Ce;Ce=Ce+Te;for(var he=[],Be=0;Be {\n // This is necessary because:\n // typeof null === 'object'\n // typeof [] === 'object'\n // [] instanceof Object === true\n return Object.prototype.toString.call(it) === '[object Object]'; // this code is 25% faster than below one\n // return it && typeof it === 'object' && !(it instanceof Array);\n}\n\nexport interface DeviceManagerPropsProps {\n /* socket object */\n socket: Connection;\n /* Instance to communicate with device-manager backend, like `adapterName.X` */\n selectedInstance: string; // adapterName.X\n registerHandler?: (handler: null | ((command: string) => void)) => void;\n themeName: ThemeName;\n themeType: ThemeType;\n isFloatComma: boolean;\n dateFormat: string;\n /** Instance to upload images to, like `adapterName.X` */\n uploadImagesToInstance?: string;\n /** Filter devices with this string */\n filter?: string;\n /** If this component is used in GUI with own toolbar. `false` if this list is used with multiple instances and true if only with one (in this case, it will monitor alive itself */\n embedded?: boolean;\n /** If embedded, this text is shown in the toolbar */\n title?: string;\n /** Style of a component that displays all devices */\n style?: React.CSSProperties;\n /** Use small cards for devices */\n smallCards?: boolean;\n}\n\nexport interface ConfigGenericProps {\n oContext: JsonConfigContext;\n alive: boolean;\n arrayIndex?: number;\n attr?: string;\n changed: boolean;\n className?: string;\n style?: Record;\n commandRunning?: boolean;\n common: Record;\n custom?: boolean;\n customObj?: Record;\n data: Record;\n disabled?: boolean;\n // filled only by table and represents the obj.native or obj.common.custom['adapter.X'] object\n globalData?: Record;\n // filled only by table\n index?: number;\n isParentTab?: boolean;\n onChange: (attrOrData: string | Record, val?: any, cb?: () => void, saveConfig?: boolean) => void;\n onError: (attr: string, error?: string) => void;\n originalData: Record;\n /** This indicates that the component is the very firsts one - root */\n root?: boolean;\n /** Provided props by the specific component */\n schema: ConfigItemAny;\n /** This item is in the table. Maybe some layouts must be changed */\n table?: boolean;\n themeName: ThemeName;\n}\n\nexport interface ConfigGenericState {\n confirmDialog: boolean;\n confirmNewValue: any;\n confirmAttr: any;\n confirmData: ConfigItemConfirmData | null;\n value?: any;\n confirmDepAttr?: any;\n confirmDepNewValue?: any;\n confirmCallback: null | ((result: boolean) => void);\n}\n\nexport default class ConfigGeneric<\n Props extends ConfigGenericProps = ConfigGenericProps,\n State extends ConfigGenericState = ConfigGenericState,\n> extends Component {\n static DIFFERENT_VALUE = '__different__';\n\n static DIFFERENT_LABEL = 'ra___different__';\n\n static NONE_VALUE = '';\n\n static NONE_LABEL = 'ra_none';\n\n private readonly defaultValue: any;\n\n private isError: any;\n\n private readonly lang: ioBroker.Languages;\n\n private defaultSendToDone?: boolean;\n\n private sendToTimeout?: any;\n\n private noPlaceRequired: any;\n\n constructor(props: Props) {\n super(props);\n\n // @ts-expect-error of course, as we just\n this.state = {\n confirmDialog: false,\n confirmNewValue: null,\n confirmAttr: null,\n confirmData: null,\n confirmCallback: null,\n } satisfies ConfigGenericState;\n\n this.isError = {};\n\n if (props.schema) {\n if (props.custom) {\n this.defaultValue = props.schema.defaultFunc\n ? this.executeCustom(\n props.schema.defaultFunc,\n props.data,\n props.customObj,\n props.oContext.instanceObj,\n props.arrayIndex,\n props.globalData,\n )\n : props.schema.default;\n } else if (props.schema.type !== 'state') {\n this.defaultValue = props.schema.defaultFunc\n ? this.execute(\n props.schema.defaultFunc,\n props.schema.default,\n props.data,\n props.arrayIndex,\n props.globalData,\n )\n : props.schema.default;\n }\n }\n\n this.lang = I18n.getLanguage();\n }\n\n componentDidMount(): void {\n if (this.props.oContext.registerOnForceUpdate) {\n this.props.oContext.registerOnForceUpdate(this.props.attr, this.onUpdate);\n }\n const LIKE_SELECT = ['select', 'autocomplete', 'autocompleteSendTo'];\n // init default value\n if (this.defaultValue !== undefined) {\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n if (\n value === undefined ||\n (LIKE_SELECT.includes(this.props.schema.type) && (value === '' || value === null))\n ) {\n setTimeout(() => {\n if (this.props.custom) {\n this.props.onChange(this.props.attr, this.defaultValue, () =>\n setTimeout(() => this.props.oContext.forceUpdate([this.props.attr], this.props.data), 100),\n );\n } else {\n ConfigGeneric.setValue(this.props.data, this.props.attr, this.defaultValue);\n this.props.onChange(this.props.data, undefined, () =>\n this.props.oContext.forceUpdate([this.props.attr], this.props.data),\n );\n }\n }, 100);\n }\n } else if (this.props.schema.defaultSendTo) {\n this.sendTo();\n }\n }\n\n sendTo(): void {\n if (this.props.alive) {\n this.defaultSendToDone = true;\n let data: any = this.props.schema.data;\n if (data === undefined && this.props.schema.jsonData) {\n const dataStr = this.getPattern(this.props.schema.jsonData, null, true);\n try {\n data = JSON.parse(dataStr);\n } catch {\n console.error(`Cannot parse json data: ${dataStr}`);\n }\n } else {\n data = {\n attr: this.props.attr,\n value: ConfigGeneric.getValue(this.props.data, this.props.attr),\n };\n }\n\n if (data === undefined) {\n data = null;\n }\n\n void this.props.oContext.socket\n .sendTo(\n `${this.props.oContext.adapterName}.${this.props.oContext.instance}`,\n this.props.schema.defaultSendTo,\n data,\n )\n .then((value: any) => {\n if (value !== null && value !== undefined) {\n if (this.props.custom) {\n this.props.onChange(this.props.attr, value, () =>\n this.props.oContext.forceUpdate([this.props.attr], this.props.data),\n );\n } else {\n ConfigGeneric.setValue(this.props.data, this.props.attr, value);\n this.props.onChange(this.props.data, undefined, () =>\n this.props.oContext.forceUpdate([this.props.attr], this.props.data),\n );\n }\n }\n });\n } else {\n this.defaultSendToDone = false;\n if (!this.props.schema.allowSaveWithError) {\n // show error, that instance did not start\n this.onError(\n this.props.attr,\n I18n.t('ra_Instance %s is not alive', this.props.oContext.instance.toString()),\n );\n }\n }\n }\n\n componentWillUnmount(): void {\n if (this.props.oContext.registerOnForceUpdate) {\n this.props.oContext.registerOnForceUpdate(this.props.attr);\n }\n if (this.sendToTimeout) {\n clearTimeout(this.sendToTimeout);\n this.sendToTimeout = null;\n }\n }\n\n onUpdate = (data: Record): void => {\n const value = ConfigGeneric.getValue(data || this.props.data, this.props.attr) || '';\n if (this.state.value !== value) {\n this.setState({ value });\n } else {\n this.forceUpdate();\n }\n };\n\n /**\n * Extract attribute out of data\n */\n static getValue(data: Record, attr: string | string[]): any {\n if (typeof attr === 'string') {\n return ConfigGeneric.getValue(data, attr.split('.'));\n }\n if (attr.length === 1) {\n return data[attr[0]];\n }\n const part = attr.shift();\n\n if (typeof part === 'string' && typeof data[part] === 'object') {\n return ConfigGeneric.getValue(data[part], attr);\n }\n return undefined;\n }\n\n static setValue(data: Record, attr: string | string[], value: any): void {\n if (typeof attr === 'string') {\n ConfigGeneric.setValue(data, attr.split('.'), value);\n return;\n }\n if (attr.length === 1) {\n if (value === null) {\n delete data[attr[0]];\n } else {\n data[attr[0]] = value;\n }\n } else {\n const part = attr.shift();\n\n if (typeof part !== 'string') {\n return;\n }\n\n if (!data[part] || typeof data[part] === 'object') {\n data[part] = data[part] || {};\n }\n ConfigGeneric.setValue(data[part], attr, value);\n }\n }\n\n getText(text: ioBroker.StringOrTranslated, noTranslation?: boolean): string {\n if (!text) {\n return '';\n }\n\n if (typeof text === 'string') {\n const strText = noTranslation ? text : I18n.t(text);\n if (strText.includes('${')) {\n return this.getPattern(strText, null, noTranslation);\n }\n return strText;\n }\n\n if (isObject(text)) {\n // todo\n if ((text as any).func) {\n // calculate pattern\n if (typeof (text as any).func === 'object') {\n return this.getPattern((text as any).func[this.lang] || (text as any).func.en || '', null, true);\n }\n return this.getPattern((text as any).func, null, noTranslation);\n }\n\n return text[this.lang] || text.en || '';\n }\n\n return (text as any).toString();\n }\n\n renderDialogConfirm(): JSX.Element | null {\n if (!this.state.confirmDialog) {\n return null;\n }\n const confirm = this.state.confirmData || this.props.schema.confirm;\n let icon: null | JSX.Element = null;\n if (confirm.type === 'warning') {\n icon = ;\n } else if (confirm.type === 'error') {\n icon = ;\n } else if (confirm.type === 'info') {\n icon = ;\n }\n\n return (\n \n this.setState({ confirmDialog: false }, () => {\n if (isOk) {\n if (this.state.confirmCallback) {\n const callback = this.state.confirmCallback;\n this.setState({ confirmCallback: null }, () => callback(true));\n return;\n }\n\n const data = JSON.parse(JSON.stringify(this.props.data));\n if (this.state.confirmDepAttr) {\n ConfigGeneric.setValue(data, this.state.confirmDepAttr, this.state.confirmDepNewValue);\n }\n\n ConfigGeneric.setValue(data, this.state.confirmAttr, this.state.confirmNewValue);\n this.setState(\n {\n confirmDialog: false,\n confirmDepAttr: null,\n confirmDepNewValue: null,\n confirmNewValue: null,\n confirmAttr: null,\n confirmData: null,\n },\n () => this.props.onChange(data),\n );\n } else {\n const callback = this.state.confirmCallback;\n this.setState(\n {\n confirmDialog: false,\n confirmDepAttr: null,\n confirmDepNewValue: null,\n confirmNewValue: null,\n confirmAttr: null,\n confirmData: null,\n confirmCallback: null,\n },\n () => {\n if (callback) {\n callback(false);\n }\n },\n );\n }\n })\n }\n />\n );\n }\n\n // eslint-disable-next-line react/no-unused-class-component-methods\n getIcon(iconSettings?: ConfigIconType | null): JSX.Element | null {\n iconSettings = iconSettings || this.props.schema.icon;\n let icon = null;\n if (iconSettings === 'auth') {\n icon = ;\n } else if (iconSettings === 'send') {\n icon = ;\n } else if (iconSettings === 'web') {\n icon = ;\n } else if (iconSettings === 'warning') {\n icon = ;\n } else if (iconSettings === 'error') {\n icon = ;\n } else if (iconSettings === 'info') {\n icon = ;\n } else if (iconSettings === 'search') {\n icon = ;\n } else if (iconSettings === 'book') {\n icon = ;\n } else if (iconSettings === 'help') {\n icon = ;\n } else if (iconSettings === 'upload') {\n icon = ;\n } else if (iconSettings === 'edit') {\n icon = ;\n } else if (iconSettings === 'user') {\n icon = ;\n } else if (iconSettings === 'group') {\n icon = ;\n } else if (iconSettings === 'delete') {\n icon = ;\n } else if (iconSettings === 'refresh') {\n icon = ;\n } else if (iconSettings === 'add') {\n icon = ;\n } else if (iconSettings === 'unpair') {\n icon = ;\n } else if (iconSettings === 'pair') {\n icon = ;\n } else if (iconSettings === 'save') {\n icon = ;\n } else if (iconSettings === 'open') {\n icon = ;\n } else if (iconSettings) {\n if (iconSettings.endsWith('.png') || iconSettings.endsWith('.svg') || iconSettings.endsWith('.jpg')) {\n // this path is relative to ./adapter/NAME\n if (!iconSettings.startsWith('http://') && !iconSettings.startsWith('https://')) {\n iconSettings = `./adapter/${this.props.oContext.adapterName}/${iconSettings}`;\n }\n }\n\n icon = (\n \n );\n }\n\n return icon;\n }\n\n /**\n * Trigger onChange, to activate save button on change\n *\n * @param attr the changed attribute\n * @param newValue new value of the attribute\n */\n // eslint-disable-next-line react/no-unused-class-component-methods\n onChangeAsync(attr: string, newValue: unknown): Promise {\n return new Promise(resolve => {\n const mayBePromise = this.onChange(attr, newValue, resolve);\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n });\n }\n\n /**\n * Trigger onChange, to activate save button on change\n *\n * @param attr the changed attribute\n * @param newValue new value of the attribute\n * @param cb optional callback function, else returns a Promise\n */\n onChange(attr: string, newValue: unknown, cb?: () => void): Promise {\n // Do not use here deep copy, as it is not JsonConfig\n const data = JSON.parse(JSON.stringify(this.props.data));\n ConfigGeneric.setValue(data, attr, newValue);\n\n if (\n this.props.schema.confirm &&\n this.execute(this.props.schema.confirm.condition, false, data, this.props.arrayIndex, this.props.globalData)\n ) {\n return new Promise(resolve => {\n this.setState(\n {\n confirmDialog: true,\n confirmNewValue: newValue,\n confirmAttr: attr,\n confirmData: null,\n },\n () => {\n if (typeof cb === 'function') {\n cb();\n } else {\n resolve();\n }\n },\n );\n });\n }\n // find any inputs with confirmation\n if (this.props.schema.confirmDependsOn) {\n for (let z = 0; z < this.props.schema.confirmDependsOn.length; z++) {\n const dep = this.props.schema.confirmDependsOn[z];\n if (dep.confirm) {\n const val = ConfigGeneric.getValue(data, dep.attr);\n\n if (\n this.execute(dep.confirm.condition, false, data, this.props.arrayIndex, this.props.globalData)\n ) {\n return new Promise(resolve => {\n this.setState(\n {\n confirmDialog: true,\n confirmNewValue: newValue,\n confirmAttr: attr,\n confirmDepNewValue: val,\n confirmDepAttr: dep.attr,\n confirmData: dep.confirm,\n },\n () => {\n if (typeof cb === 'function') {\n cb();\n } else {\n resolve();\n }\n },\n );\n });\n }\n }\n }\n }\n\n const changed: string[] = [];\n if (this.props.schema.onChangeDependsOn) {\n for (let z = 0; z < this.props.schema.onChangeDependsOn.length; z++) {\n const dep = this.props.schema.onChangeDependsOn[z];\n if (dep.onChange) {\n const val = ConfigGeneric.getValue(data, dep.attr);\n\n let _newValue;\n if (this.props.custom) {\n _newValue = this.executeCustom(\n dep.onChange.calculateFunc,\n data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n this.props.arrayIndex,\n this.props.globalData,\n );\n } else {\n _newValue = this.execute(\n dep.onChange.calculateFunc,\n val,\n data,\n this.props.arrayIndex,\n this.props.globalData,\n );\n }\n\n if (_newValue !== val) {\n ConfigGeneric.setValue(data, dep.attr, _newValue);\n changed.push(dep.attr);\n }\n }\n }\n }\n\n if (this.props.schema.hiddenDependsOn) {\n for (let z = 0; z < this.props.schema.hiddenDependsOn.length; z++) {\n const dep = this.props.schema.hiddenDependsOn[z];\n if (dep.hidden) {\n changed.push(dep.attr);\n }\n }\n }\n\n if (this.props.schema.labelDependsOn) {\n for (let z = 0; z < this.props.schema.labelDependsOn.length; z++) {\n const dep = this.props.schema.labelDependsOn[z];\n if (dep.hidden) {\n changed.push(dep.attr);\n }\n }\n }\n\n if (this.props.schema.helpDependsOn) {\n for (let z = 0; z < this.props.schema.helpDependsOn.length; z++) {\n const dep = this.props.schema.helpDependsOn[z];\n if (dep.hidden) {\n changed.push(dep.attr);\n }\n }\n }\n\n if (this.props.schema.onChange && !this.props.schema.onChange.ignoreOwnChanges) {\n const val = ConfigGeneric.getValue(data, this.props.attr);\n\n const newValue_ = this.props.custom\n ? this.executeCustom(\n this.props.schema.onChange.calculateFunc,\n data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n this.props.arrayIndex,\n this.props.globalData,\n )\n : this.execute(\n this.props.schema.onChange.calculateFunc,\n val,\n data,\n this.props.arrayIndex,\n this.props.globalData,\n );\n if (newValue_ !== val) {\n ConfigGeneric.setValue(data, this.props.attr, newValue_);\n }\n }\n\n if (this.props.custom) {\n this.props.onChange(attr, newValue, () => cb && cb());\n\n if (changed?.length) {\n changed.forEach((_attr, i) =>\n setTimeout(() => this.props.onChange(_attr, ConfigGeneric.getValue(data, _attr)), i * 50),\n );\n }\n } else {\n this.props.onChange(data, undefined, () => {\n if (changed.length) {\n this.props.oContext.forceUpdate(changed, data);\n }\n if (cb) {\n cb();\n }\n });\n }\n\n return Promise.resolve();\n }\n\n execute(\n func: string | boolean | Record,\n defaultValue: string | number | boolean,\n data: Record,\n arrayIndex: number,\n globalData: Record,\n ): string | number | boolean {\n let fun: string;\n\n if (isObject(func)) {\n fun = func.func;\n } else if (typeof func === 'string') {\n fun = func;\n } else {\n return func;\n }\n\n if (!fun) {\n return defaultValue;\n }\n try {\n const f = new Function(\n 'data',\n 'originalData',\n '_system',\n '_alive',\n '_common',\n '_socket',\n '_instance',\n 'arrayIndex',\n 'globalData',\n '_changed',\n fun.includes('return') ? fun : `return ${fun}`,\n );\n return f(\n data || this.props.data,\n this.props.originalData,\n this.props.oContext.systemConfig,\n this.props.alive,\n this.props.common,\n this.props.oContext.socket,\n this.props.oContext.instance,\n arrayIndex,\n globalData,\n this.props.changed,\n );\n } catch (e) {\n console.error(`Cannot execute ${JSON.stringify(func)}: ${e}`);\n return defaultValue;\n }\n }\n\n executeCustom(\n func: string | boolean | Record,\n data: Record,\n customObj: Record,\n instanceObj: ioBroker.InstanceObject,\n arrayIndex: number,\n globalData: Record,\n ): string | boolean | number | null {\n let fun: string;\n\n if (isObject(func)) {\n fun = func.func;\n } else if (typeof func === 'string') {\n fun = func;\n } else {\n return func;\n }\n\n if (!fun) {\n return null;\n }\n try {\n const f = new Function(\n 'data',\n 'originalData',\n '_system',\n 'instanceObj',\n 'customObj',\n '_socket',\n 'arrayIndex',\n 'globalData',\n '_changed',\n fun.includes('return') ? fun : `return ${fun}`,\n );\n return f(\n data || this.props.data,\n this.props.originalData,\n this.props.oContext.systemConfig,\n instanceObj,\n customObj,\n this.props.oContext.socket,\n arrayIndex,\n globalData,\n this.props.changed,\n );\n } catch (e) {\n console.error(`Cannot execute ${fun}: ${e}`);\n return null;\n }\n }\n\n calculate(schema: Record): {\n error: boolean;\n disabled: boolean;\n hidden: boolean;\n defaultValue: null | string | number | boolean;\n } {\n let error: boolean;\n let disabled: boolean;\n let hidden: boolean;\n let defaultValue: null | string | number | boolean;\n\n if (this.props.custom) {\n error = schema.validator\n ? !this.executeCustom(\n schema.validator,\n this.props.data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n this.props.arrayIndex,\n this.props.globalData,\n )\n : false;\n if (schema.disabled === true) {\n disabled = true;\n } else {\n disabled = schema.disabled\n ? (this.executeCustom(\n schema.disabled,\n this.props.data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n this.props.arrayIndex,\n this.props.globalData,\n ) as boolean)\n : false;\n }\n if (schema.hidden === true) {\n hidden = true;\n } else {\n hidden = schema.hidden\n ? (this.executeCustom(\n schema.hidden,\n this.props.data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n this.props.arrayIndex,\n this.props.globalData,\n ) as boolean)\n : false;\n }\n defaultValue = schema.defaultFunc\n ? this.executeCustom(\n schema.defaultFunc,\n this.props.data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n this.props.arrayIndex,\n this.props.globalData,\n )\n : schema.default;\n } else {\n error = schema.validator\n ? !this.execute(schema.validator, false, this.props.data, this.props.arrayIndex, this.props.globalData)\n : false;\n if (schema.disabled === true) {\n disabled = true;\n } else {\n disabled = schema.disabled\n ? (this.execute(\n schema.disabled,\n false,\n this.props.data,\n this.props.arrayIndex,\n this.props.globalData,\n ) as boolean)\n : false;\n }\n if (schema.hidden === true) {\n hidden = true;\n } else {\n hidden = schema.hidden\n ? (this.execute(\n schema.hidden,\n false,\n this.props.data,\n this.props.arrayIndex,\n this.props.globalData,\n ) as boolean)\n : false;\n }\n defaultValue = schema.defaultFunc\n ? this.execute(\n schema.defaultFunc,\n schema.default,\n this.props.data,\n this.props.arrayIndex,\n this.props.globalData,\n )\n : schema.default;\n }\n\n return {\n error,\n disabled,\n hidden,\n defaultValue,\n };\n }\n\n onError(attr: string, error?: string): void {\n if (!error) {\n delete this.isError[attr];\n } else {\n this.isError[attr] = error;\n }\n\n if (this.props.onError) {\n this.props.onError(attr, error);\n }\n }\n\n renderItem(_error: unknown, _disabled: boolean, _defaultValue?: unknown): JSX.Element | string | null {\n return this.getText(this.props.schema.label) || this.getText(this.props.schema.text);\n }\n\n // eslint-disable-next-line react/no-unused-class-component-methods\n renderHelp(\n text: ioBroker.StringOrTranslated,\n link: string,\n noTranslation: boolean,\n ): JSX.Element | JSX.Element[] | string {\n if (!link) {\n text = this.getText(text, noTranslation) || '';\n if (\n text &&\n (text.includes('
') || text.includes(''))\n ) {\n return Utils.renderTextWithA(text);\n }\n return text;\n }\n return (\n \n {this.getText(text, noTranslation)}\n \n );\n }\n\n // we have a problem that a string '{\"password\": \"${password}\"}' cannot contain a double quota inside the string\n // escape it with \\\"\n static escapeString(str: string, data: Record): string {\n if (typeof str !== 'string') {\n return '';\n }\n str = str.replace(/`/g, '\\\\`');\n // extract all tokes with ${data.token}\n str = str.replace(/\\${([^}]+)}/g, (_match: string, p1: any) => {\n if (p1 && typeof p1 === 'string' && p1.startsWith('data.')) {\n const value = ConfigGeneric.getValue(data, p1.replace(/^data\\./, ''));\n\n if (typeof value === 'string' && value.includes('\"')) {\n return `\\${${p1}.replace(/\"/g, '\\\\\\\\\"')}`;\n }\n }\n return _match;\n });\n\n return str;\n }\n\n getPattern(pattern: string | { func: string }, data?: Record, noTranslation?: boolean): string {\n data = data || this.props.data;\n if (!pattern) {\n return '';\n }\n let patternStr: string;\n if (typeof pattern === 'object') {\n if (pattern.func) {\n patternStr = (pattern as { func: string }).func;\n } else {\n console.log(`Object must be stringified: ${JSON.stringify(pattern)}`);\n patternStr = JSON.stringify(pattern);\n }\n } else {\n patternStr = pattern;\n }\n\n try {\n if (this.props.custom) {\n const f = new Function(\n 'data',\n 'originalData',\n 'arrayIndex',\n 'globalData',\n '_system',\n 'instanceObj',\n 'customObj',\n '_socket',\n '_changed',\n `return \\`${ConfigGeneric.escapeString(patternStr, data)}\\``,\n );\n return f(\n data,\n this.props.originalData,\n this.props.arrayIndex,\n this.props.globalData,\n this.props.oContext.systemConfig,\n this.props.oContext.instanceObj,\n this.props.customObj,\n this.props.oContext.socket,\n this.props.changed,\n );\n }\n\n const f = new Function(\n 'data',\n 'originalData',\n 'arrayIndex',\n 'globalData',\n '_system',\n '_alive',\n '_common',\n '_socket',\n '_changed',\n `return \\`${ConfigGeneric.escapeString(patternStr, data)}\\``,\n );\n const text = f(\n data,\n this.props.originalData,\n this.props.arrayIndex,\n this.props.globalData,\n this.props.oContext.systemConfig,\n this.props.alive,\n this.props.common,\n this.props.oContext.socket,\n this.props.changed,\n );\n if (noTranslation) {\n return text;\n }\n return I18n.t(text);\n } catch (e) {\n console.error(`Cannot execute ${patternStr}: ${e}`);\n return patternStr;\n }\n }\n\n render(): string | JSX.Element | null {\n const schema = this.props.schema;\n\n if (!schema) {\n return null;\n }\n\n // Do not show this component if expert mode is false\n if (this.props.oContext.expertMode === false && schema.expertMode) {\n return null;\n }\n\n if (this.props.alive && this.defaultSendToDone === false) {\n this.sendToTimeout = setTimeout(() => {\n this.sendToTimeout = null;\n this.sendTo();\n }, 200);\n }\n\n const { error, disabled, hidden, defaultValue } = this.calculate(schema);\n\n if (hidden) {\n // Remove all errors if element is hidden\n if (Object.keys(this.isError).length) {\n setTimeout(\n isError => Object.keys(isError).forEach(attr => this.props.onError(attr)),\n 100,\n JSON.parse(JSON.stringify(this.isError)),\n );\n this.isError = {};\n }\n\n if (schema.hideOnlyControl) {\n const item = (\n \n );\n\n if (schema.newLine) {\n return (\n <>\n
\n {item}\n \n );\n }\n return item;\n }\n return null;\n }\n // Add error\n if (schema.validatorNoSaveOnError) {\n if (error && !Object.keys(this.isError).length) {\n this.isError = {\n [this.props.attr]: schema.validatorErrorText ? I18n.t(schema.validatorErrorText) : true,\n };\n setTimeout(\n isError => Object.keys(isError).forEach(attr => this.props.onError(attr, isError[attr])),\n 100,\n JSON.parse(JSON.stringify(this.isError)),\n );\n } else if (!error && Object.keys(this.isError).length) {\n setTimeout(\n isError => Object.keys(isError).forEach(attr => this.props.onError(attr)),\n 100,\n JSON.parse(JSON.stringify(this.isError)),\n );\n this.isError = {};\n }\n }\n\n const renderedItem = this.renderItem(\n error,\n disabled || this.props.commandRunning || this.props.disabled,\n defaultValue,\n );\n\n if (this.noPlaceRequired) {\n return renderedItem;\n }\n\n const item = (\n \n {this.props.schema.defaultSendTo && this.props.schema.button ? (\n \n {renderedItem}\n \n this.sendTo()}\n title={\n this.props.schema.buttonTooltip\n ? this.getText(\n this.props.schema.buttonTooltip,\n this.props.schema.buttonTooltipNoTranslation,\n )\n : I18n.t('ra_Request data by instance')\n }\n >\n {this.getText(this.props.schema.button as ioBroker.StringOrTranslated)}\n \n \n \n ) : (\n renderedItem\n )}\n \n );\n\n if (schema.newLine) {\n return (\n <>\n
\n {this.renderDialogConfirm()}\n {item}\n \n );\n }\n if (this.state.confirmDialog) {\n return (\n <>\n {this.renderDialogConfirm()}\n {item}\n \n );\n }\n return item;\n }\n}\n","import React, { type JSX } from 'react';\n\nimport {\n FormHelperText,\n Accordion,\n AccordionSummary,\n AccordionDetails,\n IconButton,\n Paper,\n Toolbar,\n Tooltip,\n Typography,\n} from '@mui/material';\n\nimport {\n Add as AddIcon,\n Delete as DeleteIcon,\n ArrowUpward as UpIcon,\n ArrowDownward as DownIcon,\n ContentCopy as CopyContentIcon,\n ExpandMore as ExpandMoreIcon,\n} from '@mui/icons-material';\n\nimport { I18n, type IobTheme, Utils } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemAccordion, ConfigItemAny, ConfigItemIndexed, ConfigItemPanel } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nimport ConfigPanel from './ConfigPanel';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n accordionSummary: (theme: IobTheme): React.CSSProperties => ({\n backgroundColor: theme.palette.mode === 'dark' ? 'rgba(255, 255, 255, 0.08)' : 'rgba(0, 0, 0, 0.08)',\n }),\n accordionTitle: {\n // fontWeight: 'bold',\n },\n toolbar: (theme: IobTheme): React.CSSProperties => ({\n backgroundColor: theme.palette.mode === 'dark' ? 'rgba(255, 255, 255, 0.08)' : 'rgba(0, 0, 0, 0.08)',\n borderRadius: '3px',\n }),\n tooltip: {\n pointerEvents: 'none',\n },\n};\n\ninterface ConfigAccordionProps extends ConfigGenericProps {\n schema: ConfigItemAccordion;\n}\n\ninterface ConfigAccordionState extends ConfigGenericState {\n value: Record[];\n activeIndex: number;\n iteration: number;\n}\n\nclass ConfigAccordion extends ConfigGeneric {\n private typingTimer: ReturnType | null = null;\n\n constructor(props: ConfigAccordionProps) {\n super(props);\n this.props.schema.items = this.props.schema.items || [];\n }\n\n componentDidMount(): void {\n super.componentDidMount();\n\n let value = ConfigGeneric.getValue(this.props.data, this.props.attr) || [];\n\n if (!Array.isArray(value)) {\n value = [];\n }\n\n this.setState({\n value,\n activeIndex: -1,\n iteration: 0,\n });\n }\n\n componentWillUnmount(): void {\n if (this.typingTimer) {\n clearTimeout(this.typingTimer);\n this.typingTimer = null;\n }\n super.componentWillUnmount();\n }\n\n itemAccordion(data: Record, idx: number): JSX.Element {\n const { value } = this.state;\n const { schema } = this.props;\n\n const schemaItem: ConfigItemPanel = {\n type: 'panel',\n items: schema.items.reduce(\n (accumulator: Record, currentValue: ConfigItemIndexed) => {\n accumulator[currentValue.attr] = currentValue;\n return accumulator;\n },\n {},\n ) as Record,\n style: { marginLeft: '-8px', marginTop: '10px', marginBottom: '10px' },\n };\n\n return (\n {\n const newObj: Record = JSON.parse(JSON.stringify(value));\n newObj[idx][attr] = valueChange;\n this.setState({ value: newObj } as ConfigAccordionState, () => this.onChangeWrapper(newObj));\n }}\n onError={(error, attr) => this.onError(error, attr)}\n table={this.props.table}\n />\n );\n }\n\n onDelete = (index: number) => (): void => {\n const newValue = JSON.parse(JSON.stringify(this.state.value));\n newValue.splice(index, 1);\n\n this.setState({ value: newValue, iteration: this.state.iteration + 10000 }, () =>\n this.onChangeWrapper(newValue),\n );\n };\n\n onClone = (index: number) => (): void => {\n const newValue = JSON.parse(JSON.stringify(this.state.value)) as Record[];\n const cloned = JSON.parse(JSON.stringify(newValue[index]));\n if (typeof this.props.schema.clone === 'string' && typeof cloned[this.props.schema.clone] === 'string') {\n let i = 1;\n let text = cloned[this.props.schema.clone];\n const pattern = text.match(/(\\d+)$/);\n if (pattern) {\n text = text.replace(pattern[0], '');\n i = parseInt(pattern[0], 10) + 1;\n } else {\n text += '_';\n }\n while (newValue.find(it => it[this.props.schema.clone as string] === text + i.toString())) {\n i++;\n }\n cloned[this.props.schema.clone] = `${cloned[this.props.schema.clone]}_${i}`;\n }\n\n newValue.splice(index, 0, cloned);\n\n this.setState(\n {\n value: newValue,\n activeIndex: -1,\n iteration: this.state.iteration + 10000,\n },\n () => this.onChangeWrapper(newValue),\n );\n };\n\n onChangeWrapper = (newValue: any): void => {\n if (this.typingTimer) {\n clearTimeout(this.typingTimer);\n }\n\n this.typingTimer = setTimeout(\n value => {\n this.typingTimer = null;\n\n const mayByPromise = this.onChange(this.props.attr, value);\n if (mayByPromise instanceof Promise) {\n void mayByPromise.catch(e => this.onError(e));\n }\n },\n 300,\n newValue,\n );\n };\n\n onAdd = (): void => {\n const { schema } = this.props;\n const newValue = JSON.parse(JSON.stringify(this.state.value));\n const newItem: Record =\n schema.items &&\n schema.items.reduce((accumulator: Record, currentValue: ConfigItemIndexed) => {\n let defaultValue;\n if (currentValue.defaultFunc) {\n if (this.props.custom) {\n defaultValue = currentValue.defaultFunc\n ? this.executeCustom(\n currentValue.defaultFunc,\n this.props.data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n newValue.length,\n this.props.data,\n )\n : this.props.schema.default;\n } else {\n defaultValue = currentValue.defaultFunc\n ? this.execute(\n currentValue.defaultFunc,\n this.props.schema.default,\n this.props.data,\n newValue.length,\n this.props.data,\n )\n : this.props.schema.default;\n }\n } else {\n defaultValue = currentValue.default === undefined ? null : currentValue.default;\n }\n\n accumulator[currentValue.attr] = defaultValue;\n return accumulator;\n }, {});\n\n newValue.push(newItem);\n\n this.setState({ value: newValue, activeIndex: newValue.length - 1 }, () => this.onChangeWrapper(newValue));\n };\n\n onMoveUp(idx: number): void {\n const newValue = JSON.parse(JSON.stringify(this.state.value));\n const item = newValue[idx];\n newValue.splice(idx, 1);\n newValue.splice(idx - 1, 0, item);\n\n const newIndex = this.state.activeIndex - 1;\n this.setState({ value: newValue, activeIndex: newIndex, iteration: this.state.iteration + 10000 }, () =>\n this.onChangeWrapper(newValue),\n );\n }\n\n onMoveDown(idx: number): void {\n const newValue = JSON.parse(JSON.stringify(this.state.value));\n const item = newValue[idx];\n newValue.splice(idx, 1);\n newValue.splice(idx + 1, 0, item);\n\n const newIndex = this.state.activeIndex + 1;\n this.setState({ value: newValue, activeIndex: newIndex, iteration: this.state.iteration + 10000 }, () =>\n this.onChangeWrapper(newValue),\n );\n }\n\n renderItem(/* error, disabled, defaultValue */): JSX.Element | null {\n const { schema } = this.props;\n const { value } = this.state;\n\n if (!value) {\n return null;\n }\n\n return (\n \n {schema.label || !schema.noDelete ? (\n \n {schema.label ? (\n \n {this.getText(schema.label)}\n \n ) : null}\n {!schema.noDelete ? (\n \n \n \n ) : null}\n \n ) : null}\n {value.map((idx, i) => (\n this.setState({ activeIndex: expanded ? i : -1 })}\n >\n }\n sx={Utils.getStyle(this.props.oContext.theme, styles.fullWidth, styles.accordionSummary)}\n >\n {idx[schema.titleAttr]}\n \n \n {this.itemAccordion(value[i], i)}\n \n {i ? (\n \n this.onMoveUp(i)}\n >\n \n \n \n ) : (\n
\n )}\n {i < value.length - 1 ? (\n \n this.onMoveDown(i)}\n >\n \n \n \n ) : (\n
\n )}\n {!schema.noDelete ? (\n \n \n \n \n \n ) : null}\n {schema.clone ? (\n \n \n \n \n \n ) : null}\n \n \n \n ))}\n {!schema.noDelete && value.length > 0 ? (\n \n \n \n \n \n ) : null}\n {schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigAccordion;\n","import React, { type JSX } from 'react';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\nimport type { ConfigItemAlive } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n root: {\n width: '100%',\n },\n notAlive: {\n color: '#a30000',\n },\n};\n\ninterface ConfigAliveProps extends ConfigGenericProps {\n schema: ConfigItemAlive;\n}\n\ninterface ConfigAliveState extends ConfigGenericState {\n alive?: boolean | null;\n instance?: string;\n}\n\nclass ConfigAlive extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n\n const instance = this.getInstance();\n\n void this.props.oContext.socket\n .getState(`${instance}.alive`)\n .then(state => this.setState({ alive: !!(state && state.val), instance }));\n }\n\n getInstance(): string {\n let instance =\n this.props.schema.instance || `${this.props.oContext.adapterName}.${this.props.oContext.instance}`;\n if (instance.includes('${')) {\n instance = this.getPattern(instance, null, true);\n }\n if (instance && !instance.startsWith('system.adapter.')) {\n instance = `system.adapter.${instance}`;\n }\n return instance;\n }\n\n renderItem(): JSX.Element | null {\n if (this.getInstance() !== this.state.instance) {\n setTimeout(() => {\n const instance = this.getInstance();\n if (instance) {\n void this.props.oContext.socket\n .getState(`${instance}.alive`)\n .then(state => this.setState({ alive: !!(state && state.val), instance }));\n } else {\n this.setState({ alive: null, instance });\n }\n }, 200);\n }\n\n if (this.state.alive !== false && this.state.alive !== true) {\n return null;\n }\n\n const instance = this.state.instance.replace(/^system.adapter./, '');\n return (\n
\n {this.state.alive\n ? this.props.schema.textAlive !== undefined\n ? this.props.schema.textAlive\n ? I18n.t(this.props.schema.textAlive, instance)\n : ''\n : I18n.t('ra_Instance %s is alive', instance)\n : this.props.schema.textNotAlive !== undefined\n ? this.props.schema.textNotAlive\n ? I18n.t(this.props.schema.textNotAlive, instance)\n : ''\n : I18n.t('ra_Instance %s is not alive', instance)}\n
\n );\n }\n}\n\nexport default ConfigAlive;\n","import React, { type JSX } from 'react';\n\nimport { Autocomplete, TextField } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemAutocomplete, ConfigItemSelectOption } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericState, type ConfigGenericProps } from './ConfigGeneric';\n\nexport interface ConfigAutocompleteProps extends ConfigGenericProps {\n schema: ConfigItemAutocomplete;\n}\n\nexport interface ConfigAutocompleteState extends ConfigGenericState {\n selectOptions: { value: string; label: string }[];\n}\n\nclass ConfigAutocomplete extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n\n const selectOptions: { label: string; value: string }[] = this.props.schema.options.map(\n (item: { label: string; value: string } | string) =>\n typeof item === 'string' ? { label: item, value: item } : JSON.parse(JSON.stringify(item)),\n );\n\n // if __different\n if (Array.isArray(value)) {\n selectOptions.unshift({\n label: I18n.t(ConfigGeneric.DIFFERENT_LABEL),\n value: ConfigGeneric.DIFFERENT_VALUE,\n });\n this.setState({ value: ConfigGeneric.DIFFERENT_VALUE, selectOptions });\n } else {\n this.setState({ value, selectOptions });\n }\n }\n\n renderItem(error: unknown, disabled: boolean): JSX.Element | null {\n if (!this.state.selectOptions) {\n return null;\n }\n\n let item;\n const options: ConfigItemSelectOption[] = JSON.parse(JSON.stringify(this.state.selectOptions));\n const isIndeterminate = Array.isArray(this.state.value) || this.state.value === ConfigGeneric.DIFFERENT_VALUE;\n\n if (isIndeterminate) {\n [...this.state.value]\n .filter(val => !options.find(it => (typeof it === 'object' ? it.value === val : it === val)))\n .forEach(it => options.push({ label: it.toString(), value: it }));\n\n item = { label: I18n.t(ConfigGeneric.DIFFERENT_LABEL), value: ConfigGeneric.DIFFERENT_VALUE };\n options.unshift(item);\n } else {\n item =\n this.state.value !== null &&\n this.state.value !== undefined &&\n options.find(_item =>\n typeof _item === 'object' ? _item.value == this.state.value : _item == this.state.value,\n ); // let \"==\" be and not ===\n\n if (this.state.value !== null && this.state.value !== undefined && !item && this.props.schema.freeSolo) {\n item = { value: this.state.value, label: this.state.value };\n options.push(item);\n }\n }\n\n return (\n option.value === value.value}\n filterOptions={(options: { value: string; label: string }[], params) => {\n const filtered = options.filter(option => {\n if (params.inputValue === '') {\n return true;\n }\n return (\n option.label.toLowerCase().includes(params.inputValue.toLowerCase()) ||\n option.value.toLowerCase().includes(params.inputValue.toLowerCase())\n );\n });\n\n if (this.props.schema.freeSolo && params.inputValue !== '') {\n filtered.push({\n label: params.inputValue,\n value: params.inputValue,\n });\n }\n\n return filtered;\n }}\n // autoComplete\n onInputChange={e => {\n if (!e || !this.props.schema.freeSolo) {\n return;\n }\n\n const val = (e.target as HTMLInputElement).value;\n if (val !== this.state.value) {\n this.setState({ value: val }, () => this.onChange(this.props.attr, val));\n }\n }}\n onChange={(_, value) => {\n const val = typeof value === 'object' ? (value ? value.value : '') : value;\n if (val !== this.state.value) {\n this.setState({ value: val }, () => this.onChange(this.props.attr, val));\n }\n }}\n getOptionLabel={option => (typeof option === 'object' ? (option?.label ?? '') : '')}\n renderInput={params => (\n \n )}\n />\n );\n }\n}\n\nexport default ConfigAutocomplete;\n","import React, { type JSX } from 'react';\n\nimport { Autocomplete, TextField } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemAutocompleteSendTo } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps } from './ConfigGeneric';\nimport type { ConfigAutocompleteState } from './ConfigAutocomplete';\n\ninterface ConfigAutocompleteSendToProps extends ConfigGenericProps {\n schema: ConfigItemAutocompleteSendTo;\n}\n\nclass ConfigAutocompleteSendTo extends ConfigGeneric {\n private initialized = false;\n\n private localContext: string | undefined;\n\n askInstance(): void {\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n const selectOptions = this.props.schema.options\n ? this.props.schema.options.map((item: any) =>\n typeof item === 'string' ? { label: item, value: item } : JSON.parse(JSON.stringify(item)),\n )\n : [];\n\n if (this.props.alive) {\n let data = this.props.schema.data;\n if (data === undefined && this.props.schema.jsonData) {\n const dataStr: string = this.getPattern(this.props.schema.jsonData, null, true);\n try {\n if (typeof dataStr === 'string') {\n data = JSON.parse(dataStr);\n }\n } catch {\n console.error(`Cannot parse json data: ${JSON.stringify(data)}`);\n }\n }\n\n if (data === undefined) {\n data = null;\n }\n\n void this.props.oContext.socket\n .sendTo(\n `${this.props.oContext.adapterName}.${this.props.oContext.instance}`,\n this.props.schema.command || 'send',\n data,\n )\n .then((list: unknown) => {\n if (list && Array.isArray(list)) {\n list.forEach(item =>\n selectOptions.push(\n typeof item === 'string'\n ? { label: item, value: item }\n : JSON.parse(JSON.stringify(item)),\n ),\n );\n }\n\n // if __different\n if (Array.isArray(value)) {\n selectOptions.unshift({\n label: I18n.t(ConfigGeneric.DIFFERENT_LABEL),\n value: ConfigGeneric.DIFFERENT_VALUE,\n });\n this.setState({ value: ConfigGeneric.DIFFERENT_VALUE, selectOptions });\n } else {\n this.setState({ value, selectOptions });\n }\n });\n } else if (Array.isArray(value)) {\n // if __different\n selectOptions.unshift({\n label: I18n.t(ConfigGeneric.DIFFERENT_LABEL),\n value: ConfigGeneric.DIFFERENT_VALUE,\n });\n this.setState({ value: ConfigGeneric.DIFFERENT_VALUE, selectOptions });\n } else {\n this.setState({ value, selectOptions });\n }\n }\n\n getContext(): string {\n const localContext: Record = {};\n if (Array.isArray(this.props.schema.alsoDependsOn)) {\n this.props.schema.alsoDependsOn.forEach(\n attr => (localContext[attr] = ConfigGeneric.getValue(this.props.data, attr)),\n );\n }\n return JSON.stringify(localContext);\n }\n\n renderItem(error: unknown, disabled: boolean): JSX.Element | null {\n if (this.props.alive) {\n const localContext = this.getContext();\n if (localContext !== this.localContext || !this.initialized) {\n this.localContext = localContext;\n setTimeout(() => this.askInstance(), this.initialized ? 300 : 50);\n this.initialized = true;\n }\n }\n\n let item;\n const options: { value: string; label: string }[] = this.state.selectOptions\n ? JSON.parse(JSON.stringify(this.state.selectOptions))\n : [];\n const isIndeterminate = Array.isArray(this.state.value) || this.state.value === ConfigGeneric.DIFFERENT_LABEL;\n\n if (isIndeterminate) {\n [...this.state.value]\n .filter(val => !options.find((it: any) => it.value === val))\n .forEach(it => options.push({ label: it.toString(), value: it }));\n\n item = { label: I18n.t(ConfigGeneric.DIFFERENT_LABEL), value: ConfigGeneric.DIFFERENT_VALUE };\n options.unshift(item);\n } else {\n item =\n this.state.value !== null &&\n this.state.value !== undefined &&\n options.find((item: any) => item.value == this.state.value); // let \"==\" be and not ===\n\n if (this.state.value !== null && this.state.value !== undefined && !item && this.props.schema.freeSolo) {\n item = { value: this.state.value, label: this.state.value };\n options.push(item);\n }\n item = item || null;\n }\n\n if (!options.length) {\n return (\n {\n const value = e.target.value;\n this.setState({ value }, () => this.onChange(this.props.attr, (value || '').trim()));\n }}\n placeholder={this.getText(this.props.schema.placeholder)}\n label={this.getText(this.props.schema.label)}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n />\n );\n }\n return (\n option.value === value.value}\n filterOptions={(options: { value: string; label: string }[], params) => {\n const filtered = options.filter(option => {\n if (params.inputValue === '') {\n return true;\n }\n return (\n option.label.toLowerCase().includes(params.inputValue.toLowerCase()) ||\n option.value.toLowerCase().includes(params.inputValue.toLowerCase())\n );\n });\n\n if (this.props.schema.freeSolo && params.inputValue !== '') {\n filtered.push({\n label: params.inputValue,\n value: params.inputValue,\n });\n }\n\n return filtered;\n }}\n getOptionLabel={(option: { value: string; label: string }): string => option?.label ?? ''}\n onInputChange={e => {\n if (!e || !this.props.schema.freeSolo) {\n return;\n }\n\n const val = (e.target as HTMLInputElement).value;\n if (val !== this.state.value) {\n this.setState({ value: val }, () => this.onChange(this.props.attr, val));\n }\n }}\n onChange={(_, value) => {\n const val = typeof value === 'object' ? (value ? value.value : '') : value;\n if (val !== this.state.value) {\n this.setState({ value: val }, () => this.onChange(this.props.attr, val));\n }\n }}\n renderInput={params => (\n \n )}\n />\n );\n }\n}\n\nexport default ConfigAutocompleteSendTo;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, FormControl, Button, TextField } from '@mui/material';\n\nimport { DialogCron, I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemCRON } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n flex: {\n display: 'flex',\n },\n button: {\n height: 48,\n marginLeft: 4,\n minWidth: 48,\n },\n};\n\ninterface ConfigCRONProps extends ConfigGenericProps {\n schema: ConfigItemCRON;\n}\n\ninterface ConfigCRONState extends ConfigGenericState {\n showDialog?: boolean;\n}\n\nclass ConfigCRON extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const { data, attr } = this.props;\n const value = ConfigGeneric.getValue(data, attr) || '';\n this.setState({ value, showDialog: false });\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n const { schema, attr } = this.props;\n const { value, showDialog } = this.state;\n\n return (\n \n {schema.label ? {this.getText(schema.label)} : null}\n
\n {\n const value_ = e.target.value;\n this.setState({ value: value_ }, () => this.onChange(attr, value_));\n }}\n />\n this.setState({ showDialog: true })}\n >\n ...\n \n
\n {showDialog ? (\n this.setState({ showDialog: false })}\n cancel={I18n.t('ra_Cancel')}\n ok={I18n.t('ra_Ok')}\n theme={this.props.oContext.theme}\n onOk={value_ =>\n this.setState({ showDialog: false, value: value_ }, () => this.onChange(attr, value_))\n }\n />\n ) : null}\n \n );\n }\n}\n\nexport default ConfigCRON;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, MenuItem, FormControl, Select, FormHelperText } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\nimport type { ConfigItemCertificateSelect } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigCertificateSelectProps extends ConfigGenericProps {\n schema: ConfigItemCertificateSelect;\n}\n\ninterface ConfigCertificateSelectState extends ConfigGenericState {\n selectOptions?: { label: string; value: string }[];\n}\n\nclass ConfigCertificateSelect extends ConfigGeneric {\n async componentDidMount(): Promise {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n // Important: getCertificates is only available in AdminConnection\n const certificates = await this.props.oContext.socket.getCertificates();\n\n const selectOptions: { label: string; value: string }[] = certificates\n .filter(el => {\n const name = this.props.attr.toLowerCase();\n\n if (name.includes(el.type)) {\n return true;\n }\n if (el.type === 'public' && name.includes('cert')) {\n return true;\n }\n if (el.type === 'private' && (name.includes('priv') || name.includes('key'))) {\n return true;\n }\n return !!(el.type === 'chained' && (name.includes('chain') || name.includes('ca')));\n })\n .map(el => ({ label: el.name, value: el.name }));\n\n selectOptions.unshift({ label: I18n.t(ConfigGeneric.NONE_LABEL), value: ConfigGeneric.NONE_VALUE });\n\n this.setState({ value, selectOptions });\n }\n\n renderItem(error: unknown, disabled: boolean /* , defaultValue */): JSX.Element | null {\n if (!this.state.selectOptions) {\n return null;\n }\n\n const item = this.state.selectOptions?.find(_item => _item.value === this.state.value);\n\n return (\n \n {this.props.schema.label ? (\n {this.getText(this.props.schema.label)}\n ) : null}\n this.getText(item?.label, this.props.schema.noTranslation !== false)}\n onChange={e =>\n this.setState({ value: e.target.value }, () => this.onChange(this.props.attr, this.state.value))\n }\n >\n {this.state.selectOptions?.map(item_ => (\n \n {this.getText(item_.label, this.props.schema.noTranslation !== false)}\n \n ))}\n \n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigCertificateSelect;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, MenuItem, FormControl, Select } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\nimport type { ConfigItemCertificates } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n leWidth: {\n width: 620,\n marginBottom: 10,\n },\n certWidth: {\n width: 200,\n marginRight: 10,\n },\n};\n\ninterface ConfigCertificatesProps extends ConfigGenericProps {\n schema: ConfigItemCertificates;\n}\n\ninterface ConfigCertificatesState extends ConfigGenericState {\n certsPublicOptions?: { label: string; value: string }[];\n certsChainOptions?: { label: string; value: string }[];\n certsPrivateOptions?: { label: string; value: string }[];\n collectionsOptions?: string[];\n}\n\nclass ConfigCertificates extends ConfigGeneric {\n async componentDidMount(): Promise {\n super.componentDidMount();\n // Important: getCertificates is only available in AdminConnection\n const certificates = await this.props.oContext.socket.getCertificates();\n const certsPublicOptions: { label: string; value: string }[] = [];\n const certsPrivateOptions: { label: string; value: string }[] = [];\n const certsChainOptions: { label: string; value: string }[] = [];\n\n let collectionsOptions: string[] | null = [];\n const collectionsOptionsObj = await this.props.oContext.socket.getObject('system.certificates');\n if (collectionsOptionsObj?.native?.collections) {\n collectionsOptions = Object.keys(collectionsOptionsObj.native.collections);\n } else {\n collectionsOptions = null;\n }\n\n certificates.forEach(el => {\n if (el.type === 'public') {\n certsPublicOptions.push({ label: el.name, value: el.name });\n } else if (el.type === 'private') {\n certsPrivateOptions.push({ label: el.name, value: el.name });\n } else if (el.type === 'chained') {\n certsChainOptions.push({ label: el.name, value: el.name });\n } else {\n certsPublicOptions.push({ label: el.name, value: el.name });\n certsPrivateOptions.push({ label: el.name, value: el.name });\n certsChainOptions.push({ label: el.name, value: el.name });\n }\n });\n\n certsPublicOptions.unshift({ label: I18n.t(ConfigGeneric.NONE_LABEL), value: ConfigGeneric.NONE_VALUE });\n certsPrivateOptions.unshift({ label: I18n.t(ConfigGeneric.NONE_LABEL), value: ConfigGeneric.NONE_VALUE });\n certsChainOptions.unshift({ label: I18n.t(ConfigGeneric.NONE_LABEL), value: ConfigGeneric.NONE_VALUE });\n\n this.setState({\n certsPublicOptions,\n certsChainOptions,\n certsPrivateOptions,\n collectionsOptions,\n });\n }\n\n renderItem(error: unknown, disabled: boolean /* , defaultValue */): JSX.Element | null {\n if (!this.state.certsPublicOptions || !this.state.certsPrivateOptions || !this.state.certsChainOptions) {\n return null;\n }\n const leCollection = (\n ConfigGeneric.getValue(this.props.data, this.props.schema.leCollectionName || 'leCollection') || 'false'\n ).toString();\n const certPublic = ConfigGeneric.getValue(this.props.data, this.props.schema.certPublicName || 'certPublic');\n const certPrivate = ConfigGeneric.getValue(this.props.data, this.props.schema.certPrivateName || 'certPrivate');\n const certChained = ConfigGeneric.getValue(this.props.data, this.props.schema.certChainedName || 'certChained');\n\n const itemCertPublic = this.state.certsPublicOptions?.find(item => item.value === certPublic);\n const itemCertPrivate = this.state.certsPrivateOptions?.find(item => item.value === certPrivate);\n const itemCertChained = this.state.certsChainOptions?.find(item => item.value === certChained);\n\n return (\n
\n {this.state.collectionsOptions ? (\n \n Let's encrypt\n \n this.onChange(\n this.props.schema.leCollectionName || 'leCollection',\n e.target.value === 'false'\n ? false\n : e.target.value === 'true'\n ? true\n : e.target.value,\n )\n }\n >\n \n {I18n.t(\"ra_Do not use let's encrypt\")}\n \n \n {I18n.t(\"ra_Use all available let's encrypt certificates\")}\n \n {this.state.collectionsOptions?.map(item => (\n \n {item}\n \n ))}\n \n \n ) : null}\n {this.state.collectionsOptions ?
: null}\n {this.state.collectionsOptions && leCollection !== 'false' ? (\n
{I18n.t('ra_Fallback custom certificates')}
\n ) : null}\n \n {I18n.t('ra_Public certificate')}\n this.getText(itemCertPublic?.label)}\n onChange={e => this.onChange(this.props.schema.certPublicName || 'certPublic', e.target.value)}\n >\n {this.state.certsPublicOptions?.map((item, i) => (\n \n {this.getText(item.label)}\n \n ))}\n \n \n \n {I18n.t('ra_Private certificate')}\n this.getText(itemCertPrivate?.label)}\n onChange={e =>\n this.onChange(this.props.schema.certPrivateName || 'certPrivate', e.target.value)\n }\n >\n {this.state.certsPrivateOptions?.map((item, i) => (\n \n {this.getText(item.label)}\n \n ))}\n \n \n \n {I18n.t('ra_Chained certificate')}\n this.getText(itemCertChained?.label)}\n onChange={e =>\n this.onChange(this.props.schema.certChainedName || 'certChained', e.target.value)\n }\n >\n {this.state.certsChainOptions?.map((item, i) => (\n \n {this.getText(item.label)}\n \n ))}\n \n \n
\n );\n }\n}\n\nexport default ConfigCertificates;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, MenuItem, FormControl, Select, FormHelperText } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\nimport type { ConfigItemCertCollection } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigCertCollectionProps extends ConfigGenericProps {\n schema: ConfigItemCertCollection;\n}\n\ninterface ConfigCertCollectionState extends ConfigGenericState {\n collectionsOptions?: string[];\n}\n\ninterface CertCollection {\n /** Source of the certificate */\n from: string;\n key: string;\n cert: string;\n chain: string[];\n domains: string[];\n staging?: boolean;\n tsExpires?: number;\n}\n\nclass ConfigCertCollection extends ConfigGeneric {\n async componentDidMount(): Promise {\n super.componentDidMount();\n\n let collectionsOptions: string[];\n const collectionsOptionsObj = await this.props.oContext.socket.getObject('system.certificates');\n if (collectionsOptionsObj?.native?.collections) {\n collectionsOptions = Object.keys(\n collectionsOptionsObj.native.collections as Record,\n );\n } else {\n collectionsOptions = [];\n }\n this.setState({ collectionsOptions });\n }\n\n renderItem(error: unknown, disabled: boolean /* , defaultValue */): JSX.Element {\n if (!this.state.collectionsOptions) {\n return null;\n }\n const leCollection = (\n ConfigGeneric.getValue(this.props.data, this.props.schema.leCollectionName || 'leCollection') || 'false'\n ).toString();\n\n return (\n \n {this.props.schema.label ? (\n {this.getText(this.props.schema.label)}\n ) : null}\n \n this.onChange(\n this.props.schema.leCollectionName || 'leCollection',\n e.target.value === 'false' ? false : e.target.value === 'true' ? true : e.target.value,\n )\n }\n >\n \n {I18n.t(\"ra_Do not use let's encrypt\")}\n \n \n {I18n.t(\"ra_Use all available let's encrypt certificates\")}\n \n {this.state.collectionsOptions?.map(item => (\n \n {item}\n \n ))}\n \n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigCertCollection;\n","import React, { type JSX } from 'react';\n\nimport {\n Button,\n CircularProgress,\n Dialog,\n DialogContent,\n DialogActions,\n DialogTitle,\n Table,\n TableHead,\n TableCell,\n TableRow,\n TableBody,\n DialogContentText,\n TableContainer,\n Box,\n} from '@mui/material';\n\nimport { Check as IconCheck, Send as IconSend } from '@mui/icons-material';\n\nimport { DialogConfirm, I18n, type IobTheme } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemCheckLicense } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n icon: {\n width: 24,\n height: 24,\n marginRight: 4,\n },\n licLabel: {\n fontWeight: 'bold',\n minWidth: 100,\n marginRight: 10,\n textTransform: 'capitalize',\n display: 'inline-block',\n },\n licValue: {\n fontWeight: 'normal',\n },\n errorTitle: (theme: IobTheme): React.CSSProperties => ({\n color: theme.palette.mode === 'dark' ? '#e39191' : '#b62020',\n }),\n okTitle: (theme: IobTheme): React.CSSProperties => ({\n color: theme.palette.mode === 'dark' ? '#6fd56f' : '#007c00',\n }),\n errorText: (theme: IobTheme): any => ({\n color: theme.palette.mode === 'dark' ? '#e39191' : '#b62020',\n mb: '30px',\n }),\n};\n\nexport interface License {\n id: string;\n product: string;\n time: number;\n uuid: string;\n validTill: string;\n version: string;\n usedBy: string;\n invoice: string;\n json: string;\n}\n\ninterface LicenseResult {\n id: string;\n validName: boolean;\n validUuid: boolean;\n validVersion: boolean;\n validTill: boolean;\n license: License;\n used?: boolean;\n}\n\ninterface ConfigCheckLicenseProps extends ConfigGenericProps {\n schema: ConfigItemCheckLicense;\n fullWidth?: boolean;\n}\n\ninterface ConfigCheckLicenseState extends ConfigGenericState {\n showLicenseData: null | Record;\n _error: string;\n result: null | boolean;\n running: boolean;\n foundSuitableLicense: boolean;\n licenseOfflineCheck: boolean;\n showLinkToProfile: boolean;\n allLicenses: null | LicenseResult[];\n askForUpdate: boolean;\n}\n\nclass ConfigCheckLicense extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n this.setState({\n _error: '',\n running: false,\n showLicenseData: null,\n foundSuitableLicense: false,\n licenseOfflineCheck: false,\n result: null,\n allLicenses: null,\n askForUpdate: false,\n showLinkToProfile: false,\n });\n }\n\n renderErrorDialog(): JSX.Element | null {\n if (this.state._error && !this.state.showLicenseData) {\n let content: string | JSX.Element[] = this.state._error;\n if (this.state.allLicenses) {\n content = [
{content}
];\n content.push(\n window.open('https://iobroker.net/www/account/licenses', '_blank')}\n >\n {I18n.t('iobroker.net')}\n ,\n );\n if (!this.state.allLicenses.length) {\n content.push(
{I18n.t('ra_No one license found in license manager')}
);\n content.push(
{I18n.t('ra_Please create license')}
);\n } else {\n // license.id,\n // validName,\n // validUuid,\n // validTill,\n // validVersion,\n // license,\n content.push(\n \n \n \n \n {I18n.t('ra_Product')}\n {I18n.t('ra_Version')}\n UUID\n {I18n.t('ra_ValidTill')}\n {I18n.t('ra_Commercial')}\n ID\n \n \n \n {this.state.allLicenses.map(license => (\n \n \n {license.license.product}\n \n \n {license.license.version}\n \n \n {license.license.uuid || '--'}\n \n \n {license.license.validTill &&\n license.license.validTill !== '0000-00-00 00:00:00'\n ? new Date(license.license.validTill).toLocaleDateString()\n : '--'}\n \n \n {license.license.invoice !== 'free'\n ? license.license.invoice === 'MANUALLY_CREATED'\n ? '✓'\n : license.license.invoice\n : '-'}\n \n {license.id}\n \n ))}\n \n
\n
,\n );\n }\n }\n\n return (\n this.setState({ _error: '', allLicenses: null })}\n >\n {I18n.t('ra_Error')}\n \n {content}\n \n \n this.setState({ _error: '', allLicenses: null })}\n color=\"primary\"\n autoFocus\n startIcon={}\n >\n {I18n.t('ra_Ok')}\n \n \n \n );\n }\n\n return null;\n }\n\n renderMessageDialog(): JSX.Element | null {\n if (this.state.showLicenseData) {\n const pre = [];\n const data = this.state.showLicenseData;\n Object.keys(data).forEach(key => {\n if (data[key] === null || data[key] === undefined) {\n return;\n }\n if (typeof data[key] === 'object') {\n const obj = data[key];\n Object.keys(obj).forEach(key1 => {\n if (obj[key1] !== null && obj[key1] !== undefined) {\n if (typeof obj[key1] === 'object') {\n pre.push(\n
\n
{key1}:
\n {JSON.stringify(obj[key1], null, 2)}\n
,\n );\n } else {\n pre.push(\n
\n
\n {key} -{key1}:\n
\n {obj[key1].toString()}\n
,\n );\n }\n }\n });\n } else {\n pre.push(\n
\n
{key.replace(/_/g, ' ')}:
\n {data[key].toString()}\n
,\n );\n }\n });\n pre.push(\n
\n
{I18n.t('ra_Checked')}:
\n {this.state.licenseOfflineCheck ? I18n.t('ra_locally') : I18n.t('ra_via internet')}\n
,\n );\n\n return (\n this.setState({ showLicenseData: null })}\n >\n \n \n {I18n.t('ra_License %s', this.state.result ? 'OK' : 'INVALID')}\n \n \n \n {this.state.showLinkToProfile ? (\n window.open('https://iobroker.net/www/account/licenses', '_blank')}\n >\n https://iobroker.net\n \n ) : null}\n {this.state._error ? (\n \n {this.state._error}\n \n ) : null}\n {pre}\n \n \n this.setState({ showLicenseData: null, _error: '' })}\n color=\"primary\"\n variant=\"contained\"\n >\n {I18n.t('ra_Close')}\n \n \n \n );\n }\n return null;\n }\n\n static parseJwt(token: string): {\n exp: number;\n iat: number;\n name: string;\n email: string;\n uuid: string;\n version: string;\n invoice: string;\n /** @deprecated use validTill */\n valid_till: string;\n validTill: string;\n [key: string]: string | number;\n } | null {\n const base64Url = token.split('.')[1];\n const base64 = base64Url.replace(/-/g, '+').replace(/_/g, '/');\n const jsonPayload = decodeURIComponent(\n atob(base64)\n .split('')\n .map(c => `%${`00${c.charCodeAt(0).toString(16)}`.slice(-2)}`)\n .join(''),\n );\n try {\n return JSON.parse(jsonPayload);\n } catch {\n return null;\n }\n }\n\n static isVersionValid(version: string, rule: string, invoice: string, adapterName: string): boolean {\n if (!rule || !version) {\n return true;\n }\n let result = true;\n const [major] = version.split('.');\n if (rule.startsWith('>=')) {\n result = parseInt(major, 10) >= parseInt(rule.substring(2, 10));\n } else if (rule.startsWith('<=')) {\n result = parseInt(major, 10) <= parseInt(rule.substring(2, 10));\n } else if (rule.startsWith('>')) {\n result = parseInt(major, 10) > parseInt(rule.substring(1, 10));\n } else if (rule.startsWith('<')) {\n result = parseInt(major, 10) < parseInt(rule.substring(1, 10));\n } else if (rule.startsWith('=')) {\n result = parseInt(major, 10) === parseInt(rule.substring(1, 10));\n } else if (rule.startsWith('==')) {\n result = parseInt(major, 10) === parseInt(rule.substring(2, 10));\n } else if (rule.startsWith('===')) {\n result = parseInt(major, 10) === parseInt(rule.substring(3, 10));\n }\n\n if (!result && invoice && adapterName) {\n // all commercial licenses are valid for all versions\n if (invoice !== 'free') {\n return true;\n }\n }\n\n return true;\n }\n\n async findInLicenseManager(adapterName: string): Promise {\n // read if the license manager is supported\n const licenses = await this.props.oContext.socket.getObject('system.licenses');\n const errors: LicenseResult[] = [];\n if (licenses?.native?.licenses?.length) {\n // enable license manager\n let useLicense: License | null = null;\n const now = Date.now();\n\n let uuid: string;\n if (this.props.schema.uuid) {\n const uuidObj = await this.props.oContext.socket.getObject('system.meta.uuid');\n uuid = uuidObj?.native?.uuid;\n }\n let version: string;\n if (this.props.schema.version) {\n const aObj = await this.props.oContext.socket.getObject(`system.adapter.${adapterName}`);\n version = aObj?.common?.version;\n }\n\n // find license for vis\n licenses.native.licenses.forEach((license: License) => {\n const validTill =\n !license.validTill ||\n license.validTill === '0000-00-00 00:00:00' ||\n new Date(license.validTill).getTime() > now;\n const parts = (license.product || '').split('.');\n const validName = parts[1] === adapterName || (adapterName === 'vis-2' && parts[1] === 'vis');\n const validUuid = !uuid || !license.uuid || license.uuid === uuid;\n const validVersion = ConfigCheckLicense.isVersionValid(\n version,\n license.version,\n license.invoice,\n adapterName,\n );\n // commercial license has priority over free license\n if (\n (!useLicense || license.invoice !== 'free') &&\n validTill &&\n validName &&\n validUuid &&\n validVersion\n ) {\n useLicense = license;\n }\n errors.push({\n id: license.id,\n validName,\n validUuid,\n validVersion,\n validTill,\n license,\n });\n });\n\n if (useLicense) {\n errors.find(e => e.id === useLicense.id).used = true;\n }\n }\n\n return errors;\n }\n\n async checkLicense(license: string, adapterName: string): Promise {\n let uuid;\n if (this.props.schema.uuid) {\n const uuidObj = await this.props.oContext.socket.getObject('system.meta.uuid');\n uuid = uuidObj?.native?.uuid;\n }\n let version;\n if (this.props.schema.version) {\n const aObj = await this.props.oContext.socket.getObject(`system.adapter.${adapterName}`);\n version = aObj?.common?.version;\n }\n\n const controller = new AbortController();\n let timeout = setTimeout(() => {\n timeout = null;\n controller.abort();\n }, 5000);\n\n try {\n const response = await window.fetch('https://iobroker.net/api/v1/public/cert/', {\n method: 'POST',\n body: JSON.stringify({ json: license, uuid }),\n headers: {\n 'Content-Type': 'text/plain',\n },\n signal: controller.signal,\n });\n if (timeout) {\n clearTimeout(timeout);\n }\n const dataStr = await response.text();\n let data: {\n error?: string;\n validTill?: string;\n /** @deprecated use validTill */\n valid_till?: string;\n name?: string;\n version?: string;\n uuid?: string;\n invoice?: string;\n };\n try {\n data = JSON.parse(dataStr);\n } catch {\n // ignore\n }\n\n if (data?.error) {\n try {\n const data_ = ConfigCheckLicense.parseJwt(license);\n const _error = I18n.t(`ra_${data_.error || data.error || 'Unknown error'}`).replace(/^ra_/, '');\n\n return this.setState({\n _error,\n licenseOfflineCheck: false,\n showLicenseData: data_,\n result: false,\n running: false,\n });\n } catch {\n console.log('Cannot parse license');\n return this.setState({ _error: data.error, result: false, running: false });\n }\n } else {\n let showLicenseData = null;\n try {\n showLicenseData = ConfigCheckLicense.parseJwt(license);\n } catch {\n // ignore\n }\n if (data) {\n const validTill = data.validTill || data.valid_till;\n if (\n validTill &&\n validTill !== '0000-00-00 00:00:00' &&\n new Date(validTill).getTime() < Date.now()\n ) {\n return this.setState({\n _error: I18n.t('ra_License expired on %s', new Date(validTill).toLocaleString()),\n licenseOfflineCheck: false,\n showLicenseData,\n result: false,\n running: false,\n });\n }\n const parts = (data.name || '').split('.');\n if (parts[1] === adapterName || (parts[1] === 'vis' && adapterName === 'vis-2')) {\n // check UUID\n if (uuid && !data.uuid && adapterName === 'vis-2') {\n return this.setState({\n _error: I18n.t('ra_License must be converted', data.uuid),\n showLinkToProfile: true,\n licenseOfflineCheck: false,\n showLicenseData,\n result: false,\n running: false,\n });\n }\n\n if (uuid && data.uuid && data.uuid !== uuid) {\n return this.setState({\n _error: I18n.t(\n 'ra_Serial number (UUID) \"%s\" in license is for other device.',\n data.uuid,\n ),\n licenseOfflineCheck: false,\n showLicenseData,\n result: false,\n running: false,\n });\n }\n\n if (!ConfigCheckLicense.isVersionValid(version, data.version, data.invoice, adapterName)) {\n return this.setState({\n _error: I18n.t(\n 'ra_License is for version %s, but required version is %s',\n data.version,\n this.props.schema.version,\n ),\n licenseOfflineCheck: false,\n showLicenseData,\n result: false,\n running: false,\n });\n }\n\n return this.setState({\n licenseOfflineCheck: false,\n showLicenseData,\n result: true,\n running: false,\n });\n }\n return this.setState({\n _error: I18n.t('ra_License for other product \"%s\"', data.name),\n licenseOfflineCheck: false,\n showLicenseData,\n result: false,\n running: false,\n });\n }\n throw new Error('ra_Invalid answer from server');\n }\n } catch (error) {\n if (error?.response?.status === 404) {\n return this.setState({ _error: I18n.t('ra_License does not exist'), result: false, running: false });\n }\n // check offline\n try {\n const data = ConfigCheckLicense.parseJwt(license);\n const parts = (data.name || '').split('.');\n\n if (\n data.valid_till &&\n data.valid_till !== '0000-00-00 00:00:00' &&\n new Date(data.valid_till).getTime() < Date.now()\n ) {\n return this.setState({\n _error: I18n.t('ra_License expired on %s', new Date(data.valid_till).toLocaleString()),\n showLicenseData: data,\n licenseOfflineCheck: true,\n running: false,\n result: false,\n });\n }\n if (parts[1] === adapterName) {\n // check UUID\n if (uuid && data.uuid && data.uuid !== uuid) {\n return this.setState({\n _error: I18n.t('ra_Serial number (UUID) \"%s\" in license is for other device.', data.uuid),\n showLicenseData: data,\n licenseOfflineCheck: true,\n result: false,\n running: false,\n });\n }\n\n if (!ConfigCheckLicense.isVersionValid(version, data.version, data.invoice, adapterName)) {\n return this.setState({\n _error: I18n.t(\n 'ra_License is for version %s, but required version is %s',\n data.version,\n this.props.schema.version,\n ),\n licenseOfflineCheck: true,\n showLicenseData: data,\n result: false,\n running: false,\n });\n }\n\n return this.setState({\n running: false,\n result: true,\n licenseOfflineCheck: true,\n showLicenseData: data,\n });\n }\n return this.setState({\n _error: I18n.t('ra_License for other product \"%s\"', data.name),\n licenseOfflineCheck: true,\n showLicenseData: data,\n result: false,\n running: false,\n });\n } catch {\n return this.setState({\n _error: I18n.t('ra_Cannot decode license'),\n result: false,\n licenseOfflineCheck: true,\n running: false,\n });\n }\n }\n }\n\n renderAskForUpdate(): JSX.Element | null {\n if (!this.state.askForUpdate) {\n return null;\n }\n return (\n {\n if (isYes) {\n this.setState({ askForUpdate: false });\n try {\n // updateLicense is available only in AdminConnection\n await this.props.oContext.socket.updateLicenses(null, null);\n } catch (e) {\n window.alert(I18n.t('ra_Cannot read licenses: %s', e));\n return;\n }\n await this._onClick(true);\n } else {\n this.setState({ askForUpdate: false, running: false });\n }\n }}\n />\n );\n }\n\n async _onClick(secondRun?: boolean): Promise {\n const adapterName = this.props.oContext.adapterName === 'vis-2' ? 'vis' : this.props.oContext.adapterName;\n this.setState({ running: true });\n let license;\n let licenses;\n if (this.props.data.useLicenseManager) {\n licenses = await this.findInLicenseManager(adapterName);\n license = licenses.find(li => li.used);\n if (license) {\n license = license.license.json;\n }\n if (!license && !secondRun) {\n // no suitable license found in the license manager\n // should we read all licenses again?\n this.setState({ askForUpdate: true });\n return;\n }\n } else {\n license = this.props.data.license;\n }\n if (license) {\n await this.checkLicense(license, adapterName);\n } else if (this.props.data.useLicenseManager) {\n this.setState({\n _error: I18n.t('ra_Suitable license not found in license manager'),\n result: false,\n running: false,\n allLicenses: licenses,\n });\n } else {\n // this case could not happen\n this.setState({\n _error: I18n.t('ra_Please enter the license'),\n result: false,\n running: false,\n });\n }\n }\n\n renderItem(/* error, disabled, defaultValue */): JSX.Element {\n return (\n
\n }\n onClick={() => this._onClick()}\n >\n {this.state.running ? (\n \n ) : null}\n {this.getText(this.props.schema.label || 'ra_Check license', this.props.schema.noTranslation)}\n \n {this.renderMessageDialog()}\n {this.renderErrorDialog()}\n {this.renderAskForUpdate()}\n
\n );\n }\n}\n\nexport default ConfigCheckLicense;\n","import React, { type JSX } from 'react';\n\nimport { FormControlLabel, Checkbox, FormHelperText, FormControl } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemCheckbox } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigCheckboxProps extends ConfigGenericProps {\n schema: ConfigItemCheckbox;\n}\n\nclass ConfigCheckbox extends ConfigGeneric {\n renderItem(error: unknown, disabled: boolean): JSX.Element {\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n const isIndeterminate = Array.isArray(value);\n\n return (\n \n {\n e.preventDefault();\n e.stopPropagation();\n\n if (!disabled) {\n const mayByPromise = this.onChange(this.props.attr, !value);\n if (mayByPromise instanceof Promise) {\n void mayByPromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n }\n }}\n control={\n {\n let mayBePromise: void | Promise;\n if (isIndeterminate) {\n mayBePromise = this.onChange(this.props.attr, true);\n } else {\n mayBePromise = this.onChange(this.props.attr, e.target.checked);\n }\n if (mayBePromise instanceof Promise) {\n void mayBePromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n }}\n disabled={disabled || this.props.schema.readOnly}\n />\n }\n label={this.getText(this.props.schema.label)}\n />\n \n {error\n ? this.props.schema.validatorErrorText\n ? I18n.t(this.props.schema.validatorErrorText)\n : I18n.t('ra_Error')\n : null}\n \n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigCheckbox;\n","/**\n * Notice: Some code was adapted from Material-UI's text field.\n * Copyright (c) 2014 Call-Em-All (https://github.com/callemall/material-ui)\n */\nimport React, { type RefObject, type JSX } from 'react';\nimport ReactDOM from 'react-dom';\n\nimport { Input, OutlinedInput, InputLabel, Chip, FormControl, FormHelperText, Box } from '@mui/material';\nimport FilledInput from '@mui/material/FilledInput/FilledInput';\nimport blue from '@mui/material/colors/blue';\n\nimport { type IobTheme, type ThemeType, Utils } from '@iobroker/adapter-react-v5';\n\nconst variantComponent = {\n standard: Input,\n filled: FilledInput,\n outlined: OutlinedInput,\n};\n\nconst styles: Record = (theme: IobTheme): Record => {\n const light = theme.palette.mode === 'light';\n const bottomLineColor = light ? 'rgba(0, 0, 0, 0.42)' : 'rgba(255, 255, 255, 0.7)';\n\n return {\n root: {},\n inputRoot: {\n display: 'inline-flex',\n flexWrap: 'wrap',\n flex: 1,\n marginTop: 0,\n minWidth: 70,\n '&.mui-variant-outlined,&.mui-variant-filled': {\n boxSizing: 'border-box',\n },\n '&.mui-variant-outlined': {\n paddingTop: '14px',\n },\n '&.mui-variant-filled': {\n paddingTop: '28px',\n },\n },\n input: {\n display: 'inline-block',\n textOverflow: 'ellipsis',\n overflow: 'hidden',\n whiteSpace: 'nowrap',\n appearance: 'none', // Remove border in Safari, doesn't seem to break anything in other browsers\n WebkitTapHighlightColor: 'rgba(0,0,0,0)', // Remove mobile color flashing (deprecated style).\n float: 'left',\n flex: 1,\n },\n chipContainer: {\n display: 'flex',\n flexFlow: 'row wrap',\n alignItems: 'center',\n cursor: 'text',\n marginBottom: '-2px',\n minHeight: 40,\n },\n outlined: {\n '& input': {\n height: 16,\n paddingTop: '4px',\n paddingBottom: '12px',\n marginTop: '4px',\n marginBottom: '4px',\n },\n },\n standard: {\n marginTop: '18px',\n },\n filled: {\n '& input': {\n height: 22,\n marginBottom: '4px',\n marginTop: '4px',\n paddingTop: 0,\n },\n '$marginDense & input': {\n height: 26,\n },\n },\n labeled: {},\n label: {\n top: 4,\n '&$outlined&:not($labelShrink)': {\n top: 2,\n '$marginDense &': {\n top: 5,\n },\n },\n '&$filled&:not($labelShrink)': {\n top: 15,\n '$marginDense &': {\n top: 20,\n },\n },\n },\n labelShrink: {\n top: 0,\n },\n helperText: {\n marginBottom: -20,\n },\n focused: {},\n disabled: {},\n underline: {\n '&:after': {\n borderBottom: `2px solid ${theme.palette.primary[light ? 'dark' : 'light']}`,\n left: 0,\n bottom: 0,\n // Doing the other way around a crash on IE 11 \"''\" https://github.com/cssinjs/jss/issues/242\n content: '\"\"',\n position: 'absolute',\n right: 0,\n transform: 'scaleX(0)',\n transition: theme.transitions.create('transform', {\n duration: theme.transitions.duration.shorter,\n easing: theme.transitions.easing.easeOut,\n }),\n pointerEvents: 'none', // Transparent to the hover style.\n },\n '&$focused:after': {\n transform: 'scaleX(1)',\n },\n '&$error:after': {\n borderBottomColor: theme.palette.error.main,\n transform: 'scaleX(1)', // error is always underlined in red\n },\n '&:before': {\n borderBottom: `1px solid ${bottomLineColor}`,\n left: 0,\n bottom: 0,\n // Doing the other way around a crash on IE 11 \"''\" https://github.com/cssinjs/jss/issues/242\n content: '\"\\\\00a0\"',\n position: 'absolute',\n right: 0,\n transition: theme.transitions.create('border-bottom-color', {\n duration: theme.transitions.duration.shorter,\n }),\n pointerEvents: 'none', // Transparent to the hover style.\n },\n '&:hover:not($disabled):not($focused):not($error):before': {\n borderBottom: `2px solid ${theme.palette.text.primary}`,\n // Reset on touch devices, it doesn't add specificity\n '@media (hover: none)': {\n borderBottom: `1px solid ${bottomLineColor}`,\n },\n },\n '&$disabled:before': {\n borderBottomStyle: 'dotted',\n },\n },\n error: {\n '&:after': {\n backgroundColor: theme.palette.error.main,\n transform: 'scaleX(1)', // error is always underlined in red\n },\n },\n chip: {\n margin: '0 8px 8px 0',\n float: 'left',\n },\n marginDense: {},\n };\n};\n\nconst keyCodes = {\n BACKSPACE: 8,\n DELETE: 46,\n LEFT_ARROW: 37,\n RIGHT_ARROW: 39,\n};\n\ninterface ChipRendererProps {\n value: string;\n isFocused: boolean;\n isDisabled: boolean;\n isReadOnly: boolean;\n handleClick: () => void;\n handleDelete: () => void;\n style: React.CSSProperties;\n}\n\nexport const defaultChipRenderer = (\n { value, isFocused, isDisabled, isReadOnly, handleClick, handleDelete, style }: ChipRendererProps,\n key: string,\n): JSX.Element => (\n \n);\n\ninterface ChipInputProps {\n /** Allows duplicate chips if set to true. */\n allowDuplicates?: boolean;\n /** If true, the placeholder will always be visible. */\n alwaysShowPlaceholder?: boolean;\n /** Behavior when the chip input is blurred: `'clear'` clears the input, `'add'` creates a chip and `'ignore'` keeps the input. */\n blurBehavior?: 'clear' | 'add' | 'add-or-clear' | 'ignore';\n /** A function of the type `({ value, text, chip, isFocused, isDisabled, isReadOnly, handleClick, handleDelete, className }, key) => node` that returns a chip based on the given properties. This can be used to customize chip styles. Each item in the `dataSource` array will be passed to `chipRenderer` as arguments `chip`, `value` and `text`. If `dataSource` is an array of objects and `dataSourceConfig` is present, then `value` and `text` will instead correspond to the object values defined in `dataSourceConfig`. If `dataSourceConfig` is not set and `dataSource` is an array of objects, then a custom `chipRenderer` must be set. `chip` is always the raw value from `dataSource`, either an object or a string. */\n chipRenderer?: (props: ChipRendererProps) => JSX.Element;\n /** Whether the input value should be cleared if the `value` prop is changed. */\n clearInputValueOnChange?: boolean;\n /** Data source for auto complete. This should be an array of strings or objects. */\n dataSource?: string[];\n /** The chips to display by default (for uncontrolled mode). */\n defaultValue?: string[];\n /** Whether to use `setTimeout` to delay adding chips in case other input events like `onSelection` need to fire first */\n delayBeforeAdd?: boolean;\n /** Disables the chip input if set to true. */\n disabled?: boolean;\n /** Disable the input underline. Only valid for 'standard' variant */\n disableUnderline?: boolean;\n /** Props to pass through to the `FormHelperText` component. */\n FormHelperTextProps?: Record;\n /** If true, the chip input will fill the available width. */\n fullWidth?: boolean;\n /** If true, the input field will always be below the chips and fill the available space. By default, it will try to be beside the chips. */\n fullWidthInput?: boolean;\n /** Helper text that is displayed below the input. */\n helperText?: string | JSX.Element;\n /** Props to pass through to the `InputLabel`. */\n InputLabelProps?: Record;\n /** Props to pass through to the `Input`. */\n InputProps?: Record;\n /** Use this property to pass a ref callback to the native input component. */\n inputRef?: (el: HTMLInputElement) => void;\n /** The input value (enables controlled mode for the text input if set). */\n inputValue?: string;\n /* The content of the floating label. */\n label?: string | JSX.Element;\n /** The key codes (`KeyboardEvent.keyCode`) used to determine when to create a new chip. */\n newChipKeyCodes?: number[];\n /** The keys (`KeyboardEvent.key`) used to determine when to create a new chip. */\n newChipKeys?: string[];\n /** Callback function that is called when a new chip was added (in controlled mode). */\n onAdd?: (chip: string) => void;\n /** Callback function that is called with the chip to be added and should return true to add the chip or false to prevent the chip from being added without clearing the text input. */\n onBeforeAdd?: (chip: string) => boolean;\n onBlur?: (event: React.FocusEvent) => void;\n onFocus?: (event: React.FocusEvent) => void;\n onKeyDown?: (event: React.KeyboardEvent) => void;\n onKeyUp?: (event: React.KeyboardEvent) => void;\n // onKeyPress?: (event: React.KeyboardEvent) => void;\n /** Callback function that is called when the chips change (in uncontrolled mode). */\n onChange?: (chips: string[]) => void;\n /** Callback function that is called when a new chip was removed (in controlled mode). */\n onDelete: (chip: string, i: number) => void;\n /** Callback function that is called when the input changes. */\n onUpdateInput?: (e: React.ChangeEvent) => void;\n /** A placeholder that is displayed if the input has no values. */\n placeholder?: string;\n /** Makes the chip input read-only if set to true. */\n readOnly?: boolean;\n /** The chips to display (enables controlled mode if set). */\n value?: string[];\n /** The variant of the Input component */\n variant?: 'outlined' | 'standard' | 'filled';\n className?: string;\n error?: boolean;\n id?: string;\n required?: boolean;\n rootRef?: RefObject;\n margin?: 'dense' | 'normal' | 'none';\n theme: IobTheme;\n}\n\ninterface ChipInputState {\n chips: string[];\n focusedChip: number | null;\n inputValue: string;\n isFocused: boolean;\n chipsUpdated: boolean;\n prevPropsValue: string[];\n variant: 'outlined' | 'standard' | 'filled';\n}\n\nclass ChipInput extends React.Component {\n private readonly labelRef: React.RefObject;\n\n private labelNode: HTMLLabelElement | null = null;\n\n private readonly input: React.RefObject;\n\n private readonly newChipKeyCodes: number[];\n\n private readonly newChipKeys: string[];\n\n private actualInput: HTMLInputElement | null = null;\n\n private inputBlurTimeout: ReturnType | null = null;\n\n private _keyPressed: boolean;\n\n private _preventChipCreation: boolean;\n\n private styles: Record = {};\n\n private styleTheme: ThemeType | null = null;\n\n constructor(props: ChipInputProps) {\n super(props);\n this.state = {\n chips: props.defaultValue || [],\n focusedChip: null,\n inputValue: '',\n isFocused: false,\n chipsUpdated: false,\n prevPropsValue: [],\n variant: this.props.variant || 'standard',\n };\n this.newChipKeyCodes = props.newChipKeyCodes || [13];\n this.newChipKeys = props.newChipKeys || ['Enter'];\n\n this.labelRef = React.createRef();\n this.input = React.createRef();\n }\n\n componentDidMount(): void {\n if (this.state.variant === 'outlined') {\n // eslint-disable-next-line react/no-find-dom-node\n this.labelNode = ReactDOM.findDOMNode(this.labelRef.current) as HTMLLabelElement;\n this.forceUpdate();\n }\n }\n\n componentWillUnmount(): void {\n if (this.inputBlurTimeout) {\n clearTimeout(this.inputBlurTimeout);\n }\n }\n\n static getDerivedStateFromProps(props: ChipInputProps, state: ChipInputState): Partial | null {\n let newState: Partial | null = null;\n\n if (props.value && props.value.length !== state.prevPropsValue.length) {\n newState = { prevPropsValue: props.value };\n if (props.clearInputValueOnChange) {\n newState.inputValue = '';\n }\n }\n\n // if change detection is only necessary for clearInputValueOnChange\n if (props.clearInputValueOnChange && props.value && props.value.length !== state.prevPropsValue.length) {\n newState = { prevPropsValue: props.value, inputValue: '' };\n }\n\n if (props.disabled) {\n newState = { ...newState, focusedChip: null };\n }\n\n if (!state.chipsUpdated && props.defaultValue) {\n newState = { ...newState, chips: props.defaultValue };\n }\n\n return newState;\n }\n\n /**\n * Blurs this component.\n */\n // blur() {\n // if (this.input) {\n // this.actualInput.blur();\n // }\n // }\n\n /**\n * Focuses this component.\n */\n focus = (): void => {\n this.actualInput?.focus();\n if (this.state.focusedChip) {\n this.setState({ focusedChip: null });\n }\n };\n\n handleInputBlur = (event: React.FocusEvent): void => {\n if (this.props.onBlur) {\n this.props.onBlur(event);\n }\n this.setState({ isFocused: false });\n if (this.state.focusedChip) {\n this.setState({ focusedChip: null });\n }\n const value = event.target.value;\n let addChipOptions: { clearInputOnFail: boolean };\n switch (this.props.blurBehavior || 'clear') {\n case 'add-or-clear':\n addChipOptions = { clearInputOnFail: true };\n // falls through\n case 'add':\n if (this.props.delayBeforeAdd) {\n // Let's assume that we only want to add the existing content as chip, when\n // another event has not added a chip within 200ms.\n // e.g., onSelection Callback in Autocomplete case\n const numChipsBefore = (this.props.value || this.state.chips).length;\n this.inputBlurTimeout = setTimeout(() => {\n const numChipsAfter = (this.props.value || this.state.chips).length;\n if (numChipsBefore === numChipsAfter) {\n this.handleAddChip(value, addChipOptions);\n } else {\n this.clearInput();\n }\n }, 150);\n } else {\n this.handleAddChip(value, addChipOptions);\n }\n break;\n\n case 'clear':\n this.clearInput();\n break;\n\n default:\n break;\n }\n };\n\n handleInputFocus = (event: React.FocusEvent): void => {\n this.setState({ isFocused: true });\n if (this.props.onFocus) {\n this.props.onFocus(event);\n }\n };\n\n handleKeyDown = (event: React.KeyboardEvent): void => {\n const { focusedChip } = this.state;\n this._keyPressed = false;\n this._preventChipCreation = false;\n\n if (this.props.onKeyDown) {\n // Needed for arrow controls on a menu in autocomplete scenario\n this.props.onKeyDown(event);\n // Check if the callback marked the event as isDefaultPrevented() and skip further actions\n // enter key, for example, should not always add the current value of the inputField\n if (event.isDefaultPrevented()) {\n return;\n }\n }\n const chips = this.props.value || this.state.chips;\n if (this.newChipKeyCodes.includes(event.keyCode) || this.newChipKeys.includes(event.key)) {\n const result = this.handleAddChip((event.target as HTMLInputElement).value);\n if (result !== false) {\n event.preventDefault();\n }\n return;\n }\n\n switch (event.keyCode) {\n case keyCodes.BACKSPACE:\n if ((event.target as HTMLInputElement).value === '') {\n if (focusedChip) {\n this.handleDeleteChip(chips[focusedChip], focusedChip);\n if (focusedChip) {\n this.setState({ focusedChip: focusedChip - 1 });\n }\n } else {\n this.setState({ focusedChip: chips.length - 1 });\n }\n }\n break;\n case keyCodes.DELETE:\n if ((event.target as HTMLInputElement).value === '' && focusedChip) {\n this.handleDeleteChip(chips[focusedChip], focusedChip);\n if (focusedChip <= chips.length - 1) {\n this.setState({ focusedChip });\n }\n }\n break;\n case keyCodes.LEFT_ARROW:\n if (focusedChip === null && (event.target as HTMLInputElement).value === '' && chips.length) {\n this.setState({ focusedChip: chips.length - 1 });\n } else if (focusedChip !== null && focusedChip > 0) {\n this.setState({ focusedChip: focusedChip - 1 });\n }\n break;\n case keyCodes.RIGHT_ARROW:\n if (focusedChip !== null && focusedChip < chips.length - 1) {\n this.setState({ focusedChip: focusedChip + 1 });\n } else {\n this.setState({ focusedChip: null });\n }\n break;\n default:\n this.setState({ focusedChip: null });\n break;\n }\n };\n\n handleKeyUp = (event: React.KeyboardEvent): void => {\n if (\n !this._preventChipCreation &&\n (this.newChipKeyCodes.includes(event.keyCode) || this.newChipKeys.includes(event.key)) &&\n this._keyPressed\n ) {\n this.clearInput();\n } else {\n this.updateInput((event.target as HTMLInputElement).value);\n }\n if (this.props.onKeyUp) {\n this.props.onKeyUp(event);\n }\n };\n\n // handleKeyPress = (event: React.KeyboardEvent) => {\n // this._keyPressed = true;\n // if (this.props.onKeyPress) {\n // this.props.onKeyPress(event);\n // }\n // };\n\n handleUpdateInput = (e: React.ChangeEvent): void => {\n if (this.props.inputValue === null || this.props.inputValue === undefined) {\n this.updateInput(e.target.value);\n }\n\n if (this.props.onUpdateInput) {\n this.props.onUpdateInput(e);\n }\n };\n\n /**\n * Handles adding a chip.\n *\n * @param chip Value of the chip, either a string or an object (if dataSourceConfig is set)\n * @param options Additional options\n * @param options.clearInputOnFail If `true`, and `onBeforeAdd` returns `false`, clear the input\n * @returns True if the chip was added (or at least `onAdd` was called), false if adding the chip was prevented\n */\n handleAddChip(chip: string, options?: { clearInputOnFail: boolean }): boolean {\n if (this.props.onBeforeAdd && !this.props.onBeforeAdd(chip)) {\n this._preventChipCreation = true;\n if (options && options.clearInputOnFail) {\n this.clearInput();\n }\n return false;\n }\n this.clearInput();\n const chips = this.props.value || this.state.chips;\n\n if (chip.trim().length) {\n if (this.props.allowDuplicates || !chips.includes(chip)) {\n if (this.props.value && this.props.onAdd) {\n this.props.onAdd(chip);\n } else {\n this.updateChips([...this.state.chips, chip]);\n }\n }\n return true;\n }\n return false;\n }\n\n handleDeleteChip(chip: string, i: number): void {\n if (!this.props.value) {\n const chips = this.state.chips.slice();\n const changed = chips.splice(i, 1); // remove the chip at index i\n if (changed) {\n let focusedChip = this.state.focusedChip;\n if (this.state.focusedChip === i) {\n focusedChip = null;\n } else if (this.state.focusedChip > i) {\n focusedChip = this.state.focusedChip - 1;\n }\n this.updateChips(chips, { focusedChip });\n }\n } else if (this.props.onDelete) {\n this.props.onDelete(chip, i);\n }\n }\n\n updateChips(chips: string[], additionalUpdates = {}): void {\n this.setState({ chips, chipsUpdated: true, ...additionalUpdates });\n if (this.props.onChange) {\n this.props.onChange(chips);\n }\n }\n\n /**\n * Clears the text field for adding new chips.\n * This only works in uncontrolled input mode, i.e., if the inputValue prop is not used.\n */\n clearInput(): void {\n this.updateInput('');\n }\n\n updateInput(value: string): void {\n this.setState({ inputValue: value });\n }\n\n /**\n * Set the reference to the actual input, that is the input of the Input.\n *\n * @param ref - The reference\n */\n setActualInputRef = (ref: HTMLInputElement): void => {\n this.actualInput = ref;\n if (this.props.inputRef) {\n this.props.inputRef(ref);\n }\n };\n\n render(): JSX.Element {\n const {\n alwaysShowPlaceholder,\n chipRenderer = defaultChipRenderer,\n className,\n disabled,\n disableUnderline,\n error,\n FormHelperTextProps,\n fullWidth,\n fullWidthInput,\n helperText,\n id,\n InputProps = {},\n InputLabelProps = {},\n inputValue,\n label,\n placeholder,\n readOnly,\n required,\n rootRef,\n value,\n margin,\n } = this.props;\n const variant = this.state.variant;\n\n if (this.styleTheme !== this.props.theme.palette.mode) {\n this.styleTheme = this.props.theme.palette.mode;\n this.styles = Utils.getStyle(this.props.theme, styles);\n }\n\n let chips = value || this.state.chips || [];\n if (!Array.isArray(chips)) {\n chips = ((chips as string) || '')\n .toString()\n .split(/[,\\s]+/)\n .map((c: string) => c.trim());\n }\n const actualInputValue = inputValue ?? this.state.inputValue;\n\n const hasInput = (this.props.value || actualInputValue).length || actualInputValue.length;\n const shrinkFloatingLabel =\n typeof InputLabelProps.shrink === 'boolean'\n ? InputLabelProps.shrink\n : label !== null && (hasInput || this.state.isFocused || chips.length);\n\n const chipComponents = chips.map((chip, i) =>\n chipRenderer(\n {\n value: chip,\n isDisabled: !!disabled,\n isReadOnly: readOnly,\n isFocused: this.state.focusedChip === i,\n handleClick: () => this.setState({ focusedChip: i }),\n handleDelete: () => this.handleDeleteChip(chip, i),\n style: this.styles.chip,\n },\n i.toString(),\n ),\n );\n\n const InputMore: { notched?: boolean; labelWidth?: number; startAdornment?: JSX.Element[] } = {};\n if (variant === 'outlined') {\n InputMore.notched = !!shrinkFloatingLabel;\n InputMore.labelWidth = (shrinkFloatingLabel && this.labelNode && this.labelNode.offsetWidth) || 0;\n }\n\n if (variant !== 'standard') {\n InputMore.startAdornment = chipComponents;\n } else {\n InputProps.disableUnderline = true;\n }\n\n const InputComponent = variantComponent[variant];\n\n return (\n 0 ? undefined : required}\n onClick={this.focus}\n disabled={disabled}\n variant={variant}\n component=\"div\"\n margin={margin}\n >\n {label && (\n \n {label}\n \n )}\n \n {variant === 'standard' && chipComponents}\n \n \n {helperText && (\n \n {helperText}\n \n )}\n \n );\n }\n}\n\nexport default ChipInput;\n","import React, { type JSX } from 'react';\n\nimport { FormHelperText, FormControl } from '@mui/material';\n\nimport type { ConfigItemChip } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\nimport ChipInput from './ChipInput';\n\ninterface ConfigChipProps extends ConfigGenericProps {\n schema: ConfigItemChip;\n}\n\nclass ConfigChip extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const { data, attr } = this.props;\n const value = ConfigGeneric.getValue(data, attr);\n if (this.props.schema.delimiter && typeof value === 'string') {\n const parts = value\n .split(this.props.schema.delimiter)\n .map(a => a.trim())\n .filter(a => a);\n this.setState({ value: parts });\n } else {\n this.setState({ value: value || [] });\n }\n }\n\n renderItem(error: string, disabled: boolean): JSX.Element | null {\n const { attr, schema } = this.props;\n const { value } = this.state;\n return (\n \n {\n const newValue = JSON.parse(JSON.stringify(value));\n newValue.push(chip);\n this.setState({ value: newValue }, () => {\n let mayBePromise: void | Promise;\n if (this.props.schema.delimiter) {\n mayBePromise = this.onChange(attr, newValue.join(`${this.props.schema.delimiter} `));\n } else {\n mayBePromise = this.onChange(attr, newValue);\n }\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => console.error(e));\n }\n });\n }}\n theme={this.props.oContext.theme}\n onDelete={(_chip, index) => {\n const newValue = JSON.parse(JSON.stringify(value));\n newValue.splice(index, 1);\n this.setState({ value: newValue }, () => {\n let mayBePromise: void | Promise;\n if (this.props.schema.delimiter) {\n mayBePromise = this.onChange(attr, newValue.join(`${this.props.schema.delimiter} `));\n } else {\n mayBePromise = this.onChange(attr, newValue);\n }\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => console.error(e));\n }\n });\n }}\n />\n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigChip;\n","import React, { type JSX } from 'react';\nimport { ChromePicker, type ColorResult } from 'react-color';\n\nimport { IconButton, TextField, Dialog } from '@mui/material';\n\nimport { Close as ClearIcon } from '@mui/icons-material';\n\nimport { Utils } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemText } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigColorProps extends ConfigGenericProps {\n schema: ConfigItemText;\n}\n\ninterface ConfigColorState extends ConfigGenericState {\n showColorDialog?: boolean;\n colorDialogValue?: string;\n}\n\nclass ConfigColor extends ConfigGeneric {\n renderColorDialog(): JSX.Element | null {\n return (\n !!this.state.showColorDialog && (\n this.setState({ showColorDialog: false })}\n open={this.state.showColorDialog}\n >\n \n this.setState({ colorDialogValue: color.hex }, () =>\n this.onChange(this.props.attr, this.state.colorDialogValue),\n )\n }\n />\n \n )\n );\n }\n\n renderItem(_error: unknown, disabled: boolean /* , defaultValue */): JSX.Element {\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n let textColor = Utils.isUseBright(value, null);\n if (textColor === null) {\n textColor = undefined;\n }\n return (\n <>\n {this.renderColorDialog()}\n \n !this.props.schema.readOnly &&\n this.setState({ showColorDialog: true, colorDialogValue: value || '' })\n }\n onChange={e => {\n const color = e.target.value;\n const mayBePromise = this.onChange(this.props.attr, color);\n if (mayBePromise instanceof Promise) {\n void mayBePromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n }}\n slotProps={{\n htmlInput: {\n style: {\n // paddingLeft: noPadding ? 0 : 8,\n backgroundColor: value,\n color: textColor ? '#FFF' : '#000',\n },\n readOnly: this.props.schema.readOnly || false,\n },\n input: {\n endAdornment:\n !this.props.schema.readOnly && value && !this.props.schema.noClearButton ? (\n {\n e.stopPropagation();\n const mayBePromise = this.onChange(this.props.attr, '');\n if (mayBePromise instanceof Promise) {\n void mayBePromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n }}\n >\n \n \n ) : undefined,\n },\n inputLabel: {\n shrink: true,\n },\n }}\n />\n \n );\n }\n}\n\nexport default ConfigColor;\n","import React, { type JSX } from 'react';\n\nimport { TextField, Fab, FormControlLabel, Checkbox } from '@mui/material';\n\nimport { GpsFixed as IconGpsFixed, LocationOn as IconLocationOn } from '@mui/icons-material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemCoordinates } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n width: {\n width: 'calc(100% - 85px)',\n },\n width50: {\n width: 120,\n marginRight: 5,\n },\n};\n\ninterface ConfigCoordinatesProps extends ConfigGenericProps {\n schema: ConfigItemCoordinates;\n}\n\ninterface ConfigCoordinatesState extends ConfigGenericState {\n useSystem?: boolean;\n longitude?: string | number;\n latitude?: string | number;\n}\n\nclass ConfigCoordinates extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n this.setState({ value });\n\n const newState: Partial = {};\n if (this.props.schema.useSystemName) {\n newState.useSystem = !!ConfigGeneric.getValue(this.props.data, this.props.schema.useSystemName);\n }\n if (this.props.schema.longitudeName && this.props.schema.latitudeName) {\n newState.longitude = ConfigGeneric.getValue(this.props.data, this.props.schema.longitudeName);\n newState.latitude = ConfigGeneric.getValue(this.props.data, this.props.schema.latitudeName);\n if (!newState.longitude && !newState.latitude && this.props.schema.autoInit) {\n setTimeout(() => this.getCoordinates(), 300);\n }\n } else {\n const value_ = ConfigGeneric.getValue(this.props.data, this.props.attr);\n if (!value_ && this.props.schema.autoInit) {\n setTimeout(() => this.getCoordinates(), 300);\n }\n }\n if (Object.keys(newState).length) {\n setTimeout(() => this.setState(newState as ConfigCoordinatesState), 50);\n }\n }\n\n async getSystemCoordinates(): Promise {\n const obj = await this.props.oContext.socket.getCompactSystemConfig();\n if (obj?.common && (obj.common.longitude || obj.common.latitude)) {\n window.alert(I18n.t('ra_Used system settings'));\n if (this.props.schema.longitudeName && this.props.schema.latitudeName) {\n this.setState(\n {\n longitude: obj.common.longitude,\n latitude: obj.common.latitude,\n },\n async () => {\n await this.onChange(this.props.schema.longitudeName, obj.common.longitude);\n await this.onChange(this.props.schema.latitudeName, obj.common.latitude);\n },\n );\n } else {\n const value = obj.common.latitude + (this.props.schema.divider || ',') + obj.common.longitude;\n this.setState(\n {\n value,\n },\n () => {\n const mayByPromise = this.onChange(this.props.attr, value);\n if (mayByPromise instanceof Promise) {\n mayByPromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n },\n );\n }\n } else {\n window.alert(\n I18n.t(\n 'ra_Cannot determine position: System settings are empty and GPS detection is disabled in browser',\n ),\n );\n }\n }\n\n getCoordinates(): void {\n if (navigator.geolocation) {\n navigator.geolocation.getCurrentPosition(\n async (position: GeolocationPosition): Promise => {\n if (position?.coords) {\n if (this.props.schema.longitudeName && this.props.schema.latitudeName) {\n this.setState(\n {\n longitude: position.coords.longitude,\n latitude: position.coords.latitude,\n },\n async () => {\n await this.onChange(\n this.props.schema.longitudeName,\n position.coords.longitude || '',\n );\n await this.onChange(this.props.schema.latitudeName, position.coords.latitude || '');\n },\n );\n } else {\n const value =\n position.coords.latitude +\n (this.props.schema.divider || ',') +\n position.coords.longitude;\n this.setState({ value }, () => {\n const mayByPromise = this.onChange(this.props.attr, value);\n if (mayByPromise instanceof Promise) {\n mayByPromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n });\n }\n } else {\n await this.getSystemCoordinates();\n }\n },\n async (error: GeolocationPositionError): Promise => {\n console.error(`Cannot determine coordinates from browser: ${error.message}`);\n await this.getSystemCoordinates();\n },\n );\n } else {\n void this.getSystemCoordinates().catch(e => {\n console.error(`Cannot determine coordinates: ${e}`);\n });\n }\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n return (\n <>\n {this.props.schema.useSystemName ? (\n {\n const useSystem = e.target.checked;\n if (useSystem) {\n void this.getSystemCoordinates().catch(e =>\n console.error(`Cannot determine coordinates: ${e}`),\n );\n }\n this.setState({ useSystem }, () =>\n this.onChange(this.props.schema.useSystemName, useSystem),\n );\n }}\n />\n }\n label={I18n.t('ra_Use system settings for position')}\n />\n ) : null}\n {this.props.schema.longitudeName && this.props.schema.latitudeName ? (\n {\n const longitude = e.target.value;\n this.setState({ longitude }, () => {\n const mayBePromise = this.onChange(\n this.props.schema.longitudeName,\n (longitude || '').trim(),\n );\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n });\n }}\n label={I18n.t('ra_Longitude')}\n />\n ) : null}\n {this.props.schema.longitudeName && this.props.schema.latitudeName ? (\n {\n const latitude = e.target.value;\n this.setState({ latitude }, () =>\n this.onChange(this.props.schema.latitudeName, (latitude || '').trim()),\n );\n }}\n label={I18n.t('ra_Latitude')}\n />\n ) : null}\n {!this.props.schema.longitudeName || !this.props.schema.latitudeName ? (\n {\n const value = e.target.value;\n this.setState({ value }, () => this.onChange(this.props.attr, (value || '').trim()));\n }}\n placeholder={this.getText(this.props.schema.placeholder)}\n label={this.getText(this.props.schema.label)}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n />\n ) : null}\n {!this.state.useSystem ? (\n this.getCoordinates()}\n title={I18n.t('ra_Take browser position')}\n style={{ marginRight: 4 }}\n >\n \n \n ) : null}\n {!this.state.useSystem ? (\n this.getSystemCoordinates()}\n title={I18n.t('ra_Take position from system settings')}\n >\n \n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigCoordinates;\n","import React, { type JSX } from 'react';\nimport { Grid2, LinearProgress } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\nimport type { ConfigItemCustom } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from '#JC/JsonConfigComponent/ConfigGeneric';\n\nconst getOrLoadRemote = (\n remote: string,\n shareScope: string,\n remoteFallbackUrl?: string,\n): Promise<{ get: (module: string) => () => Promise<{ default: Record> }> }> =>\n new Promise((resolve, reject) => {\n // check if remote exists on the global `window`object\n if (!(window as any)[remote]) {\n // search dom to see if remote tag exists, but might still be loading (async)\n const existingRemote: HTMLScriptElement = document.querySelector(`script[data-webpack=\"${remote}\"]`);\n // when remote is loaded.\n const onload = async (): Promise => {\n // check if it was initialized\n if ((window as any)[remote]) {\n if (!(window as any)[remote].__initialized) {\n // if share scope doesn't exist (like in webpack 4) then expect shareScope to be a manual object\n // @ts-expect-error it is a trick and must be so\n if (typeof __webpack_share_scopes__ === 'undefined') {\n // use a default share scope object passed in manually\n await (window as any)[remote].init(shareScope);\n } else {\n // otherwise, init share scope as usual\n // @ts-expect-error it is a trick and must be so\n await (window as any)[remote].init((__webpack_share_scopes__ as any)[shareScope]);\n }\n // mark remote as initialized\n (window as any)[remote].__initialized = true;\n }\n } else {\n console.error(`Cannot load ${remote}`);\n reject(new Error(`Cannot load ${remote}`));\n return;\n }\n // resolve promise so marking remote as loaded\n resolve((window as any)[remote]);\n };\n\n if (existingRemote) {\n // if existing remote but not loaded, hook into its onload and wait for it to be ready\n existingRemote.onload = onload;\n existingRemote.onerror = reject;\n // check if remote fallback exists as param passed to function\n // TODO: should scan public config for a matching key if no override exists\n } else if (remoteFallbackUrl) {\n // inject remote if a fallback exists and call the same onload function\n const d = document;\n const script = d.createElement('script');\n script.type = 'text/javascript';\n // mark as data-webpack so runtime can track it internally\n script.setAttribute('data-webpack', `${remote}`);\n script.async = true;\n script.onerror = reject;\n script.onload = onload;\n script.src = remoteFallbackUrl;\n d.getElementsByTagName('head')[0].appendChild(script);\n } else {\n // no remote and no fallback exist, reject\n reject(new Error(`Cannot Find Remote ${remote} to inject`));\n }\n } else {\n // remote already instantiated, resolve\n resolve((window as any)[remote]);\n }\n });\n\nfunction loadComponent(\n remote: string,\n sharedScope: string,\n module: string,\n url: string,\n): () => Promise<{ default: Record> }> {\n return async (): Promise<{ default: Record> }> => {\n const container = await getOrLoadRemote(remote, sharedScope, url);\n // eslint-disable-next-line @typescript-eslint/await-thenable\n const factory = await container.get(module);\n return factory();\n };\n}\n\ninterface ConfigCustomProps extends ConfigGenericProps {\n schema: ConfigItemCustom;\n}\n\ninterface ConfigCustomState extends ConfigGenericState {\n Component: React.FC | null;\n error: string;\n}\n\nexport default class ConfigCustom extends ConfigGeneric {\n static runningLoads: Record> }>> = {};\n\n constructor(props: ConfigCustomProps) {\n super(props);\n // schema.url - location of Widget\n // schema.name - Component name\n // schema.i18n - i18n\n\n Object.assign(this.state, {\n Component: null,\n error: '',\n });\n }\n\n // load component dynamically\n async componentDidMount(): Promise {\n if (!this.props.schema.url) {\n console.error('URL is empty. Cannot load custom component!');\n this.setState({ error: 'URL is empty. Cannot load custom component!' });\n return;\n }\n\n let url;\n /*\n if (this.props.schema.url.startsWith('http:') || this.props.schema.url.startsWith('https:')) {\n url = this.props.schema.url;\n } else\n */\n if (this.props.schema.url.startsWith('./')) {\n url = `${window.location.protocol}//${window.location.host}${this.props.schema.url.replace(/^\\./, '')}`;\n } else {\n url = `${window.location.protocol}//${window.location.host}/adapter/${this.props.oContext.adapterName}/${this.props.schema.url}`;\n }\n const [uniqueName, fileToLoad, ...componentNameParts] = this.props.schema.name.split('/');\n const componentName = componentNameParts.join('/');\n if (!url) {\n console.error(\n 'Cannot find URL for custom component! Please define \"url\" as \"custom/customComponents.js\" in the schema',\n );\n return;\n }\n if (!uniqueName || !fileToLoad || !componentName) {\n console.error(\n 'Invalid format of \"name\"! Please define \"name\" as \"ConfigCustomBackItUpSet/Components/AdapterExist\" in the schema',\n );\n return;\n }\n let setPromise: Promise<{ default: Record> }> | undefined =\n ConfigCustom.runningLoads[`${url}!${fileToLoad}`];\n\n if (!(setPromise instanceof Promise)) {\n let i18nPromise: Promise | undefined;\n if (this.props.schema.i18n === true) {\n // load i18n from files\n const pos = url.lastIndexOf('/');\n let i18nURL: string;\n if (pos !== -1) {\n i18nURL = url.substring(0, pos);\n } else {\n i18nURL = url;\n }\n const lang = I18n.getLanguage();\n const file = `${i18nURL}/i18n/${lang}.json`;\n\n i18nPromise = fetch(file)\n .then(data => data.json())\n .then(json => I18n.extendTranslations(json, lang))\n .catch(error => {\n if (lang !== 'en') {\n // try to load English\n fetch(`${i18nURL}/i18n/en.json`)\n .then(data => data.json())\n .then(json => I18n.extendTranslations(json, lang))\n .catch(err => console.log(`Cannot load i18n \"${file}\": ${err}`));\n return;\n }\n console.log(`Cannot load i18n \"${file}\": ${error}`);\n });\n } else if (this.props.schema.i18n && typeof this.props.schema.i18n === 'object') {\n try {\n I18n.extendTranslations(this.props.schema.i18n);\n } catch (error) {\n console.error(`Cannot import i18n: ${error}`);\n }\n }\n try {\n console.log(uniqueName, fileToLoad, componentName);\n setPromise = loadComponent(uniqueName, 'default', `./${fileToLoad}`, url)();\n if (i18nPromise instanceof Promise) {\n setPromise = Promise.all([setPromise, i18nPromise]).then(result => result[0]);\n }\n // remember promise\n ConfigCustom.runningLoads[`${url}!${fileToLoad}`] = setPromise;\n } catch (error) {\n this.setState({ error: `Cannot import from ${this.props.schema.url}: ${error}` });\n }\n }\n\n try {\n const component: Record> = (await setPromise).default;\n\n if (!component?.[componentName]) {\n const keys = Object.keys(component || {});\n console.error('URL is empty. Cannot load custom component!');\n this.setState({\n error: `Component ${this.props.schema.name} not found in ${this.props.schema.url}. Found: ${keys.join(', ')}`,\n });\n } else {\n this.setState({ Component: component[componentName] });\n }\n } catch (error) {\n this.setState({ error: `Cannot import from ${this.props.schema.url}: ${error}` });\n }\n }\n\n render(): JSX.Element {\n const CustomComponent: React.FC = this.state.Component;\n\n // render temporary placeholder\n if (!CustomComponent) {\n const schema = this.props.schema || ({} as ConfigItemCustom);\n\n const item = (\n \n {this.state.error ?
{this.state.error}
: }\n \n );\n\n if (schema.newLine) {\n return (\n <>\n
\n {item}\n \n );\n }\n return item;\n }\n\n return ;\n }\n}\n","import React, { type JSX } from 'react';\n\nimport { DatePicker } from '@mui/x-date-pickers';\n\nimport type { ConfigItemDatePicker } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps } from './ConfigGeneric';\n\ninterface ConfigDatePickerProps extends ConfigGenericProps {\n schema: ConfigItemDatePicker;\n}\n\nexport default class ConfigDatePicker extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n this.setState({ value });\n }\n\n renderItem(_error: unknown, disabled: boolean /* , defaultValue */): JSX.Element {\n return (\n ({\n width: '100%',\n borderBottom: `1px solid ${theme.palette.text.primary}`,\n '& fieldset': {\n display: 'none',\n },\n '& input': {\n padding: `${theme.spacing(1.5)} 0 4px 0`,\n },\n '& .MuiInputAdornment-root': {\n marginLeft: 0,\n marginTop: 1, // it is already in spaces\n },\n '& label': {\n transform: 'translate(0px, -9px) scale(0.75)',\n },\n })}\n format={this.props.oContext.systemConfig.dateFormat.toLowerCase().replace('mm', 'MM')}\n disabled={!!disabled}\n value={this.state.value as never}\n onChange={value => {\n this.setState({ value }, () => this.onChange(this.props.attr, this.state.value));\n }}\n label={this.getText(this.props.schema.label)}\n />\n );\n }\n}\n","import React, { type JSX } from 'react';\n\nimport type { ConfigItemDeviceManager } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigDeviceManagerProps extends ConfigGenericProps {\n schema: ConfigItemDeviceManager;\n}\n\nclass ConfigDeviceManager extends ConfigGeneric {\n renderItem(): JSX.Element | null {\n const schema = this.props.schema;\n\n if (!schema) {\n return null;\n }\n\n if (this.props.oContext.DeviceManager) {\n const DeviceManager = this.props.oContext.DeviceManager;\n return (\n \n );\n }\n\n return
DeviceManager not found
;\n }\n}\n\nexport default ConfigDeviceManager;\n","import React, { type JSX } from 'react';\nimport Dropzone, { type DropzoneRef } from 'react-dropzone';\n\nimport {\n InputLabel,\n MenuItem,\n FormHelperText,\n FormControl,\n Select,\n IconButton,\n ListItemText,\n ListItemIcon,\n} from '@mui/material';\n\nimport {\n Refresh as IconRefresh,\n UploadFile as IconUpload,\n Delete as IconDelete,\n PlayArrow as IconPlay,\n MusicNote as IconAudio,\n Videocam as IconVideo,\n Article as IconText,\n Code as IconCode,\n} from '@mui/icons-material';\nimport { UploadFile as UploadIcon } from '@mui/icons-material';\n\nimport { DialogConfirm, Utils, I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemFileSelector } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n fullWidthOneButton: {\n width: 'calc(100% - 42px)',\n },\n fullWidthTwoButtons: {\n width: 'calc(100% - 84px)',\n },\n fullWidthThreeButtons: {\n width: 'calc(100% - 126x)',\n },\n dropZone: {\n width: '100%',\n height: '100%',\n position: 'absolute',\n },\n dropZoneEmpty: {},\n image: {\n objectFit: 'contain',\n margin: 'auto',\n display: 'flex',\n width: '100%',\n height: '100%',\n },\n uploadDiv: {\n position: 'relative',\n width: '100%',\n },\n uploadDivDragging: {\n opacity: 1,\n background: 'rgba(128,255,128,0.1)',\n },\n uploadCenterDiv: {\n margin: 5,\n border: '3px dashed grey',\n borderRadius: 5,\n width: '100%',\n height: '100%',\n position: 'absolute',\n display: 'flex',\n },\n uploadCenterIcon: {\n paddingTop: 10,\n width: 48,\n height: 48,\n },\n uploadCenterText: {\n fontSize: 16,\n },\n uploadCenterTextAndIcon: {\n textAlign: 'center',\n position: 'absolute',\n top: 0,\n bottom: 0,\n left: 0,\n right: 0,\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n },\n disabledOpacity: {\n opacity: 0.3,\n cursor: 'default',\n },\n error: {\n border: '2px solid red',\n },\n deleteButton: {},\n selectedImage: {\n height: 40,\n width: 40,\n display: 'inline-block',\n marginRight: 8,\n },\n};\n\nconst IMAGE_EXT = ['jpg', 'jpeg', 'svg', 'png', 'webp', 'gif', 'apng', 'avif', 'webp'];\nconst AUDIO_EXT = ['mp3', 'ogg', 'wav', 'aac'];\nconst VIDEO_EXT = ['avi', 'mp4', 'mov'];\nconst DOC_EXT = ['txt', 'log', 'html', 'htm'];\nconst JS_EXT = ['json', 'js', 'ts'];\n\ninterface ConfigFileSelectorProps extends ConfigGenericProps {\n schema: ConfigItemFileSelector;\n}\n\ninterface ConfigFileSelectorState extends ConfigGenericState {\n uploadFile?: boolean | 'dragging';\n uploadError?: boolean;\n files?: { name: string; size: string }[];\n deleteFile?: string;\n}\n\nclass ConfigFileSelector extends ConfigGeneric {\n private readonly dropzoneRef: React.RefObject;\n\n private readonly imagePrefix: string;\n\n private objectID: string;\n\n private path: string;\n\n constructor(props: ConfigFileSelectorProps) {\n super(props);\n this.dropzoneRef = React.createRef();\n this.imagePrefix = this.props.oContext.imagePrefix === undefined ? './files' : this.props.oContext.imagePrefix;\n }\n\n componentDidMount(): void {\n super.componentDidMount();\n\n this.objectID = (this.props.schema.objectID || '0_userdata.0').replace(\n '%INSTANCE%',\n (this.props.oContext.instance || 0).toString(),\n );\n this.path = this.props.schema.upload;\n if (this.path) {\n if (this.path === '/') {\n this.path = '';\n } else if (!this.path.endsWith('/')) {\n this.path = `${this.path}/`;\n }\n }\n\n // read files\n void this.updateFiles().then(() => {\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n this.setState({ value });\n });\n }\n\n updateFiles(): Promise {\n return this.readFiles(this.props.schema.pattern).then(files => this.setState({ files }));\n }\n\n async readFolder(\n folderName: string,\n files: { name: string; size: string }[],\n filter: string,\n ): Promise<{ name: string; size: string }[]> {\n try {\n const dirFiles = await this.props.oContext.socket.readDir(\n this.objectID,\n folderName.replace(/^\\//, '') || null,\n );\n for (let f = 0; f < dirFiles.length; f++) {\n const file = dirFiles[f];\n if (file.isDir) {\n // read it\n await this.readFolder(`${folderName + file.file}/`, files, filter);\n } else {\n let ok = false;\n if (filter === '*.*' && file.file.includes('.')) {\n ok = true;\n } else if (!filter || filter === '*') {\n ok = true;\n } else if (filter === '.*' && file.file.startsWith('.')) {\n ok = true;\n } else {\n const regExp = new RegExp(`^${filter.replace(/\\./g, '\\\\.').replace(/\\*/g, '.*')}$`);\n ok = regExp.test(file.file);\n }\n\n if (ok) {\n files.push({\n name: folderName + file.file,\n size: file.stats ? Utils.formatBytes(file.stats.size) : '--',\n });\n }\n }\n }\n } catch (e) {\n console.error(`Cannot read \"${folderName}\": ${e}`);\n }\n\n return files;\n }\n\n async readFiles(pattern: string): Promise<{ name: string; size: string }[]> {\n const files: { name: string; size: string }[] = [];\n pattern = pattern || this.props.schema.pattern;\n if (!pattern) {\n pattern = '**/*.*';\n }\n let filter;\n const pos = pattern.lastIndexOf('/');\n if (pos === -1) {\n filter = pattern;\n } else {\n filter = pattern.substring(pos + 1);\n }\n\n if (pattern.startsWith('**')) {\n // read all folders\n await this.readFolder('/', files, filter);\n } else {\n const pos_ = pattern.lastIndexOf('/');\n if (pos_ === -1) {\n await this.readFolder('/', files, filter);\n } else {\n const folder = pattern.substring(0, pos_ + 1);\n await this.readFolder(folder, files, filter);\n }\n }\n\n return files;\n }\n\n onDrop(acceptedFiles: File[]): void {\n const file = acceptedFiles[0];\n const reader = new FileReader();\n const maxSize = this.props.schema.maxSize || 2 * 1024 * 1024;\n\n reader.onabort = () => console.log('file reading was aborted');\n reader.onerror = () => console.log('file reading has failed');\n reader.onload = () => {\n let ext = `image/${file.name.split('.').pop().toLowerCase()}`;\n if (ext === 'image/jpg') {\n ext = 'image/jpeg';\n } else if (ext.includes('svg')) {\n ext = 'image/svg+xml';\n }\n if (file.size > maxSize) {\n window.alert(I18n.t('File is too big. Max %sk allowed. Try use SVG.', Math.round(maxSize / 1024)));\n return;\n }\n const base64 = `data:${ext};base64,${btoa(\n new Uint8Array(reader.result as ArrayBufferLike).reduce(\n (data, byte) => data + String.fromCharCode(byte),\n '',\n ),\n )}`;\n\n this.props.oContext.socket\n .writeFile64(this.objectID, this.path + file.name, base64)\n .then(() => this.updateFiles())\n .catch(e => window.alert(`Cannot upload file: ${e}`));\n };\n reader.readAsArrayBuffer(file);\n }\n\n renderDeleteDialog(): JSX.Element | null {\n if (!this.state.deleteFile) {\n return null;\n }\n return (\n {\n const deleteFile = this.state.deleteFile;\n this.setState({ deleteFile: '' }, () => {\n if (isOk) {\n this.props.oContext.socket\n .deleteFile(this.objectID, deleteFile)\n .then(() => this.updateFiles())\n .catch(e => window.alert(`Cannot delete file: ${e}`));\n }\n });\n }}\n />\n );\n }\n\n static base64ToArrayBuffer(base64: string): ArrayBufferLike {\n const binaryString = window.atob(base64);\n const len = binaryString.length;\n const bytes = new Uint8Array(len);\n for (let i = 0; i < len; i++) {\n bytes[i] = binaryString.charCodeAt(i);\n }\n return bytes.buffer;\n }\n\n loadFile(): Promise<{ file: string; mimeType: string }> {\n return this.props.oContext.socket.readFile(this.objectID, this.state.value, true);\n }\n\n play(): void {\n void this.loadFile().then(data => {\n if (typeof AudioContext !== 'undefined') {\n const oContext = new AudioContext();\n const buf = ConfigFileSelector.base64ToArrayBuffer(data.file);\n void oContext.decodeAudioData(\n buf,\n (buffer: AudioBuffer): void => {\n const source = oContext.createBufferSource(); // creates a sound source\n source.buffer = buffer; // tell the source which sound to play\n source.connect(oContext.destination); // connect the source to the oContext's destination (the speakers)\n source.start(0);\n },\n (err: DOMException): void => window.alert(`Cannot play: ${err.message}`),\n );\n }\n });\n }\n\n getFileIcon(item: { value: string; label: string; extension?: string }): JSX.Element | null {\n if (!item?.extension) {\n return null;\n }\n if (IMAGE_EXT.includes(item.extension)) {\n return (\n \n );\n }\n if (AUDIO_EXT.includes(item.extension)) {\n return ;\n }\n if (DOC_EXT.includes(item.extension)) {\n return ;\n }\n if (VIDEO_EXT.includes(item.extension)) {\n return ;\n }\n if (JS_EXT.includes(item.extension)) {\n return ;\n }\n return null;\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element | null {\n if (!this.state.files) {\n return null;\n }\n const folders: string[] = [];\n if (!this.props.schema.withFolder) {\n this.state.files.forEach(file => {\n const pos = file.name.lastIndexOf('/');\n if (pos === -1) {\n if (!folders.includes('/')) {\n folders.push('/');\n }\n } else {\n const folder = file.name.substring(0, pos + 1);\n if (!folders.includes(folder)) {\n folders.push(folder);\n }\n }\n });\n }\n\n const selectOptions: { value: string; label: string; extension?: string }[] = this.state.files.map(file => ({\n value: file.name,\n label:\n !this.props.schema.withFolder && folders.length === 1\n ? `${file.name.substring(folders[0].length)}`\n : `${file.name}${this.props.schema.noSize ? '' : `(${file.size})`}`,\n extension: file.name.toLowerCase().split('.').pop(),\n }));\n\n if (!this.props.schema.noNone) {\n selectOptions.unshift({ label: I18n.t('ra_none'), value: '' });\n }\n\n const item: { value: string; label: string; extension?: string } = selectOptions.find(\n _item => _item.value === this.state.value,\n );\n\n let buttons = 0;\n\n if (this.props.schema.upload) {\n buttons++;\n }\n if (this.props.schema.refresh) {\n buttons++;\n }\n const play =\n this.state.value &&\n (this.state.value.endsWith('.mp3') ||\n this.state.value.endsWith('.ogg') ||\n this.state.value.endsWith('.wav'));\n // show play button\n if (play) {\n buttons++;\n }\n\n const element = (\n
\n \n {this.props.schema.label ? {this.getText(this.props.schema.label)} : null}\n (\n <>\n {this.getFileIcon(item)}\n {item?.label || ''}\n \n )}\n onChange={e => {\n this.setState({ value: e.target.value === '_' ? '' : e.target.value }, () =>\n this.onChange(this.props.attr, this.state.value),\n );\n }}\n >\n {selectOptions.map(it => (\n \n {this.getFileIcon(it)}\n {it.label}\n {this.props.schema.delete && item.value ? (\n this.setState({ deleteFile: item.value })}\n >\n \n \n ) : null}\n \n ))}\n \n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n {this.props.schema.refresh && (\n this.updateFiles()}>\n \n \n )}\n {this.props.schema.upload && (\n this.dropzoneRef.current?.open()}>\n \n \n )}\n {play && (\n this.play()}\n >\n \n \n )}\n
\n );\n\n if (!this.props.schema.upload) {\n return (\n <>\n {element}\n {this.renderDeleteDialog()}\n \n );\n }\n let accept: Record = { '*/*': [] };\n if (this.props.schema.fileTypes === 'image') {\n accept = {\n 'image/*': ['.png', '.jpg', '.svg', '.gif', '.apng', '.avif', '.webp'],\n };\n } else if (this.props.schema.fileTypes === 'audio') {\n accept = {\n 'audio/*': ['.mp3', '.ogg', '.wav', '.mp4'],\n };\n } else if (this.props.schema.fileTypes === 'text') {\n accept = {\n 'text/plain': ['.txt'],\n };\n }\n if (this.props.schema.pattern) {\n const last = this.props.schema.pattern.split('/').pop().toLowerCase().replace(/.*\\./, '');\n if (\n last === 'png' ||\n last === 'jpg' ||\n last === 'svg' ||\n last === 'gif' ||\n last === 'apng' ||\n last === 'avif' ||\n last === 'webp'\n ) {\n accept = {\n 'image/*': ['.png', '.jpg', '.svg', '.gif', '.apng', '.avif', '.webp'],\n };\n } else if (last === 'mp3' || last === 'ogg' || last === 'wav') {\n accept = {\n 'audio/*': ['.mp3', '.ogg', '.wav', '.mp4'],\n };\n } else if (last === 'ics') {\n accept = {\n 'text/calendar': ['.ics'],\n };\n } else if (last === 'txt') {\n accept = {\n 'text/plain': ['.txt'],\n };\n } else if (last === 'pem') {\n accept = {\n 'text/plain': ['.pem'],\n };\n } else {\n accept = {\n '*/*': [`.${last}`],\n };\n }\n }\n\n return (\n {\n this.setState({ uploadFile: 'dragging' });\n }}\n onDragLeave={() => this.setState({ uploadFile: true })}\n onDrop={(acceptedFiles, errors) => {\n this.setState({ uploadFile: false });\n if (!acceptedFiles.length) {\n window.alert(\n (errors &&\n errors[0] &&\n errors[0].errors &&\n errors[0].errors[0] &&\n errors[0].errors[0].message) ||\n I18n.t('Cannot upload'),\n );\n } else {\n this.onDrop(acceptedFiles);\n }\n }}\n >\n {({ getRootProps, getInputProps }) => (\n \n \n {this.state.uploadFile === 'dragging' ? (\n \n
\n \n
\n {this.state.uploadFile === 'dragging'\n ? I18n.t('ra_Drop file here')\n : I18n.t(\n 'ra_Place your files here or click here to open the browse dialog',\n )}\n
\n
\n
\n ) : null}\n {element}\n {this.renderDeleteDialog()}\n
\n )}\n \n );\n }\n}\n\nexport default ConfigFileSelector;\n","import React, { type JSX } from 'react';\n\nimport { Button, TextField, IconButton } from '@mui/material';\n\nimport {\n Article as IconText,\n Code as IconCode,\n PlayArrow as IconPlay,\n Videocam as IconVideo,\n} from '@mui/icons-material';\n\nimport { DialogSelectFile } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemFile } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\nimport ConfigFileSelector from './ConfigFileSelector';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n fullWidthOneButton: {\n width: 'calc(100% - 69px)',\n marginRight: 4,\n },\n fullWidthIcon: {\n width: 'calc(100% - 119px)',\n marginRight: 4,\n },\n selectedImage: {\n height: 40,\n width: 40,\n display: 'inline-block',\n marginRight: 8,\n },\n};\n\nconst IMAGE_EXT = ['jpg', 'jpeg', 'svg', 'png', 'webp', 'gif', 'apng', 'avif', 'webp'];\nconst AUDIO_EXT = ['mp3', 'ogg', 'wav', 'aac'];\nconst VIDEO_EXT = ['avi', 'mp4', 'mov'];\nconst DOC_EXT = ['txt', 'log', 'html', 'htm'];\nconst JS_EXT = ['json', 'js', 'ts'];\n\ninterface ConfigFileProps extends ConfigGenericProps {\n schema: ConfigItemFile;\n}\n\ninterface ConfigFileState extends ConfigGenericState {\n showFileBrowser?: boolean;\n}\n\nclass ConfigFile extends ConfigGeneric {\n private imagePrefix = '../..';\n\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n this.imagePrefix = this.props.oContext.imagePrefix === undefined ? './files' : this.props.oContext.imagePrefix;\n this.setState({ value: value ?? '' });\n }\n\n static getDerivedStateFromProps(props: ConfigFileProps, state: ConfigFileState): Partial | null {\n const value = ConfigGeneric.getValue(props.data, props.attr);\n if (\n value === null ||\n value === undefined ||\n value.toString().trim() !== (state.value || '').toString().trim()\n ) {\n return { value: value ?? '' };\n }\n return null;\n }\n\n loadFile(): Promise<{ file: string; mimeType: string } | null> {\n const pos = this.state.value.indexOf('/');\n if (pos !== -1) {\n const adapter = this.state.value.substring(0, pos);\n const path = this.state.value.substring(pos + 1);\n return this.props.oContext.socket.readFile(adapter, path, true);\n }\n\n return Promise.resolve(null);\n }\n\n play(): void {\n void this.loadFile().then(data => {\n if (typeof AudioContext !== 'undefined' && data?.file) {\n const oContext = new AudioContext();\n const buf = ConfigFileSelector.base64ToArrayBuffer(data.file);\n void oContext.decodeAudioData(\n buf,\n (buffer: AudioBuffer): void => {\n const source = oContext.createBufferSource(); // creates a sound source\n source.buffer = buffer; // tell the source which sounds to play\n source.connect(oContext.destination); // connect the source to the oContext's destination (the speakers)\n source.start(0);\n },\n (err: DOMException): void => window.alert(`Cannot play: ${err.message}`),\n );\n }\n });\n }\n\n getIcon(): JSX.Element | null {\n const extension = this.state.value.split('.').pop().toLowerCase();\n if (IMAGE_EXT.includes(extension)) {\n return (\n \n );\n }\n if (AUDIO_EXT.includes(extension)) {\n return (\n this.play()}\n >\n \n \n );\n }\n if (DOC_EXT.includes(extension)) {\n return ;\n }\n if (VIDEO_EXT.includes(extension)) {\n return ;\n }\n if (JS_EXT.includes(extension)) {\n return ;\n }\n return null;\n }\n\n renderFileBrowser(): JSX.Element | null {\n if (!this.state.showFileBrowser) {\n return null;\n }\n return (\n this.setState({ showFileBrowser: false })}\n onOk={_value => {\n const value = Array.isArray(_value) ? _value[0] : _value;\n this.setState({ value }, () =>\n this.onChange(this.props.attr, this.props.schema.trim === false ? value : (value || '').trim()),\n );\n }}\n selectOnlyFolders={this.props.schema.selectOnlyFolders}\n allowUpload={this.props.schema.allowUpload}\n allowDownload={this.props.schema.allowDownload}\n allowCreateFolder={this.props.schema.allowCreateFolder}\n allowView={this.props.schema.allowView}\n showToolbar={this.props.schema.showToolbar}\n limitPath={this.props.schema.limitPath}\n theme={this.props.oContext.theme}\n />\n );\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n const icon = this.getIcon();\n\n return (\n
\n {icon}\n {\n const value = e.target.value;\n this.setState({ value }, () =>\n this.onChange(\n this.props.attr,\n this.props.schema.trim === false ? value : (value || '').trim(),\n ),\n );\n }}\n placeholder={this.getText(this.props.schema.placeholder)}\n label={this.getText(this.props.schema.label)}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n />\n this.setState({ showFileBrowser: true })}\n >\n ...\n \n {this.renderFileBrowser()}\n
\n );\n }\n}\n\nexport default ConfigFile;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, MenuItem, FormHelperText, FormControl, Select } from '@mui/material';\n\nimport { TextWithIcon, I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemFunc } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigFuncProps extends ConfigGenericProps {\n schema: ConfigItemFunc;\n}\n\ninterface ConfigFuncState extends ConfigGenericState {\n selectOptions?: { value: string; label: string; obj?: ioBroker.EnumObject }[];\n}\n\nclass ConfigFunc extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n\n void this.props.oContext.socket.getEnums('functions').then(enums => {\n const selectOptions: { value: string; label: string }[] = Object.keys(enums).map(id => ({\n value: this.props.schema.short ? id.replace('enum.functions.', '') : id,\n label: this.getText(enums[id].common.name),\n obj: enums[id],\n }));\n\n if (this.props.schema.allowDeactivate !== false) {\n selectOptions.unshift({ label: I18n.t(ConfigGeneric.NONE_LABEL), value: ConfigGeneric.NONE_VALUE });\n }\n\n this.setState({ value, selectOptions });\n });\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element | null {\n if (!this.state.selectOptions) {\n return null;\n }\n\n const item = this.state.selectOptions.find(it => it.value === this.state.value);\n\n return (\n \n {this.props.schema.label ? {this.getText(this.props.schema.label)} : null}\n \n item ? (\n item.obj ? (\n \n ) : (\n item.label\n )\n ) : (\n ''\n )\n }\n onChange={e => {\n this.setState({ value: e.target.value === '_' ? '' : e.target.value }, () =>\n this.onChange(this.props.attr, this.state.value),\n );\n }}\n >\n {this.state.selectOptions.map(it => (\n \n {it.obj ? (\n \n ) : (\n it.label\n )}\n \n ))}\n \n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigFunc;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, TextField, FormHelperText, MenuItem, FormControl, Select } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemIP } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigIPProps extends ConfigGenericProps {\n schema: ConfigItemIP;\n}\n\ninterface ConfigIPState extends ConfigGenericState {\n ips?: { name: string; address: string; family: string; internal?: boolean }[];\n}\n\nclass ConfigIP extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n this.props.oContext.socket\n .getHostByIp(this.props.common.host)\n .then(ips => {\n // [{name, address, family}]\n if (!this.props.schema.listenOnAllPorts) {\n ips = ips.filter(item => item.address !== '0.0.0.0' && item.address !== '::');\n }\n if (this.props.schema.onlyIp4) {\n ips = ips.filter(item => item.family === 'ipv4');\n } else if (this.props.schema.onlyIp6) {\n ips = ips.filter(item => item.family === 'ipv6');\n }\n if (this.props.schema.noInternal) {\n ips = ips.filter(item => !item.internal);\n }\n ips.forEach(item => {\n if (item.address === '0.0.0.0') {\n item.name = `[IPv4] 0.0.0.0 - ${I18n.t('ra_Listen on all IPs')}`;\n } else if (item.address === '::') {\n item.name = `[IPv6] :: - ${I18n.t('ra_Listen on all IPs')}`;\n }\n });\n this.setState({ ips });\n })\n .catch(e => console.error(e));\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n const item = this.state.ips?.find(it => it.address === value);\n\n return (\n \n {this.state.ips && this.props.schema.label ? (\n {this.getText(this.props.schema.label)}\n ) : null}\n {!this.state.ips ? (\n this.onChange(this.props.attr, e.target.value)}\n label={this.getText(this.props.schema.label)}\n />\n ) : (\n item?.name || val}\n onChange={e => this.onChange(this.props.attr, e.target.value)}\n >\n {this.state.ips?.map((it, i) => (\n \n {it.name}\n \n ))}\n \n )}\n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigIP;\n","import React, { type JSX } from 'react';\n\nimport type { ConfigItemImageSendTo } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigImageSendToProps extends ConfigGenericProps {\n schema: ConfigItemImageSendTo;\n}\n\ninterface ConfigImageSendToState extends ConfigGenericState {\n image?: string;\n}\n\nclass ConfigImageSendTo extends ConfigGeneric {\n private initialized = false;\n\n private localContext: string | undefined;\n\n componentDidMount(): void {\n super.componentDidMount();\n\n this.askInstance();\n }\n\n askInstance(): void {\n if (this.props.alive) {\n let data = this.props.schema.data;\n if (data === undefined && this.props.schema.jsonData) {\n const dataStr: string = this.getPattern(this.props.schema.jsonData, null, true);\n if (dataStr) {\n try {\n data = JSON.parse(dataStr);\n } catch {\n console.error(`Cannot parse json data: ${JSON.stringify(data)}`);\n }\n }\n }\n\n if (data === undefined) {\n data = null;\n }\n\n void this.props.oContext.socket\n .sendTo(\n `${this.props.oContext.adapterName}.${this.props.oContext.instance}`,\n this.props.schema.command || 'send',\n data,\n )\n .then(image => this.setState({ image: image || '' }));\n }\n }\n\n getContext(): string {\n const localContext: Record = {};\n\n if (Array.isArray(this.props.schema.alsoDependsOn)) {\n this.props.schema.alsoDependsOn.forEach(\n attr => (localContext[attr] = ConfigGeneric.getValue(this.props.data, attr)),\n );\n }\n\n return JSON.stringify(localContext);\n }\n\n renderItem(/* error, disabled, defaultValue */): JSX.Element {\n if (this.props.alive) {\n const localContext = this.getContext();\n if (localContext !== this.localContext || !this.initialized) {\n this.localContext = localContext;\n setTimeout(() => this.askInstance(), this.initialized ? 300 : 50);\n this.initialized = true;\n }\n }\n\n if (this.state.image === undefined) {\n return null;\n }\n\n return (\n \n );\n }\n}\n\nexport default ConfigImageSendTo;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, FormHelperText, FormControl } from '@mui/material';\n\nimport { UploadImage } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemImageUpload } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigImageUploadProps extends ConfigGenericProps {\n schema: ConfigItemImageUpload;\n}\n\ninterface ConfigImageUploadState extends ConfigGenericState {\n image?: string;\n oContext?: string;\n}\n\nclass ConfigImageUpload extends ConfigGeneric {\n private index: number;\n\n constructor(props: ConfigImageUploadProps) {\n super(props);\n this.index = Date.now();\n }\n\n componentDidMount(): void {\n super.componentDidMount();\n\n if (this.props.schema.base64) {\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n this.setState({ value });\n } else {\n void this.props.oContext.socket\n .fileExists(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`, this.props.attr)\n .then(exist => exist && this.loadImage());\n }\n }\n\n _getUrl(update?: boolean): string {\n if (update) {\n this.index = Date.now();\n }\n let url = `files/${this.props.oContext.adapterName}.${this.props.oContext.instance}/${this.props.attr}?t=${this.index}`;\n if (window.location.port === '3000') {\n url = `${window.location.protocol}//${window.location.hostname}:8081/${url}`;\n }\n\n return url;\n }\n\n loadImage(): void {\n void fetch(this._getUrl())\n .then(res => res.blob())\n .then(blob => {\n const reader = new FileReader();\n reader.onload = () => {\n this.setState({ value: reader.result });\n };\n reader.readAsDataURL(blob);\n })\n .catch(e => console.error(e));\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n return (\n \n {this.props.schema.label ? (\n {this.getText(this.props.schema.label)}\n ) : null}\n \n this.setState({ value: null }, () => {\n if (this.props.schema.base64) {\n const mayBePromise = this.onChange(this.props.attr, this.state.value);\n if (mayBePromise instanceof Promise) {\n void mayBePromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n } else {\n // delete file to /instance/attr\n void this.props.oContext.socket\n .deleteFile(`${this.props.oContext.adapterName}.${this.props.oContext.instance}`, this.props.attr)\n .catch(e => console.error(e));\n }\n })\n }\n onChange={base64 =>\n this.setState({ value: base64 }, () => {\n if (this.props.schema.base64) {\n const mayBePromise = this.onChange(this.props.attr, this.state.value);\n if (mayBePromise instanceof Promise) {\n void mayBePromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n } else if (base64.startsWith('data')) {\n base64 = base64.split(',')[1];\n }\n // upload file to /instance/attr\n this.props.oContext.socket\n .writeFile64(\n `${this.props.oContext.adapterName}.${this.props.oContext.instance}`,\n this.props.attr,\n base64,\n )\n .catch(e => console.error(e));\n })\n }\n />\n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigImageUpload;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, MenuItem, FormHelperText, FormControl, Select } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\nimport type { ConfigItemInstanceSelect } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n icon: {\n width: 20,\n height: 20,\n marginRight: 4,\n },\n};\n\ninterface ConfigInstanceSelectProps extends ConfigGenericProps {\n schema: ConfigItemInstanceSelect;\n}\n\ninterface ConfigInstanceSelectState extends ConfigGenericState {\n selectOptions?: { label: string; value: string; icon?: string }[];\n}\n\nclass ConfigInstanceSelect extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n\n let adapter = this.props.schema.adapter;\n if (adapter === '_dataSources') {\n adapter = undefined;\n }\n\n void this.props.oContext.socket\n .getAdapterInstances(adapter, true)\n .then(async instances => {\n if (this.props.schema.adapter === '_dataSources') {\n // get only \"data-sources\", like history, sql, influx\n instances = instances.filter(instance => instance?.common?.getHistory);\n } else if (this.props.schema.adapter) {\n instances = instances.filter(instance =>\n instance?._id.startsWith(`system.adapter.${this.props.schema.adapter}.`),\n );\n } else if (this.props.schema.adapters && Array.isArray(this.props.schema.adapters)) {\n instances = instances.filter(instance =>\n this.props.schema.adapters.includes(instance?.common?.name),\n );\n }\n\n if (this.props.schema.onlyEnabled) {\n instances = instances.filter(instance => instance?.common?.enabled);\n }\n\n const selectOptions: { label: string; value: string; icon?: string }[] = instances.map(instance => ({\n value: this.props.schema.long\n ? instance._id\n : this.props.schema.short\n ? instance._id.split('.').pop()\n : instance._id.replace(/^system\\.adapter\\./, ''),\n label: `${instance.common.name} [${instance._id.replace(/^system\\.adapter\\./, '')}]`,\n icon: `adapter/${instance.common.name}/${instance.common.icon}`,\n }));\n\n selectOptions.sort((a, b) => {\n if (a.value > b.value) {\n return 1;\n }\n if (a.value < b.value) {\n return -1;\n }\n return 0;\n });\n\n if (this.props.schema.allowDeactivate !== false) {\n selectOptions.unshift({ label: I18n.t(ConfigGeneric.NONE_LABEL), value: ConfigGeneric.NONE_VALUE });\n }\n if (this.props.schema.all) {\n selectOptions.unshift({ label: I18n.t('sch_all'), value: '*' });\n }\n\n this.setState({ value: value || '', selectOptions });\n\n await this.props.oContext.socket.subscribeObject(\n `system.adapter.${adapter ? `${adapter}.` : ''}*`,\n this.onInstancesUpdate,\n );\n })\n .catch(e => console.error(`Cannot get instances: ${e}`));\n }\n\n componentWillUnmount(): void {\n void this.props.oContext.socket.unsubscribeObject('system.adapter.*', this.onInstancesUpdate).then(() => {});\n super.componentWillUnmount();\n }\n\n onInstancesUpdate = (id: string, obj?: ioBroker.Object | null): void => {\n if (!id.match(/^system\\.adapter\\.[-_a-z\\d]+\\.\\d+$/)) {\n return;\n }\n const _id = this.props.schema.long\n ? id\n : this.props.schema.short\n ? id.split('.').pop()\n : id.replace(/^system\\.adapter\\./, '');\n const index = this.state.selectOptions.findIndex(item => item.value === _id);\n if (!obj) {\n // deleted\n if (index !== -1) {\n const selectOptions: { label: string; value: string; icon?: string }[] = JSON.parse(\n JSON.stringify(this.state.selectOptions),\n );\n\n const newState: Partial = {};\n if (this.state.value === selectOptions[index].value) {\n newState.value = ConfigGeneric.NONE_VALUE;\n }\n selectOptions.splice(index, 1);\n newState.selectOptions = selectOptions;\n\n this.setState(newState as ConfigInstanceSelectState);\n }\n } else {\n if (this.props.schema.adapter === '_dataSources' && (!obj.common || !obj.common.getHistory)) {\n return;\n }\n\n if (index === -1) {\n const selectOptions: { label: string; value: string; icon?: string }[] = JSON.parse(\n JSON.stringify(this.state.selectOptions),\n );\n const name =\n typeof obj.common.name === 'object'\n ? obj.common.name[I18n.getLanguage()] || obj.common.name.en\n : obj.common.name;\n selectOptions.push({\n value: this.props.schema.long\n ? obj._id\n : this.props.schema.short\n ? obj._id.split('.').pop()\n : obj._id.replace(/^system\\.adapter\\./, ''),\n label: `${name} [${obj._id.replace(/^system\\.adapter\\./, '')}]`,\n icon: `adapter/${name}/${obj.common.icon}`,\n });\n selectOptions.sort((a, b) => (a.label > b.label ? 1 : a.label < b.label ? -1 : 0));\n this.setState({ selectOptions });\n }\n }\n };\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n if (!this.state.selectOptions) {\n return null;\n }\n\n const item = this.state.selectOptions?.find(it => it.value === this.state.value);\n\n return (\n \n {this.props.schema.label ? (\n {this.getText(this.props.schema.label)}\n ) : null}\n (\n \n {item?.icon ? (\n \n ) : null}\n {this.getText(item?.label, true)}\n \n )}\n onChange={e =>\n this.setState({ value: e.target.value }, () => this.onChange(this.props.attr, this.state.value))\n }\n >\n {this.state.selectOptions.map(it => (\n \n {it.icon ? (\n \n ) : null}\n {this.getText(it.label, true)}\n \n ))}\n \n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigInstanceSelect;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, TextField, FormHelperText, MenuItem, FormControl, Select } from '@mui/material';\n\nimport type { ConfigItemInterface } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface NetworkInterfaceBase {\n address: string;\n netmask: string;\n mac: string;\n internal: boolean;\n cidr: string | null;\n}\ninterface NetworkInterfaceInfoIPv4 extends NetworkInterfaceBase {\n family: 'IPv4';\n scopeid?: undefined;\n}\ninterface NetworkInterfaceInfoIPv6 extends NetworkInterfaceBase {\n family: 'IPv6';\n scopeid: number;\n}\ntype NetworkInterfaceInfo = NetworkInterfaceInfoIPv4 | NetworkInterfaceInfoIPv6;\n\nconst styles: Record = {\n address: {\n fontSize: 'smaller',\n opacity: 0.5,\n marginLeft: 8,\n },\n};\n\ninterface ConfigInterfaceProps extends ConfigGenericProps {\n schema: ConfigItemInterface;\n}\n\ninterface ConfigInterfaceState extends ConfigGenericState {\n interfaces?: { value: string; address: string }[];\n}\n\nclass ConfigInterface extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n this.props.oContext.socket\n .getObject(`system.host.${this.props.common.host}`)\n .then(obj => {\n const interfaces: { value: string; address: string }[] = [];\n if (obj?.native?.hardware?.networkInterfaces) {\n const list = obj.native.hardware.networkInterfaces;\n Object.keys(list).forEach(inter => {\n if (this.props.schema.ignoreInternal && !list[inter].find(_ip => !_ip.internal)) {\n return;\n }\n if (\n this.props.schema.ignoreLoopback &&\n list[inter].find(_ip => _ip.address === '127.0.0.1' || _ip.address === '::1')\n ) {\n return;\n }\n\n // find ipv4 address\n let ip: NetworkInterfaceInfo = list[inter].find(_ip => _ip.family === 'IPv4');\n ip = ip || list[inter].find(_ip => _ip.family === 'IPv6');\n interfaces.push({ value: inter, address: ip.address });\n });\n }\n\n this.setState({ interfaces });\n })\n .catch(e => window.alert(`Cannot read interfaces: ${e}`));\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n const item = this.state.interfaces?.find(it => it.value === value);\n\n return (\n \n {this.state.interfaces?.length && this.props.schema.label ? (\n {this.getText(this.props.schema.label)}\n ) : null}\n {!this.state.interfaces?.length ? (\n this.onChange(this.props.attr, e.target.value)}\n label={this.getText(this.props.schema.label)}\n />\n ) : (\n {\n if (item) {\n return (\n \n {item.value}\n {item.address}\n \n );\n }\n return val;\n }}\n onChange={e => this.onChange(this.props.attr, e.target.value)}\n >\n {this.state.interfaces.map((it, i) => (\n \n \n {it.value}\n {it.address}\n \n \n ))}\n \n )}\n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigInterface;\n","import React, { type JSX, useEffect, useState } from 'react';\n\nimport { Dialog, DialogActions, DialogContent, DialogTitle, IconButton, TextField, Button } from '@mui/material';\n\nimport { Check as CheckIcon, Close as CloseIcon, Language as LanguageIcon } from '@mui/icons-material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nconst styles: Record = {\n modalDialog: {\n minWidth: 400,\n maxWidth: 800,\n },\n overflowHidden: {\n display: 'flex',\n overflow: 'hidden',\n },\n titleIcon: {\n marginRight: 5,\n },\n content: {\n fontSize: 16,\n },\n languageButton: {\n position: 'absolute',\n right: 8,\n top: 8,\n },\n languageButtonActive: {\n color: 'primary.main',\n },\n};\n\ninterface CustomModalProps {\n toggleTranslation?: () => void;\n noTranslation?: boolean;\n title: string;\n fullWidth?: boolean;\n help?: string;\n maxWidth?: 'xs' | 'sm' | 'md' | 'lg' | 'xl' | false;\n progress?: boolean;\n icon?: any;\n applyDisabled?: boolean;\n applyButton?: boolean;\n onClose: () => void;\n children: JSX.Element | JSX.Element[] | string | string[] | undefined | null;\n titleButtonApply?: string;\n titleButtonClose?: string;\n onApply: (value: string) => void;\n textInput?: boolean;\n defaultValue?: string;\n overflowHidden?: boolean;\n}\n\nconst CustomModal = ({\n toggleTranslation,\n noTranslation,\n title,\n fullWidth,\n help,\n maxWidth,\n progress,\n icon,\n applyDisabled,\n applyButton,\n onClose,\n children,\n titleButtonApply,\n titleButtonClose,\n onApply,\n textInput,\n defaultValue,\n overflowHidden,\n}: CustomModalProps): JSX.Element => {\n const [value, setValue] = useState(defaultValue);\n useEffect(() => {\n setValue(defaultValue);\n }, [defaultValue]);\n\n let Icon = null;\n\n if (icon) {\n Icon = icon;\n }\n\n return (\n \n {title && (\n \n {icon ? : null}\n {title}\n {I18n.getLanguage() !== 'en' && toggleTranslation ? (\n toggleTranslation()}\n title={I18n.t('Disable/Enable translation')}\n >\n \n \n ) : null}\n \n )}\n \n {textInput && (\n setValue(e.target.value)}\n // customValue\n />\n )}\n {children}\n {help ?
{help}
: null}\n \n \n {applyButton !== false && (\n }\n disabled={progress || (applyDisabled && defaultValue === value)}\n onClick={() => onApply && onApply(textInput ? value : '')}\n variant=\"contained\"\n color=\"primary\"\n >\n {I18n.t(titleButtonApply || 'Ok')}\n \n )}\n onClose && onClose()}\n disabled={progress}\n variant=\"contained\"\n startIcon={}\n >\n {I18n.t(titleButtonClose || 'Cancel')}\n \n \n \n );\n};\n\nexport default CustomModal;\n","import React, { type JSX } from 'react';\n\nimport AceEditor from 'react-ace';\nimport 'ace-builds/src-min-noconflict/mode-json';\nimport 'ace-builds/src-min-noconflict/worker-json';\nimport 'ace-builds/src-min-noconflict/theme-clouds_midnight';\nimport 'ace-builds/src-min-noconflict/theme-chrome';\nimport 'ace-builds/src-min-noconflict/ext-language_tools';\n\nconst styles: Record = {\n jsonError: {\n border: '1px solid red',\n minHeight: 200,\n },\n jsonNoError: {\n border: '1px solid #00000000',\n minHeight: 200,\n },\n};\n\ninterface EditorProps {\n fontSize?: number;\n value?: string;\n defaultValue?: string;\n mode?: 'json' | 'css' | 'html';\n name: string;\n onChange: (newValue: string) => void;\n themeType: string;\n editValueMode?: boolean; // flag that indicates the \"value edit mode\"\n error?: boolean;\n}\n\nfunction Editor(props: EditorProps): JSX.Element {\n return (\n props.onChange(newValue)}\n name={props.name || 'UNIQUE_ID_OF_DIV1'}\n fontSize={props.fontSize || 14}\n setOptions={{\n enableBasicAutocompletion: true,\n enableLiveAutocompletion: true,\n enableSnippets: true,\n\n showLineNumbers: props.editValueMode,\n tabSize: props.editValueMode ? 2 : undefined,\n }}\n editorProps={{ $blockScrolling: true }}\n />\n );\n}\n\nexport default Editor;\n","import React, { type JSX } from 'react';\n\nimport { FormHelperText, FormControl, Button } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\nimport type { ConfigItemJsonEditor } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\nimport CustomModal from './wrapper/Components/CustomModal';\nimport Editor from './wrapper/Components/Editor';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n flex: {\n display: 'flex',\n },\n button: {\n height: 48,\n // marginLeft: 4,\n minWidth: 48,\n },\n wrapper: {\n width: 'calc(100vw - 40px)',\n height: 'calc(100vh - 188px)',\n },\n};\n\ninterface ConfigJsonEditorProps extends ConfigGenericProps {\n schema: ConfigItemJsonEditor;\n}\n\ninterface ConfigJsonEditorState extends ConfigGenericState {\n initialized?: boolean;\n showSelectId?: boolean;\n jsonError?: boolean;\n}\n\nclass ConfigJsonEditor extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const { data, attr } = this.props;\n const value = ConfigGeneric.getValue(data, attr) || {};\n this.setState({ value, initialized: true, jsonError: this.validateJson(value) });\n }\n\n validateJson(value: string | null | undefined): boolean {\n let jsonError = false;\n if (this.props.schema.validateJson !== false) {\n if (value || !this.props.schema.allowEmpty) {\n try {\n JSON.parse(value);\n } catch (err: unknown) {\n console.log('Error in JSON', err);\n jsonError = true;\n }\n }\n }\n\n return jsonError;\n }\n\n renderItem(_error: string, disabled: boolean /* , defaultValue */): JSX.Element | null {\n if (!this.state.initialized) {\n return null;\n }\n\n const { schema, data, attr } = this.props;\n const { value, showSelectId } = this.state;\n\n return (\n \n
\n this.setState({ showSelectId: true })}\n >\n {I18n.t('ra_JSON editor')}\n \n
\n {showSelectId ? (\n \n this.setState({ showSelectId: false, value: ConfigGeneric.getValue(data, attr) || {} })\n }\n onApply={() => this.setState({ showSelectId: false }, () => this.onChange(attr, value))}\n >\n
\n \n this.setState({ value: newValue, jsonError: this.validateJson(newValue) })\n }\n name=\"ConfigJsonEditor\"\n themeType={this.props.oContext.themeType}\n />\n
\n \n ) : null}\n {schema.help || this.state.jsonError ? (\n \n {this.state.jsonError\n ? I18n.t('ra_Invalid JSON')\n : this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigJsonEditor;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, MenuItem, FormHelperText, FormControl, Select } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemLanguage } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst LANGUAGES = [\n {\n value: 'en',\n label: 'English',\n },\n {\n value: 'de',\n label: 'Deutsch',\n },\n {\n value: 'ru',\n label: 'русский',\n },\n {\n value: 'pt',\n label: 'Portugues',\n },\n {\n value: 'nl',\n label: 'Nederlands',\n },\n {\n value: 'fr',\n label: 'français',\n },\n {\n value: 'it',\n label: 'Italiano',\n },\n {\n value: 'es',\n label: 'Espanol',\n },\n {\n value: 'pl',\n label: 'Polski',\n },\n {\n value: 'uk',\n label: 'Український',\n },\n {\n value: 'zh-ch',\n label: '简体中文',\n },\n] as const;\n\ninterface LanguageSelectOption {\n /** Value to save */\n value: string;\n /** Label to show */\n label: string;\n}\n\ninterface ConfigLanguageProps extends ConfigGenericProps {\n schema: ConfigItemLanguage;\n}\n\ninterface ConfigLanguageState extends ConfigGenericState {\n selectOptions: LanguageSelectOption[];\n}\n\nclass ConfigLanguage extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n const languages: LanguageSelectOption[] = [...LANGUAGES];\n if (this.props.schema.system) {\n languages.unshift({ value: '', label: I18n.t('ra_System language') });\n } else {\n languages.unshift({ value: '', label: I18n.t('ra_none') });\n }\n\n this.setState({\n value: this.props.schema.system ? value || '' : value || I18n.getLanguage(),\n selectOptions: languages,\n });\n }\n\n renderItem(error: unknown, disabled: boolean): JSX.Element | null {\n if (!this.state.selectOptions) {\n return null;\n }\n\n const item = this.state.selectOptions?.find(\n it => it.value === this.state.value || (!it.value && !this.state.value),\n );\n\n return (\n \n {this.props.schema.label ? {this.getText(this.props.schema.label)} : null}\n this.getText(item?.label, this.props.schema.noTranslation)}\n onChange={e => {\n let { value } = e.target;\n if (value === '_') {\n value = '';\n }\n\n this.setState({ value }, () => {\n const mayBePromise = this.onChange(this.props.attr, value);\n if (mayBePromise instanceof Promise) {\n void mayBePromise.catch(err => console.error(err));\n }\n if (this.props.schema.changeGuiLanguage) {\n if (value) {\n if (value === I18n.getLanguage()) {\n return;\n }\n I18n.setLanguage(value);\n if (this.props.oContext.changeLanguage) {\n this.props.oContext.changeLanguage();\n }\n } else {\n void this.props.oContext.socket\n .getSystemConfig()\n .then((systemConfig: ioBroker.SystemConfigObject) => {\n if (systemConfig.common.language === I18n.getLanguage()) {\n return;\n }\n if (systemConfig.common.language) {\n I18n.setLanguage(systemConfig.common.language);\n if (this.props.oContext.changeLanguage) {\n this.props.oContext.changeLanguage();\n }\n }\n })\n .catch(e => console.error(`Cannot read system config: ${e}`));\n }\n }\n });\n }}\n >\n {this.state.selectOptions?.map(it => (\n \n {it.label}\n \n ))}\n \n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigLanguage;\n","import React, { type JSX } from 'react';\n\nimport {\n Button,\n Dialog,\n DialogActions,\n DialogContent,\n DialogTitle,\n LinearProgress,\n FormControlLabel,\n Checkbox,\n} from '@mui/material';\n\nimport { Check, Close } from '@mui/icons-material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemLicense } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigLicenseProps extends ConfigGenericProps {\n schema: ConfigItemLicense;\n}\n\ninterface ConfigLicenseState extends ConfigGenericState {\n showLicenseDialog?: boolean;\n licenseChecked?: boolean;\n license?: string;\n loading?: boolean;\n error?: boolean;\n scrolledDown?: boolean;\n}\n\nclass ConfigLicense extends ConfigGeneric {\n private readonly scrollRef: React.RefObject;\n\n constructor(props: ConfigLicenseProps) {\n super(props);\n this.scrollRef = React.createRef();\n }\n\n scrolledDown(): boolean {\n if (!this.scrollRef.current) {\n return false;\n }\n return (\n this.scrollRef.current.offsetHeight + this.scrollRef.current.scrollTop >=\n this.scrollRef.current.scrollHeight\n );\n }\n\n componentDidMount(): void {\n super.componentDidMount();\n if (!ConfigGeneric.getValue(this.props.data, this.props.attr)) {\n if (this.props.schema.licenseUrl) {\n this.setState({ showLicenseDialog: true, loading: true, scrolledDown: false });\n\n fetch(this.props.schema.licenseUrl)\n .then(res => res.text())\n .then(text => this.setState({ license: text, loading: false }))\n .catch(e =>\n this.setState({\n license: e.toString(),\n loading: false,\n error: true,\n scrolledDown: false,\n }),\n );\n } else {\n this.setState({ showLicenseDialog: true, scrolledDown: false });\n }\n setTimeout(() => {\n // install scroll handler\n if (this.scrollRef.current) {\n const scrolledDown = this.scrolledDown();\n if (!scrolledDown) {\n this.scrollRef.current.addEventListener('scroll', () => {\n if (!this.state.scrolledDown && this.scrolledDown()) {\n this.setState({ scrolledDown: true });\n }\n });\n } else {\n this.setState({ scrolledDown: true });\n }\n }\n }, 1000);\n }\n }\n\n renderItem(_error: string, disabled: boolean /*, defaultValue */): JSX.Element | null {\n if (!this.state.showLicenseDialog) {\n return null;\n }\n\n return (\n {\n if (reason !== 'escapeKeyDown' && reason !== 'backdropClick') {\n this.setState({ showLicenseDialog: false });\n }\n }}\n >\n \n {this.props.schema.title ? I18n.t(this.props.schema.title) : I18n.t('ra_License agreement')}\n \n \n {this.props.schema.licenseUrl ? (\n <>\n {this.state.loading ? : null}\n }\n style={{\n width: '100%',\n height: '100%',\n overflowY: 'auto',\n fontSize: 14,\n }}\n >\n {this.state.license}\n \n \n ) : null}\n {!this.props.schema.licenseUrl && this.props.schema.texts ? (\n }\n style={{\n width: '100%',\n height: '100%',\n overflowY: 'auto',\n fontSize: 14,\n }}\n >\n {this.props.schema.texts.map((text, i) =>\n this.props.schema.noTranslation ?

{text}

:

{I18n.t(text)}

,\n )}\n
\n ) : null}\n \n \n {this.props.schema.checkBox ? (\n this.setState({ licenseChecked: !this.state.licenseChecked })}\n />\n }\n label={I18n.t(this.props.schema.checkBox)}\n />\n ) : null}\n {\n this.setState({ showLicenseDialog: false });\n const mayBePromise = this.onChange(this.props.attr, true);\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n }}\n color=\"primary\"\n variant=\"contained\"\n startIcon={}\n >\n {this.props.schema.agreeText\n ? I18n.t(this.props.schema.agreeText)\n : I18n.t('ra_Accept license')}\n \n {\n this.setState({ showLicenseDialog: false });\n setTimeout(() => this.setState({ showLicenseDialog: true }), 2000);\n }}\n color=\"grey\"\n variant=\"contained\"\n startIcon={}\n >\n {I18n.t('ra_Close')}\n \n \n \n );\n }\n}\n\nexport default ConfigLicense;\n","import React, { type JSX } from 'react';\n\nimport { Autocomplete, TextField, FormControl } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemNumber } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n indeterminate: {\n opacity: 0.5,\n },\n control: {\n flexDirection: 'row',\n width: '100%',\n },\n};\n\ninterface ConfigNumberProps extends ConfigGenericProps {\n schema: ConfigItemNumber;\n}\n\ninterface ConfigNumberState extends ConfigGenericState {\n _value: string;\n oldValue: string | null;\n}\n\nclass ConfigNumber extends ConfigGeneric {\n private updateTimeout?: ReturnType;\n\n componentDidMount(): void {\n super.componentDidMount();\n let _value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n\n if (_value === null || _value === undefined) {\n _value = '';\n }\n\n if (Array.isArray(_value) && this.props.oContext.multiEdit) {\n _value = ConfigGeneric.DIFFERENT_VALUE;\n this.setState({ _value, oldValue: _value });\n return;\n }\n\n this.setState({ _value: _value.toString(), oldValue: _value.toString() });\n }\n\n static getDerivedStateFromProps(\n props: ConfigNumberProps,\n state: ConfigNumberState,\n ): Partial | null {\n if (\n (props.schema.min !== undefined && props.schema.min < 0) ||\n (props.schema.max !== undefined && props.schema.max < 0)\n ) {\n return null;\n }\n const _value = ConfigGeneric.getValue(props.data, props.attr);\n\n if (props.oContext.multiEdit && state._value === ConfigGeneric.DIFFERENT_VALUE) {\n return { _value: ConfigGeneric.DIFFERENT_VALUE };\n }\n\n if (\n _value === null ||\n _value === undefined ||\n state.oldValue === null ||\n state.oldValue === undefined ||\n (_value.toString() !== parseFloat(state._value).toString() &&\n _value.toString() !== state.oldValue.toString())\n ) {\n return { _value };\n }\n\n return null;\n }\n\n checkValue(value: string): string | null {\n if (value === null || value === undefined) {\n return null;\n }\n value = value.toString().trim();\n const f = value === '' ? 0 : parseFloat(value);\n\n if (value !== '' && Number.isNaN(f)) {\n return 'ra_Not a number';\n }\n\n if (value !== '' && window.isFinite(f)) {\n if (this.props.schema.min !== undefined && f < this.props.schema.min) {\n return 'ra_Too small';\n }\n if (this.props.schema.max !== undefined && f > this.props.schema.max) {\n return 'ra_Too big';\n }\n if (value === '' || value === '-' || Number.isNaN(f)) {\n return 'ra_Not a number';\n }\n\n return null;\n }\n\n return 'ra_Not a number';\n }\n\n renderItem(error: unknown, disabled: boolean): JSX.Element | null {\n const isIndeterminate = Array.isArray(this.state._value) || this.state._value === ConfigGeneric.DIFFERENT_VALUE;\n\n if (this.state.oldValue !== null && this.state.oldValue !== undefined) {\n if (this.updateTimeout) {\n clearTimeout(this.updateTimeout);\n }\n this.updateTimeout = setTimeout(() => {\n this.updateTimeout = undefined;\n this.setState({ oldValue: null });\n }, 30);\n } else if (this.updateTimeout) {\n clearTimeout(this.updateTimeout);\n this.updateTimeout = undefined;\n }\n\n if (isIndeterminate) {\n const autoCompleteOptions = ConfigGeneric.getValue(this.props.data, this.props.attr);\n const arr =\n autoCompleteOptions\n ?.filter((a: number | null | undefined) => a || a === 0)\n .map((item: number) => ({ label: item.toString(), value: item })) || [];\n\n arr.unshift({ label: I18n.t(ConfigGeneric.DIFFERENT_LABEL), value: ConfigGeneric.DIFFERENT_VALUE });\n\n return (\n option.label === value.label}\n onChange={(_, value: (typeof arr)[number]) => {\n const mayBePromise = this.onChange(this.props.attr, value?.value, () => {\n this.setState({ _value: value?.value, oldValue: this.state._value });\n });\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => console.error(e));\n }\n }}\n options={arr}\n getOptionLabel={(option: (typeof arr)[number]) => option.label}\n renderInput={params => (\n \n )}\n />\n );\n }\n if (!error && this.state._value !== null && this.state._value !== undefined && this.state._value) {\n error = this.checkValue(this.state._value);\n if (error) {\n error = I18n.t(error as string);\n }\n }\n\n return (\n \n {\n const _value = e.target.value; // value is always a string and it is validly formatted\n const _error = this.checkValue(_value);\n if (_error) {\n this.onError(this.props.attr, I18n.t(_error));\n } else {\n this.onError(this.props.attr); // clear error\n }\n\n this.setState({ _value, oldValue: this.state._value }, () =>\n this.onChange(this.props.attr, parseFloat(_value)),\n );\n }}\n placeholder={this.getText(this.props.schema.placeholder)}\n label={this.getText(this.props.schema.label)}\n helperText={\n error && typeof error === 'string'\n ? error\n : this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )\n }\n />\n \n );\n }\n}\n\nexport default ConfigNumber;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, FormControl, Button, TextField } from '@mui/material';\n\nimport { DialogSelectID } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemObjectId } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n flex: {\n display: 'flex',\n },\n button: {\n height: 48,\n marginLeft: 4,\n minWidth: 48,\n },\n};\n\ninterface ConfigObjectIdProps extends ConfigGenericProps {\n schema: ConfigItemObjectId;\n}\n\ninterface ConfigObjectIdState extends ConfigGenericState {\n showSelectId?: boolean;\n initialized?: boolean;\n}\n\nclass ConfigObjectId extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const { data, attr } = this.props;\n const value = ConfigGeneric.getValue(data, attr) || '';\n this.setState({ value, initialized: true });\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n if (!this.state.initialized) {\n return null;\n }\n const socket = this.props.oContext.socket;\n const { schema, attr } = this.props;\n const { value, showSelectId } = this.state;\n\n return (\n \n {schema.label ? {this.getText(schema.label)} : null}\n
\n {\n const value_ = e.target.value;\n this.setState({ value: value_ }, () => this.onChange(attr, value_));\n }}\n />\n this.setState({ showSelectId: true })}\n >\n ...\n \n
\n {showSelectId ? (\n this.setState({ showSelectId: false })}\n onOk={value_ =>\n this.setState({ showSelectId: false, value: value_ }, () => this.onChange(attr, value_))\n }\n />\n ) : null}\n \n );\n }\n}\n\nexport default ConfigObjectId;\n","import React, { type JSX } from 'react';\n\nimport { TextField, IconButton, InputAdornment } from '@mui/material';\n\nimport { Visibility, VisibilityOff } from '@mui/icons-material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemPassword } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n display: 'inline-block',\n },\n halfWidth1: {\n width: 'calc(50% - 5px)',\n display: 'inline-block',\n marginRight: 8,\n },\n halfWidth2: {\n width: 'calc(50% - 5px)',\n display: 'inline-block',\n },\n};\n\nconst PASSWORD_PLACEHOLDER = '____ppp____';\n\ninterface ConfigPasswordProps extends ConfigGenericProps {\n schema: ConfigItemPassword;\n}\n\ninterface ConfigPasswordState extends ConfigGenericState {\n _notEqual?: boolean;\n _repeat?: string;\n _visible?: boolean;\n}\n\nclass ConfigPassword extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n this.setState({\n _repeat: value ? PASSWORD_PLACEHOLDER : '',\n _visible: false,\n value: value ? PASSWORD_PLACEHOLDER : '',\n _notEqual: false,\n });\n }\n\n onChangePassword(password?: string, repeatPassword?: string): void {\n if (password === undefined) {\n password = this.state.value;\n }\n if (repeatPassword === undefined) {\n repeatPassword = this.state._repeat;\n }\n const _notEqual = !!this.props.schema.repeat && repeatPassword !== password;\n this.setState({ value: password, _repeat: repeatPassword, _notEqual }, () => {\n if (_notEqual) {\n this.onError(this.props.attr, I18n.t('ra_Passwords are not equal!'));\n } else {\n this.onError(this.props.attr); // clear error\n const mayBePromise = this.onChange(this.props.attr, password);\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => this.onError(this.props.attr, e));\n }\n }\n });\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n if (this.state._notEqual === undefined) {\n return null;\n }\n\n const password = (\n this.onChangePassword(e.target.value)}\n label={this.getText(this.props.schema.label)}\n slotProps={{\n input: {\n autoComplete: 'new-password',\n endAdornment:\n this.state.value &&\n this.state.value !== PASSWORD_PLACEHOLDER &&\n this.props.schema.visible &&\n !disabled &&\n !this.props.schema.readOnly ? (\n \n {\n e.preventDefault();\n e.stopPropagation();\n this.setState({ _visible: !this.state._visible });\n }}\n edge=\"end\"\n >\n {this.state._visible ? : }\n \n \n ) : undefined,\n },\n htmlInput: {\n autoComplete: 'new-password',\n form: { autoComplete: 'off' },\n maxLength: this.props.schema.maxLength || this.props.schema.max || undefined,\n readOnly: this.props.schema.readOnly || false,\n },\n }}\n helperText={\n this.state._notEqual\n ? I18n.t('ra_Passwords are not equal!')\n : this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )\n }\n />\n );\n\n if (this.props.schema.repeat && !this.props.schema.readOnly) {\n const passwordRepeat = !this.state._visible ? (\n this.onChangePassword(undefined, e.target.value)}\n label={`${this.getText(this.props.schema.label)} (${I18n.t('ra_repeat')})`}\n slotProps={{\n input: {\n autoComplete: 'new-password',\n },\n htmlInput: {\n autoComplete: 'new-password',\n form: { autoComplete: 'off' },\n maxLength: this.props.schema.maxLength || this.props.schema.max || undefined,\n },\n }}\n helperText={\n this.state._notEqual\n ? I18n.t('ra_Passwords are not equal!')\n : this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )\n }\n />\n ) : null;\n\n return (\n
\n
{password}
\n
{passwordRepeat}
\n
\n );\n }\n return password;\n }\n}\n\nexport default ConfigPassword;\n","import React, { type JSX } from 'react';\n\nimport { IconButton, TextField } from '@mui/material';\n\nimport { I18n, IconCopy, Utils } from '@iobroker/adapter-react-v5';\nimport type { ConfigItemPattern } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigPatternProps extends ConfigGenericProps {\n schema: ConfigItemPattern;\n}\n\nclass ConfigPattern extends ConfigGeneric {\n renderItem(_error: unknown, disabled: boolean): JSX.Element | null {\n return (\n {\n Utils.copyToClipboard(\n this.getPattern(\n this.props.schema.pattern,\n null,\n this.props.schema.noTranslation,\n ),\n );\n window.alert(I18n.t('ra_Copied'));\n }}\n >\n \n \n ) : undefined,\n },\n }}\n value={this.getPattern(this.props.schema.pattern, null, true)}\n label={this.getText(this.props.schema.label)}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n />\n );\n }\n}\n\nexport default ConfigPattern;\n","import React, { type JSX } from 'react';\n\nimport { TextField } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemPort } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n warning: {\n '& .Mui-error': {\n color: 'orange',\n },\n },\n};\n\ninterface Port {\n name: string;\n port: number;\n bind: string;\n v6bind: string;\n enabled: boolean;\n}\n\ninterface ConfigPortProps extends ConfigGenericProps {\n schema: ConfigItemPort;\n}\n\ninterface ConfigPortState extends ConfigGenericState {\n _value: string;\n oldValue: string | null;\n ports: Port[];\n}\n\nclass ConfigPort extends ConfigGeneric {\n private updateTimeout?: ReturnType;\n\n async componentDidMount(): Promise {\n super.componentDidMount();\n let _value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n if (_value === null || _value === undefined) {\n _value = '';\n }\n this.setState({ _value: _value.toString(), oldValue: _value.toString() });\n\n // read all instances\n const instances: ioBroker.InstanceObject[] = await this.props.oContext.socket.getAdapterInstances();\n\n const ownId = `system.adapter.${this.props.oContext.adapterName}.${this.props.oContext.instance}`;\n const instanceObj: ioBroker.InstanceObject = (await this.props.oContext.socket.getObject(\n ownId,\n )) as ioBroker.InstanceObject;\n const ownHostname = instanceObj?.common.host;\n\n const ports: Port[] = [];\n instances.forEach(instance => {\n // ignore own instance and instances on another host\n if (!instance || instance._id === ownId || instance.common.host !== ownHostname) {\n return;\n }\n // check port only if bind attribute is present too\n if (!instance.native?.bind) {\n return;\n }\n\n // if let's encrypt is enabled and update is enabled, then add port to check\n if (instance?.native && instance.native.secure && instance.native.leEnabled && instance.native.leUpdate) {\n const port = parseInt(instance.native.leCheckPort || instance.native.lePort, 10);\n if (port) {\n ports.push({\n name: `${instance._id.replace('system.adapter.', '')} (LE)`,\n port,\n v6bind: instance.native.bind.includes(':') ? instance.native.bind : instance.native.v6bind,\n bind: instance.native.bind,\n enabled: !!instance.common?.enabled,\n });\n }\n }\n\n const port = parseInt(instance?.native?.port, 10);\n if (port) {\n ports.push({\n name: instance._id.replace('system.adapter.', ''),\n bind: instance.native.bind,\n v6bind: instance.native.bind.includes(':') ? instance.native.bind : instance.native.v6bind,\n port,\n enabled: !!instance.common?.enabled,\n });\n }\n });\n this.setState({ ports });\n }\n\n static getDerivedStateFromProps(props: ConfigPortProps, state: ConfigPortState): Partial | null {\n const _value = ConfigGeneric.getValue(props.data, props.attr);\n if (\n _value === null ||\n _value === undefined ||\n state.oldValue === null ||\n state.oldValue === undefined ||\n (_value.toString() !== parseInt(state._value, 10).toString() &&\n _value.toString() !== state.oldValue.toString())\n ) {\n return { _value };\n }\n\n return null;\n }\n\n checkValue(value: string): string | null {\n if (value === null || value === undefined) {\n return null;\n }\n\n const min = this.props.schema.min === undefined ? 20 : this.props.schema.min;\n const max = this.props.schema.max || 0xffff;\n\n value = value.toString().trim();\n const f = value === '' ? 0 : parseInt(value, 10);\n\n if (value !== '' && Number.isNaN(f)) {\n return 'ra_Not a number';\n }\n\n if (value !== '' && window.isFinite(Number(value))) {\n if (f < min) {\n return 'ra_Too small';\n }\n if (f > max) {\n return 'ra_Too big';\n }\n if (value === '' || value === '-' || Number.isNaN(f)) {\n return 'ra_Not a number';\n }\n\n return null;\n }\n\n return 'ra_Not a number';\n }\n\n renderItem(error: unknown, disabled: boolean): JSX.Element {\n if (this.state.oldValue !== null && this.state.oldValue !== undefined) {\n if (this.updateTimeout) {\n clearTimeout(this.updateTimeout);\n }\n this.updateTimeout = setTimeout(() => {\n this.updateTimeout = undefined;\n this.setState({ oldValue: null });\n }, 30);\n } else if (this.updateTimeout) {\n clearTimeout(this.updateTimeout);\n this.updateTimeout = undefined;\n }\n\n const min = this.props.schema.min === undefined ? 20 : this.props.schema.min;\n const max = this.props.schema.max || 0xffff;\n\n let warning;\n if (this.state.ports) {\n const num = parseInt(this.state._value, 10);\n\n if (num) {\n // filter ports only with the same bind address\n // todo: IPv6 (v6bind or '::/0')\n const ports = this.state.ports.filter(\n item =>\n !this.props.data.bind ||\n this.props.data.bind === item.bind ||\n this.props.data.bind === '0.0.0.0' ||\n item.bind === '0.0.0.0',\n );\n\n let idx = ports.findIndex(item => item.port === num && item.enabled);\n if (idx !== -1) {\n error = I18n.t('ra_Port is already used by %s', this.state.ports[idx].name);\n } else {\n idx = ports.findIndex(item => item.port === num && !item.enabled);\n if (idx !== -1) {\n warning = true;\n error = I18n.t('ra_Port could be used by %s', this.state.ports[idx].name);\n }\n }\n }\n }\n\n if (!error && this.state._value !== null && this.state._value !== undefined) {\n error = this.checkValue(this.state._value);\n if (typeof error === 'string') {\n error = I18n.t(error);\n }\n }\n\n return (\n {\n const _value = Number(e.target.value.toString().replace(/[^0-9]/g, '')).toString();\n const _error = this.checkValue(_value);\n if (_error) {\n this.onError(this.props.attr, I18n.t(_error));\n } else {\n this.onError(this.props.attr); // clear error\n }\n\n this.setState({ _value, oldValue: this.state._value }, () => {\n if (_value.trim() === parseInt(_value, 10).toString()) {\n const maybePromise = this.onChange(this.props.attr, parseInt(_value, 10) || 0);\n if (maybePromise instanceof Promise) {\n maybePromise.catch(err => {\n console.error(`Cannot set value for ${this.props.attr}: ${err}`);\n });\n }\n }\n });\n }}\n placeholder={this.getText(this.props.schema.placeholder)}\n label={this.getText(this.props.schema.label)}\n helperText={\n error && typeof error === 'string'\n ? error\n : this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )\n }\n />\n );\n }\n}\n\nexport default ConfigPort;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, MenuItem, FormHelperText, FormControl, Select } from '@mui/material';\n\nimport { TextWithIcon, I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemRoom } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigRoomProps extends ConfigGenericProps {\n schema: ConfigItemRoom;\n}\n\ninterface ConfigRoomState extends ConfigGenericState {\n selectOptions?: { value: string; label: string; obj?: ioBroker.EnumObject }[];\n}\n\nclass ConfigRoom extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n\n void this.props.oContext.socket\n .getEnums('rooms')\n .then(enums => {\n const selectOptions: { value: string; label: string; obj?: ioBroker.EnumObject }[] = Object.keys(\n enums,\n ).map(id => ({\n value: this.props.schema.short ? id.replace('enum.rooms.', '') : id,\n label: this.getText(enums[id].common.name),\n obj: enums[id],\n }));\n\n if (this.props.schema.allowDeactivate !== false) {\n selectOptions.unshift({ label: I18n.t(ConfigGeneric.NONE_LABEL), value: ConfigGeneric.NONE_VALUE });\n }\n\n this.setState({ value, selectOptions });\n })\n .catch(e => console.error(`Cannot get enums: ${e}`));\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n if (!this.state.selectOptions) {\n return null;\n }\n\n const item = this.state.selectOptions.find(it => it.value === this.state.value);\n\n return (\n \n {this.props.schema.label ? {this.getText(this.props.schema.label)} : null}\n \n item ? (\n item.obj ? (\n \n ) : (\n item.label\n )\n ) : (\n ''\n )\n }\n onChange={e => {\n this.setState({ value: e.target.value === '_' ? '' : e.target.value }, () =>\n this.onChange(this.props.attr, this.state.value),\n );\n }}\n >\n {this.state.selectOptions.map(it => (\n \n {it.obj ? (\n \n ) : (\n it.label\n )}\n \n ))}\n \n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigRoom;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, FormHelperText, FormControl, Select, MenuItem, ListSubheader } from '@mui/material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemSelect, ConfigItemSelectOption } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n noMargin: {\n '&>div': {\n marginTop: 0,\n },\n },\n};\n\ninterface ConfigInstanceSelectProps extends ConfigGenericProps {\n schema: ConfigItemSelect;\n}\n\ninterface ConfigInstanceSelectState extends ConfigGenericState {\n selectOptions?: { label: string; value: number | string; group?: boolean; hidden?: string | boolean }[];\n}\n\nclass ConfigSelect extends ConfigGeneric {\n private initialValue: string | string[] = '';\n\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n\n const selectOptions: {\n label: string;\n value: number | string;\n group?: boolean;\n hidden?: string | boolean;\n }[] = [];\n\n (this.props.schema.options || []).forEach(item => {\n // if optgroup\n const groupItem: {\n items: ConfigItemSelectOption[];\n label: ioBroker.StringOrTranslated;\n value?: number | string;\n hidden?: string | boolean;\n } = item as {\n items: ConfigItemSelectOption[];\n label: ioBroker.StringOrTranslated;\n value?: number | string;\n hidden?: string | boolean;\n };\n if (Array.isArray(groupItem.items)) {\n selectOptions.push({ label: this.getText(item.label), value: item.value, group: true });\n groupItem.items.forEach(it =>\n selectOptions.push({\n label: this.getText(it.label),\n value: it.value,\n hidden: it.hidden,\n }),\n );\n } else {\n selectOptions.push({\n label: this.getText(item.label),\n value: item.value,\n hidden: item.hidden,\n });\n }\n });\n\n // if __different\n if (Array.isArray(value)) {\n this.initialValue = [...value];\n selectOptions.unshift({\n label: I18n.t(ConfigGeneric.DIFFERENT_LABEL),\n value: ConfigGeneric.DIFFERENT_VALUE,\n });\n this.setState({ value: ConfigGeneric.DIFFERENT_VALUE, selectOptions });\n } else {\n this.setState({ value, selectOptions });\n }\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n if (!this.state.selectOptions) {\n return null;\n }\n\n const selectOptions = (this.state.selectOptions || []).filter(item => {\n // if optgroup or no hidden function\n if (!item.hidden) {\n return true;\n }\n\n if (this.props.custom) {\n return !this.executeCustom(\n item.hidden,\n this.props.data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n this.props.arrayIndex,\n this.props.globalData,\n );\n }\n return !this.execute(\n item.hidden,\n this.props.schema.default,\n this.props.data,\n this.props.arrayIndex,\n this.props.globalData,\n );\n });\n\n const item = selectOptions.find(it => it.value == this.state.value); // let \"==\" be and not ===\n\n return (\n \n {this.props.schema.label ? {this.getText(this.props.schema.label)} : null}\n this.getText(item?.label, this.props.schema.noTranslation)}\n onChange={e => {\n this.setState({ value: e.target.value === '_' ? '' : e.target.value }, () => {\n let mayBePromise: void | Promise;\n if (this.state.value === ConfigGeneric.DIFFERENT_VALUE) {\n mayBePromise = this.onChange(this.props.attr, this.initialValue);\n } else {\n mayBePromise = this.onChange(this.props.attr, this.state.value);\n }\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => console.error(e));\n }\n });\n }}\n >\n {selectOptions.map((it, i) => {\n if (it.group) {\n return (\n \n {this.getText(it.label, this.props.schema.noTranslation)}\n \n );\n }\n return (\n \n {this.getText(it.label, this.props.schema.noTranslation)}\n \n );\n })}\n \n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigSelect;\n","import React, { type JSX } from 'react';\n\nimport {\n InputLabel,\n MenuItem,\n FormHelperText,\n FormControl,\n Select,\n TextField,\n CircularProgress,\n ListItemText,\n Checkbox,\n Chip,\n Box,\n InputAdornment,\n IconButton,\n} from '@mui/material';\n\nimport { Close as CloseIcon } from '@mui/icons-material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemSelectSendTo } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n menuPaper: {\n maxHeight: 800,\n },\n};\n\n/*\nto use this option, your adapter must implement listUart message\n\nadapter.on('message', obj => {\n if (obj) {\n switch (obj.command) {\n case 'command':\n if (obj.callback) {\n try {\n const serialport = require('serialport');\n if (serialport) {\n // read all found serial ports\n serialport.list()\n .then(ports => {\n adapter.log.info('List of port: ' + JSON.stringify(ports));\n adapter.sendTo(obj.from, obj.command, ports.map(item =>\n ({label: item.path, value: item.path})), obj.callback);\n })\n .catch(e => {\n adapter.sendTo(obj.from, obj.command, [], obj.callback);\n adapter.log.error(e)\n });\n } else {\n adapter.log.warn('Module serialport is not available');\n adapter.sendTo(obj.from, obj.command, [{label: 'Not available', value: ''}], obj.callback);\n }\n } catch (e) {\n adapter.sendTo(obj.from, obj.command, [{label: 'Not available', value: ''}], obj.callback);\n }\n }\n\n break;\n }\n }\n});\n */\n\ninterface ConfigSelectSendToProps extends ConfigGenericProps {\n schema: ConfigItemSelectSendTo;\n}\n\ninterface ConfigSelectSendToState extends ConfigGenericState {\n list?: { label: string; value: string; hidden?: boolean }[];\n running?: boolean;\n}\n\nclass ConfigSelectSendTo extends ConfigGeneric {\n private initialized = false;\n\n private localContext: string | undefined;\n\n askInstance(): void {\n if (this.props.alive) {\n let data: Record | undefined = this.props.schema.data;\n if (data === undefined && this.props.schema.jsonData) {\n const dataStr: string = this.getPattern(this.props.schema.jsonData, null, true);\n try {\n data = JSON.parse(dataStr);\n } catch {\n console.error(`Cannot parse json data: ${dataStr}`);\n }\n }\n\n if (data === undefined) {\n data = null;\n }\n this.setState({ running: true }, () => {\n void this.props.oContext.socket\n .sendTo(\n `${this.props.oContext.adapterName}.${this.props.oContext.instance}`,\n this.props.schema.command || 'send',\n data,\n )\n .then(list => this.setState({ list, running: false }))\n .catch(e => {\n console.error(`Cannot send command: ${e}`);\n });\n });\n } else {\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n\n this.setState({ value, running: false });\n }\n }\n\n getContext(): string {\n const localContext: Record = {};\n\n if (Array.isArray(this.props.schema.alsoDependsOn)) {\n this.props.schema.alsoDependsOn.forEach(\n attr => (localContext[attr] = ConfigGeneric.getValue(this.props.data, attr)),\n );\n }\n\n return JSON.stringify(localContext);\n }\n\n _getValue(): string | string[] {\n let value =\n this.state.value === null || this.state.value === undefined\n ? ConfigGeneric.getValue(this.props.data, this.props.attr)\n : this.state.value;\n\n if (this.props.schema.multiple) {\n if (typeof value === 'string') {\n value = [value];\n } else if (value === null || value === undefined) {\n value = [];\n }\n }\n\n return value;\n }\n\n renderItem(error: unknown, disabled: boolean /* , defaultValue */): JSX.Element | string {\n if (this.props.alive) {\n const localContext = this.getContext();\n if (localContext !== this.localContext || !this.initialized) {\n this.localContext = localContext;\n setTimeout(() => this.askInstance(), this.initialized ? 300 : 50);\n this.initialized = true;\n }\n }\n\n const value = this._getValue();\n\n if (!this.props.alive || (!this.state.running && !this.state.list?.length)) {\n if (this.props.schema.multiple || this.props.schema.manual === false) {\n return I18n.t('ra_Cannot retrieve options, as instance is offline');\n }\n return (\n {\n const value_ = e.target.value;\n this.setState({ value: value_ }, () => this.onChange(this.props.attr, (value_ || '').trim()));\n }}\n placeholder={this.getText(this.props.schema.placeholder)}\n label={this.getText(this.props.schema.label)}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n slotProps={{\n input: {\n endAdornment:\n this.state.value && !this.props.schema.noClearButton ? (\n \n \n this.setState({ value: '' }, () => this.onChange(this.props.attr, ''))\n }\n >\n \n \n \n ) : null,\n },\n }}\n />\n );\n }\n\n if (this.state.running) {\n return ;\n }\n\n const selectOptions = this.state.list.filter(item => {\n if (!item.hidden) {\n return true;\n }\n if (this.props.custom) {\n return !this.executeCustom(\n item.hidden,\n this.props.data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n this.props.arrayIndex,\n this.props.globalData,\n );\n }\n return !this.execute(\n item.hidden,\n this.props.schema.default,\n this.props.data,\n this.props.arrayIndex,\n this.props.globalData,\n );\n });\n\n const item = selectOptions.find(it => it.value === value);\n\n return (\n \n {this.props.schema.label ? {this.getText(this.props.schema.label)} : null}\n \n this.props.schema.multiple ? (\n \n {(val as string[]).map((v: string) => {\n const it = selectOptions.find(_item => _item.value === v);\n if (it || this.props.schema.showAllValues !== false) {\n const label = it?.label || v;\n return (\n \n );\n }\n return null;\n })}\n \n ) : (\n item?.label || val\n )\n }\n onChange={e => {\n const mayBePromise = this.onChange(this.props.attr, e.target.value);\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n }}\n >\n {selectOptions.map((it, i) => (\n \n {this.props.schema.multiple ? (\n {\n const _value = JSON.parse(JSON.stringify(this._getValue()));\n const pos = value.indexOf(it.value);\n if (pos !== -1) {\n _value.splice(pos, 1);\n } else {\n _value.push(it.value);\n _value.sort();\n }\n this.setState({ value: _value }, () => this.onChange(this.props.attr, _value));\n }}\n />\n ) : null}\n \n \n ))}\n \n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigSelectSendTo;\n","import React, { type JSX } from 'react';\n\nimport { Button, CircularProgress } from '@mui/material';\n\nimport { Warning as IconWarning, Error as IconError, Info as IconInfo } from '@mui/icons-material';\n\nimport { DialogConfirm, DialogError, DialogMessage, I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemSendTo } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n};\n\nfunction ip2int(ip: string): number {\n return ip.split('.').reduce((ipInt, octet) => (ipInt << 8) + parseInt(octet, 10), 0) >>> 0;\n}\n\n// copied from iobroker.admin/src-rx/src/Utils.js\nfunction findNetworkAddressOfHost(obj: Record, localIp: string): string {\n const networkInterfaces = obj?.native?.hardware?.networkInterfaces;\n if (!networkInterfaces) {\n return null;\n }\n\n let hostIp: string | undefined;\n\n // check ipv4 addresses\n Object.keys(networkInterfaces).forEach(inter =>\n networkInterfaces[inter].forEach((ip: Record) => {\n if (ip.internal) {\n return;\n }\n if (localIp.includes(':') && ip.family !== 'IPv6') {\n return;\n }\n if (localIp.includes('.') && !localIp.match(/[^.\\d]/) && ip.family !== 'IPv4') {\n return;\n }\n // if ip4 and not docker or wsl\n if (\n ip.family === 'IPv4' &&\n !ip.address.startsWith('172') &&\n (localIp === '127.0.0.0' || localIp === 'localhost' || localIp.match(/[^.\\d]/))\n ) {\n // if DNS name\n hostIp = ip.address;\n } else if (!hostIp) {\n if (\n ip.family === 'IPv4' &&\n localIp.includes('.') &&\n (ip2int(localIp) & ip2int(ip.netmask)) === (ip2int(ip.address) & ip2int(ip.netmask))\n ) {\n hostIp = ip.address;\n } else {\n hostIp = ip.address;\n }\n }\n }),\n );\n\n // check ipv6 addresses\n if (!hostIp) {\n Object.keys(networkInterfaces).forEach(inter =>\n networkInterfaces[inter].forEach((ip: Record) => {\n if (ip.internal) {\n return;\n }\n if (localIp.includes(':') && ip.family !== 'IPv6') {\n return;\n }\n if (localIp.includes('.') && !localIp.match(/[^.\\d]/) && ip.family !== 'IPv4') {\n return;\n }\n if (\n ip.family === 'IPv6' &&\n (localIp === '127.0.0.0' || localIp === 'localhost' || localIp.match(/[^.\\d]/))\n ) {\n // if DNS name\n hostIp = ip.address;\n } else if (!hostIp) {\n if (\n ip.family === 'IPv4' &&\n localIp.includes('.') &&\n (ip2int(localIp) & ip2int(ip.netmask)) === (ip2int(ip.address) & ip2int(ip.netmask))\n ) {\n hostIp = ip.address;\n } else {\n hostIp = ip.address;\n }\n }\n }),\n );\n }\n\n if (!hostIp) {\n Object.keys(networkInterfaces).forEach(inter => {\n networkInterfaces[inter].forEach((ip: Record) => {\n if (ip.internal) {\n return;\n }\n if (localIp.includes(':') && ip.family !== 'IPv6') {\n return;\n }\n if (localIp.includes('.') && !localIp.match(/[^.\\d]/) && ip.family !== 'IPv4') {\n return;\n }\n if (localIp === '127.0.0.0' || localIp === 'localhost' || localIp.match(/[^.\\d]/)) {\n // if DNS name\n hostIp = ip.address;\n } else {\n hostIp = ip.address;\n }\n });\n });\n }\n\n if (!hostIp) {\n Object.keys(networkInterfaces).forEach(inter => {\n networkInterfaces[inter].forEach((ip: Record) => {\n if (ip.internal) {\n return;\n }\n hostIp = ip.address;\n });\n });\n }\n\n return hostIp;\n}\n\ninterface ConfigSendToProps extends ConfigGenericProps {\n schema: ConfigItemSendTo;\n}\n\ninterface ConfigSendToState extends ConfigGenericState {\n _error: string;\n _message: string;\n hostname: string;\n running?: boolean;\n}\n\nclass ConfigSendto extends ConfigGeneric {\n async componentDidMount(): Promise {\n super.componentDidMount();\n\n let hostname = window.location.hostname;\n if (this.props.schema.openUrl) {\n // read admin host\n const adminInstance = await this.props.oContext.socket.getCurrentInstance();\n const instanceObj = await this.props.oContext.socket.getObject(\n `system.adapter.${adminInstance}` as ioBroker.ObjectIDs.Instance,\n );\n\n if (instanceObj) {\n const hostObj = await this.props.oContext.socket.getObject(`system.host.${instanceObj?.common?.host}`);\n if (hostObj) {\n const ip = findNetworkAddressOfHost(hostObj, window.location.hostname);\n if (ip) {\n hostname = `${ip}:${window.location.port}`;\n } else {\n console.warn(\n `Cannot find suitable IP in host ${instanceObj.common.host} for ${instanceObj._id}`,\n );\n return;\n }\n }\n }\n }\n\n await new Promise(resolve => {\n this.setState({ _error: '', _message: '', hostname }, resolve);\n });\n\n if (this.props.schema.onLoaded) {\n this._onClick();\n }\n }\n\n renderErrorDialog(): JSX.Element | null {\n if (this.state._error) {\n return (\n this.setState({ _error: '' })}\n />\n );\n }\n return null;\n }\n\n renderMessageDialog(): JSX.Element | null {\n if (this.state._message) {\n return (\n this.setState({ _message: '' })}\n />\n );\n }\n return null;\n }\n\n _onClick(): void {\n this.props.oContext.onCommandRunning(true);\n this.setState({ running: true });\n\n const _origin = `${window.location.protocol}//${window.location.host}${window.location.pathname.replace(/\\/index\\.html$/, '')}`;\n const _originIp = `${window.location.protocol}//${this.state.hostname.split(':').length > 3 ? `[${this.state.hostname}]` : this.state.hostname}${window.location.pathname.replace(/\\/index\\.html$/, '')}`;\n\n let data: Record = this.props.schema.data;\n if (data === undefined && this.props.schema.jsonData) {\n const dataStr = this.getPattern(this.props.schema.jsonData, {\n _origin,\n _originIp,\n ...this.props.data,\n }, true);\n\n try {\n data = JSON.parse(dataStr);\n } catch {\n console.error(`Cannot parse json data: ${dataStr}`);\n }\n }\n if (data === undefined) {\n data = null;\n }\n if (this.props.schema.openUrl && !data) {\n data = {\n _origin,\n _originIp,\n };\n }\n let timeout: ReturnType | undefined;\n if (this.props.schema.timeout) {\n timeout = setTimeout(\n () => {\n this.props.oContext.onCommandRunning(false);\n this.setState({ _error: I18n.t('ra_Request timed out'), running: false });\n },\n parseInt(this.props.schema.timeout as any as string, 10) || 10000,\n );\n }\n\n void this.props.oContext.socket\n .sendTo(\n `${this.props.oContext.adapterName}.${this.props.oContext.instance}`,\n this.props.schema.command || 'send',\n data,\n )\n .then(async (response: Record) => {\n if (timeout) {\n clearTimeout(timeout);\n timeout = undefined;\n }\n if (response?.error) {\n if (this.props.schema.error && this.props.schema.error[response.error]) {\n let error = this.getText(this.props.schema.error[response.error]);\n if (response.args) {\n response.args.forEach((arg: string) => (error = error.replace('%s', arg)));\n }\n this.setState({ _error: error });\n } else {\n this.setState({ _error: response.error ? I18n.t(response.error) : I18n.t('ra_Error') });\n }\n } else {\n if (response?.command) {\n // If backend requested to refresh the config\n if (this.props.oContext.onBackEndCommand) {\n this.props.oContext.onBackEndCommand(response.command);\n }\n return;\n }\n if (response?.reloadBrowser && this.props.schema.reloadBrowser) {\n window.location.reload();\n } else if (response?.openUrl && this.props.schema.openUrl) {\n window.open(response.openUrl, response.window || this.props.schema.window || '_blank');\n } else if (\n response?.result &&\n this.props.schema.result &&\n this.props.schema.result[response.result]\n ) {\n let text = this.getText(this.props.schema.result[response.result]);\n if (response.args) {\n response.args.forEach((arg: string) => (text = text.replace('%s', arg)));\n }\n window.alert(text);\n }\n\n if (response?.native && this.props.schema.useNative) {\n for (const [attr, val] of Object.entries(response.native)) {\n await this.onChangeAsync(attr, val);\n }\n\n setTimeout(\n () => this.props.oContext.forceUpdate(Object.keys(response.native), this.props.data),\n 300,\n );\n } else if (response?.result) {\n window.alert(\n typeof response.result === 'object' ? JSON.stringify(response.result) : response.result,\n );\n } else {\n window.alert(I18n.t('ra_Ok'));\n }\n\n if (response?.saveConfig) {\n this.props.onChange(null, null, null, true);\n }\n }\n })\n .catch((e: any) => {\n if (this.props.schema.error && this.props.schema.error[e.toString()]) {\n this.setState({ _error: this.getText(this.props.schema.error[e.toString()]) });\n } else {\n this.setState({ _error: I18n.t(e.toString()) || I18n.t('ra_Error') });\n }\n })\n .then(() => {\n this.props.oContext.onCommandRunning(false);\n this.setState({ running: false });\n });\n }\n\n renderDialogConfirm(): JSX.Element | null {\n if (!this.state.confirmDialog) {\n return null;\n }\n const confirm = this.state.confirmData || this.props.schema.confirm;\n let icon = null;\n if (confirm.type === 'warning') {\n icon = ;\n } else if (confirm.type === 'error') {\n icon = ;\n } else if (confirm.type === 'info') {\n icon = ;\n }\n\n return (\n this.setState({ confirmDialog: false }, () => isOk && this._onClick())}\n />\n );\n }\n\n renderItem(error: Error | undefined, disabled: boolean): JSX.Element {\n const icon = this.getIcon();\n\n return (\n
\n {\n if (this.props.schema.confirm) {\n this.setState({ confirmDialog: true });\n } else {\n this._onClick();\n }\n }}\n >\n {this.props.schema.showProcess && this.state.running ? (\n \n ) : null}\n {this.getText(this.props.schema.label, this.props.schema.noTranslation)}\n \n {this.renderErrorDialog()}\n {this.renderMessageDialog()}\n
\n );\n }\n}\n\nexport default ConfigSendto;\n","import React, { type JSX } from 'react';\n\nimport { Button } from '@mui/material';\n\nimport { Warning as IconWarning, Error as IconError, Info as IconInfo } from '@mui/icons-material';\n\nimport { DialogConfirm, Icon, I18n } from '@iobroker/adapter-react-v5';\nimport type { ConfigItemSetState } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n icon: {\n width: 24,\n height: 24,\n marginRight: 4,\n },\n};\n\ninterface ConfigInstanceSelectProps extends ConfigGenericProps {\n schema: ConfigItemSetState;\n}\n\nclass ConfigSetState extends ConfigGeneric {\n async _onClick(): Promise {\n let val = this.props.schema.val;\n if (typeof val === 'string' && val.includes('${')) {\n val = this.getPattern(val, null, true);\n const obj = await this.props.oContext.socket.getObject(this.props.schema.id);\n if (obj?.common?.type === 'number') {\n val = parseFloat(val);\n } else if (obj?.common?.type === 'boolean') {\n // @ts-expect-error val could be anything\n val = val === 'true' || val === true || val === '1' || val === 1;\n }\n }\n\n const id = (this.props.schema.id || '').replace(/%INSTANCE%/g, (this.props.oContext.instance || 0).toString());\n\n try {\n await this.props.oContext.socket.setState(id, { val, ack: !!this.props.schema.ack });\n if (this.props.schema.okText) {\n window.alert(this.getText(this.props.schema.okText));\n }\n } catch (e) {\n if (this.props.schema.error && this.props.schema.error[e.toString()]) {\n window.alert(this.getText(this.props.schema.error[e.toString()]));\n } else {\n window.alert(I18n.t(e.toString()) || I18n.t('ra_Error'));\n }\n }\n }\n\n renderDialogConfirm(): JSX.Element | null {\n if (!this.state.confirmDialog) {\n return null;\n }\n const confirm = this.state.confirmData || this.props.schema.confirm;\n let icon = null;\n if (confirm.type === 'warning') {\n icon = ;\n } else if (confirm.type === 'error') {\n icon = ;\n } else if (confirm.type === 'info') {\n icon = ;\n }\n\n return (\n this.setState({ confirmDialog: false }, () => isOk && this._onClick())}\n />\n );\n }\n\n renderItem(_error: string, disabled: boolean /* , defaultValue */): JSX.Element | null {\n return (\n {\n if (this.props.schema.confirm) {\n this.setState({ confirmDialog: true });\n } else {\n await this._onClick();\n }\n }}\n >\n {this.props.schema.icon ? (\n \n ) : null}\n {this.getText(this.props.schema.label, this.props.schema.noTranslation)}\n \n );\n }\n}\n\nexport default ConfigSetState;\n","import React, { type JSX } from 'react';\n\nimport { Box, Typography, Slider } from '@mui/material';\n\nimport type { ConfigItemSlider } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n slider: {\n marginLeft: 10,\n marginRight: 10,\n width: 'calc(100% - 20px)',\n },\n};\n\ninterface ConfigSliderProps extends ConfigGenericProps {\n schema: ConfigItemSlider;\n}\n\ninterface ConfigSliderState extends ConfigGenericState {\n _value: number;\n}\n\nclass ConfigSlider extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const _value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n this.setState({ _value });\n }\n\n static getDerivedStateFromProps(\n props: ConfigSliderProps,\n state: ConfigSliderState,\n ): Partial | null {\n if (\n (props.schema.min !== undefined && props.schema.min < 0) ||\n (props.schema.max !== undefined && props.schema.max < 0)\n ) {\n return null;\n }\n const _value = ConfigGeneric.getValue(props.data, props.attr);\n if (\n _value === null ||\n _value === undefined ||\n _value.toString() !== parseFloat(state._value as any as string).toString()\n ) {\n return { _value };\n }\n\n return null;\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n const min = this.props.schema.min || 0;\n const max = this.props.schema.max || 100;\n const unit = this.props.schema.unit || '';\n\n const marks = [\n { value: min, label: min + unit },\n { value: max, label: max + unit },\n ];\n\n return (\n \n {this.props.schema.label ? (\n {this.getText(this.props.schema.label)}\n ) : null}\n value + unit}\n step={this.props.schema.step || (max - min) / 100}\n valueLabelDisplay=\"auto\"\n marks={marks}\n min={min}\n max={max}\n disabled={!!disabled}\n onChange={e => {\n const _value = (e.target as HTMLInputElement).value as any as number;\n this.setState({ _value }, () => this.onChange(this.props.attr, _value));\n }}\n />\n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigSlider;\n","import React, { type JSX } from 'react';\n\nimport {\n Add,\n Delete,\n Edit,\n Refresh,\n Search,\n Wifi,\n WifiOff,\n Visibility,\n LinkOff,\n Link as LinkIcon,\n NotListedLocation,\n PlayArrow,\n Stop,\n FastForward,\n FastRewind,\n Pause,\n Lightbulb,\n Power,\n Fluorescent,\n WbIncandescent,\n Settings,\n Group,\n Person,\n QrCode,\n} from '@mui/icons-material';\n\nexport default function getIconByName(name: string, style?: React.CSSProperties): JSX.Element | null {\n if (name === 'edit' || name === 'rename') {\n return ;\n }\n if (name === 'delete') {\n return ;\n }\n if (name === 'refresh') {\n return ;\n }\n if (name === 'newDevice' || name === 'new' || name === 'add') {\n return ;\n }\n if (name === 'discover' || name === 'search') {\n return ;\n }\n if (name === 'unpairDevice' || name === 'unpair') {\n return ;\n }\n if (name === 'pairDevice' || name === 'pair') {\n return ;\n }\n if (name === 'identify') {\n return ;\n }\n if (name === 'play') {\n return ;\n }\n if (name === 'stop') {\n return ;\n }\n if (name === 'pause') {\n return ;\n }\n if (name === 'forward' || name === 'next') {\n return ;\n }\n if (name === 'rewind' || name === 'previous') {\n return ;\n }\n if (name === 'lamp' || name === 'light') {\n return ;\n }\n if (name === 'backlight') {\n return ;\n }\n if (name === 'dimmer') {\n return ;\n }\n if (name === 'socket') {\n return ;\n }\n if (name === 'settings') {\n return ;\n }\n if (name === 'users' || name === 'group') {\n return ;\n }\n if (name === 'user') {\n return ;\n }\n if (name === 'qrcode') {\n return ;\n }\n if (name === 'connection') {\n return ;\n }\n if (name === 'no-connection') {\n return ;\n }\n if (name === 'visible') {\n return ;\n }\n return null;\n}\n","import React, { type JSX } from 'react';\n\nimport { TextField, IconButton, Button, Switch, Slider, Box } from '@mui/material';\n\nimport { I18n, Icon, type IobTheme } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemState } from '#JC/types';\nimport getIconByName from './Icons';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nfunction valueBlinkOnce(theme: IobTheme, color?: string | boolean): any {\n if (typeof color === 'string') {\n return {\n '@keyframes newStateAnimationOnceColor': {\n '0%': {\n color,\n },\n '100%': {\n color: theme.palette.mode === 'dark' ? '#fff' : '#000',\n },\n },\n animation: 'newStateAnimationOnceColor 2s ease-in-out',\n };\n }\n return {\n '@keyframes newStateAnimationOnce': {\n '0%': {\n color: '#00f900',\n },\n '80%': {\n color: theme.palette.mode === 'dark' ? '#518851' : '#008000',\n },\n '100%': {\n color: theme.palette.mode === 'dark' ? '#fff' : '#000',\n },\n },\n animation: 'newStateAnimationOnce 2s ease-in-out',\n };\n}\n\ninterface ConfigStateProps extends ConfigGenericProps {\n schema: ConfigItemState;\n}\n\ninterface ConfigStateState extends ConfigGenericState {\n stateValue?: string | number | boolean | null;\n controlType?: string;\n obj?: ioBroker.Object | null;\n}\n\nclass ConfigState extends ConfigGeneric {\n controlTimeout: ReturnType | null = null;\n\n delayedUpdate: { timer: ReturnType | null; value: string | boolean | number | null } = {\n timer: null,\n value: null,\n };\n\n getObjectID(): string {\n if (this.props.schema.foreign) {\n return this.props.schema.oid;\n }\n return `${this.props.schema.system ? 'system.adapter.' : ''}${this.props.oContext.adapterName}.${this.props.oContext.instance}.${this.props.schema.oid}`;\n }\n\n async componentDidMount(): Promise {\n super.componentDidMount();\n const obj: ioBroker.StateObject = (await this.props.oContext.socket.getObject(\n this.getObjectID(),\n )) as ioBroker.StateObject;\n const controlType = this.props.schema.control || this.detectType(obj);\n\n const state = await this.props.oContext.socket.getState(this.getObjectID());\n\n this.setState({ stateValue: state ? state.val : null, controlType, obj }, async () => {\n await this.props.oContext.socket.subscribeState(this.getObjectID(), this.onStateChanged);\n });\n }\n\n componentWillUnmount(): void {\n super.componentWillUnmount();\n this.props.oContext.socket.unsubscribeState(this.getObjectID(), this.onStateChanged);\n if (this.delayedUpdate.timer) {\n clearTimeout(this.delayedUpdate.timer);\n this.delayedUpdate.timer = null;\n }\n\n if (this.controlTimeout) {\n clearTimeout(this.controlTimeout);\n this.controlTimeout = null;\n this.props.oContext.socket\n .setState(this.getObjectID(), this.state.stateValue, false)\n .catch(e => console.error(`Cannot control value: ${e}`));\n }\n }\n\n onStateChanged = (_id: string, state: ioBroker.State | null | undefined): void => {\n let val = state ? state.val : null;\n if (this.state.controlType === 'button' || this.state.controlType === 'switch') {\n val = !!val;\n if (this.state.stateValue !== val) {\n this.setState({ stateValue: val });\n }\n } else if (val !== null && (this.state.controlType === 'slider' || this.state.controlType === 'number')) {\n val = parseFloat(val as unknown as string);\n console.log(`${Date.now()} Received new value: ${val}`);\n if (val !== this.state.stateValue) {\n if (this.delayedUpdate.timer) {\n clearTimeout(this.delayedUpdate.timer);\n this.delayedUpdate.timer = null;\n }\n this.delayedUpdate.value = val;\n this.delayedUpdate.timer = setTimeout(() => {\n this.setState({ stateValue: this.delayedUpdate.value });\n }, 500);\n } else if (this.delayedUpdate.timer) {\n clearTimeout(this.delayedUpdate.timer);\n this.delayedUpdate.timer = null;\n }\n } else if (this.state.stateValue.toString() !== val.toString()) {\n this.setState({ stateValue: val });\n }\n };\n\n detectType(obj: ioBroker.StateObject): 'button' | 'switch' | 'slider' | 'input' | 'text' {\n obj = obj || ({} as ioBroker.StateObject);\n obj.common = obj.common || ({} as ioBroker.StateCommon);\n\n // read object\n if (obj.common.type === 'boolean') {\n if (this.props.schema.controlled !== false) {\n if (obj.common.read === false || this.props.schema.controlled === true) {\n return 'button';\n }\n if (obj.common.write || this.props.schema.controlled === true) {\n return 'switch';\n }\n }\n\n return 'text';\n }\n\n if (obj.common.type === 'number' && this.props.schema.controlled !== false) {\n if (obj.common.write || this.props.schema.controlled === true) {\n if (obj.common.max !== undefined) {\n return 'slider';\n }\n return 'input';\n }\n return 'text';\n }\n\n if (obj.common.write && this.props.schema.controlled !== false) {\n return 'input';\n }\n\n return 'text';\n }\n\n renderItem(_error: string, disabled: boolean/*, defaultValue */): JSX.Element {\n if (!this.state.obj) {\n return null;\n }\n\n let content: JSX.Element;\n\n if (this.state.controlType === 'button') {\n let icon: JSX.Element | null = null;\n if (this.props.schema.falseImage) {\n icon = getIconByName(this.props.schema.falseImage);\n }\n\n const text = this.getText(\n this.props.schema.falseText || this.props.schema.label,\n this.props.schema.noTranslation,\n );\n\n if (!text && icon) {\n content = (\n {\n if (this.props.schema.confirm) {\n this.setState({\n confirmDialog: true,\n confirmCallback: async (result: boolean) => {\n if (result) {\n await this.props.oContext.socket.setState(this.getObjectID(), true, false);\n }\n },\n });\n } else {\n await this.props.oContext.socket.setState(this.getObjectID(), true, false);\n }\n }}\n >\n {icon}\n \n );\n } else {\n content = (\n {\n if (this.props.schema.confirm) {\n this.setState({\n confirmDialog: true,\n confirmCallback: async (result: boolean) => {\n if (result) {\n await this.props.oContext.socket.setState(this.getObjectID(), true, false);\n }\n },\n });\n } else {\n await this.props.oContext.socket.setState(this.getObjectID(), true, false);\n }\n }}\n >\n {text || this.getObjectID().split('.').pop()}\n \n );\n }\n } else if (this.state.controlType === 'input') {\n content = (\n {\n this.setState({ stateValue: e.target.value }, (): void => {\n if (this.controlTimeout) {\n clearTimeout(this.controlTimeout);\n }\n this.controlTimeout = setTimeout(async () => {\n this.controlTimeout = null;\n await this.props.oContext.socket.setState(this.getObjectID(), this.state.stateValue, false);\n }, this.props.schema.controlDelay || 0);\n });\n }}\n label={this.getText(this.props.schema.label)}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n />\n );\n } else if (this.state.obj.common.type === 'number') {\n const min = this.props.schema.min === undefined ? this.state.obj.common.min || 0 : this.props.schema.min;\n const max =\n this.props.schema.max === undefined\n ? this.state.obj.common.max === undefined\n ? 100\n : this.state.obj.common.max\n : this.props.schema.max;\n const step =\n this.props.schema.step === undefined ? this.state.obj.common.step || 1 : this.props.schema.step;\n\n content = (\n {\n this.setState({ stateValue: e.target.value }, (): void => {\n if (this.controlTimeout) {\n clearTimeout(this.controlTimeout);\n }\n this.controlTimeout = setTimeout(async () => {\n this.controlTimeout = null;\n const val = parseFloat(this.state.stateValue as unknown as string);\n await this.props.oContext.socket.setState(this.getObjectID(), val, false);\n }, this.props.schema.controlDelay || 0);\n });\n }}\n label={this.getText(this.props.schema.label, this.props.schema.noTranslation)}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n />\n );\n } else {\n let fontSize: number | undefined;\n if (this.props.schema.size === 'normal') {\n fontSize = 16;\n } else if (this.props.schema.size === 'large') {\n fontSize = 20;\n } else if (typeof this.props.schema.size === 'number') {\n fontSize = this.props.schema.size;\n }\n let label = this.getText(this.props.schema.label, this.props.schema.noTranslation);\n\n const divStyle: React.CSSProperties = {\n display: 'flex',\n alignItems: 'center',\n fontSize: fontSize || '1rem',\n gap: 8,\n };\n\n if (!this.props.schema.narrow) {\n divStyle.width = '100%';\n divStyle.justifyContent = 'space-between';\n }\n\n if (label.trim()) {\n if (!label.trim().endsWith(':') && this.props.schema.addColon) {\n label = `${label.trim()}:`;\n }\n }\n\n let blinkStyle: React.CSSProperties | undefined;\n if (this.props.schema.blinkOnUpdate) {\n blinkStyle = valueBlinkOnce(this.props.oContext.theme, this.props.schema.blinkOnUpdate);\n }\n\n let labelIcon: React.JSX.Element | undefined;\n if (this.props.schema.labelIcon) {\n labelIcon = (\n \n );\n }\n\n let labelControl: React.JSX.Element | undefined;\n if (label && labelIcon) {\n labelControl = (\n
\n {labelIcon}\n {label}\n
\n );\n } else if (label) {\n labelControl =
{label}
;\n } else if (labelIcon) {\n labelControl = labelIcon;\n }\n\n if (this.state.controlType === 'switch') {\n let iconFalse: JSX.Element | null = null;\n const textFalse = this.getText(this.props.schema.falseText, this.props.schema.noTranslation);\n if (this.props.schema.falseImage) {\n iconFalse = getIconByName(this.props.schema.falseImage, textFalse ? { marginLeft: 8 } : undefined);\n }\n let iconTrue: JSX.Element | null = null;\n const textTrue = this.getText(this.props.schema.trueText, this.props.schema.noTranslation);\n if (this.props.schema.trueImage) {\n iconTrue = getIconByName(this.props.schema.trueImage, textTrue ? { marginRight: 8 } : undefined);\n }\n\n content = (\n {\n if (this.props.schema.confirm) {\n this.setState({\n confirmDialog: true,\n confirmCallback: async (result: boolean) => {\n if (result) {\n await this.props.oContext.socket.setState(\n this.getObjectID(),\n !this.state.stateValue,\n false,\n );\n }\n },\n });\n } else {\n await this.props.oContext.socket.setState(this.getObjectID(), !this.state.stateValue, false);\n }\n }}\n />\n );\n\n if (textFalse || iconFalse || textTrue || iconTrue) {\n content = (\n
\n \n {textFalse}\n {iconFalse}\n \n {content}\n \n {iconTrue}\n {textTrue}\n \n
\n );\n }\n\n if (labelControl) {\n content = (\n
\n {labelControl}\n {content}\n
\n );\n }\n } else if (this.state.controlType === 'slider') {\n let iconFalse: JSX.Element | null = null;\n const textFalse = this.getText(this.props.schema.falseText, this.props.schema.noTranslation);\n if (this.props.schema.falseImage) {\n iconFalse = getIconByName(this.props.schema.falseImage, textFalse ? { marginLeft: 8 } : undefined);\n }\n let iconTrue: JSX.Element | null = null;\n const textTrue = this.getText(this.props.schema.trueText, this.props.schema.noTranslation);\n if (this.props.schema.trueImage) {\n iconTrue = getIconByName(this.props.schema.trueImage, textTrue ? { marginRight: 8 } : undefined);\n }\n\n const min =\n this.props.schema.min === undefined ? this.state.obj.common.min || 0 : this.props.schema.min;\n const max =\n this.props.schema.max === undefined\n ? this.state.obj.common.max === undefined\n ? 100\n : this.state.obj.common.max\n : this.props.schema.max;\n const step =\n this.props.schema.step === undefined ? this.state.obj.common.step || 1 : this.props.schema.step;\n\n content = (\n \n `${value}${this.getText(this.props.schema.unit, this.props.schema.noTranslation) || this.state.obj.common.unit || ''}`\n }\n onChange={(_e: Event, value: number) => {\n this.setState({ stateValue: value }, (): void => {\n if (this.controlTimeout) {\n clearTimeout(this.controlTimeout);\n }\n this.controlTimeout = setTimeout(async () => {\n console.log(`${Date.now()} Send new value: ${this.state.stateValue}`);\n this.controlTimeout = null;\n await this.props.oContext.socket.setState(this.getObjectID(), this.state.stateValue, false);\n }, this.props.schema.controlDelay || 0);\n });\n }}\n />\n );\n\n if (textFalse || iconFalse || textTrue || iconTrue) {\n content = (\n \n \n {textFalse}\n {iconFalse}\n \n {content}\n \n {iconTrue}\n {textTrue}\n \n
\n );\n }\n if (labelControl) {\n content = (\n
\n {labelControl}\n {content}\n
\n );\n }\n } else if (this.state.obj.common.type === 'boolean') {\n let icon: JSX.Element | null = null;\n let text: string;\n let style: React.CSSProperties | undefined;\n if (!this.state.stateValue) {\n text = this.getText(this.props.schema.falseText, this.props.schema.noTranslation);\n if (this.props.schema.falseImage) {\n icon = getIconByName(this.props.schema.falseImage, text ? { marginLeft: 8 } : undefined);\n }\n style = this.props.schema.falseTextStyle;\n } else {\n text = this.getText(this.props.schema.trueText, this.props.schema.noTranslation);\n if (this.props.schema.trueImage) {\n icon = getIconByName(this.props.schema.falseImage, text ? { marginRight: 8 } : undefined);\n }\n style = this.props.schema.trueTextStyle;\n }\n style = Object.assign(divStyle, style);\n\n content = (\n
\n {labelControl}\n \n {icon}\n {text || (this.state.stateValue ? I18n.t('ra_true') : I18n.t('ra_false'))}\n \n
\n );\n } else {\n // text or HTML\n const unit =\n this.getText(this.props.schema.unit, this.props.schema.noTranslation) || this.state.obj.common.unit;\n\n let value;\n let key: string;\n if (this.state.controlType === 'html') {\n key = (this.state.stateValue || '').toString();\n value = ;\n } else if (this.state.stateValue === null) {\n value = 'null';\n key = value;\n } else if (this.state.stateValue === undefined) {\n value = 'undefined';\n key = value;\n } else {\n value = this.state.stateValue.toString();\n key = value;\n }\n\n content = (\n
\n {labelControl}\n
\n \n {value}\n \n {unit ? {unit} : null}\n
\n
\n );\n }\n }\n\n return content;\n }\n}\n\nexport default ConfigState;\n","import React, { type JSX } from 'react';\n\nimport { Box } from '@mui/material';\n\nimport { type IobTheme, Utils } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemStaticDivider } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: {\n fullWidth: (theme: IobTheme) => React.CSSProperties;\n primary: (theme: IobTheme) => React.CSSProperties;\n secondary: (theme: IobTheme) => React.CSSProperties;\n} = {\n fullWidth: (theme: IobTheme): React.CSSProperties => ({\n width: '100%',\n backgroundColor: theme.palette.mode === 'dark' ? '#FFF' : '#000',\n borderStyle: 'hidden',\n }),\n primary: (theme: IobTheme): React.CSSProperties => ({\n backgroundColor: theme.palette.primary.main,\n }),\n secondary: (theme: IobTheme): React.CSSProperties => ({\n backgroundColor: theme.palette.secondary.main,\n }),\n};\n\ninterface ConfigInstanceSelectProps extends ConfigGenericProps {\n schema: ConfigItemStaticDivider;\n}\n\nclass ConfigStaticDivider extends ConfigGeneric {\n renderItem(): JSX.Element {\n return (\n \n );\n }\n}\n\nexport default ConfigStaticDivider;\n","import React, { type JSX } from 'react';\n\nimport { Box } from '@mui/material';\n\nimport type { IobTheme } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemStaticHeader } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n header: (theme: IobTheme): React.CSSProperties => ({\n width: '100%',\n background: theme.palette.primary.main,\n color: theme.palette.primary.contrastText,\n padding: '4px !important',\n borderRadius: '3px',\n marginBlockEnd: 0,\n marginBlockStart: 0,\n }),\n};\n\ninterface ConfigInstanceSelectProps extends ConfigGenericProps {\n schema: ConfigItemStaticHeader;\n}\n\nclass ConfigStaticHeader extends ConfigGeneric {\n renderItem(/* error: string, disabled: boolean, defaultValue */): JSX.Element {\n let component: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' = 'h5';\n switch ((this.props.schema.size || 5).toString()) {\n case '1':\n component = 'h1';\n break;\n\n case '2':\n component = 'h2';\n break;\n\n case '3':\n component = 'h3';\n break;\n\n case '4':\n component = 'h4';\n break;\n\n case '5':\n default:\n component = 'h5';\n break;\n }\n return (\n \n {this.getText(this.props.schema.label || this.props.schema.text, this.props.schema.noTranslation)}\n \n );\n }\n}\n\nexport default ConfigStaticHeader;\n","import React, { type JSX } from 'react';\n\nimport type { ConfigItemStaticImage } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigInstanceSelectProps extends ConfigGenericProps {\n schema: ConfigItemStaticImage;\n}\n\nclass ConfigStaticImage extends ConfigGeneric {\n renderItem(/* error: string, disabled: boolean, defaultValue */): JSX.Element {\n let src = this.props.schema.src;\n if (\n src &&\n !src.startsWith('.') &&\n !src.startsWith('http') &&\n !src.startsWith(`adapter/${this.props.oContext.adapterName}/`) &&\n !src.startsWith(`./adapter/${this.props.oContext.adapterName}/`)\n ) {\n src = `adapter/${this.props.oContext.adapterName}/${src}`;\n }\n\n return (\n this.props.schema.href && window.open(this.props.schema.href, '_blank')\n : null\n }\n alt=\"\"\n />\n );\n }\n}\n\nexport default ConfigStaticImage;\n","import React, { type JSX } from 'react';\n\nimport { Box, Checkbox } from '@mui/material';\nimport { ContentCopy } from '@mui/icons-material';\nimport { I18n, Icon, type IobTheme, Utils } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemStaticInfo } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nfunction valueBlinkOnce(theme: IobTheme, force: boolean, color?: string | boolean): any {\n if (typeof color === 'string') {\n return {\n '@keyframes newValueAnimationOnceColor': {\n '0%': {\n color: force ? `${color} !important` : color,\n },\n '100%': {\n color:\n theme.palette.mode === 'dark'\n ? force\n ? '#fff !important'\n : '#fff'\n : force\n ? '#000 !important'\n : '#000',\n },\n },\n animation: 'newValueAnimationOnceColor 2s ease-in-out',\n };\n }\n return {\n '@keyframes newValueAnimationOnce': {\n '0%': {\n color: force ? `#00f900 !important` : '#00f900',\n },\n '80%': {\n color:\n theme.palette.mode === 'dark'\n ? force\n ? `#518851 !important`\n : '#518851'\n : force\n ? `#008000 !important`\n : '#008000',\n },\n '100%': {\n color:\n theme.palette.mode === 'dark'\n ? force\n ? '#fff !important'\n : '#fff'\n : force\n ? '#000 !important'\n : '#000',\n },\n },\n animation: 'newValueAnimationOnce 2s ease-in-out',\n };\n}\n\nfunction valueBlink(theme: IobTheme, color?: string | boolean): any {\n if (typeof color === 'string') {\n return {\n '@keyframes blinkAnimationColor': {\n '0%': {\n color,\n },\n '100%': {\n color: theme.palette.mode === 'dark' ? '#fff' : '#000',\n },\n },\n animation: 'blinkAnimationColor 2s ease-in-out infinite',\n };\n }\n return {\n '@keyframes blinkAnimation': {\n '0%': {\n color: '#00f900',\n },\n '80%': {\n color: theme.palette.mode === 'dark' ? '#518851' : '#008000',\n },\n '100%': {\n color: theme.palette.mode === 'dark' ? '#fff' : '#000',\n },\n },\n animation: 'blinkAnimation 2s ease-in-out infinite',\n };\n}\n\nconst styles: Record = {\n label: {\n fontWeight: 'bold',\n whiteSpace: 'nowrap',\n },\n valueImage: {\n maxHeight: '100%',\n },\n valueAndUnit: {\n display: 'flex',\n gap: 4,\n alignItems: 'baseline',\n },\n value: {},\n unit: {\n fontSize: 'smaller',\n opacity: 0.7,\n },\n};\n\ninterface ConfigStaticInfoProps extends ConfigGenericProps {\n schema: ConfigItemStaticInfo;\n}\n\nclass ConfigStaticInfo extends ConfigGeneric {\n renderItem(_error: string): JSX.Element {\n let label: string | JSX.Element | JSX.Element[] = this.getText(\n this.props.schema.text || this.props.schema.label,\n this.props.schema.noTranslation,\n );\n if (this.props.schema.addColon && typeof label === 'string' && !label.trim().endsWith(':')) {\n label = `${label.trim()}:`;\n }\n\n if (\n label &&\n (label.includes('') || label.includes(''))\n ) {\n label = Utils.renderTextWithA(label);\n }\n let fontSize: number | undefined;\n if (this.props.schema.size === 'normal') {\n fontSize = 16;\n } else if (this.props.schema.size === 'large') {\n fontSize = 20;\n } else if (typeof this.props.schema.size === 'number') {\n fontSize = this.props.schema.size;\n }\n\n const divStyle: React.CSSProperties = {\n width: '100%',\n height: '100%',\n display: 'flex',\n alignItems: 'center',\n position: 'relative',\n fontSize,\n };\n\n if (this.props.schema.narrow) {\n divStyle.gap = 8;\n } else {\n divStyle.justifyContent = 'space-between';\n }\n\n let value: React.JSX.Element;\n let valueTxt: string;\n if (this.props.schema.data && typeof this.props.schema.data === 'object' && this.props.schema.data.en) {\n valueTxt = this.getText(this.props.schema.data);\n } else if (\n typeof this.props.schema.data === 'object' ||\n this.props.schema.data === undefined ||\n this.props.schema.data === null\n ) {\n valueTxt = JSON.stringify(this.props.schema.data);\n } else if (typeof this.props.schema.data === 'number') {\n valueTxt = this.props.schema.data.toString();\n if (this.props.oContext.isFloatComma) {\n valueTxt = valueTxt.replace('.', ',');\n }\n } else if (!this.props.schema.booleanAsCheckbox || typeof this.props.schema.data !== 'boolean') {\n valueTxt = this.props.schema.data.toString();\n }\n let multiLine = false;\n\n if (this.props.schema.booleanAsCheckbox && typeof this.props.schema.data === 'boolean') {\n value = (\n \n );\n } else if (valueTxt.startsWith('data:image/')) {\n value = (\n
\n \n
\n );\n } else {\n const valStyle: React.CSSProperties = { ...styles.value, ...(this.props.schema.styleValue || undefined) };\n if (this.props.schema.html) {\n value = (\n \n );\n } else {\n if (Array.isArray(this.props.schema.data)) {\n multiLine = true;\n value = (\n
\n {this.props.schema.data.map((it, i) => (\n
\n {typeof it === 'object' || it === null || it === undefined\n ? JSON.stringify(it)\n : it}\n
\n ))}\n
\n );\n } else {\n if (valueTxt.includes('\\n')) {\n multiLine = true;\n value =
{Utils.renderTextWithA(valueTxt)}
;\n } else {\n value =
{valueTxt}
;\n }\n }\n }\n }\n\n if (this.props.schema.blinkOnUpdate && this.props.schema.blink) {\n const style1 = valueBlinkOnce(this.props.oContext.theme, true, this.props.schema.blinkOnUpdate);\n const style2 = valueBlink(this.props.oContext.theme, this.props.schema.blink);\n value = (\n \n {value}\n \n );\n } else if (this.props.schema.blinkOnUpdate) {\n const style = valueBlinkOnce(this.props.oContext.theme, false, this.props.schema.blinkOnUpdate);\n value = (\n \n {value}\n \n );\n } else if (this.props.schema.blink) {\n const style = valueBlink(this.props.oContext.theme, this.props.schema.blink);\n value = {value};\n }\n\n if (this.props.schema.unit) {\n value = (\n
\n {value}\n
\n {this.getText(this.props.schema.unit)}\n
\n
\n );\n }\n\n let labelIcon: React.JSX.Element | undefined;\n if (this.props.schema.labelIcon) {\n labelIcon = (\n \n );\n }\n let copyButton: React.JSX.Element | undefined;\n if (this.props.schema.copyToClipboard) {\n copyButton = (\n {\n Utils.copyToClipboard(valueTxt);\n window.alert(I18n.t('ra_Copied'));\n }}\n />\n );\n }\n\n const boxStyle: Record = {\n '& .staticCopyButton': {\n display: 'none',\n },\n '& .staticCopyButton:action': {\n transform: 'scale(0.9)',\n },\n '&:hover .staticCopyButton': {\n display: 'block',\n },\n };\n if (this.props.schema.highlight) {\n boxStyle['&:hover'] = {\n backgroundColor: this.props.oContext.themeType === 'dark' ? '#51515180' : '#b8b8b880',\n };\n }\n if (multiLine) {\n divStyle.alignItems = 'top';\n }\n\n return (\n \n
\n {labelIcon}\n {label}\n
\n {value}\n {copyButton}\n \n );\n }\n}\n\nexport default ConfigStaticInfo;\n","import React, { type JSX } from 'react';\n\nimport { Box, Button } from '@mui/material';\n\nimport { type IobTheme, Utils } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemStaticText } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n height: '100%',\n width: '100%',\n },\n link: (theme: IobTheme): React.CSSProperties => ({\n textDecoration: 'underline',\n color: theme.palette.mode === 'dark' ? '#4dabf5' : '#254e72',\n cursor: 'pointer',\n }),\n};\n\n// eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents\nfunction onLink(href: string, target: '_blank' | '_self' | string, instanceId: string): void {\n let _target;\n let url = '';\n if (!href) {\n url = `#tab-instances/config/${instanceId}`;\n _target = target || '_self';\n } else if (href.toString().startsWith('#')) {\n _target = target || '_self';\n url = href;\n } else if (href.toString().startsWith('/')) {\n _target = target || '_self';\n url = href;\n } else if (href.startsWith('http://') || href.startsWith('https://')) {\n _target = target || '_blank';\n url = href;\n } else {\n url = `#tab-instances/config/${instanceId}/${href}`;\n _target = target || '_self';\n }\n if (_target === '_self') {\n // close dialog\n setTimeout(\n (_url: string) => {\n if (_url.startsWith('#')) {\n window.location.hash = _url;\n } else if (_url.startsWith('/')) {\n url = `${window.location.protocol}:${window.location.host}${url}`;\n } else if (_url.startsWith('http://') || _url.startsWith('https://')) {\n window.location.href = _url;\n }\n },\n 100,\n url,\n );\n } else {\n if (url.startsWith('#')) {\n url = `${window.location.protocol}:${window.location.host}${window.location.pathname}${url}`;\n } else if (url.startsWith('/')) {\n url = `${window.location.protocol}:${window.location.host}${url}`;\n }\n\n window.open(url, _target);\n }\n}\n\ninterface ConfigStaticTextProps extends ConfigGenericProps {\n schema: ConfigItemStaticText;\n}\n\nclass ConfigStaticText extends ConfigGeneric {\n renderItem(_error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n if (this.props.schema.button) {\n const icon = this.getIcon();\n return (\n {\n // calculate one more time just before call\n const href = this.props.schema.href\n ? this.getText(this.props.schema.href, true)\n : null;\n if (href) {\n if (this.props.oContext.onBackEndCommand) {\n this.props.oContext.onBackEndCommand({\n command: 'link',\n url: href,\n target: this.props.schema.target,\n close: this.props.schema.close,\n });\n } else {\n onLink(\n href,\n this.props.schema.target,\n `${this.props.oContext.adapterName}.${this.props.oContext.instance}`,\n );\n }\n }\n }\n : null\n }\n >\n {this.getText(this.props.schema.text || this.props.schema.label, this.props.schema.noTranslation)}\n \n );\n }\n let text: string | JSX.Element | JSX.Element[] = this.getText(\n this.props.schema.text || this.props.schema.label,\n this.props.schema.noTranslation,\n );\n if (text && (text.includes('
') || text.includes(''))) {\n text = Utils.renderTextWithA(text);\n }\n\n return (\n {\n // calculate one more time just before call\n const href = this.props.schema.href ? this.getText(this.props.schema.href, true) : null;\n if (href) {\n if (this.props.oContext.onBackEndCommand) {\n this.props.oContext.onBackEndCommand({\n command: 'link',\n url: href,\n target: this.props.schema.target || '_blank',\n close: this.props.schema.close,\n });\n } else {\n onLink(\n href,\n this.props.schema.target || '_blank',\n `${this.props.oContext.adapterName}.${this.props.oContext.instance}`,\n );\n }\n }\n }\n : null\n }\n >\n {text}\n \n );\n }\n}\n\nexport default ConfigStaticText;\n","import React, { createRef, type JSX, type RefObject } from 'react';\nimport Dropzone from 'react-dropzone';\n\nimport {\n Button,\n Dialog,\n DialogActions,\n DialogContent,\n DialogTitle,\n IconButton,\n InputAdornment,\n Paper,\n Table,\n TableBody,\n TableCell,\n TableContainer,\n TableHead,\n TableRow,\n TableSortLabel,\n TextField,\n Toolbar,\n Tooltip,\n Typography,\n FormHelperText,\n} from '@mui/material';\n\nimport {\n Add as AddIcon,\n Delete as DeleteIcon,\n Close as CloseIcon,\n ArrowUpward as UpIcon,\n ArrowDownward as DownIcon,\n FilterAlt as IconFilterOn,\n FilterAltOff as IconFilterOff,\n ContentCopy as CopyContentIcon,\n Download as ExportIcon,\n Warning as ErrorIcon,\n UploadFile as ImportIcon,\n Close as IconClose,\n} from '@mui/icons-material';\n\nimport { I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemTableIndexed, ConfigItemPanel, ConfigItemTable } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\nimport ConfigPanel from './ConfigPanel';\n\nconst MAX_SIZE = 1024 * 1024; // 1MB\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n root: {\n width: '100%',\n },\n paper: {\n width: '100%',\n marginBottom: 16,\n backgroundColor: 'rgba(255, 255, 255, 0.1)',\n },\n headerText: {\n width: '100%',\n },\n table: {\n minWidth: 750,\n },\n visuallyHidden: {\n border: 0,\n clip: 'rect(0 0 0 0)',\n height: 1,\n margin: -1,\n overflow: 'hidden',\n padding: 0,\n position: 'absolute',\n top: 20,\n width: 1,\n },\n label: {\n display: 'flex',\n justifyContent: 'space-between',\n },\n // highlight: (theme: IobTheme): React.CSSProperties => (theme.palette.mode === 'light'\n // ? {\n // color: theme.palette.secondary.main,\n // // backgroundColor: lighten(theme.palette.secondary.light, 0.85),\n // }\n // : {\n // color: theme.palette.text.primary,\n // backgroundColor: theme.palette.secondary.dark,\n // }),\n title: {\n flex: '1 1 100%',\n },\n rootTool: {\n paddingLeft: 16,\n paddingRight: 8,\n },\n silver: {\n opacity: 0.2,\n },\n flex: {\n display: 'flex',\n alignItems: 'baseline',\n },\n filteredOut: {\n padding: 10,\n display: 'flex',\n textAlign: 'center',\n },\n buttonEmpty: {\n width: 34,\n display: 'inline-block',\n },\n buttonCell: {\n whiteSpace: 'nowrap',\n },\n\n dropZone: {\n width: '100%',\n height: 100,\n position: 'relative',\n },\n dropZoneEmpty: {},\n uploadDiv: {\n position: 'relative',\n width: '100%',\n minHeight: 300,\n opacity: 0.9,\n marginTop: 30,\n cursor: 'pointer',\n outline: 'none',\n },\n uploadDivDragging: {\n opacity: 1,\n background: 'rgba(128,255,128,0.1)',\n },\n image: {\n objectFit: 'contain',\n margin: 'auto',\n display: 'flex',\n width: '100%',\n height: '100%',\n },\n uploadCenterDiv: {\n margin: 5,\n border: '3px dashed grey',\n borderRadius: 5,\n width: 'calc(100% - 10px)',\n height: 'calc(100% - 10px)',\n minHeight: 300,\n position: 'relative',\n display: 'flex',\n },\n uploadCenterIcon: {\n paddingTop: 10,\n width: 48,\n height: 48,\n },\n uploadCenterText: {\n fontSize: 16,\n },\n uploadCenterTextAndIcon: {\n textAlign: 'center',\n position: 'absolute',\n top: 0,\n bottom: 0,\n left: 0,\n right: 0,\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n },\n buttonRemoveWrapper: {\n position: 'absolute',\n zIndex: 222,\n right: 0,\n },\n error: {\n border: '2px solid red',\n boxSizing: 'border-box',\n },\n tooltip: {\n pointerEvents: 'none',\n },\n};\n\nfunction objectToArray(\n object: Record,\n nameOfFirstAttr: string,\n nameOfSecondAttr?: string,\n): Record[] {\n nameOfFirstAttr = nameOfFirstAttr || 'key';\n\n const array: Record[] = [];\n Object.keys(object).forEach(key => {\n const item: Record = {};\n item[nameOfFirstAttr] = key;\n\n if (nameOfSecondAttr) {\n item[nameOfSecondAttr] = object[key];\n array.push(item);\n } else {\n array.push(Object.assign(item, object[key]));\n }\n });\n\n return array;\n}\n\nfunction arrayToObject(\n array: Record[],\n nameOfFirstAttr: string,\n nameOfSecondAttr?: string,\n): Record {\n nameOfFirstAttr = nameOfFirstAttr || 'key';\n\n const object: Record = {};\n\n array.forEach((row: Record) => {\n let key = row[nameOfFirstAttr];\n if (key === null || key === undefined) {\n key = '';\n }\n delete row[nameOfFirstAttr];\n\n if (nameOfSecondAttr) {\n object[key] = row[nameOfSecondAttr];\n } else {\n object[key] = row;\n }\n });\n\n return object;\n}\n\ninterface ConfigTableProps extends ConfigGenericProps {\n schema: ConfigItemTable;\n}\n\ninterface ConfigTableState extends ConfigGenericState {\n value: Record[];\n visibleValue: number[] | null;\n orderBy: string;\n order: 'asc' | 'desc';\n iteration: number;\n filterOn: string[];\n errorMessage: string;\n showImportDialog: boolean;\n showTypeOfImportDialog: Record[] | false;\n instanceObj: ioBroker.InstanceObject;\n customObj: Record;\n uploadFile: boolean | 'dragging';\n icon: boolean;\n}\n\nfunction encrypt(secret: string, value: string): string {\n let result = '';\n for (let i = 0; i < value.length; i++) {\n result += String.fromCharCode(secret[i % secret.length].charCodeAt(0) ^ value.charCodeAt(i));\n }\n return result;\n}\nfunction decrypt(secret: string, value: string): string {\n let result = '';\n for (let i = 0; i < value.length; i++) {\n result += String.fromCharCode(secret[i % secret.length].charCodeAt(0) ^ value.charCodeAt(i));\n }\n return result;\n}\n\nclass ConfigTable extends ConfigGeneric {\n private readonly filterRefs: Record>;\n\n private typingTimer: ReturnType | null = null;\n\n private secret: string = 'Zgfr56gFe87jJOM';\n\n constructor(props: ConfigTableProps) {\n super(props);\n this.filterRefs = {};\n this.props.schema.items = this.props.schema.items || [];\n this.props.schema.items.forEach((el: ConfigItemTableIndexed) => {\n if (el.filter) {\n this.filterRefs[el.attr] = createRef();\n }\n });\n }\n\n /**\n * React lifecycle hook, called once as component is mounted\n */\n async componentDidMount(): Promise {\n super.componentDidMount();\n const _value: Record[] | Record =\n ConfigGeneric.getValue(this.props.data, this.props.attr) || [];\n let value: Record[];\n\n // if the list is given as an object\n if (this.props.schema.objKeyName) {\n value = objectToArray(\n _value as Record,\n this.props.schema.objKeyName,\n this.props.schema.objValueName,\n );\n } else {\n value = _value as Record[];\n }\n\n if (!Array.isArray(value)) {\n value = [];\n }\n\n if (this.props.schema.encryptedAttributes) {\n const systemConfig = await this.props.oContext.socket.getCompactSystemConfig();\n this.secret = systemConfig?.native.secret || this.secret;\n\n _value.forEach((el: Record) => {\n this.props.schema.encryptedAttributes.forEach((attr: string) => {\n if (el[attr]) {\n el[attr] = decrypt(this.secret, el[attr]);\n }\n });\n });\n }\n\n this.setState(\n {\n value,\n visibleValue: null,\n orderBy: /* this.props.schema.items.length ? this.props.schema.items[0].attr : */ '',\n order: 'asc',\n iteration: 0,\n filterOn: [],\n },\n () => this.validateUniqueProps(),\n );\n }\n\n componentWillUnmount(): void {\n if (this.typingTimer) {\n clearTimeout(this.typingTimer);\n this.typingTimer = null;\n }\n super.componentWillUnmount();\n }\n\n itemTable(attrItem: string, data: Record, idx: number): JSX.Element | null {\n const { schema } = this.props;\n const schemaForAttribute =\n schema.items && schema.items.find((el: ConfigItemTableIndexed) => el.attr === attrItem);\n\n if (!schemaForAttribute) {\n return null;\n }\n\n const schemaItem = {\n items: {\n [attrItem]: schemaForAttribute,\n },\n };\n\n return (\n {\n const newObj: Record[] = JSON.parse(JSON.stringify(this.state.value));\n newObj[idx][attr] = valueChange;\n this.setState({ value: newObj }, () => {\n this.validateUniqueProps();\n this.onChangeWrapper(newObj, true);\n });\n }}\n onError={(error: string, attr?: string) => this.onError(error, attr)}\n originalData={this.props.originalData}\n schema={schemaItem as ConfigItemPanel}\n table\n themeName={this.props.themeName}\n />\n );\n }\n\n /**\n * Validate that columns configured in `uniqueColumns` have unique values\n */\n validateUniqueProps(): void {\n if (!this.props.schema.uniqueColumns) {\n return;\n }\n\n for (const uniqueCol of this.props.schema.uniqueColumns) {\n const allVals: (string | number)[] = [];\n const found = this.state.value.find(entry => {\n const val = entry[uniqueCol];\n if (allVals.includes(val)) {\n this.onError(uniqueCol, 'is not unique');\n this.setState({\n errorMessage: I18n.t('Non-allowed duplicate entry \"%s\" in column \"%s\"', val, uniqueCol),\n });\n return true;\n }\n allVals.push(val);\n return false;\n });\n\n if (!found) {\n this.onError(uniqueCol, null);\n this.setState({ errorMessage: '' });\n }\n }\n }\n\n static descendingComparator(a: Record, b: Record, orderBy: string): number {\n if (b[orderBy] < a[orderBy]) {\n return -1;\n }\n if (b[orderBy] > a[orderBy]) {\n return 1;\n }\n return 0;\n }\n\n static getComparator(\n order: 'desc' | 'asc',\n orderBy: string,\n ): (a: Record, b: Record) => number {\n return order === 'desc'\n ? (a: Record, b: Record) => ConfigTable.descendingComparator(a, b, orderBy)\n : (a: Record, b: Record) => -ConfigTable.descendingComparator(a, b, orderBy);\n }\n\n static getFilterValue(el: React.RefObject): string {\n return (el?.current?.children[0]?.children[0] as HTMLInputElement)?.value;\n }\n\n static setFilterValue(el: React.RefObject, filterValue: string): string {\n return ((el.current.children[0].children[0] as HTMLInputElement).value = filterValue);\n }\n\n handleRequestSort = (property: string, orderCheck: boolean = false): void => {\n const { order, orderBy } = this.state;\n if (orderBy) {\n const isAsc = orderBy === property && order === 'asc';\n const newOrder = orderCheck ? order : isAsc ? 'desc' : 'asc';\n const newValue = this.stableSort(newOrder, property);\n this.setState({ order: newOrder, orderBy: property, iteration: this.state.iteration + 10000 }, () =>\n this.applyFilter(false, newValue),\n );\n }\n };\n\n stableSort = (order: 'desc' | 'asc', orderBy: string): Record[] => {\n const { value } = this.state;\n const comparator = ConfigTable.getComparator(order, orderBy);\n const stabilizedThis = value.map((el, index) => ({ el, index }));\n\n stabilizedThis.sort((a, b) => {\n const order_ = comparator(a.el, b.el);\n if (order_ !== 0) {\n return order_;\n }\n return a.index - b.index;\n });\n\n return stabilizedThis.map(el => el.el);\n };\n\n enhancedTableHead(buttonsWidth: number, doAnyFilterSet: boolean): JSX.Element {\n const { schema } = this.props;\n const { order, orderBy } = this.state;\n return (\n \n \n {schema.items &&\n schema.items.map((headCell: ConfigItemTableIndexed, i: number) => (\n \n \n {!i && !schema.noDelete ? (\n \n \n \n \n \n \n \n ) : null}\n {headCell.sort && (\n this.handleRequestSort(headCell.attr)}\n />\n )}\n {headCell.filter && this.state.filterOn.includes(headCell.attr) ? (\n this.applyFilter()}\n title={I18n.t('ra_You can filter entries by entering here some text')}\n slotProps={{\n input: {\n endAdornment: ConfigTable.getFilterValue(\n this.filterRefs[headCell.attr],\n ) && (\n \n {\n ConfigTable.setFilterValue(\n this.filterRefs[headCell.attr],\n '',\n );\n this.applyFilter();\n }}\n >\n \n \n \n ),\n },\n }}\n fullWidth\n placeholder={this.getText(headCell.title)}\n />\n ) : (\n {this.getText(headCell.title)}\n )}\n {headCell.filter ? (\n {\n const filterOn = [...this.state.filterOn];\n const pos = this.state.filterOn.indexOf(headCell.attr);\n if (pos === -1) {\n filterOn.push(headCell.attr);\n } else {\n filterOn.splice(pos, 1);\n }\n this.setState({ filterOn }, () => {\n if (\n pos &&\n ConfigTable.getFilterValue(this.filterRefs[headCell.attr])\n ) {\n ConfigTable.setFilterValue(this.filterRefs[headCell.attr], '');\n this.applyFilter();\n }\n });\n }}\n >\n {this.state.filterOn.includes(headCell.attr) ? (\n \n ) : (\n \n )}\n \n ) : null}\n
\n \n ))}\n {!schema.noDelete && (\n \n {schema.import ? (\n this.setState({ showImportDialog: true })}\n title={I18n.t('ra_import data from %s file', 'CSV')}\n >\n \n \n ) : null}\n {schema.export ? (\n this.onExport()}\n title={I18n.t('ra_Export data to %s file', 'CSV')}\n >\n \n \n ) : null}\n \n \n \n \n )}\n \n \n );\n }\n\n onDelete = (index: number) => (): void => {\n const newValue: Record[] = JSON.parse(JSON.stringify(this.state.value));\n newValue.splice(index, 1);\n\n this.setState({ value: newValue, iteration: this.state.iteration + 10_000 }, () =>\n this.applyFilter(false, null, () => this.onChangeWrapper(newValue)),\n );\n };\n\n onExport(): void {\n const { schema } = this.props;\n const { value } = this.state;\n const cols = schema.items.map((it: ConfigItemTableIndexed) => it.attr);\n const lines = [cols.join(';')];\n value.forEach(row => {\n const line: string[] = [];\n schema.items.forEach((it: ConfigItemTableIndexed) => {\n if (row[it.attr]?.includes(';')) {\n line.push(`\"${row[it.attr]}\"`);\n } else {\n line.push(row[it.attr] === undefined || row[it.attr] === null ? '' : row[it.attr]);\n }\n });\n lines.push(line.join(';'));\n });\n const el = document.createElement('a');\n el.setAttribute('href', `data:text/csv;charset=utf-8,${encodeURIComponent(lines.join('\\n'))}`);\n const now = new Date();\n el.setAttribute(\n 'download',\n `${now.getFullYear()}_${(now.getMonth() + 1).toString().padStart(2, '0')}_${now.getDate().toString().padStart(2, '0')}_${this.props.oContext.adapterName}.${this.props.oContext.instance}_${this.props.attr}.csv`,\n );\n\n el.style.display = 'none';\n document.body.appendChild(el);\n\n el.click();\n\n document.body.removeChild(el);\n }\n\n onImport(text: string): void {\n const lines = text.split('\\n').map((line: string) => line.replace('\\r', '').trim());\n // the first line is header\n const { schema } = this.props;\n\n const header = lines\n .shift()\n .split(';')\n .filter(it => it && schema.items.find((it2: ConfigItemTableIndexed) => it2.attr === it));\n\n const values: Record[] = [];\n lines.forEach((line: string) => {\n const parts: string[] = line.split(';');\n const obj: Record = {};\n for (let p = 0; p < parts.length; p++) {\n let value = parts[p];\n if (value.startsWith('\"')) {\n value = value.substring(1);\n while (p < parts.length && !value.endsWith('\"')) {\n value += `;${parts[++p]}`;\n }\n value = value.substring(0, value.length - 1);\n }\n\n let val: string | number | boolean = value;\n\n if (value === 'true') {\n val = true;\n } else if (value === 'false') {\n val = false;\n } else if (window.isFinite(value as any as number)) {\n const attr = this.props.schema.items.find((it: ConfigItemTableIndexed) => it.attr === header[p]);\n if (attr && attr.type === 'number') {\n // if a type of attribute is a \"number\"\n val = parseFloat(value);\n } else {\n val = value;\n }\n } else {\n val = value;\n }\n\n obj[header[p]] = val;\n }\n values.push(obj);\n });\n\n if (values.length) {\n if (this.state.value?.length) {\n this.setState({ showTypeOfImportDialog: values, showImportDialog: false });\n } else {\n this.setState({ value: values, showImportDialog: false });\n }\n } else {\n window.alert('ra_No data found in file');\n }\n }\n\n onClone = (index: number) => (): void => {\n const newValue: Record[] = JSON.parse(JSON.stringify(this.state.value));\n const cloned: Record = JSON.parse(JSON.stringify(newValue[index]));\n if (typeof this.props.schema.clone === 'string' && typeof cloned[this.props.schema.clone] === 'string') {\n let i = 1;\n let text = cloned[this.props.schema.clone];\n const pattern = text.match(/(\\d+)$/);\n if (pattern) {\n text = text.replace(pattern[0], '');\n i = parseInt(pattern[0], 10) + 1;\n } else {\n text += '_';\n }\n while (\n newValue.find(\n (it: Record) => it[this.props.schema.clone as string] === text + i.toString(),\n )\n ) {\n i++;\n }\n cloned[this.props.schema.clone] = `${cloned[this.props.schema.clone]}_${i}`;\n }\n\n newValue.splice(index, 0, cloned);\n\n this.setState({ value: newValue, iteration: this.state.iteration + 10000 }, () =>\n this.applyFilter(false, null, () => this.onChangeWrapper(newValue)),\n );\n };\n\n onChangeWrapper = (newValue: Record[], updateVisible?: boolean): void => {\n if (this.typingTimer) {\n clearTimeout(this.typingTimer);\n }\n\n this.typingTimer = setTimeout(\n (value, _updateVisible) => {\n this.typingTimer = null;\n\n let mayBePromise: Promise | void;\n if (this.props.schema.encryptedAttributes) {\n const _value = JSON.parse(JSON.stringify(value));\n _value.forEach((el: Record) => {\n this.props.schema.encryptedAttributes.forEach((attr: string) => {\n if (el[attr]) {\n el[attr] = encrypt(this.secret, el[attr]);\n }\n });\n });\n\n if (this.props.schema.objKeyName) {\n const objValue = arrayToObject(\n _value,\n this.props.schema.objKeyName,\n this.props.schema.objValueName,\n );\n mayBePromise = this.onChange(this.props.attr, objValue);\n } else {\n mayBePromise = this.onChange(this.props.attr, _value);\n }\n } else if (this.props.schema.objKeyName) {\n const objValue = arrayToObject(\n JSON.parse(JSON.stringify(value)),\n this.props.schema.objKeyName,\n this.props.schema.objValueName,\n );\n mayBePromise = this.onChange(this.props.attr, objValue);\n } else {\n mayBePromise = this.onChange(this.props.attr, value);\n }\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => console.error(`Cannot save: ${e}`));\n }\n if (_updateVisible) {\n this.applyFilter(false, value);\n this.handleRequestSort(this.state.orderBy, true);\n }\n },\n 300,\n newValue,\n updateVisible,\n );\n };\n\n onAdd = (): void => {\n const { schema } = this.props;\n const newValue: Record[] = JSON.parse(JSON.stringify(this.state.value));\n const newItem = schema.items?.reduce(\n (accumulator: Record, currentValue: ConfigItemTableIndexed) => {\n let defaultValue;\n if (currentValue.defaultFunc) {\n if (this.props.custom) {\n defaultValue = currentValue.defaultFunc\n ? this.executeCustom(\n currentValue.defaultFunc,\n this.props.data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n newValue.length,\n this.props.data,\n )\n : this.props.schema.default;\n } else {\n defaultValue = currentValue.defaultFunc\n ? this.execute(\n currentValue.defaultFunc,\n this.props.schema.default,\n this.props.data,\n newValue.length,\n this.props.data,\n )\n : this.props.schema.default;\n }\n } else {\n defaultValue = currentValue.default === undefined ? null : currentValue.default;\n }\n\n accumulator[currentValue.attr] = defaultValue;\n return accumulator;\n },\n {},\n );\n\n newValue.push(newItem);\n\n this.setState({ value: newValue }, () => this.applyFilter(false, null, () => this.onChangeWrapper(newValue)));\n };\n\n isAnyFilterSet(): boolean {\n return !!Object.keys(this.filterRefs).find(attr => ConfigTable.getFilterValue(this.filterRefs[attr]));\n }\n\n applyFilter = (clear?: boolean, value?: Record[], cb?: () => void): void => {\n value = value || this.state.value;\n let visibleValue = value.map((_, i) => i);\n Object.keys(this.filterRefs).forEach(attr => {\n let valueInputRef = ConfigTable.getFilterValue(this.filterRefs[attr]);\n if (!clear && valueInputRef) {\n valueInputRef = valueInputRef.toLowerCase();\n visibleValue = visibleValue.filter(\n idx => value[idx] && value[idx][attr] && value[idx][attr].toLowerCase().includes(valueInputRef),\n );\n } else if (this.filterRefs[attr].current) {\n ConfigTable.setFilterValue(this.filterRefs[attr], '');\n }\n });\n\n if (visibleValue.length === value.length) {\n visibleValue = null;\n }\n\n if (visibleValue === null && this.state.visibleValue === null) {\n if (cb) {\n cb();\n }\n return;\n }\n\n if (JSON.stringify(visibleValue) !== JSON.stringify(this.state.visibleValue)) {\n this.setState({ visibleValue }, () => cb && cb());\n } else if (cb) {\n cb();\n }\n };\n\n onMoveUp(idx: number): void {\n const newValue: Record[] = JSON.parse(JSON.stringify(this.state.value));\n const item = newValue[idx];\n newValue.splice(idx, 1);\n newValue.splice(idx - 1, 0, item);\n this.setState({ value: newValue, iteration: this.state.iteration + 10000 }, () =>\n this.applyFilter(false, null, () => this.onChangeWrapper(newValue)),\n );\n }\n\n onMoveDown(idx: number): void {\n const newValue: Record[] = JSON.parse(JSON.stringify(this.state.value));\n const item = newValue[idx];\n newValue.splice(idx, 1);\n newValue.splice(idx + 1, 0, item);\n this.setState({ value: newValue, iteration: this.state.iteration + 10000 }, () =>\n this.applyFilter(false, null, () => this.onChangeWrapper(newValue)),\n );\n }\n\n onDrop(acceptedFiles: File[]): void {\n const file = acceptedFiles[0];\n const reader = new FileReader();\n\n reader.onabort = () => console.log('file reading was aborted');\n reader.onerror = () => console.log('file reading has failed');\n reader.onload = () => {\n if (file.size > MAX_SIZE) {\n window.alert(I18n.t('ra_File is too big. Max %sk allowed. Try use SVG.', Math.round(MAX_SIZE / 1024)));\n return;\n }\n const text = new Uint8Array(reader.result as ArrayBufferLike).reduce(\n (data, byte) => data + String.fromCharCode(byte),\n '',\n );\n\n this.onImport(text);\n };\n reader.readAsArrayBuffer(file);\n }\n\n showTypeOfImportDialog(): JSX.Element | null {\n if (!this.state.showTypeOfImportDialog) {\n return null;\n }\n return (\n this.setState({ showTypeOfImportDialog: false })}\n maxWidth=\"md\"\n >\n {I18n.t('ra_Append or replace?')}\n \n {I18n.t('ra_Append %s entries or replace existing?', this.state.showTypeOfImportDialog.length)}\n \n \n {\n const value: Record[] = JSON.parse(JSON.stringify(this.state.value));\n\n (this.state.showTypeOfImportDialog as Record[]).forEach(\n (obj: Record) => value.push(obj),\n );\n\n this.setState(\n {\n value,\n iteration: this.state.iteration + 10000,\n showTypeOfImportDialog: false,\n },\n () => this.applyFilter(false, null, () => this.onChangeWrapper(value)),\n );\n }}\n >\n {I18n.t('ra_Append')}\n \n {\n const value: Record[] = this.state.showTypeOfImportDialog as Record<\n string,\n any\n >[];\n this.setState(\n {\n value,\n iteration: this.state.iteration + 10000,\n showTypeOfImportDialog: false,\n },\n () => this.applyFilter(false, null, () => this.onChangeWrapper(value)),\n );\n }}\n >\n {I18n.t('ra_Replace')}\n \n \n \n );\n }\n\n showImportDialog(): JSX.Element | null {\n if (!this.state.showImportDialog) {\n return null;\n }\n return (\n this.setState({ showImportDialog: false })}\n sx={{\n '& .MuiDialog-paper': {\n minHeight: 500,\n },\n }}\n maxWidth=\"md\"\n fullWidth\n >\n {I18n.t('ra_Import from %s', 'CSV')}\n \n this.setState({ uploadFile: 'dragging' })}\n onDragLeave={() => this.setState({ uploadFile: true })}\n onDrop={(acceptedFiles, errors) => {\n this.setState({ uploadFile: false });\n if (!acceptedFiles.length) {\n window.alert(\n (errors &&\n errors[0] &&\n errors[0].errors &&\n errors[0].errors[0] &&\n errors[0].errors[0].message) ||\n I18n.t('ra_Cannot upload'),\n );\n } else {\n this.onDrop(acceptedFiles);\n }\n }}\n >\n {({ getRootProps, getInputProps }) => (\n \n \n
\n
\n \n
\n {this.state.uploadFile === 'dragging'\n ? I18n.t('ra_Drop file here')\n : I18n.t(\n 'ra_Place your files here or click here to open the browse dialog',\n )}\n
\n
\n
\n \n )}\n \n
\n \n this.setState({ showImportDialog: false })}\n color=\"primary\"\n startIcon={}\n >\n {I18n.t('Cancel')}\n \n \n \n );\n }\n\n renderItem(/* error, disabled, defaultValue */): JSX.Element | null {\n const { schema } = this.props;\n let { visibleValue } = this.state;\n\n if (!this.state.value || !Array.isArray(this.state.value)) {\n return null;\n }\n\n visibleValue = visibleValue || this.state.value.map((_, i) => i);\n\n const doAnyFilterSet = this.isAnyFilterSet();\n\n let tdStyle: React.CSSProperties | undefined;\n if (this.props.schema.compact) {\n tdStyle = { paddingTop: 1, paddingBottom: 1 };\n }\n\n return (\n \n {this.showImportDialog()}\n {this.showTypeOfImportDialog()}\n {schema.label ? (\n
\n \n \n {this.getText(schema.label)}\n \n \n
\n ) : null}\n \n \n {this.enhancedTableHead(!doAnyFilterSet && !this.state.orderBy ? 120 : 64, doAnyFilterSet)}\n \n {visibleValue.map((idx, i) => (\n \n {schema.items &&\n schema.items.map((headCell: ConfigItemTableIndexed) => (\n \n {this.itemTable(headCell.attr, this.state.value[idx], idx)}\n \n ))}\n {!schema.noDelete && (\n \n {!doAnyFilterSet && !this.state.orderBy ? (\n i ? (\n \n this.onMoveUp(idx)}\n >\n \n \n \n ) : (\n
\n )\n ) : null}\n {!doAnyFilterSet && !this.state.orderBy ? (\n i < visibleValue.length - 1 ? (\n \n this.onMoveDown(idx)}\n >\n \n \n \n ) : (\n
\n )\n ) : null}\n \n \n \n \n \n {this.props.schema.clone ? (\n \n \n \n \n \n ) : null}\n \n )}\n \n ))}\n {!schema.noDelete && visibleValue.length >= (schema.showSecondAddAt || 5) ? (\n \n \n \n \n \n \n \n \n \n \n \n ) : null}\n \n \n {!visibleValue.length && this.state.value.length ? (\n
\n \n {I18n.t('ra_All items are filtered out')}\n this.applyFilter(true)}\n >\n \n \n \n
\n ) : null}\n \n {schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n {this.state.errorMessage ? (\n
\n \n {this.state.errorMessage}\n
\n ) : null}\n \n );\n }\n}\n\nexport default ConfigTable;\n","import React, { type JSX } from 'react';\n\nimport { Autocomplete, TextField, TextareaAutosize, InputAdornment, IconButton } from '@mui/material';\n\nimport { Close as CloseIcon } from '@mui/icons-material';\n\nimport { I18n, IconCopy, Utils } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemText } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n indeterminate: {\n opacity: 0.5,\n },\n label: {\n width: '100%',\n fontSize: 14,\n marginBottom: 2,\n },\n helper: {\n width: '100%',\n fontSize: 12,\n },\n error: {\n width: '100%',\n fontSize: 12,\n color: '#FF0000',\n },\n};\n\ninterface ConfigTextProps extends ConfigGenericProps {\n schema: ConfigItemText;\n}\n\ninterface ConfigTextState extends ConfigGenericState {\n oldValue?: string;\n jsonError?: boolean;\n}\n\nclass ConfigText extends ConfigGeneric {\n private updateTimeout: ReturnType | null = null;\n\n componentDidMount(): void {\n super.componentDidMount();\n let value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n\n if (Array.isArray(value) && this.props.oContext.multiEdit) {\n value = ConfigGeneric.DIFFERENT_VALUE;\n this.setState({ value, oldValue: value, jsonError: false });\n return;\n }\n\n this.setState({ value, oldValue: value, jsonError: this.validateJson(value) });\n }\n\n validateJson(value: string | null | undefined): boolean {\n let jsonError = false;\n if (this.props.schema.validateJson) {\n if (value || !this.props.schema.allowEmpty) {\n try {\n JSON.parse(value);\n } catch (err: unknown) {\n console.log('Error in JSON', err);\n jsonError = true;\n }\n }\n }\n\n return jsonError;\n }\n\n static getDerivedStateFromProps(props: ConfigTextProps, state: ConfigTextState): Partial | null {\n if (props.oContext.multiEdit && state.value === ConfigGeneric.DIFFERENT_VALUE) {\n return { value: ConfigGeneric.DIFFERENT_VALUE };\n }\n\n let value = ConfigGeneric.getValue(props.data, props.attr);\n\n if (value !== null && value !== undefined) {\n value = value.toString();\n }\n\n if (value === null || value === undefined || (value !== state.value && value !== state.oldValue)) {\n return { value };\n }\n return null;\n }\n\n renderItem(error?: boolean, disabled?: boolean): JSX.Element {\n const isIndeterminate = Array.isArray(this.state.value) || this.state.value === ConfigGeneric.DIFFERENT_VALUE;\n\n if (this.props.schema.time) {\n // show read-only time\n\n let time = '';\n if (typeof this.state.value === 'number') {\n // If the value is a number, it is a timestamp.\n if (this.state.value && this.state.value < 946659600000) {\n // If the value is less than 2000-01-01, it is a timestamp in seconds.\n time = new Date(this.state.value * 1000).toLocaleString();\n } else {\n time = new Date(this.state.value).toLocaleString();\n }\n } else if (typeof this.state.value === 'string') {\n // If the value is a string, it is a date string.\n time = new Date(this.state.value).toLocaleString();\n }\n\n return (\n \n );\n }\n\n if (this.state.oldValue !== null && this.state.oldValue !== undefined) {\n if (this.updateTimeout) {\n clearTimeout(this.updateTimeout);\n }\n this.updateTimeout = setTimeout(() => {\n this.updateTimeout = null;\n this.setState({ oldValue: null });\n }, 30);\n } else if (this.updateTimeout) {\n clearTimeout(this.updateTimeout);\n this.updateTimeout = null;\n }\n\n if (isIndeterminate) {\n const autoCompleteOptions = ConfigGeneric.getValue(this.props.data, this.props.attr);\n const arr =\n autoCompleteOptions\n ?.filter((a: any) => a || a === 0)\n .map((item: any) => ({ label: item.toString() || '', value: item })) || [];\n\n arr.unshift({ label: I18n.t(ConfigGeneric.DIFFERENT_LABEL), value: ConfigGeneric.DIFFERENT_VALUE });\n\n return (\n option.label === value.label}\n onChange={(_, value) => {\n const val = value ? value.value : '';\n const mayBePromise = this.onChange(this.props.attr, val, () => {\n this.setState({ value: val, oldValue: val, jsonError: this.validateJson(value) });\n });\n if (mayBePromise instanceof Promise) {\n mayBePromise.catch(e => console.error(`Cannot set value: ${e}`));\n }\n }}\n options={arr}\n getOptionLabel={option => option.label}\n renderInput={params => (\n \n )}\n />\n );\n }\n\n let actionButton: React.JSX.Element | undefined;\n let actionButtonStyle: React.CSSProperties | undefined;\n if ((this.props.schema.readOnly || disabled) && this.props.schema.copyToClipboard) {\n if (this.props.schema.minRows > 1) {\n actionButtonStyle = {\n position: 'absolute',\n right: 3,\n top: 20,\n zIndex: 1000,\n };\n }\n actionButton = (\n {\n Utils.copyToClipboard(this.state.value);\n window.alert(I18n.t('ra_Copied'));\n }}\n >\n \n \n );\n } else if (!this.props.schema.readOnly && !disabled && this.state.value && !this.props.schema.noClearButton) {\n if (this.props.schema.minRows > 1) {\n actionButtonStyle = {\n position: 'absolute',\n right: 3,\n top: 20,\n zIndex: 1000,\n };\n }\n actionButton = (\n \n this.setState({ value: '', oldValue: this.state.value }, () =>\n this.onChange(this.props.attr, ''),\n )\n }\n >\n \n \n );\n if (this.props.schema.minRows <= 1) {\n actionButton = {actionButton};\n }\n }\n\n if (this.props.schema.minRows > 1) {\n const helper = this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n );\n return (\n
\n {this.props.schema.label ? (\n
{this.getText(this.props.schema.label)}
\n ) : null}\n {\n const value = e.target.value;\n this.setState(\n { value, oldValue: this.state.value, jsonError: this.validateJson(value) },\n () => this.onChange(this.props.attr, value || ''),\n );\n }}\n placeholder={this.getText(this.props.schema.placeholder)}\n />\n {helper || error || this.state.jsonError ? (\n
\n {error || (this.state.jsonError ? I18n.t('ra_Invalid JSON') : helper)}\n
\n ) : null}\n
\n );\n }\n\n return (\n {\n const value = e.target.value;\n\n this.setState({ value, oldValue: this.state.value, jsonError: this.validateJson(value) }, () =>\n this.onChange(this.props.attr, value),\n );\n }}\n placeholder={this.getText(this.props.schema.placeholder)}\n label={this.getText(this.props.schema.label)}\n helperText={\n this.state.jsonError\n ? I18n.t('ra_Invalid JSON')\n : this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )\n }\n />\n );\n }\n}\n\nexport default ConfigText;\n","import React, { type JSX } from 'react';\n\nimport { TextField, IconButton } from '@mui/material';\n\nimport { I18n, Icon, IconCopy, Utils } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemSendTo } from '#JC/types';\nimport getIconByName from './Icons';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n },\n};\n\ninterface ConfigTextSendToProps extends ConfigGenericProps {\n schema: ConfigItemSendTo;\n}\n\ninterface ConfigTextSendToState extends ConfigGenericState {\n text?: string;\n style?: React.CSSProperties;\n icon?: string;\n iconStyle?: React.CSSProperties;\n}\n\ninterface Response {\n text: string;\n style?: React.CSSProperties;\n icon?: string;\n iconStyle?: React.CSSProperties;\n}\n\nclass ConfigTextSendTo extends ConfigGeneric {\n private initialized = false;\n\n private localContext: string | undefined;\n\n askInstance(): void {\n if (this.props.alive) {\n let data: Record | undefined = this.props.schema.data;\n if (data === undefined && this.props.schema.jsonData) {\n const dataStr: string = this.getPattern(this.props.schema.jsonData, null, true);\n try {\n data = JSON.parse(dataStr);\n } catch {\n console.error(`Cannot parse json data: ${dataStr}`);\n }\n }\n\n if (data === undefined) {\n data = null;\n }\n\n void this.props.oContext.socket\n .sendTo(\n `${this.props.oContext.adapterName}.${this.props.oContext.instance}`,\n this.props.schema.command || 'send',\n data,\n )\n .then(result => {\n if (typeof result === 'object') {\n const _data: Response = result;\n this.setState({\n text: _data.text || '',\n style: _data.style,\n icon: _data.icon,\n iconStyle: _data.iconStyle,\n });\n } else if (typeof result === 'string') {\n this.setState({ text: result || '' });\n }\n })\n .catch(e => console.error(`Cannot send command: ${e}`));\n }\n }\n\n getLocalContext(): string {\n const localContext: Record = {};\n if (Array.isArray(this.props.schema.alsoDependsOn)) {\n this.props.schema.alsoDependsOn.forEach(\n attr => (localContext[attr] = ConfigGeneric.getValue(this.props.data, attr)),\n );\n }\n return JSON.stringify(localContext);\n }\n\n renderItem(/* error, disabled, defaultValue */): JSX.Element {\n if (this.props.alive) {\n const localContext = this.getLocalContext();\n if (localContext !== this.localContext || !this.initialized) {\n this.localContext = localContext;\n setTimeout(() => this.askInstance(), this.initialized ? 300 : 50);\n this.initialized = true;\n }\n }\n\n if (this.state.text === undefined) {\n return null;\n }\n\n let icon: JSX.Element | null = null;\n if (this.state.icon) {\n icon = getIconByName(this.state.icon, {\n marginRight: this.state.text ? 8 : undefined,\n ...(this.state.iconStyle || undefined),\n });\n if (!icon) {\n icon = (\n \n );\n }\n }\n\n if (this.props.schema.container === 'text') {\n return (\n {\n Utils.copyToClipboard(this.state.text);\n window.alert(I18n.t('ra_Copied'));\n }}\n >\n \n \n ) : undefined,\n },\n }}\n value={this.state.text}\n label={this.getText(this.props.schema.label)}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n />\n );\n }\n return (\n
\n {icon}\n {this.props.schema.container === 'html' ? (\n \n ) : (\n this.state.text\n )}\n
\n );\n }\n}\n\nexport default ConfigTextSendTo;\n","import React, { type JSX } from 'react';\n\nimport { TimePicker } from '@mui/x-date-pickers';\n\nimport type { ConfigItemTimePicker } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps } from './ConfigGeneric';\n\ninterface ConfigTimePickerProps extends ConfigGenericProps {\n schema: ConfigItemTimePicker;\n dialogName?: string;\n}\n\nexport default class ConfigTimePicker extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n this.setState({ value });\n }\n\n renderItem(_error: unknown, disabled: boolean): JSX.Element {\n // the format could be 'HH:mm:ss' or 'HH:mm'\n const shortFormat = this.props.schema.returnFormat !== 'HH:mm:ss';\n\n const value: never = new Date(Date.parse(`Thu, 01 Jan 1970 ${this.state.value || '00:00:00'}`)) as never;\n\n return (\n ({\n width: '100%',\n borderBottom: `1px solid ${theme.palette.text.primary}`,\n '& fieldset': {\n display: 'none',\n },\n '& input': {\n padding: `${theme.spacing(1.5)} 0 4px 0`,\n },\n '& .MuiInputAdornment-root': {\n marginLeft: 0,\n marginTop: 1, // it is already in spaces\n },\n '& label': {\n transform: 'translate(0px, -9px) scale(0.75)',\n },\n })}\n ampm={this.props.oContext.systemConfig.dateFormat.includes('/')}\n timeSteps={\n this.props.schema.timeSteps || this.props.schema.timesteps || { hours: 1, minutes: 5, seconds: 5 }\n }\n format={this.props.schema.format || 'HH:mm:ss'}\n disabled={!!disabled}\n value={value}\n onChange={(newValue: Date) => {\n let strValue: string;\n strValue =\n (newValue as any) instanceof Date\n ? newValue.toTimeString().split(' ')[0]\n : newValue.toTimeString();\n if (shortFormat) {\n strValue = strValue.split(':').slice(0, 2).join(':');\n }\n\n this.setState({ value: strValue }, () => this.onChange(this.props.attr, this.state.value));\n }}\n views={this.props.schema.views || ['hours', 'minutes', 'seconds']}\n label={this.getText(this.props.schema.label)}\n />\n );\n }\n}\n","import React, { type JSX } from 'react';\n\nimport { TextField } from '@mui/material';\n\nimport type { ConfigItemTopic } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nfunction convertID2Topic(id: string, namespace: string): string {\n let topic;\n if (namespace && id.substring(0, namespace.length) === namespace) {\n topic = id.substring(namespace.length + 1);\n } else {\n topic = id;\n }\n topic = topic.replace(/\\./g, '/').replace(/_/g, ' ');\n return topic;\n}\n\ninterface ConfigTopicProps extends ConfigGenericProps {\n schema: ConfigItemTopic;\n}\n\nclass ConfigTopic extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n if (!value && this.props.customObj?._id) {\n const topic = convertID2Topic(\n this.props.customObj._id,\n `${this.props.oContext.adapterName}.${this.props.oContext.instance}`,\n );\n this.setState({ value: topic });\n } else {\n this.setState({ value: value || '' });\n }\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n return (\n {\n const value = e.target.value;\n this.setState({ value }, () => this.onChange(this.props.attr, value));\n }}\n />\n );\n }\n}\n\nexport default ConfigTopic;\n","import React, { type JSX } from 'react';\n\nimport { TextField, IconButton } from '@mui/material';\n\nimport { ContentCopy as IconCopy } from '@mui/icons-material';\n\nimport { Utils, I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemUUID } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigUUIDProps extends ConfigGenericProps {\n schema: ConfigItemUUID;\n}\n\ninterface ConfigUUIDState extends ConfigGenericState {\n uuid?: string;\n}\n\nclass ConfigUUID extends ConfigGeneric {\n async componentDidMount(): Promise {\n super.componentDidMount();\n\n const uuidObj = await this.props.oContext.socket.getObject('system.meta.uuid');\n this.setState({ uuid: uuidObj?.native?.uuid || 'unknown' });\n }\n\n renderItem(error: unknown, disabled: boolean): JSX.Element {\n return (\n {\n Utils.copyToClipboard(this.state.uuid);\n window.alert(I18n.t('ra_Copied %s', this.state.uuid));\n }}\n >\n \n \n ),\n },\n }}\n value={this.state.uuid || ''}\n label={this.getText(this.props.schema.label) || I18n.t('ra_Serial number (UUID)')}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n />\n );\n }\n}\n\nexport default ConfigUUID;\n","import React, { type JSX } from 'react';\n\nimport { InputLabel, TextField, MenuItem, FormHelperText, FormControl, Select } from '@mui/material';\n\nimport { Icon, Utils, I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemUser } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\nconst styles: Record = {\n icon: {\n width: 16,\n height: 16,\n marginRight: 8,\n },\n};\n\ninterface ConfigUserProps extends ConfigGenericProps {\n schema: ConfigItemUser;\n}\n\ninterface ConfigUserState extends ConfigGenericState {\n users: Record;\n}\n\nclass ConfigUser extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n this.props.oContext.socket\n .getUsers()\n .then(users => {\n const _users: Record = {};\n const lang = I18n.getLanguage();\n\n if (this.props.schema.short) {\n users.forEach(\n user =>\n (_users[user._id] = {\n color: user.common?.color,\n icon: user.common?.icon,\n name: Utils.getObjectNameFromObj(user, lang),\n }),\n );\n } else {\n users.forEach(\n user =>\n (_users[user._id.replace(/^system\\.user\\./, '')] = {\n color: user.common?.color,\n icon: user.common?.icon,\n name: Utils.getObjectNameFromObj(user, lang),\n }),\n );\n }\n\n this.setState({ users: _users });\n })\n .catch(e => console.error(`Cannot get users: ${e}`));\n }\n\n renderItem(error: string, disabled: boolean /* , defaultValue */): JSX.Element {\n const value = ConfigGeneric.getValue(this.props.data, this.props.attr);\n\n return (\n \n {this.state.users && this.props.schema.label ? (\n {this.getText(this.props.schema.label)}\n ) : null}\n {!this.state.users ? (\n this.onChange(this.props.attr, e.target.value)}\n label={this.getText(this.props.schema.label)}\n />\n ) : (\n (\n \n {this.state.users && this.state.users[val]?.icon ? (\n \n ) : null}\n {(this.state.users && this.state.users[val]?.name) || val || ''}\n \n )}\n style={{\n color: (this.state.users && this.state.users[value]?.color) || undefined,\n backgroundColor: Utils.getInvertedColor(\n this.state.users && this.state.users[value]?.color,\n this.props.oContext.themeType,\n ),\n }}\n onChange={e => this.onChange(this.props.attr, e.target.value)}\n >\n {this.state.users &&\n Object.keys(this.state.users).map(id => (\n \n {this.state.users[id].icon ? (\n \n ) : null}\n {this.state.users[id].name}\n \n ))}\n \n )}\n {this.props.schema.help ? (\n \n {this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n \n ) : null}\n \n );\n }\n}\n\nexport default ConfigUser;\n","import React, { type JSX } from 'react';\n\nimport type QRCode from 'react-qr-code';\nimport type { ConfigItemQrCode } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigQrCodeProps extends ConfigGenericProps {\n schema: ConfigItemQrCode;\n}\n\ninterface ConfigQrCodeState extends ConfigGenericState {\n QRCode: typeof QRCode | null;\n}\n\nclass ConfigQrCode extends ConfigGeneric {\n async componentDidMount(): Promise {\n super.componentDidMount();\n // lazy load of qrcode\n const module = await import('react-qr-code');\n this.setState({ QRCode: module.default });\n }\n\n renderItem(): JSX.Element | null {\n const QRCodeComponent = this.state.QRCode;\n if (!QRCodeComponent) {\n return null;\n }\n return (\n \n );\n }\n}\n\nexport default ConfigQrCode;\n","import React, { type JSX } from 'react';\n\nimport { Grid2, Accordion, AccordionSummary, AccordionDetails, Typography, Box } from '@mui/material';\n\nimport { ExpandMore as ExpandMoreIcon } from '@mui/icons-material';\n\nimport { type IobTheme, Utils } from '@iobroker/adapter-react-v5';\nimport type { ConfigItemPanel } from '#JC/types';\n\nimport ConfigGeneric, { type ConfigGenericState, type ConfigGenericProps } from './ConfigGeneric';\nimport ConfigAccordion from './ConfigAccordion';\nimport ConfigAlive from './ConfigAlive';\nimport ConfigAutocomplete from './ConfigAutocomplete';\nimport ConfigAutocompleteSendTo from './ConfigAutocompleteSendTo';\nimport ConfigCRON from './ConfigCRON';\nimport ConfigCertificateSelect from './ConfigCertificateSelect';\nimport ConfigCertificates from './ConfigCertificates';\nimport ConfigCertCollection from './ConfigCertCollection';\nimport ConfigCheckLicense from './ConfigCheckLicense';\nimport ConfigCheckbox from './ConfigCheckbox';\nimport ConfigChip from './ConfigChip';\nimport ConfigColor from './ConfigColor';\nimport ConfigCoordinates from './ConfigCoordinates';\nimport ConfigCustom from './ConfigCustom';\nimport ConfigDatePicker from './ConfigDatePicker';\nimport ConfigDeviceManager from './ConfigDeviceManager';\nimport ConfigFile from './ConfigFile';\nimport ConfigFileSelector from './ConfigFileSelector';\nimport ConfigFunc from './ConfigFunc';\nimport ConfigIP from './ConfigIP';\nimport ConfigImageSendTo from './ConfigImageSendTo';\nimport ConfigImageUpload from './ConfigImageUpload';\nimport ConfigInstanceSelect from './ConfigInstanceSelect';\nimport ConfigInterface from './ConfigInterface';\nimport ConfigJsonEditor from './ConfigJsonEditor';\nimport ConfigLanguage from './ConfigLanguage';\nimport ConfigLicense from './ConfigLicense';\nimport ConfigNumber from './ConfigNumber';\nimport ConfigObjectId from './ConfigObjectId';\nimport ConfigPassword from './ConfigPassword';\nimport ConfigPattern from './ConfigPattern';\nimport ConfigPort from './ConfigPort';\nimport ConfigRoom from './ConfigRoom';\nimport ConfigSelect from './ConfigSelect';\nimport ConfigSelectSendTo from './ConfigSelectSendTo';\nimport ConfigSendTo from './ConfigSendto';\nimport ConfigSetState from './ConfigSetState';\nimport ConfigSlider from './ConfigSlider';\nimport ConfigState from './ConfigState';\nimport ConfigStaticDivider from './ConfigStaticDivider';\nimport ConfigStaticHeader from './ConfigStaticHeader';\nimport ConfigStaticImage from './ConfigStaticImage';\nimport ConfigStaticInfo from './ConfigStaticInfo';\nimport ConfigStaticText from './ConfigStaticText';\nimport ConfigTable from './ConfigTable';\nimport ConfigText from './ConfigText';\nimport ConfigTextSendTo from './ConfigTextSendTo';\nimport ConfigTimePicker from './ConfigTimePicker';\nimport ConfigTopic from './ConfigTopic';\nimport ConfigUUID from './ConfigUUID';\nimport ConfigUser from './ConfigUser';\nimport ConfigQrCode from './ConfigQrCode';\n\nconst components: Record> = {\n accordion: ConfigAccordion,\n alive: ConfigAlive,\n autocomplete: ConfigAutocomplete,\n autocompleteSendTo: ConfigAutocompleteSendTo,\n certCollection: ConfigCertCollection,\n certificate: ConfigCertificateSelect,\n certificates: ConfigCertificates,\n checkbox: ConfigCheckbox,\n checkLicense: ConfigCheckLicense,\n chip: ConfigChip, // deprecated. Use \"chips\"\n chips: ConfigChip,\n color: ConfigColor,\n coordinates: ConfigCoordinates,\n cron: ConfigCRON,\n custom: ConfigCustom,\n datePicker: ConfigDatePicker,\n deviceManager: ConfigDeviceManager,\n divider: ConfigStaticDivider,\n file: ConfigFile,\n fileSelector: ConfigFileSelector,\n func: ConfigFunc,\n header: ConfigStaticHeader,\n image: ConfigImageUpload,\n imageSendTo: ConfigImageSendTo,\n instance: ConfigInstanceSelect,\n interface: ConfigInterface,\n ip: ConfigIP,\n jsonEditor: ConfigJsonEditor,\n language: ConfigLanguage,\n license: ConfigLicense,\n number: ConfigNumber,\n objectId: ConfigObjectId,\n password: ConfigPassword,\n pattern: ConfigPattern,\n port: ConfigPort,\n qrCode: ConfigQrCode,\n room: ConfigRoom,\n select: ConfigSelect,\n selectSendTo: ConfigSelectSendTo,\n // @deprecated Use \"sendTo\"\n sendto: ConfigSendTo,\n sendTo: ConfigSendTo,\n setState: ConfigSetState,\n slider: ConfigSlider,\n state: ConfigState,\n staticImage: ConfigStaticImage,\n staticInfo: ConfigStaticInfo,\n staticLink: ConfigStaticText,\n staticText: ConfigStaticText,\n table: ConfigTable,\n text: ConfigText,\n textSendTo: ConfigTextSendTo,\n timePicker: ConfigTimePicker,\n topic: ConfigTopic,\n uuid: ConfigUUID,\n user: ConfigUser,\n};\n\nconst styles: Record = {\n fullWidth: {\n width: '100%',\n // height: '100%',\n },\n paper: {\n margin: 1,\n width: 'auto !important',\n overflowY: 'auto',\n paddingBottom: 1,\n },\n paperWithIcons: {\n height: 'calc(100vh - 259px) !important',\n },\n paperWithoutIcons: {\n height: 'calc(100vh - 235px) !important',\n },\n padding: {\n padding: '10px',\n },\n heading: {},\n primary: (theme: IobTheme): React.CSSProperties => ({\n backgroundColor: theme.palette.primary.main,\n color: theme.palette.mode === 'dark' ? 'inherit' : '#FFF',\n }),\n secondary: (theme: IobTheme): React.CSSProperties => ({\n backgroundColor: theme.palette.secondary.main,\n }),\n};\n\ninterface ConfigPanelProps extends ConfigGenericProps {\n schema: ConfigItemPanel;\n withIcons?: boolean;\n}\ninterface ConfigPanelState extends ConfigGenericState {\n expanded?: boolean;\n}\n\nclass ConfigPanel extends ConfigGeneric {\n componentDidMount(): void {\n super.componentDidMount();\n if (this.props.schema && this.props.schema.collapsable) {\n this.setState({\n expanded:\n (((window as any)._localStorage as Storage) || window.localStorage).getItem(\n `${this.props.oContext.adapterName}.${this.props.attr}`,\n ) === 'true',\n });\n }\n }\n\n renderItems(items: Record, disabled: boolean): JSX.Element[] | null {\n return items\n ? Object.keys(items).map(attr => {\n if (this.props.oContext.multiEdit && items[attr].noMultiEdit) {\n return null;\n }\n\n const type = items[attr].type || 'panel';\n let ItemComponent: typeof ConfigGeneric;\n if (type === 'custom') {\n // name\n // url\n if (items[attr].url) {\n ItemComponent = ConfigCustom;\n } else if (this.props.oContext.customs && this.props.oContext.customs[items[attr].component]) {\n ItemComponent = this.props.oContext.customs[items[attr].component];\n } else {\n console.error(`Cannot find custom component: ${items[attr].component}`);\n ItemComponent = ConfigGeneric;\n }\n } else if (type === 'panel') {\n ItemComponent = ConfigPanel;\n } else {\n ItemComponent = components[type] || ConfigGeneric;\n }\n\n return (\n \n );\n })\n : null;\n }\n\n render(): JSX.Element | null {\n const schema = this.props.schema;\n\n if (!schema) {\n return null;\n }\n\n const { disabled, hidden } = this.calculate(schema);\n\n const items = this.props.schema.items;\n const schemaStyle = this.props.schema.style || {};\n\n if (hidden) {\n if (schema.hideOnlyControl) {\n const item = (\n \n );\n\n if (schema.newLine) {\n return (\n <>\n
\n {item}\n \n );\n }\n return item;\n }\n return null;\n }\n\n if (this.props.table) {\n return this.renderItems(items, disabled) as any as JSX.Element;\n }\n\n if (this.props.custom) {\n return (\n \n {this.renderItems(items, disabled)}\n \n );\n }\n\n let content;\n if (schema.collapsable) {\n content = (\n {\n (((window as any)._localStorage as Storage) || window.localStorage).setItem(\n `${this.props.oContext.adapterName}.${this.props.attr}`,\n this.state.expanded ? 'false' : 'true',\n );\n this.setState({ expanded: !this.state.expanded });\n }}\n >\n }\n sx={Utils.getStyle(\n this.props.oContext.theme,\n schemaStyle,\n this.props.oContext.themeType && schema.darkStyle,\n schema.color === 'primary'\n ? styles.primary\n : schema.color === 'secondary' && styles.secondary,\n { width: '100%' },\n )}\n >\n {this.getText(schema.label)}\n \n \n \n {this.renderItems(items, disabled)}\n \n \n \n );\n } else {\n content = (\n \n \n {this.renderItems(items, disabled)}\n \n \n );\n }\n\n if (!this.props.isParentTab) {\n const item = (\n \n {content}\n \n );\n\n if (schema.newLine) {\n return (\n <>\n
\n {item}\n \n );\n }\n return item;\n }\n return content;\n }\n}\n\nexport default ConfigPanel;\n","import React, { type JSX } from 'react';\n\nimport { Tabs, Tab } from '@mui/material';\n\nimport type { ConfigItemTabs } from '#JC/types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\nimport ConfigPanel from './ConfigPanel';\n\nconst styles: Record = {\n tabs: {\n height: '100%',\n width: '100%',\n },\n panel: {\n width: '100%',\n display: 'block',\n },\n panelWithIcons: {\n height: 'calc(100% - 72px)',\n },\n panelWithoutIcons: {\n height: 'calc(100% - 48px)',\n },\n};\n\ninterface ConfigTabsProps extends ConfigGenericProps {\n schema: ConfigItemTabs;\n dialogName?: string;\n}\n\ninterface ConfigTabsState extends ConfigGenericState {\n tab?: string;\n}\n\nclass ConfigTabs extends ConfigGeneric {\n constructor(props: ConfigTabsProps) {\n super(props);\n let tab: string | undefined;\n\n if (this.props.root) {\n // read the path from hash\n // #tab-instances/config/system.adapter.ping.0/\n const hash = (window.location.hash || '').replace(/^#/, '').split('/');\n if (hash.length >= 3 && hash[1] === 'config') {\n const tabS = hash[3];\n const tabN = parseInt(tabS, 10);\n if (tabS && tabN.toString() === tabS) {\n if (tabN >= 0 && tabN < Object.keys(this.props.schema.items).length) {\n tab = Object.keys(this.props.schema.items)[tabN];\n }\n } else if (tabS && Object.keys(this.props.schema.items).includes(tabS)) {\n tab = tabS;\n }\n\n // install on hash change handler\n window.addEventListener('hashchange', this.onHashTabsChanged, false);\n }\n }\n\n if (tab === undefined) {\n tab =\n (((window as any)._localStorage as Storage) || window.localStorage).getItem(\n `${this.props.dialogName || 'App'}.${this.props.oContext.adapterName}`,\n ) || Object.keys(this.props.schema.items)[0];\n if (!Object.keys(this.props.schema.items).includes(tab)) {\n tab = Object.keys(this.props.schema.items)[0];\n }\n }\n\n Object.assign(this.state, { tab });\n }\n\n componentWillUnmount(): void {\n window.removeEventListener('hashchange', this.onHashTabsChanged, false);\n super.componentWillUnmount();\n }\n\n onHashTabsChanged = (): void => {\n const hash = (window.location.hash || '').replace(/^#/, '').split('/');\n if (hash.length > 3 && hash[1] === 'config') {\n const tabS = hash[3];\n const tabN = parseInt(tabS, 10);\n let tab;\n if (tabN.toString() === tabS) {\n if (tabN >= 0 && tabN < Object.keys(this.props.schema.items).length) {\n tab = Object.keys(this.props.schema.items)[tabN];\n }\n } else if (Object.keys(this.props.schema.items).includes(tabS)) {\n tab = tabS;\n }\n if (tab !== undefined && tab !== this.state.tab) {\n (((window as any)._localStorage as Storage) || window.localStorage).setItem(\n `${this.props.dialogName || 'App'}.${this.props.oContext.adapterName}`,\n tab,\n );\n this.setState({ tab });\n }\n }\n };\n\n render(): JSX.Element {\n const items = this.props.schema.items;\n let withIcons = false;\n\n return (\n
\n {\n (((window as any)._localStorage as Storage) || window.localStorage).setItem(\n `${this.props.dialogName || 'App'}.${this.props.oContext.adapterName}`,\n tab,\n );\n this.setState({ tab }, () => {\n if (this.props.root) {\n const hash = (window.location.hash || '').split('/');\n if (hash.length >= 3 && hash[1] === 'config') {\n hash[3] = this.state.tab;\n window.location.hash = hash.join('/');\n }\n }\n });\n }}\n >\n {Object.keys(items).map(name => {\n let disabled: boolean;\n if (this.props.custom) {\n const hidden = this.executeCustom(\n items[name].hidden,\n this.props.data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n this.props.index,\n this.props.globalData,\n );\n if (hidden) {\n return null;\n }\n disabled = this.executeCustom(\n items[name].disabled,\n this.props.data,\n this.props.customObj,\n this.props.oContext.instanceObj,\n this.props.index,\n this.props.globalData,\n ) as boolean;\n } else {\n const hidden: boolean = this.execute(\n items[name].hidden,\n false,\n this.props.data,\n this.props.index,\n this.props.globalData,\n ) as boolean;\n if (hidden) {\n return null;\n }\n disabled = this.execute(\n items[name].disabled,\n false,\n this.props.data,\n this.props.index,\n this.props.globalData,\n ) as boolean;\n }\n const icon = this.getIcon(items[name].icon);\n withIcons = withIcons || !!icon;\n\n return (\n \n );\n })}\n \n \n
\n );\n }\n}\n\nexport default ConfigTabs;\n","import React, { Component, type JSX } from 'react';\n\nimport { LinearProgress } from '@mui/material';\n\nimport { type AdminConnection, I18n, type ThemeName, type ThemeType, type IobTheme } from '@iobroker/adapter-react-v5';\n\nimport type { BackEndCommand, ConfigItemPanel, ConfigItemTabs, JsonConfigContext } from '#JC/types';\nimport type ConfigGeneric from '#JC/JsonConfigComponent/ConfigGeneric';\nimport { type DeviceManagerPropsProps } from '#JC/JsonConfigComponent/ConfigGeneric';\nimport ConfigTabs from './ConfigTabs';\nimport ConfigPanel from './ConfigPanel';\n\nconst styles: Record = {\n root: {\n width: '100%',\n height: '100%',\n },\n};\n\ninterface JsonConfigComponentProps {\n socket: AdminConnection;\n themeName: ThemeName;\n themeType: ThemeType;\n adapterName: string;\n instance: number;\n isFloatComma: boolean;\n dateFormat: string;\n imagePrefix?: string;\n schema: ConfigItemTabs | ConfigItemPanel;\n common?: Record;\n data: Record;\n updateData?: number;\n onError: (error: boolean) => void;\n onChange?: (data: Record, changed: boolean, saveConfig: boolean) => void;\n /** Backend request to refresh data */\n onBackEndCommand?: (command?: BackEndCommand) => void;\n custom?: boolean;\n onValueChange?: (attr: string, value: any, saveConfig: boolean) => void;\n embedded?: boolean;\n multiEdit?: boolean;\n instanceObj?: ioBroker.InstanceObject;\n customObj?: ioBroker.Object;\n customs?: Record;\n DeviceManager?: React.FC;\n style?: React.CSSProperties;\n theme: IobTheme;\n expertMode?: boolean;\n}\n\ninterface JsonConfigComponentState {\n originalData: string;\n changed: boolean;\n errors: Record;\n systemConfig: ioBroker.SystemConfigCommon | null;\n updateData?: number;\n alive: boolean;\n commandRunning: boolean;\n schema: ConfigItemTabs | ConfigItemPanel;\n}\n\nexport class JsonConfigComponent extends Component {\n private readonly forceUpdateHandlers: Record void>;\n\n private errorTimeout: ReturnType | null = null;\n\n private errorCached: Record | null = null;\n\n private oContext: JsonConfigContext;\n\n constructor(props: JsonConfigComponentProps) {\n super(props);\n\n this.state = {\n originalData: JSON.stringify(this.props.data),\n changed: false,\n errors: {},\n updateData: this.props.updateData || 0,\n systemConfig: null,\n alive: false,\n commandRunning: false,\n schema: JSON.parse(JSON.stringify(this.props.schema)),\n };\n\n this.forceUpdateHandlers = {};\n\n this.buildDependencies(this.state.schema);\n\n this.readData();\n }\n\n static getDerivedStateFromProps(\n props: JsonConfigComponentProps,\n state: JsonConfigComponentState,\n ): Partial | null {\n if (props.updateData !== state.updateData) {\n return {\n updateData: props.updateData,\n originalData: JSON.stringify(props.data),\n schema: JSON.parse(JSON.stringify(props.schema)),\n };\n }\n return null;\n }\n\n static async loadI18n(\n socket: AdminConnection,\n i18n: boolean | string | Record>,\n adapterName: string,\n ): Promise {\n if (i18n === true || (i18n && typeof i18n === 'string')) {\n const lang = I18n.getLanguage();\n const path = typeof i18n === 'string' ? i18n : 'i18n';\n let exists = await socket.fileExists(`${adapterName}.admin`, `${path}/${lang}.json`);\n let fileName;\n if (exists) {\n fileName = `${path}/${lang}.json`;\n } else {\n exists = await socket.fileExists(`${adapterName}.admin`, `${path}/${lang}/translations.json`);\n if (exists) {\n fileName = `${path}/${lang}/translations.json`;\n } else if (lang !== 'en') {\n // fallback to english\n exists = await socket.fileExists(`${adapterName}.admin`, `${path}/en.json`);\n if (exists) {\n fileName = `${path}/en.json`;\n } else {\n exists = await socket.fileExists(`${adapterName}.admin`, `${path}/en/translations.json`);\n if (exists) {\n fileName = `${path}/en/translations.json`;\n }\n }\n }\n }\n\n if (fileName) {\n const jsonFile = await socket.readFile(`${adapterName}.admin`, fileName);\n let jsonStr: string;\n if (jsonFile.file !== undefined) {\n jsonStr = jsonFile.file;\n } else {\n // @ts-expect-error deprecated\n jsonStr = jsonFile;\n }\n\n try {\n const json = JSON.parse(jsonStr);\n // apply file to I18n\n I18n.extendTranslations(json, lang);\n } catch (e) {\n console.error(`Cannot parse language file \"${adapterName}.admin/${fileName}: ${e}`);\n return '';\n }\n return fileName;\n }\n console.warn(`Cannot find i18n for ${adapterName} / ${fileName}`);\n return '';\n }\n if (i18n && typeof i18n === 'object') {\n I18n.extendTranslations(i18n);\n return '';\n }\n return '';\n }\n\n onCommandRunning = (commandRunning: boolean): void => this.setState({ commandRunning });\n\n readData(): void {\n void this.props.socket\n .getCompactSystemConfig()\n .then(systemConfig =>\n this.props.socket\n .getState(`system.adapter.${this.props.adapterName}.${this.props.instance}.alive`)\n .then(state =>\n this.setState({ systemConfig: systemConfig.common, alive: !!(state && state.val) }, () => {\n this.updateContext(true);\n if (!this.props.custom) {\n void this.props.socket.subscribeState(\n `system.adapter.${this.props.adapterName}.${this.props.instance}.alive`,\n this.onAlive,\n );\n }\n }),\n ),\n )\n .catch(e => console.error(`Cannot read system config: ${e}`));\n }\n\n onAlive = (_id: string, state?: ioBroker.State | null): void => {\n if (!!state?.val !== this.state.alive) {\n this.setState({ alive: !!state?.val });\n }\n };\n\n onChange = (attrOrData: string | Record, value: any, cb?: () => void, saveConfig?: boolean): void => {\n if (this.props.onValueChange) {\n this.props.onValueChange(attrOrData as string, value, saveConfig);\n if (cb) {\n cb();\n }\n } else if (attrOrData && this.props.onChange) {\n const newState: Partial = {\n changed: JSON.stringify(attrOrData) !== this.state.originalData,\n };\n\n this.setState(newState as JsonConfigComponentState, () => {\n this.props.onChange(attrOrData as Record, newState.changed, saveConfig);\n if (cb) {\n cb();\n }\n });\n } else if (saveConfig) {\n this.props.onChange(null, null, saveConfig);\n }\n };\n\n onError = (attr: string, error?: string): void => {\n this.errorCached = this.errorCached || JSON.parse(JSON.stringify(this.state.errors));\n const errors = this.errorCached;\n if (error) {\n errors[attr] = error;\n } else {\n delete errors[attr];\n }\n\n if (this.errorTimeout) {\n clearTimeout(this.errorTimeout);\n }\n if (JSON.stringify(errors) !== JSON.stringify(this.state.errors)) {\n this.errorTimeout = setTimeout(\n () =>\n this.setState({ errors: this.errorCached }, () => {\n this.errorTimeout = null;\n this.errorCached = null;\n this.props.onError(!!Object.keys(this.state.errors).length);\n }),\n 50,\n );\n } else {\n this.errorCached = null;\n }\n };\n\n flatten(schema: Record, _list?: Record): Record {\n _list = _list || {};\n if (schema.items) {\n Object.keys(schema.items).forEach(attr => {\n _list[attr] = schema.items[attr];\n this.flatten(schema.items[attr], _list);\n });\n }\n\n return _list;\n }\n\n buildDependencies(schema: ConfigItemTabs | ConfigItemPanel): void {\n const attrs = this.flatten(schema as Record);\n Object.keys(attrs).forEach(attr => {\n if (attrs[attr].confirm?.alsoDependsOn) {\n attrs[attr].confirm?.alsoDependsOn.forEach((dep: string) => {\n if (!attrs[dep]) {\n console.error(`[JsonConfigComponent] Attribute ${dep} does not exist!`);\n if (dep.startsWith('data.')) {\n console.warn(\n `[JsonConfigComponent] please use \"${dep.replace(/^data\\./, '')}\" instead of \"${dep}\"`,\n );\n }\n } else {\n attrs[dep].confirmDependsOn = attrs[dep].confirmDependsOn || [];\n\n const depObj = { ...attrs[attr], attr };\n if (depObj.confirm) {\n depObj.confirm.cancel = 'Undo';\n }\n\n attrs[dep].confirmDependsOn.push(depObj);\n }\n });\n }\n\n if (attrs[attr].onChange?.alsoDependsOn) {\n attrs[attr].onChange?.alsoDependsOn.forEach((dep: string) => {\n if (!attrs[dep]) {\n console.error(`[JsonConfigComponent] Attribute ${dep} does not exist!`);\n if (dep.startsWith('data.')) {\n console.warn(\n `[JsonConfigComponent] please use \"${dep.replace(/^data\\./, '')}\" instead of \"${dep}\"`,\n );\n }\n } else {\n attrs[dep].onChangeDependsOn = attrs[dep].onChangeDependsOn || [];\n\n const depObj = { ...attrs[attr], attr };\n\n attrs[dep].onChangeDependsOn.push(depObj);\n }\n });\n }\n\n if (attrs[attr].hidden?.alsoDependsOn) {\n attrs[attr].hidden?.alsoDependsOn.forEach((dep: string) => {\n if (!attrs[dep]) {\n console.error(`[JsonConfigComponent] Attribute ${dep} does not exist!`);\n if (dep.startsWith('data.')) {\n console.warn(\n `[JsonConfigComponent] please use \"${dep.replace(/^data\\./, '')}\" instead of \"${dep}\"`,\n );\n }\n } else {\n attrs[dep].hiddenDependsOn = attrs[dep].hiddenDependsOn || [];\n\n const depObj = { ...attrs[attr], attr };\n\n attrs[dep].hiddenDependsOn.push(depObj);\n }\n });\n }\n\n if (attrs[attr].label?.alsoDependsOn) {\n attrs[attr].label?.alsoDependsOn.forEach((dep: string) => {\n if (!attrs[dep]) {\n console.error(`[JsonConfigComponent] Attribute ${dep} does not exist!`);\n if (dep.startsWith('data.')) {\n console.warn(\n `[JsonConfigComponent] please use \"${dep.replace(/^data\\./, '')}\" instead of \"${dep}\"`,\n );\n }\n } else {\n attrs[dep].labelDependsOn = attrs[dep].labelDependsOn || [];\n\n const depObj = { ...attrs[attr], attr };\n\n attrs[dep].labelDependsOn.push(depObj);\n }\n });\n }\n\n if (attrs[attr].help?.alsoDependsOn) {\n attrs[attr].help?.alsoDependsOn.forEach((dep: string) => {\n if (!attrs[dep]) {\n console.error(`[JsonConfigComponent] Attribute ${dep} does not exist!`);\n if (dep.startsWith('data.')) {\n console.warn(\n `[JsonConfigComponent] please use \"${dep.replace(/^data\\./, '')}\" instead of \"${dep}\"`,\n );\n }\n } else {\n attrs[dep].helpDependsOn = attrs[dep].helpDependsOn || [];\n\n const depObj = { ...attrs[attr], attr };\n\n attrs[dep].helpDependsOn.push(depObj);\n }\n });\n }\n });\n }\n\n updateContext(forceUpdate?: boolean): void {\n this.oContext = {\n DeviceManager: this.props.DeviceManager,\n adapterName: this.props.adapterName,\n changeLanguage: this.changeLanguage,\n common: this.props.common,\n customs: this.props.customs,\n dateFormat: this.props.dateFormat,\n embedded: this.props.embedded,\n expertMode: this.props.expertMode,\n forceUpdate: this.forceAttrUpdate,\n imagePrefix: this.props.imagePrefix,\n instance: this.props.instance,\n instanceObj: this.props.instanceObj,\n isFloatComma: this.props.isFloatComma,\n multiEdit: this.props.multiEdit,\n onBackEndCommand: this.props.onBackEndCommand,\n onCommandRunning: this.onCommandRunning,\n onValueChange: this.props.onValueChange,\n registerOnForceUpdate: this.registerOnForceUpdate,\n socket: this.props.socket,\n systemConfig: this.state.systemConfig,\n theme: this.props.theme,\n // could be changed dynamically\n themeType: this.props.themeType,\n _themeName: this.props.themeName,\n updateData: this.state.updateData,\n } as JsonConfigContext;\n\n if (forceUpdate) {\n this.forceUpdate();\n }\n }\n\n renderItem(item: ConfigItemTabs | ConfigItemPanel): JSX.Element | null {\n if (item.type === 'tabs') {\n return (\n this.onError(attr, error)}\n originalData={JSON.parse(this.state.originalData)}\n root\n schema={item}\n themeName={this.props.themeName}\n />\n );\n }\n if (\n item.type === 'panel' ||\n // @ts-expect-error type could be empty\n !item.type\n ) {\n return (\n this.onError(attr, error)}\n originalData={JSON.parse(this.state.originalData)}\n root\n schema={item}\n themeName={this.props.themeName}\n />\n );\n }\n console.error(`Unknown item type in root: ${JSON.stringify(item)}`);\n\n return null;\n }\n\n changeLanguage = (): void => {\n this.forceUpdate();\n };\n\n forceAttrUpdate = (attr: string | string[], data: any): void => {\n if (Array.isArray(attr)) {\n attr.forEach(a => this.forceUpdateHandlers[a] && this.forceUpdateHandlers[a](data));\n } else if (this.forceUpdateHandlers[attr]) {\n this.forceUpdateHandlers[attr](data);\n }\n };\n\n registerOnForceUpdate = (attr: string, cb?: ((data: any) => void) | null): void => {\n if (cb) {\n this.forceUpdateHandlers[attr] = cb;\n } else if (this.forceUpdateHandlers[attr]) {\n delete this.forceUpdateHandlers[attr];\n }\n };\n\n render(): JSX.Element {\n if (!this.state.systemConfig || !this.oContext) {\n return ;\n }\n\n if (this.oContext._themeName !== this.props.themeName) {\n this.oContext._themeName = this.props.themeName;\n setTimeout(() => this.updateContext(true), 0);\n }\n\n return (\n \n {this.renderItem(this.state.schema)}\n
\n );\n }\n}\n\nexport default JsonConfigComponent;\n","import React from 'react';\nimport JSON5 from 'json5';\nimport MD5 from 'crypto-js/md5';\n\nimport { Fab, Tooltip, LinearProgress } from '@mui/material';\nimport { Publish as PublishIcon } from '@mui/icons-material';\n\nimport {\n I18n,\n Router,\n SaveCloseButtons,\n Theme,\n DialogConfirm,\n type AdminConnection,\n type IobTheme,\n type ThemeName,\n type ThemeType,\n Utils,\n} from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemAny, ConfigItemPanel, ConfigItemTabs } from '#JC/types';\nimport ConfigGeneric, { type DeviceManagerPropsProps } from './JsonConfigComponent/ConfigGeneric';\nimport JsonConfigComponent from './JsonConfigComponent';\n\nconst styles: Record = {\n root: {\n width: '100%',\n height: '100%',\n overflow: 'hidden',\n position: 'relative',\n },\n scroll: {\n height: 'calc(100% - 48px)',\n overflowY: 'auto',\n },\n exportImportButtons: {\n position: 'absolute',\n top: 5,\n right: 0,\n zIndex: 3,\n },\n button: {\n marginRight: '5px',\n },\n tooltip: {\n pointerEvents: 'none',\n },\n};\n\n/**\n * Decrypt the password/value with given key\n *\n * @param key - Secret key\n * @param value - value to decrypt\n */\nfunction decryptLegacy(key: string, value: string): string {\n let result = '';\n for (let i = 0; i < value.length; i++) {\n result += String.fromCharCode(key[i % key.length].charCodeAt(0) ^ value.charCodeAt(i));\n }\n return result;\n}\n\n/**\n * Encrypt the password/value with given key\n *\n * @param key - Secret key\n * @param value - value to encrypt\n */\nfunction encryptLegacy(key: string, value: string): string {\n let result = '';\n for (let i = 0; i < value.length; i++) {\n result += String.fromCharCode(key[i % key.length].charCodeAt(0) ^ value.charCodeAt(i));\n }\n return result;\n}\n\n/**\n * Decrypt the password/value with given key\n * Usage:\n * ```js\n * function load(settings, onChange) {\n * if (settings.password) {\n * settings.password = decrypt(systemSecret, settings.password);\n * // same as\n * settings.password = decrypt(settings.password);\n * }\n * // ...\n * }\n * ```\n *\n * @param key - Secret key\n * @param value - value to decrypt\n */\nfunction decrypt(key: string, value: string): string {\n if (typeof value !== 'string') {\n return value;\n }\n\n // if not encrypted as aes-192 or key not a valid 48-digit hex -> fallback\n if (!value.startsWith('$/aes-192-cbc:') || !/^[0-9a-f]{48}$/.test(key)) {\n return decryptLegacy(key, value);\n }\n\n // algorithm:iv:encryptedValue\n const textParts = value.split(':', 3);\n\n const _key = window.CryptoJS.enc.Hex.parse(key);\n const iv = window.CryptoJS.enc.Hex.parse(textParts[1]);\n\n const cipherParams = window.CryptoJS.lib.CipherParams.create({\n ciphertext: window.CryptoJS.enc.Hex.parse(textParts[2]),\n });\n\n const decryptedBinary = window.CryptoJS.AES.decrypt(cipherParams, _key, { iv });\n\n return window.CryptoJS.enc.Utf8.stringify(decryptedBinary);\n}\n\n/**\n * Encrypt the password/value with given key\n * Usage:\n * ```\n * function save(callback) {\n * ...\n * if (obj.password) {\n * obj.password = encrypt(systemSecret, obj.password);\n * // same as\n * obj.password = decrypt(obj.password);\n * }\n * ...\n * }\n * ```\n *\n * @param key - Secret key\n * @param value - value to encrypt\n * @param _iv - optional initial vector for tests\n */\nfunction encrypt(key: string, value: string, _iv?: string): string {\n if (typeof value !== 'string') {\n return value;\n }\n\n if (!/^[0-9a-f]{48}$/.test(key)) {\n // key length is not matching for AES-192-CBC or key is no valid hex - fallback to old encryption\n return encryptLegacy(key, value);\n }\n\n let iv;\n if (_iv) {\n iv = window.CryptoJS.enc.Hex.parse(_iv);\n } else {\n iv = window.CryptoJS.lib.WordArray.random(128 / 8);\n }\n\n const _key = window.CryptoJS.enc.Hex.parse(key);\n const encrypted = window.CryptoJS.AES.encrypt(value, _key, { iv }).ciphertext;\n\n return `$/aes-192-cbc:${window.CryptoJS.enc.Hex.stringify(iv)}:${encrypted}`;\n}\n\nfunction loadScript(src: string, id: string): ((this: GlobalEventHandlers, ev: Event) => any) | null | Promise {\n if (!id || !document.getElementById(id)) {\n return new Promise(resolve => {\n const script = document.createElement('script');\n script.setAttribute('id', id);\n script.onload = resolve as unknown as (this: GlobalEventHandlers, ev: Event) => any;\n script.src = src;\n document.getElementsByTagName('head')[0].appendChild(script);\n });\n }\n return document.getElementById(id)?.onload;\n}\n\ninterface BufferObject {\n type: 'Buffer';\n data: Buffer;\n}\n\ninterface JsonConfigProps {\n adapterName: string;\n instance: number;\n isFloatComma: boolean;\n dateFormat: string;\n secret?: string;\n socket: AdminConnection;\n theme: IobTheme;\n themeName: ThemeName;\n themeType: ThemeType;\n expertMode?: boolean;\n /** Translate method */\n t: typeof I18n.t;\n configStored: (notChanged: boolean) => void;\n width: 'xs' | 'sm' | 'md' | 'lg' | 'xl';\n DeviceManager?: React.FC;\n}\n\ninterface JsonConfigState {\n schema?: ConfigItemPanel | ConfigItemTabs;\n data?: Record;\n originalData?: Record;\n updateData: number;\n common?: ioBroker.InstanceCommon;\n changed: boolean;\n confirmDialog: boolean;\n theme: IobTheme;\n saveConfigDialog: boolean;\n hash: string;\n error?: boolean;\n}\n\nclass JsonConfig extends Router {\n private fileSubscribed: string[] = [];\n\n private fileLangSubscribed = '';\n\n private secret: string;\n\n constructor(props: JsonConfigProps) {\n super(props);\n\n this.state = {\n updateData: 0,\n changed: false,\n confirmDialog: false,\n theme: Theme(props.themeName), // buttons require special theme\n saveConfigDialog: false,\n hash: '_',\n };\n\n this.secret = props.secret || '';\n\n void this.getInstanceObject().then(obj =>\n this.getConfigFile().then(schema =>\n // load language\n JsonConfigComponent.loadI18n(this.props.socket, schema?.i18n, this.props.adapterName).then(\n (langFileName: string) => {\n if (langFileName) {\n // subscribe on changes\n if (!this.fileLangSubscribed) {\n this.fileLangSubscribed = langFileName;\n void this.props.socket.subscribeFiles(\n `${this.props.adapterName}.admin`,\n this.fileLangSubscribed,\n this.onFileChange,\n );\n }\n }\n\n if (obj) {\n this.setState({\n schema,\n data: obj.native,\n common: obj.common,\n hash: MD5(JSON.stringify(schema)).toString(),\n });\n } else {\n window.alert(\n `Instance system.adapter.${this.props.adapterName}.${this.props.instance} not found!`,\n );\n }\n },\n ),\n ),\n );\n }\n\n componentWillUnmount(): void {\n super.componentWillUnmount();\n if (this.fileSubscribed.length) {\n this.props.socket.unsubscribeFiles(\n `${this.props.adapterName}.admin`,\n this.fileSubscribed,\n this.onFileChange,\n );\n this.fileSubscribed = [];\n }\n if (this.fileLangSubscribed) {\n this.props.socket.unsubscribeFiles(\n `${this.props.adapterName}.admin`,\n this.fileLangSubscribed,\n this.onFileChange,\n );\n this.fileLangSubscribed = '';\n }\n }\n\n private handleFileSelect = (evt: Record): void => {\n const f = evt.target.files[0];\n if (f) {\n const r = new FileReader();\n r.onload = (e: ProgressEvent): void => {\n if (!e.target) {\n return;\n }\n\n const contents = e.target.result as string;\n try {\n const data = JSON.parse(contents);\n this.setState({ data, changed: JSON.stringify(data) !== JSON.stringify(this.state.originalData) });\n } catch {\n window.alert(I18n.t('[JsonConfig] Failed to parse JSON file'));\n }\n };\n r.readAsText(f);\n } else {\n window.alert(I18n.t('[JsonConfig] Failed to open JSON File'));\n }\n };\n\n getExportImportButtons(): JSX.Element {\n return (\n
\n \n {\n const input = document.createElement('input');\n input.setAttribute('type', 'file');\n input.setAttribute('id', 'files');\n // @ts-expect-error check\n input.setAttribute('opacity', 0);\n input.addEventListener('change', e => this.handleFileSelect(e), false);\n input.click();\n }}\n >\n \n \n \n \n {\n if (!this.state.data) {\n return;\n }\n\n Utils.generateFile(\n `${this.props.adapterName}.${this.props.instance}.json`,\n this.state.data,\n );\n }}\n >\n \n \n \n
\n );\n }\n\n onFileChange = async (id: string, fileName: string, size: number): Promise => {\n if (id === `${this.props.adapterName}.admin` && size) {\n if (fileName === this.fileLangSubscribed) {\n try {\n await JsonConfigComponent.loadI18n(\n this.props.socket,\n this.state.schema?.i18n,\n this.props.adapterName,\n );\n this.setState({ hash: `${this.state.hash}1` });\n } catch {\n // ignore errors\n }\n } else if (this.fileSubscribed.includes(fileName)) {\n try {\n const schema = await this.getConfigFile(this.fileSubscribed[0]);\n this.setState({ schema, hash: MD5(JSON.stringify(schema)).toString() });\n } catch {\n // ignore errors\n }\n }\n }\n };\n\n async getInstanceObject(): Promise {\n try {\n const obj = await this.props.socket.getObject(\n `system.adapter.${this.props.adapterName}.${this.props.instance}`,\n );\n // decode all native attributes listed in obj.encryptedNative\n if (Array.isArray(obj.encryptedNative)) {\n if (!this.secret) {\n const systemConfig = await this.props.socket.getSystemConfig();\n await loadScript('../../lib/js/crypto-js/crypto-js.js', 'crypto-js');\n this.secret = systemConfig.native.secret;\n }\n obj.encryptedNative?.forEach(attr => {\n if (obj.native[attr]) {\n obj.native[attr] = decrypt(this.secret, obj.native[attr]);\n }\n });\n return obj;\n }\n return obj;\n } catch (e) {\n window.alert(`[JsonConfig] Cannot read instance object: ${e}`);\n }\n return null;\n }\n\n renderDialogConfirm(): JSX.Element | null {\n if (!this.state.confirmDialog) {\n return null;\n }\n return (\n \n this.setState({ confirmDialog: false }, () => isYes && Router.doNavigate(null))\n }\n />\n );\n }\n\n async scanForInclude(json: Record, filePaths: string[]): Promise> {\n if (typeof json['#include'] === 'string') {\n // load file\n const data = await this._getConfigFile(json['#include'], [...filePaths]);\n delete json['#include'];\n if (data) {\n // merge data\n json = { ...json, ...data };\n }\n return json;\n }\n const keys = Object.keys(json);\n for (let k = 0; k < keys.length; k++) {\n if (json[keys[k]] && typeof json[keys[k]] === 'object') {\n json[keys[k]] = await this.scanForInclude(json[keys[k]], filePaths);\n }\n }\n return json;\n }\n\n async getConfigFile(fileName?: string): Promise {\n return this._getConfigFile(fileName);\n }\n\n async _getConfigFile(fileName?: string, _filePaths?: string[]): Promise {\n fileName = fileName || 'jsonConfig.json5';\n _filePaths = _filePaths || [];\n\n if (_filePaths.includes(fileName)) {\n window.alert(`[JsonConfig] Circular reference in file: ${fileName} => ${_filePaths.join(' => ')}`);\n return null;\n }\n _filePaths.push(fileName);\n\n try {\n const exist = await this.props.socket.fileExists(`${this.props.adapterName}.admin`, fileName);\n if (!exist) {\n fileName = 'jsonConfig.json';\n }\n const data: {\n file: string;\n mimeType: string;\n } = await this.props.socket.readFile(`${this.props.adapterName}.admin`, fileName);\n let content = '';\n let file: string | BufferObject = '';\n\n if (data.file !== undefined) {\n file = data.file;\n }\n\n if (typeof file === 'string') {\n content = file;\n // @ts-expect-error revisit\n } else if (file.type === 'Buffer') {\n let binary = '';\n // @ts-expect-error revisit\n const bytes = new Uint8Array(file.data);\n const len = bytes.byteLength;\n for (let i = 0; i < len; i++) {\n binary += String.fromCharCode(bytes[i]);\n }\n content = binary;\n }\n\n // subscribe on changes\n if (!this.fileSubscribed.includes(fileName)) {\n this.fileSubscribed.push(fileName);\n await this.props.socket.subscribeFiles(`${this.props.adapterName}.admin`, fileName, this.onFileChange);\n }\n\n try {\n // detect #include attr\n return (await this.scanForInclude(JSON5.parse(content), _filePaths)) as\n | ConfigItemPanel\n | ConfigItemTabs;\n } catch (e) {\n window.alert('[JsonConfig] Cannot parse json5 config!');\n console.log(e);\n }\n } catch (e1) {\n if (!this.state.schema) {\n window.alert(`[JsonConfig] Cannot read file \"${fileName}: ${e1}`);\n }\n }\n return null;\n }\n\n renderSaveConfigDialog(): JSX.Element | null {\n if (!this.state.saveConfigDialog) {\n return null;\n }\n return (\n \n this.setState({ saveConfigDialog: false }, () => isYes && this.onSave(true))\n }\n />\n );\n }\n\n findAttr(attr: string, schema?: ConfigItemPanel | ConfigItemTabs): ConfigItemAny | null {\n schema = schema || this.state.schema;\n if (schema?.items) {\n if (attr in schema.items) {\n return schema.items[attr];\n }\n for (const _item of Object.values(schema.items)) {\n const item = this.findAttr(attr, _item as ConfigItemPanel | ConfigItemTabs);\n if (item) {\n return item;\n }\n }\n }\n\n return null;\n }\n\n // this function is called recursively and trims all text fields, that must be trimmed\n postProcessing(data: Record, attr: string, schema: ConfigItemAny): void {\n schema = schema || this.state.schema;\n if (!data) {\n // should not happen\n console.error(`Data is empty in postProcessing: ${attr}, ${JSON.stringify(schema)}`);\n return;\n }\n\n const dataAttr = data[attr];\n\n if ((schema as ConfigItemTabs).items) {\n if (schema.type === 'table') {\n const table = dataAttr;\n\n if (!Array.isArray(table)) {\n return;\n }\n\n for (const entry of table) {\n for (const tItem of schema.items) {\n this.postProcessing(entry, tItem.attr, tItem as ConfigItemAny);\n }\n }\n } else {\n for (const [_attr, item] of Object.entries((schema as ConfigItemTabs).items)) {\n if (\n (item as any).type === 'panel' ||\n (item as any).type === 'tabs' ||\n (item as any).type === 'accordion'\n ) {\n return;\n }\n this.postProcessing(data, _attr, item);\n }\n }\n } else if (attr && typeof dataAttr === 'string') {\n // postprocessing\n if (schema.type === 'text') {\n if (schema.trim !== false) {\n data[attr] = dataAttr.trim();\n }\n } else if (schema.type === 'ip') {\n // should not happen\n data[attr] = dataAttr.trim();\n } else if (schema.type === 'number') {\n const dataVal = parseFloat(dataAttr.toString().replace(',', '.'));\n\n if (schema.min !== undefined && dataVal < schema.min) {\n data[attr] = schema.min;\n } else if (schema.max !== undefined && dataVal > schema.max) {\n data[attr] = schema.max;\n } else {\n data[attr] = dataVal;\n }\n } else if (schema.type === 'port') {\n const dataVal = parseInt(dataAttr.toString(), 10);\n if (schema.min !== undefined && dataVal < schema.min) {\n data[attr] = schema.min;\n } else if (schema.max !== undefined && dataVal > schema.max) {\n data[attr] = schema.max;\n }\n if (data[attr] !== 0 && dataVal < 20) {\n data[attr] = 20;\n } else if (dataVal > 0xffff) {\n data[attr] = 0xffff;\n } else {\n data[attr] = dataVal;\n }\n } else if (schema.type === 'checkbox') {\n // should not happen\n data[attr] =\n data[attr] === true ||\n data[attr] === 'true' ||\n data[attr] === 'on' ||\n data[attr] === 1 ||\n data[attr] === '1';\n }\n }\n }\n\n async onSave(doSave: boolean, close?: boolean): Promise {\n if (doSave) {\n const obj = await this.getInstanceObject();\n\n if (!obj) {\n console.error('Something went wrong: may be no connection?');\n window.alert('Something went wrong: may be no connection?');\n return;\n }\n\n if (!this.state.data || !this.state.schema) {\n return;\n }\n\n const doNotSaveAttributes: Record = {};\n\n for (const attr of Object.keys(this.state.data)) {\n const item = this.findAttr(attr);\n if ((!item || !item.doNotSave || item.type === 'state') && !attr.startsWith('_')) {\n ConfigGeneric.setValue(obj.native, attr, this.state.data[attr]);\n } else {\n ConfigGeneric.setValue(obj.native, attr, null);\n doNotSaveAttributes[attr] = this.state.data[attr];\n }\n }\n\n try {\n const encryptedObj = JSON.parse(JSON.stringify(obj));\n // encode all native attributes listed in obj.encryptedNative\n if (Array.isArray(encryptedObj.encryptedNative)) {\n await loadScript('../../lib/js/crypto-js/crypto-js.js', 'crypto-js');\n\n for (const attr of encryptedObj.encryptedNative) {\n if (encryptedObj.native[attr]) {\n encryptedObj.native[attr] = encrypt(this.secret, encryptedObj.native[attr]);\n }\n }\n }\n\n await this.props.socket.setObject(encryptedObj._id, encryptedObj);\n } catch (e) {\n window.alert(`[JsonConfig] Cannot set object: ${e}`);\n }\n\n /** We want to preserve the doNotSaveAttributes too, just not save it */\n const nativeWithNonSaved = { ...obj.native, ...doNotSaveAttributes };\n console.log(nativeWithNonSaved);\n\n this.setState(\n {\n changed: false,\n data: nativeWithNonSaved,\n updateData: this.state.updateData + 1,\n originalData: nativeWithNonSaved,\n },\n () => close && Router.doNavigate(null),\n );\n } else if (this.state.changed) {\n this.setState({ confirmDialog: true });\n } else {\n Router.doNavigate(null);\n }\n }\n\n componentDidUpdate(_prevProps: JsonConfigProps, prevState: JsonConfigState): void {\n if (prevState.changed !== this.state.changed) {\n this.props.configStored(!this.state.changed);\n }\n }\n\n /**\n * Validate the JSON config once on mount\n */\n async componentDidMount(): Promise {\n const link = `${window.location.protocol}//${window.location.host}${window.location.pathname}validate_config/${this.props.adapterName}`;\n console.log(`fetch ${link}`);\n await fetch(link);\n }\n\n render(): JSX.Element {\n if (!this.state.data || !this.state.schema) {\n return ;\n }\n\n return (\n
\n {this.renderDialogConfirm()}\n {this.getExportImportButtons()}\n {this.renderSaveConfigDialog()}\n this.setState({ error })}\n onChange={(data, changed, saveConfigDialog) => {\n if (saveConfigDialog && this.state.error) {\n window.alert(I18n.t('Cannot save configuration because of error in configuration'));\n saveConfigDialog = false;\n }\n if (saveConfigDialog && !this.state.changed && !changed) {\n saveConfigDialog = false;\n }\n if (data) {\n this.setState({ data, changed, saveConfigDialog });\n } else if (saveConfigDialog !== undefined) {\n this.setState({ saveConfigDialog });\n }\n }}\n DeviceManager={this.props.DeviceManager}\n theme={this.state.theme}\n />\n this.onSave(true, close)}\n onClose={() => this.onSave(false)}\n />\n
\n );\n }\n}\n\nexport default JsonConfig;\n","ace.define(\"ace/snippets\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\",\"ace/lib/oop\",\"ace/lib/event_emitter\",\"ace/lib/lang\",\"ace/range\",\"ace/range_list\",\"ace/keyboard/hash_handler\",\"ace/tokenizer\",\"ace/clipboard\",\"ace/editor\"],function(e,t,n){\"use strict\";function p(e){var t=(new Date).toLocaleString(\"en-us\",e);return t.length==1?\"0\"+t:t}var r=e(\"./lib/dom\"),i=e(\"./lib/oop\"),s=e(\"./lib/event_emitter\").EventEmitter,o=e(\"./lib/lang\"),u=e(\"./range\").Range,a=e(\"./range_list\").RangeList,f=e(\"./keyboard/hash_handler\").HashHandler,l=e(\"./tokenizer\").Tokenizer,c=e(\"./clipboard\"),h={CURRENT_WORD:function(e){return e.session.getTextRange(e.session.getWordRange())},SELECTION:function(e,t,n){var r=e.session.getTextRange();return n?r.replace(/\\n\\r?([ \\t]*\\S)/g,\"\\n\"+n+\"$1\"):r},CURRENT_LINE:function(e){return e.session.getLine(e.getCursorPosition().row)},PREV_LINE:function(e){return e.session.getLine(e.getCursorPosition().row-1)},LINE_INDEX:function(e){return e.getCursorPosition().row},LINE_NUMBER:function(e){return e.getCursorPosition().row+1},SOFT_TABS:function(e){return e.session.getUseSoftTabs()?\"YES\":\"NO\"},TAB_SIZE:function(e){return e.session.getTabSize()},CLIPBOARD:function(e){return c.getText&&c.getText()},FILENAME:function(e){return/[^/\\\\]*$/.exec(this.FILEPATH(e))[0]},FILENAME_BASE:function(e){return/[^/\\\\]*$/.exec(this.FILEPATH(e))[0].replace(/\\.[^.]*$/,\"\")},DIRECTORY:function(e){return this.FILEPATH(e).replace(/[^/\\\\]*$/,\"\")},FILEPATH:function(e){return\"/not implemented.txt\"},WORKSPACE_NAME:function(){return\"Unknown\"},FULLNAME:function(){return\"Unknown\"},BLOCK_COMMENT_START:function(e){var t=e.session.$mode||{};return t.blockComment&&t.blockComment.start||\"\"},BLOCK_COMMENT_END:function(e){var t=e.session.$mode||{};return t.blockComment&&t.blockComment.end||\"\"},LINE_COMMENT:function(e){var t=e.session.$mode||{};return t.lineCommentStart||\"\"},CURRENT_YEAR:p.bind(null,{year:\"numeric\"}),CURRENT_YEAR_SHORT:p.bind(null,{year:\"2-digit\"}),CURRENT_MONTH:p.bind(null,{month:\"numeric\"}),CURRENT_MONTH_NAME:p.bind(null,{month:\"long\"}),CURRENT_MONTH_NAME_SHORT:p.bind(null,{month:\"short\"}),CURRENT_DATE:p.bind(null,{day:\"2-digit\"}),CURRENT_DAY_NAME:p.bind(null,{weekday:\"long\"}),CURRENT_DAY_NAME_SHORT:p.bind(null,{weekday:\"short\"}),CURRENT_HOUR:p.bind(null,{hour:\"2-digit\",hour12:!1}),CURRENT_MINUTE:p.bind(null,{minute:\"2-digit\"}),CURRENT_SECOND:p.bind(null,{second:\"2-digit\"})};h.SELECTED_TEXT=h.SELECTION;var d=function(){function e(){this.snippetMap={},this.snippetNameMap={},this.variables=h}return e.prototype.getTokenizer=function(){return e.$tokenizer||this.createTokenizer()},e.prototype.createTokenizer=function(){function t(e){return e=e.substr(1),/^\\d+$/.test(e)?[{tabstopId:parseInt(e,10)}]:[{text:e}]}function n(e){return\"(?:[^\\\\\\\\\"+e+\"]|\\\\\\\\.)\"}var r={regex:\"/(\"+n(\"/\")+\"+)/\",onMatch:function(e,t,n){var r=n[0];return r.fmtString=!0,r.guard=e.slice(1,-1),r.flag=\"\",\"\"},next:\"formatString\"};return e.$tokenizer=new l({start:[{regex:/\\\\./,onMatch:function(e,t,n){var r=e[1];return r==\"}\"&&n.length?e=r:\"`$\\\\\".indexOf(r)!=-1&&(e=r),[e]}},{regex:/}/,onMatch:function(e,t,n){return[n.length?n.shift():e]}},{regex:/\\$(?:\\d+|\\w+)/,onMatch:t},{regex:/\\$\\{[\\dA-Z_a-z]+/,onMatch:function(e,n,r){var i=t(e.substr(1));return r.unshift(i[0]),i},next:\"snippetVar\"},{regex:/\\n/,token:\"newline\",merge:!1}],snippetVar:[{regex:\"\\\\|\"+n(\"\\\\|\")+\"*\\\\|\",onMatch:function(e,t,n){var r=e.slice(1,-1).replace(/\\\\[,|\\\\]|,/g,function(e){return e.length==2?e[1]:\"\\0\"}).split(\"\\0\").map(function(e){return{value:e}});return n[0].choices=r,[r[0]]},next:\"start\"},r,{regex:\"([^:}\\\\\\\\]|\\\\\\\\.)*:?\",token:\"\",next:\"start\"}],formatString:[{regex:/:/,onMatch:function(e,t,n){return n.length&&n[0].expectElse?(n[0].expectElse=!1,n[0].ifEnd={elseEnd:n[0]},[n[0].ifEnd]):\":\"}},{regex:/\\\\./,onMatch:function(e,t,n){var r=e[1];return r==\"}\"&&n.length?e=r:\"`$\\\\\".indexOf(r)!=-1?e=r:r==\"n\"?e=\"\\n\":r==\"t\"?e=\"\t\":\"ulULE\".indexOf(r)!=-1&&(e={changeCase:r,local:r>\"a\"}),[e]}},{regex:\"/\\\\w*}\",onMatch:function(e,t,n){var r=n.shift();return r&&(r.flag=e.slice(1,-1)),this.next=r&&r.tabstopId?\"start\":\"\",[r||e]},next:\"start\"},{regex:/\\$(?:\\d+|\\w+)/,onMatch:function(e,t,n){return[{text:e.slice(1)}]}},{regex:/\\${\\w+/,onMatch:function(e,t,n){var r={text:e.slice(2)};return n.unshift(r),[r]},next:\"formatStringVar\"},{regex:/\\n/,token:\"newline\",merge:!1},{regex:/}/,onMatch:function(e,t,n){var r=n.shift();return this.next=r&&r.tabstopId?\"start\":\"\",[r||e]},next:\"start\"}],formatStringVar:[{regex:/:\\/\\w+}/,onMatch:function(e,t,n){var r=n[0];return r.formatFunction=e.slice(2,-1),[n.shift()]},next:\"formatString\"},r,{regex:/:[\\?\\-+]?/,onMatch:function(e,t,n){e[1]==\"+\"&&(n[0].ifEnd=n[0]),e[1]==\"?\"&&(n[0].expectElse=!0)},next:\"formatString\"},{regex:\"([^:}\\\\\\\\]|\\\\\\\\.)*:?\",token:\"\",next:\"formatString\"}]}),e.$tokenizer},e.prototype.tokenizeTmSnippet=function(e,t){return this.getTokenizer().getLineTokens(e,t).tokens.map(function(e){return e.value||e})},e.prototype.getVariableValue=function(e,t,n){if(/^\\d+$/.test(t))return(this.variables.__||{})[t]||\"\";if(/^[A-Z]\\d+$/.test(t))return(this.variables[t[0]+\"__\"]||{})[t.substr(1)]||\"\";t=t.replace(/^TM_/,\"\");if(!this.variables.hasOwnProperty(t))return\"\";var r=this.variables[t];return typeof r==\"function\"&&(r=this.variables[t](e,t,n)),r==null?\"\":r},e.prototype.tmStrFormat=function(e,t,n){if(!t.fmt)return e;var r=t.flag||\"\",i=t.guard;i=new RegExp(i,r.replace(/[^gim]/g,\"\"));var s=typeof t.fmt==\"string\"?this.tokenizeTmSnippet(t.fmt,\"formatString\"):t.fmt,o=this,u=e.replace(i,function(){var e=o.variables.__;o.variables.__=[].slice.call(arguments);var t=o.resolveVariables(s,n),r=\"E\";for(var i=0;i=0&&s.splice(o,1)}}var n=this.snippetMap,r=this.snippetNameMap;e.content?i(e):Array.isArray(e)&&e.forEach(i)},e.prototype.parseSnippetFile=function(e){e=e.replace(/\\r/g,\"\");var t=[],n={},r=/^#.*|^({[\\s\\S]*})\\s*$|^(\\S+) (.*)$|^((?:\\n*\\t.*)+)/gm,i;while(i=r.exec(e)){if(i[1])try{n=JSON.parse(i[1]),t.push(n)}catch(s){}if(i[4])n.content=i[4].replace(/^\\t/gm,\"\"),t.push(n),n={};else{var o=i[2],u=i[3];if(o==\"regex\"){var a=/\\/((?:[^\\/\\\\]|\\\\.)*)|$/g;n.guard=a.exec(u)[1],n.trigger=a.exec(u)[1],n.endTrigger=a.exec(u)[1],n.endGuard=a.exec(u)[1]}else o==\"snippet\"?(n.tabTrigger=u.match(/^\\S*/)[0],n.name||(n.name=u)):o&&(n[o]=u)}}return t},e.prototype.getSnippetByName=function(e,t){var n=this.snippetNameMap,r;return this.getActiveScopes(t).some(function(t){var i=n[t];return i&&(r=i[e]),!!r},this),r},e}();i.implement(d.prototype,s);var v=function(e,t,n){function l(e){var t=[];for(var n=0;n1?(y=t[t.length-1].length,g+=t.length-1):y+=e.length,b+=e}else e&&(e.start?e.end={row:g,column:y}:e.start={row:g,column:y})}),{text:b,tabstops:a,tokens:u}},m=function(){function e(e){this.index=0,this.ranges=[],this.tabstops=[];if(e.tabstopManager)return e.tabstopManager;e.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=o.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(e)}return e.prototype.attach=function(e){this.$openTabstops=null,this.selectedTabstop=null,this.editor=e,this.session=e.session,this.editor.on(\"change\",this.$onChange),this.editor.on(\"changeSelection\",this.$onChangeSelection),this.editor.on(\"changeSession\",this.$onChangeSession),this.editor.commands.on(\"afterExec\",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},e.prototype.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges.length=0,this.tabstops.length=0,this.selectedTabstop=null,this.editor.off(\"change\",this.$onChange),this.editor.off(\"changeSelection\",this.$onChangeSelection),this.editor.off(\"changeSession\",this.$onChangeSession),this.editor.commands.off(\"afterExec\",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.session=null,this.editor=null},e.prototype.onChange=function(e){var t=e.action[0]==\"r\",n=this.selectedTabstop||{},r=n.parents||{},i=this.tabstops.slice();for(var s=0;s2&&(this.tabstops.length&&o.push(o.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,o))},e.prototype.addTabstopMarkers=function(e){var t=this.session;e.forEach(function(e){e.markerId||(e.markerId=t.addMarker(e,\"ace_snippet-marker\",\"text\"))})},e.prototype.removeTabstopMarkers=function(e){var t=this.session;e.forEach(function(e){t.removeMarker(e.markerId),e.markerId=null})},e.prototype.updateTabstopMarkers=function(){if(!this.selectedTabstop)return;var e=this.selectedTabstop.snippetId;this.selectedTabstop.index===0&&e--,this.tabstops.forEach(function(t){t.snippetId===e?this.addTabstopMarkers(t):this.removeTabstopMarkers(t)},this)},e.prototype.removeRange=function(e){var t=e.tabstop.indexOf(e);t!=-1&&e.tabstop.splice(t,1),t=this.ranges.indexOf(e),t!=-1&&this.ranges.splice(t,1),t=e.tabstop.rangeList.ranges.indexOf(e),t!=-1&&e.tabstop.splice(t,1),this.session.removeMarker(e.markerId),e.tabstop.length||(t=this.tabstops.indexOf(e.tabstop),t!=-1&&this.tabstops.splice(t,1),this.tabstops.length||this.detach())},e}();m.prototype.keyboardHandler=new f,m.prototype.keyboardHandler.bindKeys({Tab:function(e){if(t.snippetManager&&t.snippetManager.expandWithTab(e))return;e.tabstopManager.tabNext(1),e.renderer.scrollCursorIntoView()},\"Shift-Tab\":function(e){e.tabstopManager.tabNext(-1),e.renderer.scrollCursorIntoView()},Esc:function(e){e.tabstopManager.detach()}});var g=function(e,t){e.row==0&&(e.column+=t.column),e.row+=t.row},y=function(e,t){e.row==t.row&&(e.column-=t.column),e.row-=t.row};r.importCssString(\"\\n.ace_snippet-marker {\\n -moz-box-sizing: border-box;\\n box-sizing: border-box;\\n background: rgba(194, 193, 208, 0.09);\\n border: 1px dotted rgba(211, 208, 235, 0.62);\\n position: absolute;\\n}\",\"snippets.css\",!1),t.snippetManager=new d;var b=e(\"./editor\").Editor;(function(){this.insertSnippet=function(e,n){return t.snippetManager.insertSnippet(this,e,n)},this.expandSnippet=function(e){return t.snippetManager.expandWithTab(this,e)}}).call(b.prototype)}),ace.define(\"ace/autocomplete/popup\",[\"require\",\"exports\",\"module\",\"ace/virtual_renderer\",\"ace/editor\",\"ace/range\",\"ace/lib/event\",\"ace/lib/lang\",\"ace/lib/dom\",\"ace/config\",\"ace/lib/useragent\"],function(e,t,n){\"use strict\";var r=e(\"../virtual_renderer\").VirtualRenderer,i=e(\"../editor\").Editor,s=e(\"../range\").Range,o=e(\"../lib/event\"),u=e(\"../lib/lang\"),a=e(\"../lib/dom\"),f=e(\"../config\").nls,l=e(\"./../lib/useragent\"),c=function(e){return\"suggest-aria-id:\".concat(e)},h=l.isSafari?\"menu\":\"listbox\",p=l.isSafari?\"menuitem\":\"option\",d=l.isSafari?\"aria-current\":\"aria-selected\",v=function(e){var t=new r(e);t.$maxLines=4;var n=new i(t);return n.setHighlightActiveLine(!1),n.setShowPrintMargin(!1),n.renderer.setShowGutter(!1),n.renderer.setHighlightGutterLine(!1),n.$mouseHandler.$focusTimeout=0,n.$highlightTagPending=!0,n},m=function(){function e(e){var t=a.createElement(\"div\"),n=v(t);e&&e.appendChild(t),t.style.display=\"none\",n.renderer.content.style.cursor=\"default\",n.renderer.setStyle(\"ace_autocomplete\"),n.renderer.$textLayer.element.setAttribute(\"role\",h),n.renderer.$textLayer.element.setAttribute(\"aria-roledescription\",f(\"autocomplete.popup.aria-roledescription\",\"Autocomplete suggestions\")),n.renderer.$textLayer.element.setAttribute(\"aria-label\",f(\"autocomplete.popup.aria-label\",\"Autocomplete suggestions\")),n.renderer.textarea.setAttribute(\"aria-hidden\",\"true\"),n.setOption(\"displayIndentGuides\",!1),n.setOption(\"dragDelay\",150);var r=function(){};n.focus=r,n.$isFocused=!0,n.renderer.$cursorLayer.restartTimer=r,n.renderer.$cursorLayer.element.style.opacity=\"0\",n.renderer.$maxLines=8,n.renderer.$keepTextAreaAtCursor=!1,n.setHighlightActiveLine(!1),n.session.highlight(\"\"),n.session.$searchHighlight.clazz=\"ace_highlight-marker\",n.on(\"mousedown\",function(e){var t=e.getDocumentPosition();n.selection.moveToPosition(t),m.start.row=m.end.row=t.row,e.stop()});var i,l=new s(-1,0,-1,Infinity),m=new s(-1,0,-1,Infinity);m.id=n.session.addMarker(m,\"ace_active-line\",\"fullLine\"),n.setSelectOnHover=function(e){e?l.id&&(n.session.removeMarker(l.id),l.id=null):l.id=n.session.addMarker(l,\"ace_line-hover\",\"fullLine\")},n.setSelectOnHover(!1),n.on(\"mousemove\",function(e){if(!i){i=e;return}if(i.x==e.x&&i.y==e.y)return;i=e,i.scrollTop=n.renderer.scrollTop,n.isMouseOver=!0;var t=i.getDocumentPosition().row;l.start.row!=t&&(l.id||n.setRow(t),y(t))}),n.renderer.on(\"beforeRender\",function(){if(i&&l.start.row!=-1){i.$pos=null;var e=i.getDocumentPosition().row;l.id||n.setRow(e),y(e,!0)}}),n.renderer.on(\"afterRender\",function(){var e=n.getRow(),t=n.renderer.$textLayer,r=t.element.childNodes[e-t.config.firstRow],i=document.activeElement;r!==n.selectedNode&&n.selectedNode&&(a.removeCssClass(n.selectedNode,\"ace_selected\"),i.removeAttribute(\"aria-activedescendant\"),n.selectedNode.removeAttribute(d),n.selectedNode.removeAttribute(\"id\")),n.selectedNode=r;if(r){a.addCssClass(r,\"ace_selected\");var s=c(e);r.id=s,t.element.setAttribute(\"aria-activedescendant\",s),i.setAttribute(\"aria-activedescendant\",s),r.setAttribute(\"role\",p),r.setAttribute(\"aria-roledescription\",f(\"autocomplete.popup.item.aria-roledescription\",\"item\")),r.setAttribute(\"aria-label\",n.getData(e).caption||n.getData(e).value),r.setAttribute(\"aria-setsize\",n.data.length),r.setAttribute(\"aria-posinset\",e+1),r.setAttribute(\"aria-describedby\",\"doc-tooltip\"),r.setAttribute(d,\"true\")}});var g=function(){y(-1)},y=function(e,t){e!==l.start.row&&(l.start.row=l.end.row=e,t||n.session._emit(\"changeBackMarker\"),n._emit(\"changeHoverMarker\"))};n.getHoveredRow=function(){return l.start.row},o.addListener(n.container,\"mouseout\",function(){n.isMouseOver=!1,g()}),n.on(\"hide\",g),n.on(\"changeSelection\",g),n.session.doc.getLength=function(){return n.data.length},n.session.doc.getLine=function(e){var t=n.data[e];return typeof t==\"string\"?t:t&&t.value||\"\"};var b=n.session.bgTokenizer;return b.$tokenizeRow=function(e){function s(e,n){e&&r.push({type:(t.className||\"\")+(n||\"\"),value:e})}var t=n.data[e],r=[];if(!t)return r;typeof t==\"string\"&&(t={value:t});var i=t.caption||t.value||t.name,o=i.toLowerCase(),u=(n.filterText||\"\").toLowerCase(),a=0,f=0;for(var l=0;l<=u.length;l++)if(l!=f&&(t.matchMask&1<=l?r=\"bottom\":r=\"top\"),r===\"top\"?(c.bottom=e.top-this.$borderSize,c.top=c.bottom-l):r===\"bottom\"&&(c.top=e.top+t+this.$borderSize,c.bottom=c.top+l);var d=c.top>=0&&c.bottom<=u;if(!s&&!d)return!1;d?f.$maxPixelHeight=null:r===\"top\"?f.$maxPixelHeight=p:f.$maxPixelHeight=h,r===\"top\"?(o.style.top=\"\",o.style.bottom=u-c.bottom+\"px\",n.isTopdown=!1):(o.style.top=c.top+\"px\",o.style.bottom=\"\",n.isTopdown=!0),o.style.display=\"\";var v=e.left;return v+o.offsetWidth>a&&(v=a-o.offsetWidth),o.style.left=v+\"px\",o.style.right=\"\",n.isOpen||(n.isOpen=!0,this._signal(\"show\"),i=null),n.anchorPos=e,n.anchor=r,!0},n.show=function(e,t,n){this.tryShow(e,t,n?\"bottom\":undefined,!0)},n.goTo=function(e){var t=this.getRow(),n=this.session.getLength()-1;switch(e){case\"up\":t=t<=0?n:t-1;break;case\"down\":t=t>=n?-1:t+1;break;case\"start\":t=0;break;case\"end\":t=n}this.setRow(t)},n.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},n.$imageSize=0,n.$borderSize=1,n}return e}();a.importCssString('\\n.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {\\n background-color: #CAD6FA;\\n z-index: 1;\\n}\\n.ace_dark.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {\\n background-color: #3a674e;\\n}\\n.ace_editor.ace_autocomplete .ace_line-hover {\\n border: 1px solid #abbffe;\\n margin-top: -1px;\\n background: rgba(233,233,253,0.4);\\n position: absolute;\\n z-index: 2;\\n}\\n.ace_dark.ace_editor.ace_autocomplete .ace_line-hover {\\n border: 1px solid rgba(109, 150, 13, 0.8);\\n background: rgba(58, 103, 78, 0.62);\\n}\\n.ace_completion-meta {\\n opacity: 0.5;\\n margin-left: 0.9em;\\n}\\n.ace_completion-message {\\n margin-left: 0.9em;\\n color: blue;\\n}\\n.ace_editor.ace_autocomplete .ace_completion-highlight{\\n color: #2d69c7;\\n}\\n.ace_dark.ace_editor.ace_autocomplete .ace_completion-highlight{\\n color: #93ca12;\\n}\\n.ace_editor.ace_autocomplete {\\n width: 300px;\\n z-index: 200000;\\n border: 1px lightgray solid;\\n position: fixed;\\n box-shadow: 2px 3px 5px rgba(0,0,0,.2);\\n line-height: 1.4;\\n background: #fefefe;\\n color: #111;\\n}\\n.ace_dark.ace_editor.ace_autocomplete {\\n border: 1px #484747 solid;\\n box-shadow: 2px 3px 5px rgba(0, 0, 0, 0.51);\\n line-height: 1.4;\\n background: #25282c;\\n color: #c1c1c1;\\n}\\n.ace_autocomplete .ace_text-layer {\\n width: calc(100% - 8px);\\n}\\n.ace_autocomplete .ace_line {\\n display: flex;\\n align-items: center;\\n}\\n.ace_autocomplete .ace_line > * {\\n min-width: 0;\\n flex: 0 0 auto;\\n}\\n.ace_autocomplete .ace_line .ace_ {\\n flex: 0 1 auto;\\n overflow: hidden;\\n text-overflow: ellipsis;\\n}\\n.ace_autocomplete .ace_completion-spacer {\\n flex: 1;\\n}\\n.ace_autocomplete.ace_loading:after {\\n content: \"\";\\n position: absolute;\\n top: 0px;\\n height: 2px;\\n width: 8%;\\n background: blue;\\n z-index: 100;\\n animation: ace_progress 3s infinite linear;\\n animation-delay: 300ms;\\n transform: translateX(-100%) scaleX(1);\\n}\\n@keyframes ace_progress {\\n 0% { transform: translateX(-100%) scaleX(1) }\\n 50% { transform: translateX(625%) scaleX(2) } \\n 100% { transform: translateX(1500%) scaleX(3) } \\n}\\n@media (prefers-reduced-motion) {\\n .ace_autocomplete.ace_loading:after {\\n transform: translateX(625%) scaleX(2);\\n animation: none;\\n }\\n}\\n',\"autocompletion.css\",!1),t.AcePopup=m,t.$singleLineEditor=v,t.getAriaId=c}),ace.define(\"ace/autocomplete/inline_screenreader\",[\"require\",\"exports\",\"module\"],function(e,t,n){\"use strict\";var r=function(){function e(e){this.editor=e,this.screenReaderDiv=document.createElement(\"div\"),this.screenReaderDiv.classList.add(\"ace_screenreader-only\"),this.editor.container.appendChild(this.screenReaderDiv)}return e.prototype.setScreenReaderContent=function(e){!this.popup&&this.editor.completer&&this.editor.completer.popup&&(this.popup=this.editor.completer.popup,this.popup.renderer.on(\"afterRender\",function(){var e=this.popup.getRow(),t=this.popup.renderer.$textLayer,n=t.element.childNodes[e-t.config.firstRow];if(n){var r=\"doc-tooltip \";for(var i=0;i=0;s--){if(!n.test(e[s]))break;i.push(e[s])}return i.reverse().join(\"\")},t.retrieveFollowingIdentifier=function(e,t,n){n=n||r;var i=[];for(var s=t;s0)for(var t=this.popup.getFirstVisibleRow();t<=this.popup.getLastVisibleRow();t++){var n=this.popup.getData(t);n&&(!e||n.hideInlinePreview)&&this.$seen(n)}},e.prototype.$onPopupShow=function(e){this.$onPopupChange(e),this.stickySelection=!1,this.stickySelectionDelay>=0&&this.stickySelectionTimer.schedule(this.stickySelectionDelay)},e.prototype.observeLayoutChanges=function(){if(this.$elements||!this.editor)return;window.addEventListener(\"resize\",this.onLayoutChange,{passive:!0}),window.addEventListener(\"wheel\",this.mousewheelListener);var e=this.editor.container.parentNode,t=[];while(e)t.push(e),e.addEventListener(\"scroll\",this.onLayoutChange,{passive:!0}),e=e.parentNode;this.$elements=t},e.prototype.unObserveLayoutChanges=function(){var e=this;window.removeEventListener(\"resize\",this.onLayoutChange,{passive:!0}),window.removeEventListener(\"wheel\",this.mousewheelListener),this.$elements&&this.$elements.forEach(function(t){t.removeEventListener(\"scroll\",e.onLayoutChange,{passive:!0})}),this.$elements=null},e.prototype.onLayoutChange=function(){if(!this.popup.isOpen)return this.unObserveLayoutChanges();this.$updatePopupPosition(),this.updateDocTooltip()},e.prototype.$updatePopupPosition=function(){var e=this.editor,t=e.renderer,n=t.layerConfig.lineHeight,r=t.$cursorLayer.getPixelPosition(this.base,!0);r.left-=this.popup.getTextLeftOffset();var i=e.container.getBoundingClientRect();r.top+=i.top-t.layerConfig.offset,r.left+=i.left-e.renderer.scrollLeft,r.left+=t.gutterWidth;var s={top:r.top,left:r.left};t.$ghostText&&t.$ghostTextWidget&&this.base.row===t.$ghostText.position.row&&(s.top+=t.$ghostTextWidget.el.offsetHeight);var o=e.container.getBoundingClientRect().bottom-n,u=othis.filterText&&e.lastIndexOf(this.filterText,0)===0)var t=this.filtered;else var t=this.all;this.filterText=e,t=this.filterCompletions(t,this.filterText),t=t.sort(function(e,t){return t.exactMatch-e.exactMatch||t.$score-e.$score||(e.caption||e.value).localeCompare(t.caption||t.value)});var n=null;t=t.filter(function(e){var t=e.snippet||e.caption||e.value;return t===n?!1:(n=t,!0)}),this.filtered=t},e.prototype.filterCompletions=function(e,t){var n=[],r=t.toUpperCase(),i=t.toLowerCase();e:for(var s=0,o;o=e[s];s++){var u=!this.ignoreCaption&&o.caption||o.value||o.snippet;if(!u)continue;var a=-1,f=0,l=0,c,h;if(this.exactMatch){if(t!==u.substr(0,t.length))continue e}else{var p=u.toLowerCase().indexOf(i);if(p>-1)l=p;else for(var d=0;d=0?m<0||v0&&(a===-1&&(l+=10),l+=h,f|=1<\",o.escapeHTML(e.caption),\"\",\"
\",o.escapeHTML(l(e.snippet))].join(\"\"))},id:\"snippetCompleter\"},h=[c,a,f];t.setCompleters=function(e){h.length=0,e&&h.push.apply(h,e)},t.addCompleter=function(e){h.push(e)},t.textCompleter=a,t.keyWordCompleter=f,t.snippetCompleter=c;var p={name:\"expandSnippet\",exec:function(e){return r.expandWithTab(e)},bindKey:\"Tab\"},d=function(e,t){v(t.session.$mode)},v=function(e){typeof e==\"string\"&&(e=s.$modes[e]);if(!e)return;r.files||(r.files={}),m(e.$id,e.snippetFileId),e.modes&&e.modes.forEach(v)},m=function(e,t){if(!t||!e||r.files[e])return;r.files[e]={},s.loadModule(t,function(t){if(!t)return;r.files[e]=t,!t.snippets&&t.snippetText&&(t.snippets=r.parseSnippetFile(t.snippetText)),r.register(t.snippets||[],t.scope),t.includeScopes&&(r.snippetMap[t.scope].includeScopes=t.includeScopes,t.includeScopes.forEach(function(e){v(\"ace/mode/\"+e)}))})},g=function(e){var t=e.editor,n=t.completer&&t.completer.activated;if(e.command.name===\"backspace\")n&&!u.getCompletionPrefix(t)&&t.completer.detach();else if(e.command.name===\"insertstring\"&&!n){y=e;var r=e.editor.$liveAutocompletionDelay;r?b.delay(r):w(e)}},y,b=o.delayedCall(function(){w(y)},0),w=function(e){var t=e.editor,n=u.getCompletionPrefix(t),r=e.args,s=u.triggerAutocomplete(t,r);if(n&&n.length>=t.$liveAutocompletionThreshold||s){var o=i.for(t);o.autoShown=!0,o.showPopup(t)}},E=e(\"../editor\").Editor;e(\"../config\").defineOptions(E.prototype,\"editor\",{enableBasicAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:h),this.commands.addCommand(i.startCommand)):this.commands.removeCommand(i.startCommand)},value:!1},enableLiveAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:h),this.commands.on(\"afterExec\",g)):this.commands.off(\"afterExec\",g)},value:!1},liveAutocompletionDelay:{initialValue:0},liveAutocompletionThreshold:{initialValue:0},enableSnippets:{set:function(e){e?(this.commands.addCommand(p),this.on(\"changeMode\",d),d(null,this)):(this.commands.removeCommand(p),this.off(\"changeMode\",d))},value:!1}})}); (function() {\n ace.require([\"ace/ext/language_tools\"], function(m) {\n if (typeof module == \"object\" && typeof exports == \"object\" && module) {\n module.exports = m;\n }\n });\n })();\n ","ace.define(\"ace/mode/json_highlight_rules\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/mode/text_highlight_rules\"],function(e,t,n){\"use strict\";var r=e(\"../lib/oop\"),i=e(\"./text_highlight_rules\").TextHighlightRules,s=function(){this.$rules={start:[{token:\"variable\",regex:'[\"](?:(?:\\\\\\\\.)|(?:[^\"\\\\\\\\]))*?[\"]\\\\s*(?=:)'},{token:\"string\",regex:'\"',next:\"string\"},{token:\"constant.numeric\",regex:\"0[xX][0-9a-fA-F]+\\\\b\"},{token:\"constant.numeric\",regex:\"[+-]?\\\\d+(?:(?:\\\\.\\\\d*)?(?:[eE][+-]?\\\\d+)?)?\\\\b\"},{token:\"constant.language.boolean\",regex:\"(?:true|false)\\\\b\"},{token:\"text\",regex:\"['](?:(?:\\\\\\\\.)|(?:[^'\\\\\\\\]))*?[']\"},{token:\"comment\",regex:\"\\\\/\\\\/.*$\"},{token:\"comment.start\",regex:\"\\\\/\\\\*\",next:\"comment\"},{token:\"paren.lparen\",regex:\"[[({]\"},{token:\"paren.rparen\",regex:\"[\\\\])}]\"},{token:\"punctuation.operator\",regex:/[,]/},{token:\"text\",regex:\"\\\\s+\"}],string:[{token:\"constant.language.escape\",regex:/\\\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|[\"\\\\\\/bfnrt])/},{token:\"string\",regex:'\"|$',next:\"start\"},{defaultToken:\"string\"}],comment:[{token:\"comment.end\",regex:\"\\\\*\\\\/\",next:\"start\"},{defaultToken:\"comment\"}]}};r.inherits(s,i),t.JsonHighlightRules=s}),ace.define(\"ace/mode/matching_brace_outdent\",[\"require\",\"exports\",\"module\",\"ace/range\"],function(e,t,n){\"use strict\";var r=e(\"../range\").Range,i=function(){};(function(){this.checkOutdent=function(e,t){return/^\\s+$/.test(e)?/^\\s*\\}/.test(t):!1},this.autoOutdent=function(e,t){var n=e.getLine(t),i=n.match(/^(\\s*\\})/);if(!i)return 0;var s=i[1].length,o=e.findMatchingBracket({row:t,column:s});if(!o||o.row==t)return 0;var u=this.$getIndent(e.getLine(o.row));e.replace(new r(t,0,t,s-1),u)},this.$getIndent=function(e){return e.match(/^\\s*/)[0]}}).call(i.prototype),t.MatchingBraceOutdent=i}),ace.define(\"ace/mode/folding/cstyle\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/range\",\"ace/mode/folding/fold_mode\"],function(e,t,n){\"use strict\";var r=e(\"../../lib/oop\"),i=e(\"../../range\").Range,s=e(\"./fold_mode\").FoldMode,o=t.FoldMode=function(e){e&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\\|[^|]*?$/,\"|\"+e.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\\|[^|]*?$/,\"|\"+e.end)))};r.inherits(o,s),function(){this.foldingStartMarker=/([\\{\\[\\(])[^\\}\\]\\)]*$|^\\s*(\\/\\*)/,this.foldingStopMarker=/^[^\\[\\{\\(]*([\\}\\]\\)])|^[\\s\\*]*(\\*\\/)/,this.singleLineBlockCommentRe=/^\\s*(\\/\\*).*\\*\\/\\s*$/,this.tripleStarBlockCommentRe=/^\\s*(\\/\\*\\*\\*).*\\*\\/\\s*$/,this.startRegionRe=/^\\s*(\\/\\*|\\/\\/)#?region\\b/,this._getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(e,t,n){var r=e.getLine(n);if(this.singleLineBlockCommentRe.test(r)&&!this.startRegionRe.test(r)&&!this.tripleStarBlockCommentRe.test(r))return\"\";var i=this._getFoldWidgetBase(e,t,n);return!i&&this.startRegionRe.test(r)?\"start\":i},this.getFoldWidgetRange=function(e,t,n,r){var i=e.getLine(n);if(this.startRegionRe.test(i))return this.getCommentRegionBlock(e,i,n);var s=i.match(this.foldingStartMarker);if(s){var o=s.index;if(s[1])return this.openingBracketBlock(e,s[1],n,o);var u=e.getCommentFoldRange(n,o+s[0].length,1);return u&&!u.isMultiLine()&&(r?u=this.getSectionRange(e,n):t!=\"all\"&&(u=null)),u}if(t===\"markbegin\")return;var s=i.match(this.foldingStopMarker);if(s){var o=s.index+s[0].length;return s[1]?this.closingBracketBlock(e,s[1],n,o):e.getCommentFoldRange(n,o,-1)}},this.getSectionRange=function(e,t){var n=e.getLine(t),r=n.search(/\\S/),s=t,o=n.length;t+=1;var u=t,a=e.getLength();while(++tf)break;var l=this.getFoldWidgetRange(e,\"all\",t);if(l){if(l.start.row<=s)break;if(l.isMultiLine())t=l.end.row;else if(r==f)break}u=t}return new i(s,o,u,e.getLine(u).length)},this.getCommentRegionBlock=function(e,t,n){var r=t.search(/\\s*$/),s=e.getLength(),o=n,u=/^\\s*(?:\\/\\*|\\/\\/|--)#?(end)?region\\b/,a=1;while(++no)return new i(o,r,l,t.length)}}.call(o.prototype)}),ace.define(\"ace/mode/json\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/mode/text\",\"ace/mode/json_highlight_rules\",\"ace/mode/matching_brace_outdent\",\"ace/mode/folding/cstyle\",\"ace/worker/worker_client\"],function(e,t,n){\"use strict\";var r=e(\"../lib/oop\"),i=e(\"./text\").Mode,s=e(\"./json_highlight_rules\").JsonHighlightRules,o=e(\"./matching_brace_outdent\").MatchingBraceOutdent,u=e(\"./folding/cstyle\").FoldMode,a=e(\"../worker/worker_client\").WorkerClient,f=function(){this.HighlightRules=s,this.$outdent=new o,this.$behaviour=this.$defaultBehaviour,this.foldingRules=new u};r.inherits(f,i),function(){this.lineCommentStart=\"//\",this.blockComment={start:\"/*\",end:\"*/\"},this.getNextLineIndent=function(e,t,n){var r=this.$getIndent(t);if(e==\"start\"){var i=t.match(/^.*[\\{\\(\\[]\\s*$/);i&&(r+=n)}return r},this.checkOutdent=function(e,t,n){return this.$outdent.checkOutdent(t,n)},this.autoOutdent=function(e,t,n){this.$outdent.autoOutdent(t,n)},this.createWorker=function(e){var t=new a([\"ace\"],\"ace/mode/json_worker\",\"JsonWorker\");return t.attachToDocument(e.getDocument()),t.on(\"annotate\",function(t){e.setAnnotations(t.data)}),t.on(\"terminate\",function(){e.clearAnnotations()}),t},this.$id=\"ace/mode/json\"}.call(f.prototype),t.Mode=f}); (function() {\n ace.require([\"ace/mode/json\"], function(m) {\n if (typeof module == \"object\" && typeof exports == \"object\" && module) {\n module.exports = m;\n }\n });\n })();\n ","ace.define(\"ace/theme/chrome-css\",[\"require\",\"exports\",\"module\"],function(e,t,n){n.exports='.ace-chrome .ace_gutter {\\n background: #ebebeb;\\n color: #333;\\n overflow : hidden;\\n}\\n\\n.ace-chrome .ace_print-margin {\\n width: 1px;\\n background: #e8e8e8;\\n}\\n\\n.ace-chrome {\\n background-color: #FFFFFF;\\n color: black;\\n}\\n\\n.ace-chrome .ace_cursor {\\n color: black;\\n}\\n\\n.ace-chrome .ace_invisible {\\n color: rgb(191, 191, 191);\\n}\\n\\n.ace-chrome .ace_constant.ace_buildin {\\n color: rgb(88, 72, 246);\\n}\\n\\n.ace-chrome .ace_constant.ace_language {\\n color: rgb(88, 92, 246);\\n}\\n\\n.ace-chrome .ace_constant.ace_library {\\n color: rgb(6, 150, 14);\\n}\\n\\n.ace-chrome .ace_invalid {\\n background-color: rgb(153, 0, 0);\\n color: white;\\n}\\n\\n.ace-chrome .ace_fold {\\n}\\n\\n.ace-chrome .ace_support.ace_function {\\n color: rgb(60, 76, 114);\\n}\\n\\n.ace-chrome .ace_support.ace_constant {\\n color: rgb(6, 150, 14);\\n}\\n\\n.ace-chrome .ace_support.ace_type,\\n.ace-chrome .ace_support.ace_class\\n.ace-chrome .ace_support.ace_other {\\n color: rgb(109, 121, 222);\\n}\\n\\n.ace-chrome .ace_variable.ace_parameter {\\n font-style:italic;\\n color:#FD971F;\\n}\\n.ace-chrome .ace_keyword.ace_operator {\\n color: rgb(104, 118, 135);\\n}\\n\\n.ace-chrome .ace_comment {\\n color: #236e24;\\n}\\n\\n.ace-chrome .ace_comment.ace_doc {\\n color: #236e24;\\n}\\n\\n.ace-chrome .ace_comment.ace_doc.ace_tag {\\n color: #236e24;\\n}\\n\\n.ace-chrome .ace_constant.ace_numeric {\\n color: rgb(0, 0, 205);\\n}\\n\\n.ace-chrome .ace_variable {\\n color: rgb(49, 132, 149);\\n}\\n\\n.ace-chrome .ace_xml-pe {\\n color: rgb(104, 104, 91);\\n}\\n\\n.ace-chrome .ace_entity.ace_name.ace_function {\\n color: #0000A2;\\n}\\n\\n\\n.ace-chrome .ace_heading {\\n color: rgb(12, 7, 255);\\n}\\n\\n.ace-chrome .ace_list {\\n color:rgb(185, 6, 144);\\n}\\n\\n.ace-chrome .ace_marker-layer .ace_selection {\\n background: rgb(181, 213, 255);\\n}\\n\\n.ace-chrome .ace_marker-layer .ace_step {\\n background: rgb(252, 255, 0);\\n}\\n\\n.ace-chrome .ace_marker-layer .ace_stack {\\n background: rgb(164, 229, 101);\\n}\\n\\n.ace-chrome .ace_marker-layer .ace_bracket {\\n margin: -1px 0 0 -1px;\\n border: 1px solid rgb(192, 192, 192);\\n}\\n\\n.ace-chrome .ace_marker-layer .ace_active-line {\\n background: rgba(0, 0, 0, 0.07);\\n}\\n\\n.ace-chrome .ace_gutter-active-line {\\n background-color : #dcdcdc;\\n}\\n\\n.ace-chrome .ace_marker-layer .ace_selected-word {\\n background: rgb(250, 250, 255);\\n border: 1px solid rgb(200, 200, 250);\\n}\\n\\n.ace-chrome .ace_storage,\\n.ace-chrome .ace_keyword,\\n.ace-chrome .ace_meta.ace_tag {\\n color: rgb(147, 15, 128);\\n}\\n\\n.ace-chrome .ace_string.ace_regex {\\n color: rgb(255, 0, 0)\\n}\\n\\n.ace-chrome .ace_string {\\n color: #1A1AA6;\\n}\\n\\n.ace-chrome .ace_entity.ace_other.ace_attribute-name {\\n color: #994409;\\n}\\n\\n.ace-chrome .ace_indent-guide {\\n background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y;\\n}\\n \\n.ace-chrome .ace_indent-guide-active {\\n background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAAZSURBVHjaYvj///9/hivKyv8BAAAA//8DACLqBhbvk+/eAAAAAElFTkSuQmCC\") right repeat-y;\\n}\\n'}),ace.define(\"ace/theme/chrome\",[\"require\",\"exports\",\"module\",\"ace/theme/chrome-css\",\"ace/lib/dom\"],function(e,t,n){t.isDark=!1,t.cssClass=\"ace-chrome\",t.cssText=e(\"./chrome-css\");var r=e(\"../lib/dom\");r.importCssString(t.cssText,t.cssClass,!1)}); (function() {\n ace.require([\"ace/theme/chrome\"], function(m) {\n if (typeof module == \"object\" && typeof exports == \"object\" && module) {\n module.exports = m;\n }\n });\n })();\n ","ace.define(\"ace/theme/clouds_midnight-css\",[\"require\",\"exports\",\"module\"],function(e,t,n){n.exports=\".ace-clouds-midnight .ace_gutter {\\n background: #232323;\\n color: #929292\\n}\\n\\n.ace-clouds-midnight .ace_print-margin {\\n width: 1px;\\n background: #232323\\n}\\n\\n.ace-clouds-midnight {\\n background-color: #191919;\\n color: #929292\\n}\\n\\n.ace-clouds-midnight .ace_cursor {\\n color: #7DA5DC\\n}\\n\\n.ace-clouds-midnight .ace_marker-layer .ace_selection {\\n background: #000000\\n}\\n\\n.ace-clouds-midnight.ace_multiselect .ace_selection.ace_start {\\n box-shadow: 0 0 3px 0px #191919;\\n}\\n\\n.ace-clouds-midnight .ace_marker-layer .ace_step {\\n background: rgb(102, 82, 0)\\n}\\n\\n.ace-clouds-midnight .ace_marker-layer .ace_bracket {\\n margin: -1px 0 0 -1px;\\n border: 1px solid #BFBFBF\\n}\\n\\n.ace-clouds-midnight .ace_marker-layer .ace_active-line {\\n background: rgba(215, 215, 215, 0.031)\\n}\\n\\n.ace-clouds-midnight .ace_gutter-active-line {\\n background-color: rgba(215, 215, 215, 0.031)\\n}\\n\\n.ace-clouds-midnight .ace_marker-layer .ace_selected-word {\\n border: 1px solid #000000\\n}\\n\\n.ace-clouds-midnight .ace_invisible {\\n color: #666\\n}\\n\\n.ace-clouds-midnight .ace_keyword,\\n.ace-clouds-midnight .ace_meta,\\n.ace-clouds-midnight .ace_support.ace_constant.ace_property-value {\\n color: #927C5D\\n}\\n\\n.ace-clouds-midnight .ace_keyword.ace_operator {\\n color: #4B4B4B\\n}\\n\\n.ace-clouds-midnight .ace_keyword.ace_other.ace_unit {\\n color: #366F1A\\n}\\n\\n.ace-clouds-midnight .ace_constant.ace_language {\\n color: #39946A\\n}\\n\\n.ace-clouds-midnight .ace_constant.ace_numeric {\\n color: #46A609\\n}\\n\\n.ace-clouds-midnight .ace_constant.ace_character.ace_entity {\\n color: #A165AC\\n}\\n\\n.ace-clouds-midnight .ace_invalid {\\n color: #FFFFFF;\\n background-color: #E92E2E\\n}\\n\\n.ace-clouds-midnight .ace_fold {\\n background-color: #927C5D;\\n border-color: #929292\\n}\\n\\n.ace-clouds-midnight .ace_storage,\\n.ace-clouds-midnight .ace_support.ace_class,\\n.ace-clouds-midnight .ace_support.ace_function,\\n.ace-clouds-midnight .ace_support.ace_other,\\n.ace-clouds-midnight .ace_support.ace_type {\\n color: #E92E2E\\n}\\n\\n.ace-clouds-midnight .ace_string {\\n color: #5D90CD\\n}\\n\\n.ace-clouds-midnight .ace_comment {\\n color: #3C403B\\n}\\n\\n.ace-clouds-midnight .ace_entity.ace_name.ace_tag,\\n.ace-clouds-midnight .ace_entity.ace_other.ace_attribute-name {\\n color: #606060\\n}\\n\\n.ace-clouds-midnight .ace_indent-guide {\\n background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYHB3d/8PAAOIAdULw8qMAAAAAElFTkSuQmCC) right repeat-y\\n}\\n\\n.ace-clouds-midnight .ace_indent-guide-active {\\n background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQIW2PQ1dX9zzBz5sz/ABCcBFFentLlAAAAAElFTkSuQmCC) right repeat-y;\\n}\\n\"}),ace.define(\"ace/theme/clouds_midnight\",[\"require\",\"exports\",\"module\",\"ace/theme/clouds_midnight-css\",\"ace/lib/dom\"],function(e,t,n){t.isDark=!0,t.cssClass=\"ace-clouds-midnight\",t.cssText=e(\"./clouds_midnight-css\");var r=e(\"../lib/dom\");r.importCssString(t.cssText,t.cssClass,!1)}); (function() {\n ace.require([\"ace/theme/clouds_midnight\"], function(m) {\n if (typeof module == \"object\" && typeof exports == \"object\" && module) {\n module.exports = m;\n }\n });\n })();\n ","\"no use strict\";!function(e){function t(e,t){var n=e,r=\"\";while(n){var i=t[n];if(typeof i==\"string\")return i+r;if(i)return i.location.replace(/\\/*$/,\"/\")+(r||i.main||i.name);if(i===!1)return\"\";var s=n.lastIndexOf(\"/\");if(s===-1)break;r=n.substr(s)+r,n=n.slice(0,s)}return e}if(typeof e.window!=\"undefined\"&&e.document)return;if(e.require&&e.define)return;e.console||(e.console=function(){var e=Array.prototype.slice.call(arguments,0);postMessage({type:\"log\",data:e})},e.console.error=e.console.warn=e.console.log=e.console.trace=e.console),e.window=e,e.ace=e,e.onerror=function(e,t,n,r,i){postMessage({type:\"error\",data:{message:e,data:i&&i.data,file:t,line:n,col:r,stack:i&&i.stack}})},e.normalizeModule=function(t,n){if(n.indexOf(\"!\")!==-1){var r=n.split(\"!\");return e.normalizeModule(t,r[0])+\"!\"+e.normalizeModule(t,r[1])}if(n.charAt(0)==\".\"){var i=t.split(\"/\").slice(0,-1).join(\"/\");n=(i?i+\"/\":\"\")+n;while(n.indexOf(\".\")!==-1&&s!=n){var s=n;n=n.replace(/^\\.\\//,\"\").replace(/\\/\\.\\//,\"/\").replace(/[^\\/]+\\/\\.\\.\\//,\"\")}}return n},e.require=function(r,i){i||(i=r,r=null);if(!i.charAt)throw new Error(\"worker.js require() accepts only (parentId, id) as arguments\");i=e.normalizeModule(r,i);var s=e.require.modules[i];if(s)return s.initialized||(s.initialized=!0,s.exports=s.factory().exports),s.exports;if(!e.require.tlns)return console.log(\"unable to load \"+i);var o=t(i,e.require.tlns);return o.slice(-3)!=\".js\"&&(o+=\".js\"),e.require.id=i,e.require.modules[i]={},importScripts(o),e.require(r,i)},e.require.modules={},e.require.tlns={},e.define=function(t,n,r){arguments.length==2?(r=n,typeof t!=\"string\"&&(n=t,t=e.require.id)):arguments.length==1&&(r=t,n=[],t=e.require.id);if(typeof r!=\"function\"){e.require.modules[t]={exports:r,initialized:!0};return}n.length||(n=[\"require\",\"exports\",\"module\"]);var i=function(n){return e.require(t,n)};e.require.modules[t]={exports:{},factory:function(){var e=this,t=r.apply(this,n.slice(0,r.length).map(function(t){switch(t){case\"require\":return i;case\"exports\":return e.exports;case\"module\":return e;default:return i(t)}}));return t&&(e.exports=t),e}}},e.define.amd={},e.require.tlns={},e.initBaseUrls=function(t){for(var n in t)this.require.tlns[n]=t[n]},e.initSender=function(){var n=e.require(\"ace/lib/event_emitter\").EventEmitter,r=e.require(\"ace/lib/oop\"),i=function(){};return function(){r.implement(this,n),this.callback=function(e,t){postMessage({type:\"call\",id:t,data:e})},this.emit=function(e,t){postMessage({type:\"event\",name:e,data:t})}}.call(i.prototype),new i};var n=e.main=null,r=e.sender=null;e.onmessage=function(t){var i=t.data;if(i.event&&r)r._signal(i.event,i.data);else if(i.command)if(n[i.command])n[i.command].apply(n,i.args);else{if(!e[i.command])throw new Error(\"Unknown command:\"+i.command);e[i.command].apply(e,i.args)}else if(i.init){e.initBaseUrls(i.tlns),r=e.sender=e.initSender();var s=this.require(i.module)[i.classname];n=e.main=new s(r)}}}(this),ace.define(\"ace/lib/oop\",[],function(e,t,n){\"use strict\";t.inherits=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})},t.mixin=function(e,t){for(var n in t)e[n]=t[n];return e},t.implement=function(e,n){t.mixin(e,n)}}),ace.define(\"ace/apply_delta\",[],function(e,t,n){\"use strict\";function r(e,t){throw console.log(\"Invalid Delta:\",e),\"Invalid Delta: \"+t}function i(e,t){return t.row>=0&&t.row=0&&t.column<=e[t.row].length}function s(e,t){t.action!=\"insert\"&&t.action!=\"remove\"&&r(t,\"delta.action must be 'insert' or 'remove'\"),t.lines instanceof Array||r(t,\"delta.lines must be an Array\"),(!t.start||!t.end)&&r(t,\"delta.start/end must be an present\");var n=t.start;i(e,t.start)||r(t,\"delta.start must be contained in document\");var s=t.end;t.action==\"remove\"&&!i(e,s)&&r(t,\"delta.end must contained in document for 'remove' actions\");var o=s.row-n.row,u=s.column-(o==0?n.column:0);(o!=t.lines.length-1||t.lines[o].length!=u)&&r(t,\"delta.range must match delta lines\")}t.applyDelta=function(e,t,n){var r=t.start.row,i=t.start.column,s=e[r]||\"\";switch(t.action){case\"insert\":var o=t.lines;if(o.length===1)e[r]=s.substring(0,i)+t.lines[0]+s.substring(i);else{var u=[r,1].concat(t.lines);e.splice.apply(e,u),e[r]=s.substring(0,i)+e[r],e[r+t.lines.length-1]+=s.substring(i)}break;case\"remove\":var a=t.end.column,f=t.end.row;r===f?e[r]=s.substring(0,i)+s.substring(a):e.splice(r,f-r+1,s.substring(0,i)+e[f].substring(a))}}}),ace.define(\"ace/lib/event_emitter\",[],function(e,t,n){\"use strict\";var r={},i=function(){this.propagationStopped=!0},s=function(){this.defaultPrevented=!0};r._emit=r._dispatchEvent=function(e,t){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var n=this._eventRegistry[e]||[],r=this._defaultHandlers[e];if(!n.length&&!r)return;if(typeof t!=\"object\"||!t)t={};t.type||(t.type=e),t.stopPropagation||(t.stopPropagation=i),t.preventDefault||(t.preventDefault=s),n=n.slice();for(var o=0;o [\"+this.end.row+\"/\"+this.end.column+\"]\"},e.prototype.contains=function(e,t){return this.compare(e,t)==0},e.prototype.compareRange=function(e){var t,n=e.end,r=e.start;return t=this.compare(n.row,n.column),t==1?(t=this.compare(r.row,r.column),t==1?2:t==0?1:0):t==-1?-2:(t=this.compare(r.row,r.column),t==-1?-1:t==1?42:0)},e.prototype.comparePoint=function(e){return this.compare(e.row,e.column)},e.prototype.containsRange=function(e){return this.comparePoint(e.start)==0&&this.comparePoint(e.end)==0},e.prototype.intersects=function(e){var t=this.compareRange(e);return t==-1||t==0||t==1},e.prototype.isEnd=function(e,t){return this.end.row==e&&this.end.column==t},e.prototype.isStart=function(e,t){return this.start.row==e&&this.start.column==t},e.prototype.setStart=function(e,t){typeof e==\"object\"?(this.start.column=e.column,this.start.row=e.row):(this.start.row=e,this.start.column=t)},e.prototype.setEnd=function(e,t){typeof e==\"object\"?(this.end.column=e.column,this.end.row=e.row):(this.end.row=e,this.end.column=t)},e.prototype.inside=function(e,t){return this.compare(e,t)==0?this.isEnd(e,t)||this.isStart(e,t)?!1:!0:!1},e.prototype.insideStart=function(e,t){return this.compare(e,t)==0?this.isEnd(e,t)?!1:!0:!1},e.prototype.insideEnd=function(e,t){return this.compare(e,t)==0?this.isStart(e,t)?!1:!0:!1},e.prototype.compare=function(e,t){return!this.isMultiLine()&&e===this.start.row?tthis.end.column?1:0:ethis.end.row?1:this.start.row===e?t>=this.start.column?0:-1:this.end.row===e?t<=this.end.column?0:1:0},e.prototype.compareStart=function(e,t){return this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},e.prototype.compareEnd=function(e,t){return this.end.row==e&&this.end.column==t?1:this.compare(e,t)},e.prototype.compareInside=function(e,t){return this.end.row==e&&this.end.column==t?1:this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},e.prototype.clipRows=function(t,n){if(this.end.row>n)var r={row:n+1,column:0};else if(this.end.rown)var i={row:n+1,column:0};else if(this.start.rowthis.row)return;var t=u(e,{row:this.row,column:this.column},this.$insertRight);this.setPosition(t.row,t.column,!0)},e.prototype.setPosition=function(e,t,n){var r;n?r={row:e,column:t}:r=this.$clipPositionToDocument(e,t);if(this.row==r.row&&this.column==r.column)return;var i={row:this.row,column:this.column};this.row=r.row,this.column=r.column,this._signal(\"change\",{old:i,value:r})},e.prototype.detach=function(){this.document.off(\"change\",this.$onChange)},e.prototype.attach=function(e){this.document=e||this.document,this.document.on(\"change\",this.$onChange)},e.prototype.$clipPositionToDocument=function(e,t){var n={};return e>=this.document.getLength()?(n.row=Math.max(0,this.document.getLength()-1),n.column=this.document.getLine(n.row).length):e<0?(n.row=0,n.column=0):(n.row=e,n.column=Math.min(this.document.getLine(n.row).length,Math.max(0,t))),t<0&&(n.column=0),n},e}();s.prototype.$insertRight=!1,r.implement(s.prototype,i),t.Anchor=s}),ace.define(\"ace/document\",[],function(e,t,n){\"use strict\";var r=e(\"./lib/oop\"),i=e(\"./apply_delta\").applyDelta,s=e(\"./lib/event_emitter\").EventEmitter,o=e(\"./range\").Range,u=e(\"./anchor\").Anchor,a=function(){function e(e){this.$lines=[\"\"],e.length===0?this.$lines=[\"\"]:Array.isArray(e)?this.insertMergedLines({row:0,column:0},e):this.insert({row:0,column:0},e)}return e.prototype.setValue=function(e){var t=this.getLength()-1;this.remove(new o(0,0,t,this.getLine(t).length)),this.insert({row:0,column:0},e||\"\")},e.prototype.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},e.prototype.createAnchor=function(e,t){return new u(this,e,t)},e.prototype.$detectNewLine=function(e){var t=e.match(/^.*?(\\r\\n|\\r|\\n)/m);this.$autoNewLine=t?t[1]:\"\\n\",this._signal(\"changeNewLineMode\")},e.prototype.getNewLineCharacter=function(){switch(this.$newLineMode){case\"windows\":return\"\\r\\n\";case\"unix\":return\"\\n\";default:return this.$autoNewLine||\"\\n\"}},e.prototype.setNewLineMode=function(e){if(this.$newLineMode===e)return;this.$newLineMode=e,this._signal(\"changeNewLineMode\")},e.prototype.getNewLineMode=function(){return this.$newLineMode},e.prototype.isNewLine=function(e){return e==\"\\r\\n\"||e==\"\\r\"||e==\"\\n\"},e.prototype.getLine=function(e){return this.$lines[e]||\"\"},e.prototype.getLines=function(e,t){return this.$lines.slice(e,t+1)},e.prototype.getAllLines=function(){return this.getLines(0,this.getLength())},e.prototype.getLength=function(){return this.$lines.length},e.prototype.getTextRange=function(e){return this.getLinesForRange(e).join(this.getNewLineCharacter())},e.prototype.getLinesForRange=function(e){var t;if(e.start.row===e.end.row)t=[this.getLine(e.start.row).substring(e.start.column,e.end.column)];else{t=this.getLines(e.start.row,e.end.row),t[0]=(t[0]||\"\").substring(e.start.column);var n=t.length-1;e.end.row-e.start.row==n&&(t[n]=t[n].substring(0,e.end.column))}return t},e.prototype.insertLines=function(e,t){return console.warn(\"Use of document.insertLines is deprecated. Use the insertFullLines method instead.\"),this.insertFullLines(e,t)},e.prototype.removeLines=function(e,t){return console.warn(\"Use of document.removeLines is deprecated. Use the removeFullLines method instead.\"),this.removeFullLines(e,t)},e.prototype.insertNewLine=function(e){return console.warn(\"Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.\"),this.insertMergedLines(e,[\"\",\"\"])},e.prototype.insert=function(e,t){return this.getLength()<=1&&this.$detectNewLine(t),this.insertMergedLines(e,this.$split(t))},e.prototype.insertInLine=function(e,t){var n=this.clippedPos(e.row,e.column),r=this.pos(e.row,e.column+t.length);return this.applyDelta({start:n,end:r,action:\"insert\",lines:[t]},!0),this.clonePos(r)},e.prototype.clippedPos=function(e,t){var n=this.getLength();e===undefined?e=n:e<0?e=0:e>=n&&(e=n-1,t=undefined);var r=this.getLine(e);return t==undefined&&(t=r.length),t=Math.min(Math.max(t,0),r.length),{row:e,column:t}},e.prototype.clonePos=function(e){return{row:e.row,column:e.column}},e.prototype.pos=function(e,t){return{row:e,column:t}},e.prototype.$clipPosition=function(e){var t=this.getLength();return e.row>=t?(e.row=Math.max(0,t-1),e.column=this.getLine(t-1).length):(e.row=Math.max(0,e.row),e.column=Math.min(Math.max(e.column,0),this.getLine(e.row).length)),e},e.prototype.insertFullLines=function(e,t){e=Math.min(Math.max(e,0),this.getLength());var n=0;e0,r=t=0&&this.applyDelta({start:this.pos(e,this.getLine(e).length),end:this.pos(e+1,0),action:\"remove\",lines:[\"\",\"\"]})},e.prototype.replace=function(e,t){e instanceof o||(e=o.fromPoints(e.start,e.end));if(t.length===0&&e.isEmpty())return e.start;if(t==this.getTextRange(e))return e.end;this.remove(e);var n;return t?n=this.insert(e.start,t):n=e.start,n},e.prototype.applyDeltas=function(e){for(var t=0;t=0;t--)this.revertDelta(e[t])},e.prototype.applyDelta=function(e,t){var n=e.action==\"insert\";if(n?e.lines.length<=1&&!e.lines[0]:!o.comparePoints(e.start,e.end))return;n&&e.lines.length>2e4?this.$splitAndapplyLargeDelta(e,2e4):(i(this.$lines,e,t),this._signal(\"change\",e))},e.prototype.$safeApplyDelta=function(e){var t=this.$lines.length;(e.action==\"remove\"&&e.start.row0){t&1&&(n+=e);if(t>>=1)e+=e}return n};var r=/^\\s\\s*/,i=/\\s\\s*$/;t.stringTrimLeft=function(e){return e.replace(r,\"\")},t.stringTrimRight=function(e){return e.replace(i,\"\")},t.copyObject=function(e){var t={};for(var n in e)t[n]=e[n];return t},t.copyArray=function(e){var t=[];for(var n=0,r=e.length;n65535?2:1}}),ace.define(\"ace/worker/mirror\",[],function(e,t,n){\"use strict\";var r=e(\"../document\").Document,i=e(\"../lib/lang\"),s=t.Mirror=function(e){this.sender=e;var t=this.doc=new r(\"\"),n=this.deferredUpdate=i.delayedCall(this.onUpdate.bind(this)),s=this;e.on(\"change\",function(e){var r=e.data;if(r[0].start)t.applyDeltas(r);else for(var i=0;i=t.$lines.length)throw u=new Error(\"Invalid delta\"),u.data={path:s.$path,linesLength:t.$lines.length,start:o.start,end:o.end},u;t.applyDelta(o,!0)}if(s.$timeout)return n.schedule(s.$timeout);s.onUpdate()})};(function(){this.$timeout=500,this.setTimeout=function(e){this.$timeout=e},this.setValue=function(e){this.doc.setValue(e),this.deferredUpdate.schedule(this.$timeout)},this.getValue=function(e){this.sender.callback(this.doc.getValue(),e)},this.onUpdate=function(){},this.isPending=function(){return this.deferredUpdate.isPending()}}).call(s.prototype)}),ace.define(\"ace/mode/json/json_parse\",[],function(e,t,n){\"use strict\";var r,i,s={'\"':'\"',\"\\\\\":\"\\\\\",\"/\":\"/\",b:\"\\b\",f:\"\\f\",n:\"\\n\",r:\"\\r\",t:\"\t\"},o,u=function(e){throw{name:\"SyntaxError\",message:e,at:r,text:o}},a=function(e){return e&&e!==i&&u(\"Expected '\"+e+\"' instead of '\"+i+\"'\"),i=o.charAt(r),r+=1,i},f=function(){var e,t=\"\";i===\"-\"&&(t=\"-\",a(\"-\"));while(i>=\"0\"&&i<=\"9\")t+=i,a();if(i===\".\"){t+=\".\";while(a()&&i>=\"0\"&&i<=\"9\")t+=i}if(i===\"e\"||i===\"E\"){t+=i,a();if(i===\"-\"||i===\"+\")t+=i,a();while(i>=\"0\"&&i<=\"9\")t+=i,a()}e=+t;if(!isNaN(e))return e;u(\"Bad number\")},l=function(){var e,t,n=\"\",r;if(i==='\"')while(a()){if(i==='\"')return a(),n;if(i===\"\\\\\"){a();if(i===\"u\"){r=0;for(t=0;t<4;t+=1){e=parseInt(a(),16);if(!isFinite(e))break;r=r*16+e}n+=String.fromCharCode(r)}else{if(typeof s[i]!=\"string\")break;n+=s[i]}}else{if(i==\"\\n\"||i==\"\\r\")break;n+=i}}u(\"Bad string\")},c=function(){while(i&&i<=\" \")a()},h=function(){switch(i){case\"t\":return a(\"t\"),a(\"r\"),a(\"u\"),a(\"e\"),!0;case\"f\":return a(\"f\"),a(\"a\"),a(\"l\"),a(\"s\"),a(\"e\"),!1;case\"n\":return a(\"n\"),a(\"u\"),a(\"l\"),a(\"l\"),null}u(\"Unexpected '\"+i+\"'\")},p,d=function(){var e=[];if(i===\"[\"){a(\"[\"),c();if(i===\"]\")return a(\"]\"),e;while(i){e.push(p()),c();if(i===\"]\")return a(\"]\"),e;a(\",\"),c()}}u(\"Bad array\")},v=function(){var e,t={};if(i===\"{\"){a(\"{\"),c();if(i===\"}\")return a(\"}\"),t;while(i){e=l(),c(),a(\":\"),Object.hasOwnProperty.call(t,e)&&u('Duplicate key \"'+e+'\"'),t[e]=p(),c();if(i===\"}\")return a(\"}\"),t;a(\",\"),c()}}u(\"Bad object\")};return p=function(){c();switch(i){case\"{\":return v();case\"[\":return d();case'\"':return l();case\"-\":return f();default:return i>=\"0\"&&i<=\"9\"?f():h()}},function(e,t){var n;return o=e,r=0,i=\" \",n=p(),c(),i&&u(\"Syntax error\"),typeof t==\"function\"?function s(e,n){var r,i,o=e[n];if(o&&typeof o==\"object\")for(r in o)Object.hasOwnProperty.call(o,r)&&(i=s(o,r),i!==undefined?o[r]=i:delete o[r]);return t.call(e,n,o)}({\"\":n},\"\"):n}}),ace.define(\"ace/mode/json_worker\",[],function(e,t,n){\"use strict\";var r=e(\"../lib/oop\"),i=e(\"../worker/mirror\").Mirror,s=e(\"./json/json_parse\"),o=t.JsonWorker=function(e){i.call(this,e),this.setTimeout(200)};r.inherits(o,i),function(){this.onUpdate=function(){var e=this.doc.getValue(),t=[];try{e&&s(e)}catch(n){var r=this.doc.indexToPosition(n.at-1);t.push({row:r.row,column:r.column,text:n.message,type:\"error\"})}this.sender.emit(\"annotate\",t)}}.call(o.prototype)})",";(function (root, factory) {\n\tif (typeof exports === \"object\") {\n\t\t// CommonJS\n\t\tmodule.exports = exports = factory();\n\t}\n\telse if (typeof define === \"function\" && define.amd) {\n\t\t// AMD\n\t\tdefine([], factory);\n\t}\n\telse {\n\t\t// Global (browser)\n\t\troot.CryptoJS = factory();\n\t}\n}(this, function () {\n\n\t/*globals window, global, require*/\n\n\t/**\n\t * CryptoJS core components.\n\t */\n\tvar CryptoJS = CryptoJS || (function (Math, undefined) {\n\n\t var crypto;\n\n\t // Native crypto from window (Browser)\n\t if (typeof window !== 'undefined' && window.crypto) {\n\t crypto = window.crypto;\n\t }\n\n\t // Native crypto in web worker (Browser)\n\t if (typeof self !== 'undefined' && self.crypto) {\n\t crypto = self.crypto;\n\t }\n\n\t // Native crypto from worker\n\t if (typeof globalThis !== 'undefined' && globalThis.crypto) {\n\t crypto = globalThis.crypto;\n\t }\n\n\t // Native (experimental IE 11) crypto from window (Browser)\n\t if (!crypto && typeof window !== 'undefined' && window.msCrypto) {\n\t crypto = window.msCrypto;\n\t }\n\n\t // Native crypto from global (NodeJS)\n\t if (!crypto && typeof global !== 'undefined' && global.crypto) {\n\t crypto = global.crypto;\n\t }\n\n\t // Native crypto import via require (NodeJS)\n\t if (!crypto && typeof require === 'function') {\n\t try {\n\t crypto = require('crypto');\n\t } catch (err) {}\n\t }\n\n\t /*\n\t * Cryptographically secure pseudorandom number generator\n\t *\n\t * As Math.random() is cryptographically not safe to use\n\t */\n\t var cryptoSecureRandomInt = function () {\n\t if (crypto) {\n\t // Use getRandomValues method (Browser)\n\t if (typeof crypto.getRandomValues === 'function') {\n\t try {\n\t return crypto.getRandomValues(new Uint32Array(1))[0];\n\t } catch (err) {}\n\t }\n\n\t // Use randomBytes method (NodeJS)\n\t if (typeof crypto.randomBytes === 'function') {\n\t try {\n\t return crypto.randomBytes(4).readInt32LE();\n\t } catch (err) {}\n\t }\n\t }\n\n\t throw new Error('Native crypto module could not be used to get secure random number.');\n\t };\n\n\t /*\n\t * Local polyfill of Object.create\n\n\t */\n\t var create = Object.create || (function () {\n\t function F() {}\n\n\t return function (obj) {\n\t var subtype;\n\n\t F.prototype = obj;\n\n\t subtype = new F();\n\n\t F.prototype = null;\n\n\t return subtype;\n\t };\n\t }());\n\n\t /**\n\t * CryptoJS namespace.\n\t */\n\t var C = {};\n\n\t /**\n\t * Library namespace.\n\t */\n\t var C_lib = C.lib = {};\n\n\t /**\n\t * Base object for prototypal inheritance.\n\t */\n\t var Base = C_lib.Base = (function () {\n\n\n\t return {\n\t /**\n\t * Creates a new object that inherits from this object.\n\t *\n\t * @param {Object} overrides Properties to copy into the new object.\n\t *\n\t * @return {Object} The new object.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var MyType = CryptoJS.lib.Base.extend({\n\t * field: 'value',\n\t *\n\t * method: function () {\n\t * }\n\t * });\n\t */\n\t extend: function (overrides) {\n\t // Spawn\n\t var subtype = create(this);\n\n\t // Augment\n\t if (overrides) {\n\t subtype.mixIn(overrides);\n\t }\n\n\t // Create default initializer\n\t if (!subtype.hasOwnProperty('init') || this.init === subtype.init) {\n\t subtype.init = function () {\n\t subtype.$super.init.apply(this, arguments);\n\t };\n\t }\n\n\t // Initializer's prototype is the subtype object\n\t subtype.init.prototype = subtype;\n\n\t // Reference supertype\n\t subtype.$super = this;\n\n\t return subtype;\n\t },\n\n\t /**\n\t * Extends this object and runs the init method.\n\t * Arguments to create() will be passed to init().\n\t *\n\t * @return {Object} The new object.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var instance = MyType.create();\n\t */\n\t create: function () {\n\t var instance = this.extend();\n\t instance.init.apply(instance, arguments);\n\n\t return instance;\n\t },\n\n\t /**\n\t * Initializes a newly created object.\n\t * Override this method to add some logic when your objects are created.\n\t *\n\t * @example\n\t *\n\t * var MyType = CryptoJS.lib.Base.extend({\n\t * init: function () {\n\t * // ...\n\t * }\n\t * });\n\t */\n\t init: function () {\n\t },\n\n\t /**\n\t * Copies properties into this object.\n\t *\n\t * @param {Object} properties The properties to mix in.\n\t *\n\t * @example\n\t *\n\t * MyType.mixIn({\n\t * field: 'value'\n\t * });\n\t */\n\t mixIn: function (properties) {\n\t for (var propertyName in properties) {\n\t if (properties.hasOwnProperty(propertyName)) {\n\t this[propertyName] = properties[propertyName];\n\t }\n\t }\n\n\t // IE won't copy toString using the loop above\n\t if (properties.hasOwnProperty('toString')) {\n\t this.toString = properties.toString;\n\t }\n\t },\n\n\t /**\n\t * Creates a copy of this object.\n\t *\n\t * @return {Object} The clone.\n\t *\n\t * @example\n\t *\n\t * var clone = instance.clone();\n\t */\n\t clone: function () {\n\t return this.init.prototype.extend(this);\n\t }\n\t };\n\t }());\n\n\t /**\n\t * An array of 32-bit words.\n\t *\n\t * @property {Array} words The array of 32-bit words.\n\t * @property {number} sigBytes The number of significant bytes in this word array.\n\t */\n\t var WordArray = C_lib.WordArray = Base.extend({\n\t /**\n\t * Initializes a newly created word array.\n\t *\n\t * @param {Array} words (Optional) An array of 32-bit words.\n\t * @param {number} sigBytes (Optional) The number of significant bytes in the words.\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.lib.WordArray.create();\n\t * var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607]);\n\t * var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607], 6);\n\t */\n\t init: function (words, sigBytes) {\n\t words = this.words = words || [];\n\n\t if (sigBytes != undefined) {\n\t this.sigBytes = sigBytes;\n\t } else {\n\t this.sigBytes = words.length * 4;\n\t }\n\t },\n\n\t /**\n\t * Converts this word array to a string.\n\t *\n\t * @param {Encoder} encoder (Optional) The encoding strategy to use. Default: CryptoJS.enc.Hex\n\t *\n\t * @return {string} The stringified word array.\n\t *\n\t * @example\n\t *\n\t * var string = wordArray + '';\n\t * var string = wordArray.toString();\n\t * var string = wordArray.toString(CryptoJS.enc.Utf8);\n\t */\n\t toString: function (encoder) {\n\t return (encoder || Hex).stringify(this);\n\t },\n\n\t /**\n\t * Concatenates a word array to this word array.\n\t *\n\t * @param {WordArray} wordArray The word array to append.\n\t *\n\t * @return {WordArray} This word array.\n\t *\n\t * @example\n\t *\n\t * wordArray1.concat(wordArray2);\n\t */\n\t concat: function (wordArray) {\n\t // Shortcuts\n\t var thisWords = this.words;\n\t var thatWords = wordArray.words;\n\t var thisSigBytes = this.sigBytes;\n\t var thatSigBytes = wordArray.sigBytes;\n\n\t // Clamp excess bits\n\t this.clamp();\n\n\t // Concat\n\t if (thisSigBytes % 4) {\n\t // Copy one byte at a time\n\t for (var i = 0; i < thatSigBytes; i++) {\n\t var thatByte = (thatWords[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t thisWords[(thisSigBytes + i) >>> 2] |= thatByte << (24 - ((thisSigBytes + i) % 4) * 8);\n\t }\n\t } else {\n\t // Copy one word at a time\n\t for (var j = 0; j < thatSigBytes; j += 4) {\n\t thisWords[(thisSigBytes + j) >>> 2] = thatWords[j >>> 2];\n\t }\n\t }\n\t this.sigBytes += thatSigBytes;\n\n\t // Chainable\n\t return this;\n\t },\n\n\t /**\n\t * Removes insignificant bits.\n\t *\n\t * @example\n\t *\n\t * wordArray.clamp();\n\t */\n\t clamp: function () {\n\t // Shortcuts\n\t var words = this.words;\n\t var sigBytes = this.sigBytes;\n\n\t // Clamp\n\t words[sigBytes >>> 2] &= 0xffffffff << (32 - (sigBytes % 4) * 8);\n\t words.length = Math.ceil(sigBytes / 4);\n\t },\n\n\t /**\n\t * Creates a copy of this word array.\n\t *\n\t * @return {WordArray} The clone.\n\t *\n\t * @example\n\t *\n\t * var clone = wordArray.clone();\n\t */\n\t clone: function () {\n\t var clone = Base.clone.call(this);\n\t clone.words = this.words.slice(0);\n\n\t return clone;\n\t },\n\n\t /**\n\t * Creates a word array filled with random bytes.\n\t *\n\t * @param {number} nBytes The number of random bytes to generate.\n\t *\n\t * @return {WordArray} The random word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.lib.WordArray.random(16);\n\t */\n\t random: function (nBytes) {\n\t var words = [];\n\n\t for (var i = 0; i < nBytes; i += 4) {\n\t words.push(cryptoSecureRandomInt());\n\t }\n\n\t return new WordArray.init(words, nBytes);\n\t }\n\t });\n\n\t /**\n\t * Encoder namespace.\n\t */\n\t var C_enc = C.enc = {};\n\n\t /**\n\t * Hex encoding strategy.\n\t */\n\t var Hex = C_enc.Hex = {\n\t /**\n\t * Converts a word array to a hex string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @return {string} The hex string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var hexString = CryptoJS.enc.Hex.stringify(wordArray);\n\t */\n\t stringify: function (wordArray) {\n\t // Shortcuts\n\t var words = wordArray.words;\n\t var sigBytes = wordArray.sigBytes;\n\n\t // Convert\n\t var hexChars = [];\n\t for (var i = 0; i < sigBytes; i++) {\n\t var bite = (words[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t hexChars.push((bite >>> 4).toString(16));\n\t hexChars.push((bite & 0x0f).toString(16));\n\t }\n\n\t return hexChars.join('');\n\t },\n\n\t /**\n\t * Converts a hex string to a word array.\n\t *\n\t * @param {string} hexStr The hex string.\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Hex.parse(hexString);\n\t */\n\t parse: function (hexStr) {\n\t // Shortcut\n\t var hexStrLength = hexStr.length;\n\n\t // Convert\n\t var words = [];\n\t for (var i = 0; i < hexStrLength; i += 2) {\n\t words[i >>> 3] |= parseInt(hexStr.substr(i, 2), 16) << (24 - (i % 8) * 4);\n\t }\n\n\t return new WordArray.init(words, hexStrLength / 2);\n\t }\n\t };\n\n\t /**\n\t * Latin1 encoding strategy.\n\t */\n\t var Latin1 = C_enc.Latin1 = {\n\t /**\n\t * Converts a word array to a Latin1 string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @return {string} The Latin1 string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var latin1String = CryptoJS.enc.Latin1.stringify(wordArray);\n\t */\n\t stringify: function (wordArray) {\n\t // Shortcuts\n\t var words = wordArray.words;\n\t var sigBytes = wordArray.sigBytes;\n\n\t // Convert\n\t var latin1Chars = [];\n\t for (var i = 0; i < sigBytes; i++) {\n\t var bite = (words[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t latin1Chars.push(String.fromCharCode(bite));\n\t }\n\n\t return latin1Chars.join('');\n\t },\n\n\t /**\n\t * Converts a Latin1 string to a word array.\n\t *\n\t * @param {string} latin1Str The Latin1 string.\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Latin1.parse(latin1String);\n\t */\n\t parse: function (latin1Str) {\n\t // Shortcut\n\t var latin1StrLength = latin1Str.length;\n\n\t // Convert\n\t var words = [];\n\t for (var i = 0; i < latin1StrLength; i++) {\n\t words[i >>> 2] |= (latin1Str.charCodeAt(i) & 0xff) << (24 - (i % 4) * 8);\n\t }\n\n\t return new WordArray.init(words, latin1StrLength);\n\t }\n\t };\n\n\t /**\n\t * UTF-8 encoding strategy.\n\t */\n\t var Utf8 = C_enc.Utf8 = {\n\t /**\n\t * Converts a word array to a UTF-8 string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @return {string} The UTF-8 string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var utf8String = CryptoJS.enc.Utf8.stringify(wordArray);\n\t */\n\t stringify: function (wordArray) {\n\t try {\n\t return decodeURIComponent(escape(Latin1.stringify(wordArray)));\n\t } catch (e) {\n\t throw new Error('Malformed UTF-8 data');\n\t }\n\t },\n\n\t /**\n\t * Converts a UTF-8 string to a word array.\n\t *\n\t * @param {string} utf8Str The UTF-8 string.\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Utf8.parse(utf8String);\n\t */\n\t parse: function (utf8Str) {\n\t return Latin1.parse(unescape(encodeURIComponent(utf8Str)));\n\t }\n\t };\n\n\t /**\n\t * Abstract buffered block algorithm template.\n\t *\n\t * The property blockSize must be implemented in a concrete subtype.\n\t *\n\t * @property {number} _minBufferSize The number of blocks that should be kept unprocessed in the buffer. Default: 0\n\t */\n\t var BufferedBlockAlgorithm = C_lib.BufferedBlockAlgorithm = Base.extend({\n\t /**\n\t * Resets this block algorithm's data buffer to its initial state.\n\t *\n\t * @example\n\t *\n\t * bufferedBlockAlgorithm.reset();\n\t */\n\t reset: function () {\n\t // Initial values\n\t this._data = new WordArray.init();\n\t this._nDataBytes = 0;\n\t },\n\n\t /**\n\t * Adds new data to this block algorithm's buffer.\n\t *\n\t * @param {WordArray|string} data The data to append. Strings are converted to a WordArray using UTF-8.\n\t *\n\t * @example\n\t *\n\t * bufferedBlockAlgorithm._append('data');\n\t * bufferedBlockAlgorithm._append(wordArray);\n\t */\n\t _append: function (data) {\n\t // Convert string to WordArray, else assume WordArray already\n\t if (typeof data == 'string') {\n\t data = Utf8.parse(data);\n\t }\n\n\t // Append\n\t this._data.concat(data);\n\t this._nDataBytes += data.sigBytes;\n\t },\n\n\t /**\n\t * Processes available data blocks.\n\t *\n\t * This method invokes _doProcessBlock(offset), which must be implemented by a concrete subtype.\n\t *\n\t * @param {boolean} doFlush Whether all blocks and partial blocks should be processed.\n\t *\n\t * @return {WordArray} The processed data.\n\t *\n\t * @example\n\t *\n\t * var processedData = bufferedBlockAlgorithm._process();\n\t * var processedData = bufferedBlockAlgorithm._process(!!'flush');\n\t */\n\t _process: function (doFlush) {\n\t var processedWords;\n\n\t // Shortcuts\n\t var data = this._data;\n\t var dataWords = data.words;\n\t var dataSigBytes = data.sigBytes;\n\t var blockSize = this.blockSize;\n\t var blockSizeBytes = blockSize * 4;\n\n\t // Count blocks ready\n\t var nBlocksReady = dataSigBytes / blockSizeBytes;\n\t if (doFlush) {\n\t // Round up to include partial blocks\n\t nBlocksReady = Math.ceil(nBlocksReady);\n\t } else {\n\t // Round down to include only full blocks,\n\t // less the number of blocks that must remain in the buffer\n\t nBlocksReady = Math.max((nBlocksReady | 0) - this._minBufferSize, 0);\n\t }\n\n\t // Count words ready\n\t var nWordsReady = nBlocksReady * blockSize;\n\n\t // Count bytes ready\n\t var nBytesReady = Math.min(nWordsReady * 4, dataSigBytes);\n\n\t // Process blocks\n\t if (nWordsReady) {\n\t for (var offset = 0; offset < nWordsReady; offset += blockSize) {\n\t // Perform concrete-algorithm logic\n\t this._doProcessBlock(dataWords, offset);\n\t }\n\n\t // Remove processed words\n\t processedWords = dataWords.splice(0, nWordsReady);\n\t data.sigBytes -= nBytesReady;\n\t }\n\n\t // Return processed words\n\t return new WordArray.init(processedWords, nBytesReady);\n\t },\n\n\t /**\n\t * Creates a copy of this object.\n\t *\n\t * @return {Object} The clone.\n\t *\n\t * @example\n\t *\n\t * var clone = bufferedBlockAlgorithm.clone();\n\t */\n\t clone: function () {\n\t var clone = Base.clone.call(this);\n\t clone._data = this._data.clone();\n\n\t return clone;\n\t },\n\n\t _minBufferSize: 0\n\t });\n\n\t /**\n\t * Abstract hasher template.\n\t *\n\t * @property {number} blockSize The number of 32-bit words this hasher operates on. Default: 16 (512 bits)\n\t */\n\t var Hasher = C_lib.Hasher = BufferedBlockAlgorithm.extend({\n\t /**\n\t * Configuration options.\n\t */\n\t cfg: Base.extend(),\n\n\t /**\n\t * Initializes a newly created hasher.\n\t *\n\t * @param {Object} cfg (Optional) The configuration options to use for this hash computation.\n\t *\n\t * @example\n\t *\n\t * var hasher = CryptoJS.algo.SHA256.create();\n\t */\n\t init: function (cfg) {\n\t // Apply config defaults\n\t this.cfg = this.cfg.extend(cfg);\n\n\t // Set initial values\n\t this.reset();\n\t },\n\n\t /**\n\t * Resets this hasher to its initial state.\n\t *\n\t * @example\n\t *\n\t * hasher.reset();\n\t */\n\t reset: function () {\n\t // Reset data buffer\n\t BufferedBlockAlgorithm.reset.call(this);\n\n\t // Perform concrete-hasher logic\n\t this._doReset();\n\t },\n\n\t /**\n\t * Updates this hasher with a message.\n\t *\n\t * @param {WordArray|string} messageUpdate The message to append.\n\t *\n\t * @return {Hasher} This hasher.\n\t *\n\t * @example\n\t *\n\t * hasher.update('message');\n\t * hasher.update(wordArray);\n\t */\n\t update: function (messageUpdate) {\n\t // Append\n\t this._append(messageUpdate);\n\n\t // Update the hash\n\t this._process();\n\n\t // Chainable\n\t return this;\n\t },\n\n\t /**\n\t * Finalizes the hash computation.\n\t * Note that the finalize operation is effectively a destructive, read-once operation.\n\t *\n\t * @param {WordArray|string} messageUpdate (Optional) A final message update.\n\t *\n\t * @return {WordArray} The hash.\n\t *\n\t * @example\n\t *\n\t * var hash = hasher.finalize();\n\t * var hash = hasher.finalize('message');\n\t * var hash = hasher.finalize(wordArray);\n\t */\n\t finalize: function (messageUpdate) {\n\t // Final message update\n\t if (messageUpdate) {\n\t this._append(messageUpdate);\n\t }\n\n\t // Perform concrete-hasher logic\n\t var hash = this._doFinalize();\n\n\t return hash;\n\t },\n\n\t blockSize: 512/32,\n\n\t /**\n\t * Creates a shortcut function to a hasher's object interface.\n\t *\n\t * @param {Hasher} hasher The hasher to create a helper for.\n\t *\n\t * @return {Function} The shortcut function.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var SHA256 = CryptoJS.lib.Hasher._createHelper(CryptoJS.algo.SHA256);\n\t */\n\t _createHelper: function (hasher) {\n\t return function (message, cfg) {\n\t return new hasher.init(cfg).finalize(message);\n\t };\n\t },\n\n\t /**\n\t * Creates a shortcut function to the HMAC's object interface.\n\t *\n\t * @param {Hasher} hasher The hasher to use in this HMAC helper.\n\t *\n\t * @return {Function} The shortcut function.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var HmacSHA256 = CryptoJS.lib.Hasher._createHmacHelper(CryptoJS.algo.SHA256);\n\t */\n\t _createHmacHelper: function (hasher) {\n\t return function (message, key) {\n\t return new C_algo.HMAC.init(hasher, key).finalize(message);\n\t };\n\t }\n\t });\n\n\t /**\n\t * Algorithm namespace.\n\t */\n\t var C_algo = C.algo = {};\n\n\t return C;\n\t}(Math));\n\n\n\treturn CryptoJS;\n\n}));",";(function (root, factory) {\n\tif (typeof exports === \"object\") {\n\t\t// CommonJS\n\t\tmodule.exports = exports = factory(require(\"./core\"));\n\t}\n\telse if (typeof define === \"function\" && define.amd) {\n\t\t// AMD\n\t\tdefine([\"./core\"], factory);\n\t}\n\telse {\n\t\t// Global (browser)\n\t\tfactory(root.CryptoJS);\n\t}\n}(this, function (CryptoJS) {\n\n\t(function (Math) {\n\t // Shortcuts\n\t var C = CryptoJS;\n\t var C_lib = C.lib;\n\t var WordArray = C_lib.WordArray;\n\t var Hasher = C_lib.Hasher;\n\t var C_algo = C.algo;\n\n\t // Constants table\n\t var T = [];\n\n\t // Compute constants\n\t (function () {\n\t for (var i = 0; i < 64; i++) {\n\t T[i] = (Math.abs(Math.sin(i + 1)) * 0x100000000) | 0;\n\t }\n\t }());\n\n\t /**\n\t * MD5 hash algorithm.\n\t */\n\t var MD5 = C_algo.MD5 = Hasher.extend({\n\t _doReset: function () {\n\t this._hash = new WordArray.init([\n\t 0x67452301, 0xefcdab89,\n\t 0x98badcfe, 0x10325476\n\t ]);\n\t },\n\n\t _doProcessBlock: function (M, offset) {\n\t // Swap endian\n\t for (var i = 0; i < 16; i++) {\n\t // Shortcuts\n\t var offset_i = offset + i;\n\t var M_offset_i = M[offset_i];\n\n\t M[offset_i] = (\n\t (((M_offset_i << 8) | (M_offset_i >>> 24)) & 0x00ff00ff) |\n\t (((M_offset_i << 24) | (M_offset_i >>> 8)) & 0xff00ff00)\n\t );\n\t }\n\n\t // Shortcuts\n\t var H = this._hash.words;\n\n\t var M_offset_0 = M[offset + 0];\n\t var M_offset_1 = M[offset + 1];\n\t var M_offset_2 = M[offset + 2];\n\t var M_offset_3 = M[offset + 3];\n\t var M_offset_4 = M[offset + 4];\n\t var M_offset_5 = M[offset + 5];\n\t var M_offset_6 = M[offset + 6];\n\t var M_offset_7 = M[offset + 7];\n\t var M_offset_8 = M[offset + 8];\n\t var M_offset_9 = M[offset + 9];\n\t var M_offset_10 = M[offset + 10];\n\t var M_offset_11 = M[offset + 11];\n\t var M_offset_12 = M[offset + 12];\n\t var M_offset_13 = M[offset + 13];\n\t var M_offset_14 = M[offset + 14];\n\t var M_offset_15 = M[offset + 15];\n\n\t // Working variables\n\t var a = H[0];\n\t var b = H[1];\n\t var c = H[2];\n\t var d = H[3];\n\n\t // Computation\n\t a = FF(a, b, c, d, M_offset_0, 7, T[0]);\n\t d = FF(d, a, b, c, M_offset_1, 12, T[1]);\n\t c = FF(c, d, a, b, M_offset_2, 17, T[2]);\n\t b = FF(b, c, d, a, M_offset_3, 22, T[3]);\n\t a = FF(a, b, c, d, M_offset_4, 7, T[4]);\n\t d = FF(d, a, b, c, M_offset_5, 12, T[5]);\n\t c = FF(c, d, a, b, M_offset_6, 17, T[6]);\n\t b = FF(b, c, d, a, M_offset_7, 22, T[7]);\n\t a = FF(a, b, c, d, M_offset_8, 7, T[8]);\n\t d = FF(d, a, b, c, M_offset_9, 12, T[9]);\n\t c = FF(c, d, a, b, M_offset_10, 17, T[10]);\n\t b = FF(b, c, d, a, M_offset_11, 22, T[11]);\n\t a = FF(a, b, c, d, M_offset_12, 7, T[12]);\n\t d = FF(d, a, b, c, M_offset_13, 12, T[13]);\n\t c = FF(c, d, a, b, M_offset_14, 17, T[14]);\n\t b = FF(b, c, d, a, M_offset_15, 22, T[15]);\n\n\t a = GG(a, b, c, d, M_offset_1, 5, T[16]);\n\t d = GG(d, a, b, c, M_offset_6, 9, T[17]);\n\t c = GG(c, d, a, b, M_offset_11, 14, T[18]);\n\t b = GG(b, c, d, a, M_offset_0, 20, T[19]);\n\t a = GG(a, b, c, d, M_offset_5, 5, T[20]);\n\t d = GG(d, a, b, c, M_offset_10, 9, T[21]);\n\t c = GG(c, d, a, b, M_offset_15, 14, T[22]);\n\t b = GG(b, c, d, a, M_offset_4, 20, T[23]);\n\t a = GG(a, b, c, d, M_offset_9, 5, T[24]);\n\t d = GG(d, a, b, c, M_offset_14, 9, T[25]);\n\t c = GG(c, d, a, b, M_offset_3, 14, T[26]);\n\t b = GG(b, c, d, a, M_offset_8, 20, T[27]);\n\t a = GG(a, b, c, d, M_offset_13, 5, T[28]);\n\t d = GG(d, a, b, c, M_offset_2, 9, T[29]);\n\t c = GG(c, d, a, b, M_offset_7, 14, T[30]);\n\t b = GG(b, c, d, a, M_offset_12, 20, T[31]);\n\n\t a = HH(a, b, c, d, M_offset_5, 4, T[32]);\n\t d = HH(d, a, b, c, M_offset_8, 11, T[33]);\n\t c = HH(c, d, a, b, M_offset_11, 16, T[34]);\n\t b = HH(b, c, d, a, M_offset_14, 23, T[35]);\n\t a = HH(a, b, c, d, M_offset_1, 4, T[36]);\n\t d = HH(d, a, b, c, M_offset_4, 11, T[37]);\n\t c = HH(c, d, a, b, M_offset_7, 16, T[38]);\n\t b = HH(b, c, d, a, M_offset_10, 23, T[39]);\n\t a = HH(a, b, c, d, M_offset_13, 4, T[40]);\n\t d = HH(d, a, b, c, M_offset_0, 11, T[41]);\n\t c = HH(c, d, a, b, M_offset_3, 16, T[42]);\n\t b = HH(b, c, d, a, M_offset_6, 23, T[43]);\n\t a = HH(a, b, c, d, M_offset_9, 4, T[44]);\n\t d = HH(d, a, b, c, M_offset_12, 11, T[45]);\n\t c = HH(c, d, a, b, M_offset_15, 16, T[46]);\n\t b = HH(b, c, d, a, M_offset_2, 23, T[47]);\n\n\t a = II(a, b, c, d, M_offset_0, 6, T[48]);\n\t d = II(d, a, b, c, M_offset_7, 10, T[49]);\n\t c = II(c, d, a, b, M_offset_14, 15, T[50]);\n\t b = II(b, c, d, a, M_offset_5, 21, T[51]);\n\t a = II(a, b, c, d, M_offset_12, 6, T[52]);\n\t d = II(d, a, b, c, M_offset_3, 10, T[53]);\n\t c = II(c, d, a, b, M_offset_10, 15, T[54]);\n\t b = II(b, c, d, a, M_offset_1, 21, T[55]);\n\t a = II(a, b, c, d, M_offset_8, 6, T[56]);\n\t d = II(d, a, b, c, M_offset_15, 10, T[57]);\n\t c = II(c, d, a, b, M_offset_6, 15, T[58]);\n\t b = II(b, c, d, a, M_offset_13, 21, T[59]);\n\t a = II(a, b, c, d, M_offset_4, 6, T[60]);\n\t d = II(d, a, b, c, M_offset_11, 10, T[61]);\n\t c = II(c, d, a, b, M_offset_2, 15, T[62]);\n\t b = II(b, c, d, a, M_offset_9, 21, T[63]);\n\n\t // Intermediate hash value\n\t H[0] = (H[0] + a) | 0;\n\t H[1] = (H[1] + b) | 0;\n\t H[2] = (H[2] + c) | 0;\n\t H[3] = (H[3] + d) | 0;\n\t },\n\n\t _doFinalize: function () {\n\t // Shortcuts\n\t var data = this._data;\n\t var dataWords = data.words;\n\n\t var nBitsTotal = this._nDataBytes * 8;\n\t var nBitsLeft = data.sigBytes * 8;\n\n\t // Add padding\n\t dataWords[nBitsLeft >>> 5] |= 0x80 << (24 - nBitsLeft % 32);\n\n\t var nBitsTotalH = Math.floor(nBitsTotal / 0x100000000);\n\t var nBitsTotalL = nBitsTotal;\n\t dataWords[(((nBitsLeft + 64) >>> 9) << 4) + 15] = (\n\t (((nBitsTotalH << 8) | (nBitsTotalH >>> 24)) & 0x00ff00ff) |\n\t (((nBitsTotalH << 24) | (nBitsTotalH >>> 8)) & 0xff00ff00)\n\t );\n\t dataWords[(((nBitsLeft + 64) >>> 9) << 4) + 14] = (\n\t (((nBitsTotalL << 8) | (nBitsTotalL >>> 24)) & 0x00ff00ff) |\n\t (((nBitsTotalL << 24) | (nBitsTotalL >>> 8)) & 0xff00ff00)\n\t );\n\n\t data.sigBytes = (dataWords.length + 1) * 4;\n\n\t // Hash final blocks\n\t this._process();\n\n\t // Shortcuts\n\t var hash = this._hash;\n\t var H = hash.words;\n\n\t // Swap endian\n\t for (var i = 0; i < 4; i++) {\n\t // Shortcut\n\t var H_i = H[i];\n\n\t H[i] = (((H_i << 8) | (H_i >>> 24)) & 0x00ff00ff) |\n\t (((H_i << 24) | (H_i >>> 8)) & 0xff00ff00);\n\t }\n\n\t // Return final computed hash\n\t return hash;\n\t },\n\n\t clone: function () {\n\t var clone = Hasher.clone.call(this);\n\t clone._hash = this._hash.clone();\n\n\t return clone;\n\t }\n\t });\n\n\t function FF(a, b, c, d, x, s, t) {\n\t var n = a + ((b & c) | (~b & d)) + x + t;\n\t return ((n << s) | (n >>> (32 - s))) + b;\n\t }\n\n\t function GG(a, b, c, d, x, s, t) {\n\t var n = a + ((b & d) | (c & ~d)) + x + t;\n\t return ((n << s) | (n >>> (32 - s))) + b;\n\t }\n\n\t function HH(a, b, c, d, x, s, t) {\n\t var n = a + (b ^ c ^ d) + x + t;\n\t return ((n << s) | (n >>> (32 - s))) + b;\n\t }\n\n\t function II(a, b, c, d, x, s, t) {\n\t var n = a + (c ^ (b | ~d)) + x + t;\n\t return ((n << s) | (n >>> (32 - s))) + b;\n\t }\n\n\t /**\n\t * Shortcut function to the hasher's object interface.\n\t *\n\t * @param {WordArray|string} message The message to hash.\n\t *\n\t * @return {WordArray} The hash.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var hash = CryptoJS.MD5('message');\n\t * var hash = CryptoJS.MD5(wordArray);\n\t */\n\t C.MD5 = Hasher._createHelper(MD5);\n\n\t /**\n\t * Shortcut function to the HMAC's object interface.\n\t *\n\t * @param {WordArray|string} message The message to hash.\n\t * @param {WordArray|string} key The secret key.\n\t *\n\t * @return {WordArray} The HMAC.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var hmac = CryptoJS.HmacMD5(message, key);\n\t */\n\t C.HmacMD5 = Hasher._createHmacHelper(MD5);\n\t}(Math));\n\n\n\treturn CryptoJS.MD5;\n\n}));","(function (global, factory) {\n\ttypeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :\n\ttypeof define === 'function' && define.amd ? define(factory) :\n\t(global.JSON5 = factory());\n}(this, (function () { 'use strict';\n\n\tfunction createCommonjsModule(fn, module) {\n\t\treturn module = { exports: {} }, fn(module, module.exports), module.exports;\n\t}\n\n\tvar _global = createCommonjsModule(function (module) {\n\t// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028\n\tvar global = module.exports = typeof window != 'undefined' && window.Math == Math\n\t ? window : typeof self != 'undefined' && self.Math == Math ? self\n\t // eslint-disable-next-line no-new-func\n\t : Function('return this')();\n\tif (typeof __g == 'number') { __g = global; } // eslint-disable-line no-undef\n\t});\n\n\tvar _core = createCommonjsModule(function (module) {\n\tvar core = module.exports = { version: '2.6.5' };\n\tif (typeof __e == 'number') { __e = core; } // eslint-disable-line no-undef\n\t});\n\tvar _core_1 = _core.version;\n\n\tvar _isObject = function (it) {\n\t return typeof it === 'object' ? it !== null : typeof it === 'function';\n\t};\n\n\tvar _anObject = function (it) {\n\t if (!_isObject(it)) { throw TypeError(it + ' is not an object!'); }\n\t return it;\n\t};\n\n\tvar _fails = function (exec) {\n\t try {\n\t return !!exec();\n\t } catch (e) {\n\t return true;\n\t }\n\t};\n\n\t// Thank's IE8 for his funny defineProperty\n\tvar _descriptors = !_fails(function () {\n\t return Object.defineProperty({}, 'a', { get: function () { return 7; } }).a != 7;\n\t});\n\n\tvar document = _global.document;\n\t// typeof document.createElement is 'object' in old IE\n\tvar is = _isObject(document) && _isObject(document.createElement);\n\tvar _domCreate = function (it) {\n\t return is ? document.createElement(it) : {};\n\t};\n\n\tvar _ie8DomDefine = !_descriptors && !_fails(function () {\n\t return Object.defineProperty(_domCreate('div'), 'a', { get: function () { return 7; } }).a != 7;\n\t});\n\n\t// 7.1.1 ToPrimitive(input [, PreferredType])\n\n\t// instead of the ES6 spec version, we didn't implement @@toPrimitive case\n\t// and the second argument - flag - preferred type is a string\n\tvar _toPrimitive = function (it, S) {\n\t if (!_isObject(it)) { return it; }\n\t var fn, val;\n\t if (S && typeof (fn = it.toString) == 'function' && !_isObject(val = fn.call(it))) { return val; }\n\t if (typeof (fn = it.valueOf) == 'function' && !_isObject(val = fn.call(it))) { return val; }\n\t if (!S && typeof (fn = it.toString) == 'function' && !_isObject(val = fn.call(it))) { return val; }\n\t throw TypeError(\"Can't convert object to primitive value\");\n\t};\n\n\tvar dP = Object.defineProperty;\n\n\tvar f = _descriptors ? Object.defineProperty : function defineProperty(O, P, Attributes) {\n\t _anObject(O);\n\t P = _toPrimitive(P, true);\n\t _anObject(Attributes);\n\t if (_ie8DomDefine) { try {\n\t return dP(O, P, Attributes);\n\t } catch (e) { /* empty */ } }\n\t if ('get' in Attributes || 'set' in Attributes) { throw TypeError('Accessors not supported!'); }\n\t if ('value' in Attributes) { O[P] = Attributes.value; }\n\t return O;\n\t};\n\n\tvar _objectDp = {\n\t\tf: f\n\t};\n\n\tvar _propertyDesc = function (bitmap, value) {\n\t return {\n\t enumerable: !(bitmap & 1),\n\t configurable: !(bitmap & 2),\n\t writable: !(bitmap & 4),\n\t value: value\n\t };\n\t};\n\n\tvar _hide = _descriptors ? function (object, key, value) {\n\t return _objectDp.f(object, key, _propertyDesc(1, value));\n\t} : function (object, key, value) {\n\t object[key] = value;\n\t return object;\n\t};\n\n\tvar hasOwnProperty = {}.hasOwnProperty;\n\tvar _has = function (it, key) {\n\t return hasOwnProperty.call(it, key);\n\t};\n\n\tvar id = 0;\n\tvar px = Math.random();\n\tvar _uid = function (key) {\n\t return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36));\n\t};\n\n\tvar _library = false;\n\n\tvar _shared = createCommonjsModule(function (module) {\n\tvar SHARED = '__core-js_shared__';\n\tvar store = _global[SHARED] || (_global[SHARED] = {});\n\n\t(module.exports = function (key, value) {\n\t return store[key] || (store[key] = value !== undefined ? value : {});\n\t})('versions', []).push({\n\t version: _core.version,\n\t mode: _library ? 'pure' : 'global',\n\t copyright: '© 2019 Denis Pushkarev (zloirock.ru)'\n\t});\n\t});\n\n\tvar _functionToString = _shared('native-function-to-string', Function.toString);\n\n\tvar _redefine = createCommonjsModule(function (module) {\n\tvar SRC = _uid('src');\n\n\tvar TO_STRING = 'toString';\n\tvar TPL = ('' + _functionToString).split(TO_STRING);\n\n\t_core.inspectSource = function (it) {\n\t return _functionToString.call(it);\n\t};\n\n\t(module.exports = function (O, key, val, safe) {\n\t var isFunction = typeof val == 'function';\n\t if (isFunction) { _has(val, 'name') || _hide(val, 'name', key); }\n\t if (O[key] === val) { return; }\n\t if (isFunction) { _has(val, SRC) || _hide(val, SRC, O[key] ? '' + O[key] : TPL.join(String(key))); }\n\t if (O === _global) {\n\t O[key] = val;\n\t } else if (!safe) {\n\t delete O[key];\n\t _hide(O, key, val);\n\t } else if (O[key]) {\n\t O[key] = val;\n\t } else {\n\t _hide(O, key, val);\n\t }\n\t// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative\n\t})(Function.prototype, TO_STRING, function toString() {\n\t return typeof this == 'function' && this[SRC] || _functionToString.call(this);\n\t});\n\t});\n\n\tvar _aFunction = function (it) {\n\t if (typeof it != 'function') { throw TypeError(it + ' is not a function!'); }\n\t return it;\n\t};\n\n\t// optional / simple context binding\n\n\tvar _ctx = function (fn, that, length) {\n\t _aFunction(fn);\n\t if (that === undefined) { return fn; }\n\t switch (length) {\n\t case 1: return function (a) {\n\t return fn.call(that, a);\n\t };\n\t case 2: return function (a, b) {\n\t return fn.call(that, a, b);\n\t };\n\t case 3: return function (a, b, c) {\n\t return fn.call(that, a, b, c);\n\t };\n\t }\n\t return function (/* ...args */) {\n\t return fn.apply(that, arguments);\n\t };\n\t};\n\n\tvar PROTOTYPE = 'prototype';\n\n\tvar $export = function (type, name, source) {\n\t var IS_FORCED = type & $export.F;\n\t var IS_GLOBAL = type & $export.G;\n\t var IS_STATIC = type & $export.S;\n\t var IS_PROTO = type & $export.P;\n\t var IS_BIND = type & $export.B;\n\t var target = IS_GLOBAL ? _global : IS_STATIC ? _global[name] || (_global[name] = {}) : (_global[name] || {})[PROTOTYPE];\n\t var exports = IS_GLOBAL ? _core : _core[name] || (_core[name] = {});\n\t var expProto = exports[PROTOTYPE] || (exports[PROTOTYPE] = {});\n\t var key, own, out, exp;\n\t if (IS_GLOBAL) { source = name; }\n\t for (key in source) {\n\t // contains in native\n\t own = !IS_FORCED && target && target[key] !== undefined;\n\t // export native or passed\n\t out = (own ? target : source)[key];\n\t // bind timers to global for call from export context\n\t exp = IS_BIND && own ? _ctx(out, _global) : IS_PROTO && typeof out == 'function' ? _ctx(Function.call, out) : out;\n\t // extend global\n\t if (target) { _redefine(target, key, out, type & $export.U); }\n\t // export\n\t if (exports[key] != out) { _hide(exports, key, exp); }\n\t if (IS_PROTO && expProto[key] != out) { expProto[key] = out; }\n\t }\n\t};\n\t_global.core = _core;\n\t// type bitmap\n\t$export.F = 1; // forced\n\t$export.G = 2; // global\n\t$export.S = 4; // static\n\t$export.P = 8; // proto\n\t$export.B = 16; // bind\n\t$export.W = 32; // wrap\n\t$export.U = 64; // safe\n\t$export.R = 128; // real proto method for `library`\n\tvar _export = $export;\n\n\t// 7.1.4 ToInteger\n\tvar ceil = Math.ceil;\n\tvar floor = Math.floor;\n\tvar _toInteger = function (it) {\n\t return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it);\n\t};\n\n\t// 7.2.1 RequireObjectCoercible(argument)\n\tvar _defined = function (it) {\n\t if (it == undefined) { throw TypeError(\"Can't call method on \" + it); }\n\t return it;\n\t};\n\n\t// true -> String#at\n\t// false -> String#codePointAt\n\tvar _stringAt = function (TO_STRING) {\n\t return function (that, pos) {\n\t var s = String(_defined(that));\n\t var i = _toInteger(pos);\n\t var l = s.length;\n\t var a, b;\n\t if (i < 0 || i >= l) { return TO_STRING ? '' : undefined; }\n\t a = s.charCodeAt(i);\n\t return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff\n\t ? TO_STRING ? s.charAt(i) : a\n\t : TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;\n\t };\n\t};\n\n\tvar $at = _stringAt(false);\n\t_export(_export.P, 'String', {\n\t // 21.1.3.3 String.prototype.codePointAt(pos)\n\t codePointAt: function codePointAt(pos) {\n\t return $at(this, pos);\n\t }\n\t});\n\n\tvar codePointAt = _core.String.codePointAt;\n\n\tvar max = Math.max;\n\tvar min = Math.min;\n\tvar _toAbsoluteIndex = function (index, length) {\n\t index = _toInteger(index);\n\t return index < 0 ? max(index + length, 0) : min(index, length);\n\t};\n\n\tvar fromCharCode = String.fromCharCode;\n\tvar $fromCodePoint = String.fromCodePoint;\n\n\t// length should be 1, old FF problem\n\t_export(_export.S + _export.F * (!!$fromCodePoint && $fromCodePoint.length != 1), 'String', {\n\t // 21.1.2.2 String.fromCodePoint(...codePoints)\n\t fromCodePoint: function fromCodePoint(x) {\n\t var arguments$1 = arguments;\n\t // eslint-disable-line no-unused-vars\n\t var res = [];\n\t var aLen = arguments.length;\n\t var i = 0;\n\t var code;\n\t while (aLen > i) {\n\t code = +arguments$1[i++];\n\t if (_toAbsoluteIndex(code, 0x10ffff) !== code) { throw RangeError(code + ' is not a valid code point'); }\n\t res.push(code < 0x10000\n\t ? fromCharCode(code)\n\t : fromCharCode(((code -= 0x10000) >> 10) + 0xd800, code % 0x400 + 0xdc00)\n\t );\n\t } return res.join('');\n\t }\n\t});\n\n\tvar fromCodePoint = _core.String.fromCodePoint;\n\n\t// This is a generated file. Do not edit.\n\tvar Space_Separator = /[\\u1680\\u2000-\\u200A\\u202F\\u205F\\u3000]/;\n\tvar ID_Start = /[\\xAA\\xB5\\xBA\\xC0-\\xD6\\xD8-\\xF6\\xF8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u037F\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05D0-\\u05EA\\u05F0-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u0860-\\u086A\\u08A0-\\u08B4\\u08B6-\\u08BD\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u09FC\\u0A05-\\u0A0A\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-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F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081\\u108E\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F5\\u13F8-\\u13FD\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16EE-\\u16F8\\u1700-\\u170C\\u170E-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7\\u17DC\\u1820-\\u1877\\u1880-\\u1884\\u1887-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19B0-\\u19C9\\u1A00-\\u1A16\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4B\\u1B83-\\u1BA0\\u1BAE\\u1BAF\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1C80-\\u1C88\\u1CE9-\\u1CEC\\u1CEE-\\u1CF1\\u1CF5\\u1CF6\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2160-\\u2188\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303C\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312E\\u3131-\\u318E\\u31A0-\\u31BA\\u31F0-\\u31FF\\u3400-\\u4DB5\\u4E00-\\u9FEA\\uA000-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B\\uA640-\\uA66E\\uA67F-\\uA69D\\uA6A0-\\uA6EF\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA7AE\\uA7B0-\\uA7B7\\uA7F7-\\uA801\\uA803-\\uA805\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB\\uA8FD\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uA9E0-\\uA9E4\\uA9E6-\\uA9EF\\uA9FA-\\uA9FE\\uAA00-\\uAA28\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAA60-\\uAA76\\uAA7A\\uAA7E-\\uAAAF\\uAAB1\\uAAB5\\uAAB6\\u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\\uDE51\\uDE52\\uDE54\\uDE57\\uDE59\\uDE5B\\uDE5D\\uDE5F\\uDE61\\uDE62\\uDE64\\uDE67-\\uDE6A\\uDE6C-\\uDE72\\uDE74-\\uDE77\\uDE79-\\uDE7C\\uDE7E\\uDE80-\\uDE89\\uDE8B-\\uDE9B\\uDEA1-\\uDEA3\\uDEA5-\\uDEA9\\uDEAB-\\uDEBB]|\\uD869[\\uDC00-\\uDED6\\uDF00-\\uDFFF]|\\uD86D[\\uDC00-\\uDF34\\uDF40-\\uDFFF]|\\uD86E[\\uDC00-\\uDC1D\\uDC20-\\uDFFF]|\\uD873[\\uDC00-\\uDEA1\\uDEB0-\\uDFFF]|\\uD87A[\\uDC00-\\uDFE0]|\\uD87E[\\uDC00-\\uDE1D]/;\n\tvar ID_Continue = /[\\xAA\\xB5\\xBA\\xC0-\\xD6\\xD8-\\xF6\\xF8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0300-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u037F\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u0483-\\u0487\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u0591-\\u05BD\\u05BF\\u05C1\\u05C2\\u05C4\\u05C5\\u05C7\\u05D0-\\u05EA\\u05F0-\\u05F2\\u0610-\\u061A\\u0620-\\u0669\\u066E-\\u06D3\\u06D5-\\u06DC\\u06DF-\\u06E8\\u06EA-\\u06FC\\u06FF\\u0710-\\u074A\\u074D-\\u07B1\\u07C0-\\u07F5\\u07FA\\u0800-\\u082D\\u0840-\\u085B\\u0860-\\u086A\\u08A0-\\u08B4\\u08B6-\\u08BD\\u08D4-\\u08E1\\u08E3-\\u0963\\u0966-\\u096F\\u0971-\\u0983\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BC-\\u09C4\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12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u135D-\\u135F\\u1380-\\u138F\\u13A0-\\u13F5\\u13F8-\\u13FD\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16EE-\\u16F8\\u1700-\\u170C\\u170E-\\u1714\\u1720-\\u1734\\u1740-\\u1753\\u1760-\\u176C\\u176E-\\u1770\\u1772\\u1773\\u1780-\\u17D3\\u17D7\\u17DC\\u17DD\\u17E0-\\u17E9\\u180B-\\u180D\\u1810-\\u1819\\u1820-\\u1877\\u1880-\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1920-\\u192B\\u1930-\\u193B\\u1946-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19B0-\\u19C9\\u19D0-\\u19D9\\u1A00-\\u1A1B\\u1A20-\\u1A5E\\u1A60-\\u1A7C\\u1A7F-\\u1A89\\u1A90-\\u1A99\\u1AA7\\u1AB0-\\u1ABD\\u1B00-\\u1B4B\\u1B50-\\u1B59\\u1B6B-\\u1B73\\u1B80-\\u1BF3\\u1C00-\\u1C37\\u1C40-\\u1C49\\u1C4D-\\u1C7D\\u1C80-\\u1C88\\u1CD0-\\u1CD2\\u1CD4-\\u1CF9\\u1D00-\\u1DF9\\u1DFB-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u203F\\u2040\\u2054\\u2071\\u207F\\u2090-\\u209C\\u20D0-\\u20DC\\u20E1\\u20E5-\\u20F0\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2160-\\u2188\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2CE4\\u2CEB-\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D7F-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2DE0-\\u2DFF\\u2E2F\\u3005-\\u3007\\u3021-\\u302F\\u3031-\\u3035\\u3038-\\u303C\\u3041-\\u3096\\u3099\\u309A\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312E\\u3131-\\u318E\\u31A0-\\u31BA\\u31F0-\\u31FF\\u3400-\\u4DB5\\u4E00-\\u9FEA\\uA000-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA62B\\uA640-\\uA66F\\uA674-\\uA67D\\uA67F-\\uA6F1\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA7AE\\uA7B0-\\uA7B7\\uA7F7-\\uA827\\uA840-\\uA873\\uA880-\\uA8C5\\uA8D0-\\uA8D9\\uA8E0-\\uA8F7\\uA8FB\\uA8FD\\uA900-\\uA92D\\uA930-\\uA953\\uA960-\\uA97C\\uA980-\\uA9C0\\uA9CF-\\uA9D9\\uA9E0-\\uA9FE\\uAA00-\\uAA36\\uAA40-\\uAA4D\\uAA50-\\uAA59\\uAA60-\\uAA76\\uAA7A-\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEF\\uAAF2-\\uAAF6\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E\\uAB30-\\uAB5A\\uAB5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\uDCFF\\uDE00-\\uDE3E\\uDE47\\uDE50-\\uDE83\\uDE86-\\uDE99\\uDEC0-\\uDEF8]|\\uD807[\\uDC00-\\uDC08\\uDC0A-\\uDC36\\uDC38-\\uDC40\\uDC50-\\uDC59\\uDC72-\\uDC8F\\uDC92-\\uDCA7\\uDCA9-\\uDCB6\\uDD00-\\uDD06\\uDD08\\uDD09\\uDD0B-\\uDD36\\uDD3A\\uDD3C\\uDD3D\\uDD3F-\\uDD47\\uDD50-\\uDD59]|\\uD808[\\uDC00-\\uDF99]|\\uD809[\\uDC00-\\uDC6E\\uDC80-\\uDD43]|[\\uD80C\\uD81C-\\uD820\\uD840-\\uD868\\uD86A-\\uD86C\\uD86F-\\uD872\\uD874-\\uD879][\\uDC00-\\uDFFF]|\\uD80D[\\uDC00-\\uDC2E]|\\uD811[\\uDC00-\\uDE46]|\\uD81A[\\uDC00-\\uDE38\\uDE40-\\uDE5E\\uDE60-\\uDE69\\uDED0-\\uDEED\\uDEF0-\\uDEF4\\uDF00-\\uDF36\\uDF40-\\uDF43\\uDF50-\\uDF59\\uDF63-\\uDF77\\uDF7D-\\uDF8F]|\\uD81B[\\uDF00-\\uDF44\\uDF50-\\uDF7E\\uDF8F-\\uDF9F\\uDFE0\\uDFE1]|\\uD821[\\uDC00-\\uDFEC]|\\uD822[\\uDC00-\\uDEF2]|\\uD82C[\\uDC00-\\uDD1E\\uDD70-\\uDEFB]|\\uD82F[\\uDC00-\\uDC6A\\uDC70-\\uDC7C\\uDC80-\\uDC88\\uDC90-\\uDC99\\uDC9D\\uDC9E]|\\uD834[\\uDD65-\\uDD69\\uDD6D-\\uDD72\\uDD7B-\\uDD82\\uDD85-\\uDD8B\\uDDAA-\\uDDAD\\uDE42-\\uDE44]|\\uD835[\\uDC00-\\uDC54\\uDC56-\\uDC9C\\uDC9E\\uDC9F\\uDCA2\\uDCA5\\uDCA6\\uDCA9-\\uDCAC\\uDCAE-\\uDCB9\\uDCBB\\uDCBD-\\uDCC3\\u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\uDFE0]|\\uD87E[\\uDC00-\\uDE1D]|\\uDB40[\\uDD00-\\uDDEF]/;\n\n\tvar unicode = {\n\t\tSpace_Separator: Space_Separator,\n\t\tID_Start: ID_Start,\n\t\tID_Continue: ID_Continue\n\t};\n\n\tvar util = {\n\t isSpaceSeparator: function isSpaceSeparator (c) {\n\t return typeof c === 'string' && unicode.Space_Separator.test(c)\n\t },\n\n\t isIdStartChar: function isIdStartChar (c) {\n\t return typeof c === 'string' && (\n\t (c >= 'a' && c <= 'z') ||\n\t (c >= 'A' && c <= 'Z') ||\n\t (c === '$') || (c === '_') ||\n\t unicode.ID_Start.test(c)\n\t )\n\t },\n\n\t isIdContinueChar: function isIdContinueChar (c) {\n\t return typeof c === 'string' && (\n\t (c >= 'a' && c <= 'z') ||\n\t (c >= 'A' && c <= 'Z') ||\n\t (c >= '0' && c <= '9') ||\n\t (c === '$') || (c === '_') ||\n\t (c === '\\u200C') || (c === '\\u200D') ||\n\t unicode.ID_Continue.test(c)\n\t )\n\t },\n\n\t isDigit: function isDigit (c) {\n\t return typeof c === 'string' && /[0-9]/.test(c)\n\t },\n\n\t isHexDigit: function isHexDigit (c) {\n\t return typeof c === 'string' && /[0-9A-Fa-f]/.test(c)\n\t },\n\t};\n\n\tvar source;\n\tvar parseState;\n\tvar stack;\n\tvar pos;\n\tvar line;\n\tvar column;\n\tvar token;\n\tvar key;\n\tvar root;\n\n\tvar parse = function parse (text, reviver) {\n\t source = String(text);\n\t parseState = 'start';\n\t stack = [];\n\t pos = 0;\n\t line = 1;\n\t column = 0;\n\t token = undefined;\n\t key = undefined;\n\t root = undefined;\n\n\t do {\n\t token = lex();\n\n\t // This code is unreachable.\n\t // if (!parseStates[parseState]) {\n\t // throw invalidParseState()\n\t // }\n\n\t parseStates[parseState]();\n\t } while (token.type !== 'eof')\n\n\t if (typeof reviver === 'function') {\n\t return internalize({'': root}, '', reviver)\n\t }\n\n\t return root\n\t};\n\n\tfunction internalize (holder, name, reviver) {\n\t var value = holder[name];\n\t if (value != null && typeof value === 'object') {\n\t if (Array.isArray(value)) {\n\t for (var i = 0; i < value.length; i++) {\n\t var key = String(i);\n\t var replacement = internalize(value, key, reviver);\n\t if (replacement === undefined) {\n\t delete value[key];\n\t } else {\n\t Object.defineProperty(value, key, {\n\t value: replacement,\n\t writable: true,\n\t enumerable: true,\n\t configurable: true,\n\t });\n\t }\n\t }\n\t } else {\n\t for (var key$1 in value) {\n\t var replacement$1 = internalize(value, key$1, reviver);\n\t if (replacement$1 === undefined) {\n\t delete value[key$1];\n\t } else {\n\t Object.defineProperty(value, key$1, {\n\t value: replacement$1,\n\t writable: true,\n\t enumerable: true,\n\t configurable: true,\n\t });\n\t }\n\t }\n\t }\n\t }\n\n\t return reviver.call(holder, name, value)\n\t}\n\n\tvar lexState;\n\tvar buffer;\n\tvar doubleQuote;\n\tvar sign;\n\tvar c;\n\n\tfunction lex () {\n\t lexState = 'default';\n\t buffer = '';\n\t doubleQuote = false;\n\t sign = 1;\n\n\t for (;;) {\n\t c = peek();\n\n\t // This code is unreachable.\n\t // if (!lexStates[lexState]) {\n\t // throw invalidLexState(lexState)\n\t // }\n\n\t var token = lexStates[lexState]();\n\t if (token) {\n\t return token\n\t }\n\t }\n\t}\n\n\tfunction peek () {\n\t if (source[pos]) {\n\t return String.fromCodePoint(source.codePointAt(pos))\n\t }\n\t}\n\n\tfunction read () {\n\t var c = peek();\n\n\t if (c === '\\n') {\n\t line++;\n\t column = 0;\n\t } else if (c) {\n\t column += c.length;\n\t } else {\n\t column++;\n\t }\n\n\t if (c) {\n\t pos += c.length;\n\t }\n\n\t return c\n\t}\n\n\tvar lexStates = {\n\t default: function default$1 () {\n\t switch (c) {\n\t case '\\t':\n\t case '\\v':\n\t case '\\f':\n\t case ' ':\n\t case '\\u00A0':\n\t case '\\uFEFF':\n\t case '\\n':\n\t case '\\r':\n\t case '\\u2028':\n\t case '\\u2029':\n\t read();\n\t return\n\n\t case '/':\n\t read();\n\t lexState = 'comment';\n\t return\n\n\t case undefined:\n\t read();\n\t return newToken('eof')\n\t }\n\n\t if (util.isSpaceSeparator(c)) {\n\t read();\n\t return\n\t }\n\n\t // This code is unreachable.\n\t // if (!lexStates[parseState]) {\n\t // throw invalidLexState(parseState)\n\t // }\n\n\t return lexStates[parseState]()\n\t },\n\n\t comment: function comment () {\n\t switch (c) {\n\t case '*':\n\t read();\n\t lexState = 'multiLineComment';\n\t return\n\n\t case '/':\n\t read();\n\t lexState = 'singleLineComment';\n\t return\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t multiLineComment: function multiLineComment () {\n\t switch (c) {\n\t case '*':\n\t read();\n\t lexState = 'multiLineCommentAsterisk';\n\t return\n\n\t case undefined:\n\t throw invalidChar(read())\n\t }\n\n\t read();\n\t },\n\n\t multiLineCommentAsterisk: function multiLineCommentAsterisk () {\n\t switch (c) {\n\t case '*':\n\t read();\n\t return\n\n\t case '/':\n\t read();\n\t lexState = 'default';\n\t return\n\n\t case undefined:\n\t throw invalidChar(read())\n\t }\n\n\t read();\n\t lexState = 'multiLineComment';\n\t },\n\n\t singleLineComment: function singleLineComment () {\n\t switch (c) {\n\t case '\\n':\n\t case '\\r':\n\t case '\\u2028':\n\t case '\\u2029':\n\t read();\n\t lexState = 'default';\n\t return\n\n\t case undefined:\n\t read();\n\t return newToken('eof')\n\t }\n\n\t read();\n\t },\n\n\t value: function value () {\n\t switch (c) {\n\t case '{':\n\t case '[':\n\t return newToken('punctuator', read())\n\n\t case 'n':\n\t read();\n\t literal('ull');\n\t return newToken('null', null)\n\n\t case 't':\n\t read();\n\t literal('rue');\n\t return newToken('boolean', true)\n\n\t case 'f':\n\t read();\n\t literal('alse');\n\t return newToken('boolean', false)\n\n\t case '-':\n\t case '+':\n\t if (read() === '-') {\n\t sign = -1;\n\t }\n\n\t lexState = 'sign';\n\t return\n\n\t case '.':\n\t buffer = read();\n\t lexState = 'decimalPointLeading';\n\t return\n\n\t case '0':\n\t buffer = read();\n\t lexState = 'zero';\n\t return\n\n\t case '1':\n\t case '2':\n\t case '3':\n\t case '4':\n\t case '5':\n\t case '6':\n\t case '7':\n\t case '8':\n\t case '9':\n\t buffer = read();\n\t lexState = 'decimalInteger';\n\t return\n\n\t case 'I':\n\t read();\n\t literal('nfinity');\n\t return newToken('numeric', Infinity)\n\n\t case 'N':\n\t read();\n\t literal('aN');\n\t return newToken('numeric', NaN)\n\n\t case '\"':\n\t case \"'\":\n\t doubleQuote = (read() === '\"');\n\t buffer = '';\n\t lexState = 'string';\n\t return\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t identifierNameStartEscape: function identifierNameStartEscape () {\n\t if (c !== 'u') {\n\t throw invalidChar(read())\n\t }\n\n\t read();\n\t var u = unicodeEscape();\n\t switch (u) {\n\t case '$':\n\t case '_':\n\t break\n\n\t default:\n\t if (!util.isIdStartChar(u)) {\n\t throw invalidIdentifier()\n\t }\n\n\t break\n\t }\n\n\t buffer += u;\n\t lexState = 'identifierName';\n\t },\n\n\t identifierName: function identifierName () {\n\t switch (c) {\n\t case '$':\n\t case '_':\n\t case '\\u200C':\n\t case '\\u200D':\n\t buffer += read();\n\t return\n\n\t case '\\\\':\n\t read();\n\t lexState = 'identifierNameEscape';\n\t return\n\t }\n\n\t if (util.isIdContinueChar(c)) {\n\t buffer += read();\n\t return\n\t }\n\n\t return newToken('identifier', buffer)\n\t },\n\n\t identifierNameEscape: function identifierNameEscape () {\n\t if (c !== 'u') {\n\t throw invalidChar(read())\n\t }\n\n\t read();\n\t var u = unicodeEscape();\n\t switch (u) {\n\t case '$':\n\t case '_':\n\t case '\\u200C':\n\t case '\\u200D':\n\t break\n\n\t default:\n\t if (!util.isIdContinueChar(u)) {\n\t throw invalidIdentifier()\n\t }\n\n\t break\n\t }\n\n\t buffer += u;\n\t lexState = 'identifierName';\n\t },\n\n\t sign: function sign$1 () {\n\t switch (c) {\n\t case '.':\n\t buffer = read();\n\t lexState = 'decimalPointLeading';\n\t return\n\n\t case '0':\n\t buffer = read();\n\t lexState = 'zero';\n\t return\n\n\t case '1':\n\t case '2':\n\t case '3':\n\t case '4':\n\t case '5':\n\t case '6':\n\t case '7':\n\t case '8':\n\t case '9':\n\t buffer = read();\n\t lexState = 'decimalInteger';\n\t return\n\n\t case 'I':\n\t read();\n\t literal('nfinity');\n\t return newToken('numeric', sign * Infinity)\n\n\t case 'N':\n\t read();\n\t literal('aN');\n\t return newToken('numeric', NaN)\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t zero: function zero () {\n\t switch (c) {\n\t case '.':\n\t buffer += read();\n\t lexState = 'decimalPoint';\n\t return\n\n\t case 'e':\n\t case 'E':\n\t buffer += read();\n\t lexState = 'decimalExponent';\n\t return\n\n\t case 'x':\n\t case 'X':\n\t buffer += read();\n\t lexState = 'hexadecimal';\n\t return\n\t }\n\n\t return newToken('numeric', sign * 0)\n\t },\n\n\t decimalInteger: function decimalInteger () {\n\t switch (c) {\n\t case '.':\n\t buffer += read();\n\t lexState = 'decimalPoint';\n\t return\n\n\t case 'e':\n\t case 'E':\n\t buffer += read();\n\t lexState = 'decimalExponent';\n\t return\n\t }\n\n\t if (util.isDigit(c)) {\n\t buffer += read();\n\t return\n\t }\n\n\t return newToken('numeric', sign * Number(buffer))\n\t },\n\n\t decimalPointLeading: function decimalPointLeading () {\n\t if (util.isDigit(c)) {\n\t buffer += read();\n\t lexState = 'decimalFraction';\n\t return\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t decimalPoint: function decimalPoint () {\n\t switch (c) {\n\t case 'e':\n\t case 'E':\n\t buffer += read();\n\t lexState = 'decimalExponent';\n\t return\n\t }\n\n\t if (util.isDigit(c)) {\n\t buffer += read();\n\t lexState = 'decimalFraction';\n\t return\n\t }\n\n\t return newToken('numeric', sign * Number(buffer))\n\t },\n\n\t decimalFraction: function decimalFraction () {\n\t switch (c) {\n\t case 'e':\n\t case 'E':\n\t buffer += read();\n\t lexState = 'decimalExponent';\n\t return\n\t }\n\n\t if (util.isDigit(c)) {\n\t buffer += read();\n\t return\n\t }\n\n\t return newToken('numeric', sign * Number(buffer))\n\t },\n\n\t decimalExponent: function decimalExponent () {\n\t switch (c) {\n\t case '+':\n\t case '-':\n\t buffer += read();\n\t lexState = 'decimalExponentSign';\n\t return\n\t }\n\n\t if (util.isDigit(c)) {\n\t buffer += read();\n\t lexState = 'decimalExponentInteger';\n\t return\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t decimalExponentSign: function decimalExponentSign () {\n\t if (util.isDigit(c)) {\n\t buffer += read();\n\t lexState = 'decimalExponentInteger';\n\t return\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t decimalExponentInteger: function decimalExponentInteger () {\n\t if (util.isDigit(c)) {\n\t buffer += read();\n\t return\n\t }\n\n\t return newToken('numeric', sign * Number(buffer))\n\t },\n\n\t hexadecimal: function hexadecimal () {\n\t if (util.isHexDigit(c)) {\n\t buffer += read();\n\t lexState = 'hexadecimalInteger';\n\t return\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t hexadecimalInteger: function hexadecimalInteger () {\n\t if (util.isHexDigit(c)) {\n\t buffer += read();\n\t return\n\t }\n\n\t return newToken('numeric', sign * Number(buffer))\n\t },\n\n\t string: function string () {\n\t switch (c) {\n\t case '\\\\':\n\t read();\n\t buffer += escape();\n\t return\n\n\t case '\"':\n\t if (doubleQuote) {\n\t read();\n\t return newToken('string', buffer)\n\t }\n\n\t buffer += read();\n\t return\n\n\t case \"'\":\n\t if (!doubleQuote) {\n\t read();\n\t return newToken('string', buffer)\n\t }\n\n\t buffer += read();\n\t return\n\n\t case '\\n':\n\t case '\\r':\n\t throw invalidChar(read())\n\n\t case '\\u2028':\n\t case '\\u2029':\n\t separatorChar(c);\n\t break\n\n\t case undefined:\n\t throw invalidChar(read())\n\t }\n\n\t buffer += read();\n\t },\n\n\t start: function start () {\n\t switch (c) {\n\t case '{':\n\t case '[':\n\t return newToken('punctuator', read())\n\n\t // This code is unreachable since the default lexState handles eof.\n\t // case undefined:\n\t // return newToken('eof')\n\t }\n\n\t lexState = 'value';\n\t },\n\n\t beforePropertyName: function beforePropertyName () {\n\t switch (c) {\n\t case '$':\n\t case '_':\n\t buffer = read();\n\t lexState = 'identifierName';\n\t return\n\n\t case '\\\\':\n\t read();\n\t lexState = 'identifierNameStartEscape';\n\t return\n\n\t case '}':\n\t return newToken('punctuator', read())\n\n\t case '\"':\n\t case \"'\":\n\t doubleQuote = (read() === '\"');\n\t lexState = 'string';\n\t return\n\t }\n\n\t if (util.isIdStartChar(c)) {\n\t buffer += read();\n\t lexState = 'identifierName';\n\t return\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t afterPropertyName: function afterPropertyName () {\n\t if (c === ':') {\n\t return newToken('punctuator', read())\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t beforePropertyValue: function beforePropertyValue () {\n\t lexState = 'value';\n\t },\n\n\t afterPropertyValue: function afterPropertyValue () {\n\t switch (c) {\n\t case ',':\n\t case '}':\n\t return newToken('punctuator', read())\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t beforeArrayValue: function beforeArrayValue () {\n\t if (c === ']') {\n\t return newToken('punctuator', read())\n\t }\n\n\t lexState = 'value';\n\t },\n\n\t afterArrayValue: function afterArrayValue () {\n\t switch (c) {\n\t case ',':\n\t case ']':\n\t return newToken('punctuator', read())\n\t }\n\n\t throw invalidChar(read())\n\t },\n\n\t end: function end () {\n\t // This code is unreachable since it's handled by the default lexState.\n\t // if (c === undefined) {\n\t // read()\n\t // return newToken('eof')\n\t // }\n\n\t throw invalidChar(read())\n\t },\n\t};\n\n\tfunction newToken (type, value) {\n\t return {\n\t type: type,\n\t value: value,\n\t line: line,\n\t column: column,\n\t }\n\t}\n\n\tfunction literal (s) {\n\t for (var i = 0, list = s; i < list.length; i += 1) {\n\t var c = list[i];\n\n\t var p = peek();\n\n\t if (p !== c) {\n\t throw invalidChar(read())\n\t }\n\n\t read();\n\t }\n\t}\n\n\tfunction escape () {\n\t var c = peek();\n\t switch (c) {\n\t case 'b':\n\t read();\n\t return '\\b'\n\n\t case 'f':\n\t read();\n\t return '\\f'\n\n\t case 'n':\n\t read();\n\t return '\\n'\n\n\t case 'r':\n\t read();\n\t return '\\r'\n\n\t case 't':\n\t read();\n\t return '\\t'\n\n\t case 'v':\n\t read();\n\t return '\\v'\n\n\t case '0':\n\t read();\n\t if (util.isDigit(peek())) {\n\t throw invalidChar(read())\n\t }\n\n\t return '\\0'\n\n\t case 'x':\n\t read();\n\t return hexEscape()\n\n\t case 'u':\n\t read();\n\t return unicodeEscape()\n\n\t case '\\n':\n\t case '\\u2028':\n\t case '\\u2029':\n\t read();\n\t return ''\n\n\t case '\\r':\n\t read();\n\t if (peek() === '\\n') {\n\t read();\n\t }\n\n\t return ''\n\n\t case '1':\n\t case '2':\n\t case '3':\n\t case '4':\n\t case '5':\n\t case '6':\n\t case '7':\n\t case '8':\n\t case '9':\n\t throw invalidChar(read())\n\n\t case undefined:\n\t throw invalidChar(read())\n\t }\n\n\t return read()\n\t}\n\n\tfunction hexEscape () {\n\t var buffer = '';\n\t var c = peek();\n\n\t if (!util.isHexDigit(c)) {\n\t throw invalidChar(read())\n\t }\n\n\t buffer += read();\n\n\t c = peek();\n\t if (!util.isHexDigit(c)) {\n\t throw invalidChar(read())\n\t }\n\n\t buffer += read();\n\n\t return String.fromCodePoint(parseInt(buffer, 16))\n\t}\n\n\tfunction unicodeEscape () {\n\t var buffer = '';\n\t var count = 4;\n\n\t while (count-- > 0) {\n\t var c = peek();\n\t if (!util.isHexDigit(c)) {\n\t throw invalidChar(read())\n\t }\n\n\t buffer += read();\n\t }\n\n\t return String.fromCodePoint(parseInt(buffer, 16))\n\t}\n\n\tvar parseStates = {\n\t start: function start () {\n\t if (token.type === 'eof') {\n\t throw invalidEOF()\n\t }\n\n\t push();\n\t },\n\n\t beforePropertyName: function beforePropertyName () {\n\t switch (token.type) {\n\t case 'identifier':\n\t case 'string':\n\t key = token.value;\n\t parseState = 'afterPropertyName';\n\t return\n\n\t case 'punctuator':\n\t // This code is unreachable since it's handled by the lexState.\n\t // if (token.value !== '}') {\n\t // throw invalidToken()\n\t // }\n\n\t pop();\n\t return\n\n\t case 'eof':\n\t throw invalidEOF()\n\t }\n\n\t // This code is unreachable since it's handled by the lexState.\n\t // throw invalidToken()\n\t },\n\n\t afterPropertyName: function afterPropertyName () {\n\t // This code is unreachable since it's handled by the lexState.\n\t // if (token.type !== 'punctuator' || token.value !== ':') {\n\t // throw invalidToken()\n\t // }\n\n\t if (token.type === 'eof') {\n\t throw invalidEOF()\n\t }\n\n\t parseState = 'beforePropertyValue';\n\t },\n\n\t beforePropertyValue: function beforePropertyValue () {\n\t if (token.type === 'eof') {\n\t throw invalidEOF()\n\t }\n\n\t push();\n\t },\n\n\t beforeArrayValue: function beforeArrayValue () {\n\t if (token.type === 'eof') {\n\t throw invalidEOF()\n\t }\n\n\t if (token.type === 'punctuator' && token.value === ']') {\n\t pop();\n\t return\n\t }\n\n\t push();\n\t },\n\n\t afterPropertyValue: function afterPropertyValue () {\n\t // This code is unreachable since it's handled by the lexState.\n\t // if (token.type !== 'punctuator') {\n\t // throw invalidToken()\n\t // }\n\n\t if (token.type === 'eof') {\n\t throw invalidEOF()\n\t }\n\n\t switch (token.value) {\n\t case ',':\n\t parseState = 'beforePropertyName';\n\t return\n\n\t case '}':\n\t pop();\n\t }\n\n\t // This code is unreachable since it's handled by the lexState.\n\t // throw invalidToken()\n\t },\n\n\t afterArrayValue: function afterArrayValue () {\n\t // This code is unreachable since it's handled by the lexState.\n\t // if (token.type !== 'punctuator') {\n\t // throw invalidToken()\n\t // }\n\n\t if (token.type === 'eof') {\n\t throw invalidEOF()\n\t }\n\n\t switch (token.value) {\n\t case ',':\n\t parseState = 'beforeArrayValue';\n\t return\n\n\t case ']':\n\t pop();\n\t }\n\n\t // This code is unreachable since it's handled by the lexState.\n\t // throw invalidToken()\n\t },\n\n\t end: function end () {\n\t // This code is unreachable since it's handled by the lexState.\n\t // if (token.type !== 'eof') {\n\t // throw invalidToken()\n\t // }\n\t },\n\t};\n\n\tfunction push () {\n\t var value;\n\n\t switch (token.type) {\n\t case 'punctuator':\n\t switch (token.value) {\n\t case '{':\n\t value = {};\n\t break\n\n\t case '[':\n\t value = [];\n\t break\n\t }\n\n\t break\n\n\t case 'null':\n\t case 'boolean':\n\t case 'numeric':\n\t case 'string':\n\t value = token.value;\n\t break\n\n\t // This code is unreachable.\n\t // default:\n\t // throw invalidToken()\n\t }\n\n\t if (root === undefined) {\n\t root = value;\n\t } else {\n\t var parent = stack[stack.length - 1];\n\t if (Array.isArray(parent)) {\n\t parent.push(value);\n\t } else {\n\t Object.defineProperty(parent, key, {\n\t value: value,\n\t writable: true,\n\t enumerable: true,\n\t configurable: true,\n\t });\n\t }\n\t }\n\n\t if (value !== null && typeof value === 'object') {\n\t stack.push(value);\n\n\t if (Array.isArray(value)) {\n\t parseState = 'beforeArrayValue';\n\t } else {\n\t parseState = 'beforePropertyName';\n\t }\n\t } else {\n\t var current = stack[stack.length - 1];\n\t if (current == null) {\n\t parseState = 'end';\n\t } else if (Array.isArray(current)) {\n\t parseState = 'afterArrayValue';\n\t } else {\n\t parseState = 'afterPropertyValue';\n\t }\n\t }\n\t}\n\n\tfunction pop () {\n\t stack.pop();\n\n\t var current = stack[stack.length - 1];\n\t if (current == null) {\n\t parseState = 'end';\n\t } else if (Array.isArray(current)) {\n\t parseState = 'afterArrayValue';\n\t } else {\n\t parseState = 'afterPropertyValue';\n\t }\n\t}\n\n\t// This code is unreachable.\n\t// function invalidParseState () {\n\t// return new Error(`JSON5: invalid parse state '${parseState}'`)\n\t// }\n\n\t// This code is unreachable.\n\t// function invalidLexState (state) {\n\t// return new Error(`JSON5: invalid lex state '${state}'`)\n\t// }\n\n\tfunction invalidChar (c) {\n\t if (c === undefined) {\n\t return syntaxError((\"JSON5: invalid end of input at \" + line + \":\" + column))\n\t }\n\n\t return syntaxError((\"JSON5: invalid character '\" + (formatChar(c)) + \"' at \" + line + \":\" + column))\n\t}\n\n\tfunction invalidEOF () {\n\t return syntaxError((\"JSON5: invalid end of input at \" + line + \":\" + column))\n\t}\n\n\t// This code is unreachable.\n\t// function invalidToken () {\n\t// if (token.type === 'eof') {\n\t// return syntaxError(`JSON5: invalid end of input at ${line}:${column}`)\n\t// }\n\n\t// const c = String.fromCodePoint(token.value.codePointAt(0))\n\t// return syntaxError(`JSON5: invalid character '${formatChar(c)}' at ${line}:${column}`)\n\t// }\n\n\tfunction invalidIdentifier () {\n\t column -= 5;\n\t return syntaxError((\"JSON5: invalid identifier character at \" + line + \":\" + column))\n\t}\n\n\tfunction separatorChar (c) {\n\t console.warn((\"JSON5: '\" + (formatChar(c)) + \"' in strings is not valid ECMAScript; consider escaping\"));\n\t}\n\n\tfunction formatChar (c) {\n\t var replacements = {\n\t \"'\": \"\\\\'\",\n\t '\"': '\\\\\"',\n\t '\\\\': '\\\\\\\\',\n\t '\\b': '\\\\b',\n\t '\\f': '\\\\f',\n\t '\\n': '\\\\n',\n\t '\\r': '\\\\r',\n\t '\\t': '\\\\t',\n\t '\\v': '\\\\v',\n\t '\\0': '\\\\0',\n\t '\\u2028': '\\\\u2028',\n\t '\\u2029': '\\\\u2029',\n\t };\n\n\t if (replacements[c]) {\n\t return replacements[c]\n\t }\n\n\t if (c < ' ') {\n\t var hexString = c.charCodeAt(0).toString(16);\n\t return '\\\\x' + ('00' + hexString).substring(hexString.length)\n\t }\n\n\t return c\n\t}\n\n\tfunction syntaxError (message) {\n\t var err = new SyntaxError(message);\n\t err.lineNumber = line;\n\t err.columnNumber = column;\n\t return err\n\t}\n\n\tvar stringify = function stringify (value, replacer, space) {\n\t var stack = [];\n\t var indent = '';\n\t var propertyList;\n\t var replacerFunc;\n\t var gap = '';\n\t var quote;\n\n\t if (\n\t replacer != null &&\n\t typeof replacer === 'object' &&\n\t !Array.isArray(replacer)\n\t ) {\n\t space = replacer.space;\n\t quote = replacer.quote;\n\t replacer = replacer.replacer;\n\t }\n\n\t if (typeof replacer === 'function') {\n\t replacerFunc = replacer;\n\t } else if (Array.isArray(replacer)) {\n\t propertyList = [];\n\t for (var i = 0, list = replacer; i < list.length; i += 1) {\n\t var v = list[i];\n\n\t var item = (void 0);\n\n\t if (typeof v === 'string') {\n\t item = v;\n\t } else if (\n\t typeof v === 'number' ||\n\t v instanceof String ||\n\t v instanceof Number\n\t ) {\n\t item = String(v);\n\t }\n\n\t if (item !== undefined && propertyList.indexOf(item) < 0) {\n\t propertyList.push(item);\n\t }\n\t }\n\t }\n\n\t if (space instanceof Number) {\n\t space = Number(space);\n\t } else if (space instanceof String) {\n\t space = String(space);\n\t }\n\n\t if (typeof space === 'number') {\n\t if (space > 0) {\n\t space = Math.min(10, Math.floor(space));\n\t gap = ' '.substr(0, space);\n\t }\n\t } else if (typeof space === 'string') {\n\t gap = space.substr(0, 10);\n\t }\n\n\t return serializeProperty('', {'': value})\n\n\t function serializeProperty (key, holder) {\n\t var value = holder[key];\n\t if (value != null) {\n\t if (typeof value.toJSON5 === 'function') {\n\t value = value.toJSON5(key);\n\t } else if (typeof value.toJSON === 'function') {\n\t value = value.toJSON(key);\n\t }\n\t }\n\n\t if (replacerFunc) {\n\t value = replacerFunc.call(holder, key, value);\n\t }\n\n\t if (value instanceof Number) {\n\t value = Number(value);\n\t } else if (value instanceof String) {\n\t value = String(value);\n\t } else if (value instanceof Boolean) {\n\t value = value.valueOf();\n\t }\n\n\t switch (value) {\n\t case null: return 'null'\n\t case true: return 'true'\n\t case false: return 'false'\n\t }\n\n\t if (typeof value === 'string') {\n\t return quoteString(value, false)\n\t }\n\n\t if (typeof value === 'number') {\n\t return String(value)\n\t }\n\n\t if (typeof value === 'object') {\n\t return Array.isArray(value) ? serializeArray(value) : serializeObject(value)\n\t }\n\n\t return undefined\n\t }\n\n\t function quoteString (value) {\n\t var quotes = {\n\t \"'\": 0.1,\n\t '\"': 0.2,\n\t };\n\n\t var replacements = {\n\t \"'\": \"\\\\'\",\n\t '\"': '\\\\\"',\n\t '\\\\': '\\\\\\\\',\n\t '\\b': '\\\\b',\n\t '\\f': '\\\\f',\n\t '\\n': '\\\\n',\n\t '\\r': '\\\\r',\n\t '\\t': '\\\\t',\n\t '\\v': '\\\\v',\n\t '\\0': '\\\\0',\n\t '\\u2028': '\\\\u2028',\n\t '\\u2029': '\\\\u2029',\n\t };\n\n\t var product = '';\n\n\t for (var i = 0; i < value.length; i++) {\n\t var c = value[i];\n\t switch (c) {\n\t case \"'\":\n\t case '\"':\n\t quotes[c]++;\n\t product += c;\n\t continue\n\n\t case '\\0':\n\t if (util.isDigit(value[i + 1])) {\n\t product += '\\\\x00';\n\t continue\n\t }\n\t }\n\n\t if (replacements[c]) {\n\t product += replacements[c];\n\t continue\n\t }\n\n\t if (c < ' ') {\n\t var hexString = c.charCodeAt(0).toString(16);\n\t product += '\\\\x' + ('00' + hexString).substring(hexString.length);\n\t continue\n\t }\n\n\t product += c;\n\t }\n\n\t var quoteChar = quote || Object.keys(quotes).reduce(function (a, b) { return (quotes[a] < quotes[b]) ? a : b; });\n\n\t product = product.replace(new RegExp(quoteChar, 'g'), replacements[quoteChar]);\n\n\t return quoteChar + product + quoteChar\n\t }\n\n\t function serializeObject (value) {\n\t if (stack.indexOf(value) >= 0) {\n\t throw TypeError('Converting circular structure to JSON5')\n\t }\n\n\t stack.push(value);\n\n\t var stepback = indent;\n\t indent = indent + gap;\n\n\t var keys = propertyList || Object.keys(value);\n\t var partial = [];\n\t for (var i = 0, list = keys; i < list.length; i += 1) {\n\t var key = list[i];\n\n\t var propertyString = serializeProperty(key, value);\n\t if (propertyString !== undefined) {\n\t var member = serializeKey(key) + ':';\n\t if (gap !== '') {\n\t member += ' ';\n\t }\n\t member += propertyString;\n\t partial.push(member);\n\t }\n\t }\n\n\t var final;\n\t if (partial.length === 0) {\n\t final = '{}';\n\t } else {\n\t var properties;\n\t if (gap === '') {\n\t properties = partial.join(',');\n\t final = '{' + properties + '}';\n\t } else {\n\t var separator = ',\\n' + indent;\n\t properties = partial.join(separator);\n\t final = '{\\n' + indent + properties + ',\\n' + stepback + '}';\n\t }\n\t }\n\n\t stack.pop();\n\t indent = stepback;\n\t return final\n\t }\n\n\t function serializeKey (key) {\n\t if (key.length === 0) {\n\t return quoteString(key, true)\n\t }\n\n\t var firstChar = String.fromCodePoint(key.codePointAt(0));\n\t if (!util.isIdStartChar(firstChar)) {\n\t return quoteString(key, true)\n\t }\n\n\t for (var i = firstChar.length; i < key.length; i++) {\n\t if (!util.isIdContinueChar(String.fromCodePoint(key.codePointAt(i)))) {\n\t return quoteString(key, true)\n\t }\n\t }\n\n\t return key\n\t }\n\n\t function serializeArray (value) {\n\t if (stack.indexOf(value) >= 0) {\n\t throw TypeError('Converting circular structure to JSON5')\n\t }\n\n\t stack.push(value);\n\n\t var stepback = indent;\n\t indent = indent + gap;\n\n\t var partial = [];\n\t for (var i = 0; i < value.length; i++) {\n\t var propertyString = serializeProperty(String(i), value);\n\t partial.push((propertyString !== undefined) ? propertyString : 'null');\n\t }\n\n\t var final;\n\t if (partial.length === 0) {\n\t final = '[]';\n\t } else {\n\t if (gap === '') {\n\t var properties = partial.join(',');\n\t final = '[' + properties + ']';\n\t } else {\n\t var separator = ',\\n' + indent;\n\t var properties$1 = partial.join(separator);\n\t final = '[\\n' + indent + properties$1 + ',\\n' + stepback + ']';\n\t }\n\t }\n\n\t stack.pop();\n\t indent = stepback;\n\t return final\n\t }\n\t};\n\n\tvar JSON5 = {\n\t parse: parse,\n\t stringify: stringify,\n\t};\n\n\tvar lib = JSON5;\n\n\tvar es5 = lib;\n\n\treturn es5;\n\n})));\n"],"names":["DEFAULT_SM_SIZE","isObject","it","props","data","value","LIKE_SELECT","dataStr","attr","part","text","noTranslation","strText","confirm","icon","isOk","callback","iconSettings","newValue","resolve","mayBePromise","e","cb","z","dep","val","changed","_newValue","newValue_","_attr","i","func","defaultValue","arrayIndex","globalData","fun","customObj","instanceObj","schema","error","disabled","hidden","_error","_disabled","_defaultValue","link","str","_match","p1","pattern","patternStr","isError","item","renderedItem","ConfigGeneric","styles","theme","ConfigAccordion","index","cloned","mayByPromise","newItem","accumulator","currentValue","idx","schemaItem","valueChange","newObj","newIndex","_e","expanded","ConfigAlive","instance","state","ConfigAutocomplete","selectOptions","options","_item","option","params","filtered","_","ConfigAutocompleteSendTo","list","localContext","ConfigCRON","showDialog","value_","ConfigCertificateSelect","el","name","item_","ConfigCertificates","certificates","certsPublicOptions","certsPrivateOptions","certsChainOptions","collectionsOptions","collectionsOptionsObj","leCollection","certPublic","certPrivate","certChained","itemCertPublic","itemCertPrivate","itemCertChained","ConfigCertCollection","ConfigCheckLicense","content","license","pre","key","obj","key1","token","base64","jsonPayload","c","version","rule","invoice","adapterName","result","major","licenses","errors","useLicense","now","uuid","uuidObj","aObj","validTill","parts","validName","validUuid","validVersion","controller","timeout","response","data_","showLicenseData","isYes","secondRun","li","ConfigCheckbox","isIndeterminate","variantComponent","FilledInput","light","bottomLineColor","keyCodes","defaultChipRenderer","isFocused","isDisabled","isReadOnly","handleClick","handleDelete","style","blue","ChipInput","event","addChipOptions","numChipsBefore","numChipsAfter","focusedChip","chips","ref","newState","chip","additionalUpdates","alwaysShowPlaceholder","chipRenderer","className","disableUnderline","FormHelperTextProps","fullWidth","fullWidthInput","helperText","id","InputProps","InputLabelProps","inputValue","label","placeholder","readOnly","required","rootRef","margin","variant","actualInputValue","hasInput","shrinkFloatingLabel","chipComponents","InputMore","InputComponent","ConfigChip","a","_chip","ConfigColor","color","textColor","ConfigCoordinates","position","useSystem","longitude","latitude","getOrLoadRemote","remote","shareScope","remoteFallbackUrl","reject","existingRemote","onload","d","script","loadComponent","sharedScope","module","url","uniqueName","fileToLoad","componentNameParts","componentName","setPromise","i18nPromise","pos","i18nURL","lang","file","json","err","component","keys","CustomComponent","ConfigCustom","ConfigDatePicker","ConfigDeviceManager","DeviceManager","IMAGE_EXT","AUDIO_EXT","VIDEO_EXT","DOC_EXT","JS_EXT","ConfigFileSelector","files","folderName","filter","dirFiles","f","ok","pos_","folder","acceptedFiles","reader","maxSize","ext","byte","deleteFile","binaryString","len","bytes","oContext","buf","buffer","source","folders","buttons","play","element","accept","last","getRootProps","getInputProps","ConfigFile","adapter","path","extension","_value","ConfigFunc","enums","ConfigIP","ips","ConfigImageSendTo","image","ConfigImageUpload","exist","update","res","blob","ConfigInstanceSelect","_id","b","instances","ConfigInterface","interfaces","inter","_ip","ip","toggleTranslation","title","help","maxWidth","progress","applyDisabled","applyButton","onClose","children","titleButtonApply","titleButtonClose","onApply","textInput","overflowHidden","setValue","Icon","Editor","ConfigJsonEditor","jsonError","showSelectId","LANGUAGES","ConfigLanguage","languages","systemConfig","ConfigLicense","reason","ConfigNumber","autoCompleteOptions","arr","ConfigObjectId","socket","PASSWORD_PLACEHOLDER","ConfigPassword","password","repeatPassword","_notEqual","passwordRepeat","ConfigPattern","ConfigPort","ownId","ownHostname","ports","port","min","max","warning","num","maybePromise","ConfigRoom","ConfigSelect","groupItem","ConfigSelectSendTo","v","ip2int","ipInt","octet","findNetworkAddressOfHost","localIp","networkInterfaces","hostIp","ConfigSendto","hostname","adminInstance","hostObj","_origin","_originIp","arg","ConfigSetState","ConfigSlider","unit","marks","getIconByName","valueBlinkOnce","ConfigState","controlType","step","fontSize","divStyle","blinkStyle","labelIcon","labelControl","iconFalse","textFalse","iconTrue","textTrue","ConfigStaticDivider","ConfigStaticHeader","ConfigStaticImage","src","force","valueBlink","ConfigStaticInfo","valueTxt","multiLine","valStyle","style1","style2","copyButton","boxStyle","onLink","href","target","instanceId","_target","_url","ConfigStaticText","MAX_SIZE","objectToArray","object","nameOfFirstAttr","nameOfSecondAttr","array","arrayToObject","row","encrypt","secret","decrypt","ConfigTable","property","orderCheck","order","orderBy","newOrder","comparator","stabilizedThis","order_","updateVisible","_updateVisible","objValue","clear","visibleValue","valueInputRef","attrItem","schemaForAttribute","uniqueCol","allVals","entry","filterValue","buttonsWidth","doAnyFilterSet","headCell","filterOn","lines","line","header","it2","values","p","tdStyle","ConfigText","time","actionButton","actionButtonStyle","helper","ConfigTextSendTo","_data","ConfigTimePicker","shortFormat","strValue","convertID2Topic","namespace","topic","ConfigTopic","ConfigUUID","ConfigUser","users","_users","user","ConfigQrCode","QRCodeComponent","components","ConfigPanel","items","type","ItemComponent","schemaStyle","ConfigTabs","hash","tabS","tabN","tab","withIcons","JsonConfigComponent","commandRunning","attrOrData","saveConfig","i18n","exists","fileName","jsonFile","jsonStr","_list","attrs","depObj","forceUpdate","decryptLegacy","encryptLegacy","textParts","_key","iv","cipherParams","decryptedBinary","_iv","encrypted","loadScript","JsonConfig","evt","r","contents","size","langFileName","input","filePaths","k","_filePaths","binary","e1","dataAttr","table","tItem","dataVal","doSave","close","doNotSaveAttributes","encryptedObj","nativeWithNonSaved","_prevProps","prevState","saveConfigDialog","t","n","s","o","u","l","h","m","g","y","w","E","root","factory","exports","CryptoJS","Math","undefined","crypto","cryptoSecureRandomInt","create","F","subtype","C","C_lib","Base","overrides","properties","propertyName","WordArray","words","sigBytes","encoder","Hex","wordArray","thisWords","thatWords","thisSigBytes","thatSigBytes","thatByte","j","clone","nBytes","C_enc","hexChars","bite","hexStr","hexStrLength","Latin1","latin1Chars","latin1Str","latin1StrLength","Utf8","utf8Str","BufferedBlockAlgorithm","doFlush","processedWords","dataWords","dataSigBytes","blockSize","blockSizeBytes","nBlocksReady","nWordsReady","nBytesReady","offset","Hasher","cfg","messageUpdate","hasher","message","C_algo","T","MD5","M","offset_i","M_offset_i","H","M_offset_0","M_offset_1","M_offset_2","M_offset_3","M_offset_4","M_offset_5","M_offset_6","M_offset_7","M_offset_8","M_offset_9","M_offset_10","M_offset_11","M_offset_12","M_offset_13","M_offset_14","M_offset_15","FF","GG","HH","II","nBitsTotal","nBitsLeft","nBitsTotalH","nBitsTotalL","H_i","x","global","createCommonjsModule","fn","_global","_core","core","_core_1","_isObject","_anObject","_fails","exec","_descriptors","document","is","_domCreate","_ie8DomDefine","_toPrimitive","S","dP","O","P","Attributes","_objectDp","_propertyDesc","bitmap","_hide","hasOwnProperty","_has","px","_uid","_library","_shared","SHARED","store","_functionToString","_redefine","SRC","TO_STRING","TPL","safe","isFunction","_aFunction","_ctx","that","length","PROTOTYPE","$export","IS_FORCED","IS_GLOBAL","IS_STATIC","IS_PROTO","IS_BIND","expProto","own","out","exp","_export","ceil","floor","_toInteger","_defined","_stringAt","$at","codePointAt","_toAbsoluteIndex","fromCharCode","$fromCodePoint","arguments$1","aLen","code","fromCodePoint","Space_Separator","ID_Start","ID_Continue","unicode","util","parseState","stack","column","parse","reviver","lex","parseStates","internalize","holder","replacement","key$1","replacement$1","lexState","doubleQuote","sign","peek","lexStates","read","newToken","invalidChar","literal","unicodeEscape","invalidIdentifier","escape","separatorChar","hexEscape","count","invalidEOF","push","pop","parent","current","syntaxError","formatChar","replacements","hexString","stringify","replacer","space","indent","propertyList","replacerFunc","gap","quote","serializeProperty","quoteString","serializeArray","serializeObject","quotes","product","quoteChar","stepback","partial","propertyString","member","serializeKey","final","separator","firstChar","properties$1","JSON5","lib","es5"],"sourceRoot":""} \ No newline at end of file diff --git a/admin/custom/static/js/vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js.3a2375c7.chunk.js b/admin/custom/static/js/vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js.3a2375c7.chunk.js new file mode 100644 index 0000000..17b07bb --- /dev/null +++ b/admin/custom/static/js/vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js.3a2375c7.chunk.js @@ -0,0 +1,981 @@ +(self.webpackChunk_iobroker_admin_component_easy_access=self.webpackChunk_iobroker_admin_component_easy_access||[]).push([["vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js"],{1666:function(pe,j,J){"use strict";var _=this&&this.__extends||function(){var r=function(n,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,o){e.__proto__=o}||function(e,o){for(var a in o)Object.prototype.hasOwnProperty.call(o,a)&&(e[a]=o[a])},r(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");r(n,t);function e(){this.constructor=n}n.prototype=t===null?Object.create(t):(e.prototype=t.prototype,new e)}}(),L=this&&this.__assign||function(){return L=Object.assign||function(r){for(var n,t=1,e=arguments.length;t0&&this.handleMarkers(R);var B=this.editor.$options;s.editorOptions.forEach(function(F){B.hasOwnProperty(F)?t.editor.setOption(F,t.props[F]):t.props[F]&&console.warn("ReactAce: editor option ".concat(F," was activated but not found. Did you need to import a related tool or did you possibly mispell the option?"))}),this.handleOptions(this.props),Array.isArray(T)&&T.forEach(function(F){typeof F.exec=="string"?t.editor.commands.bindKey(F.bindKey,F.exec):t.editor.commands.addCommand(F)}),f&&this.editor.setKeyboardHandler("ace/keyboard/"+f),o&&(this.refEditor.className+=" "+o),b&&b(this.editor),this.editor.resize(),p&&this.editor.focus()},n.prototype.componentDidUpdate=function(t){for(var e=t,o=this.props,a=0;a{"use strict";Object.defineProperty(j,"__esModule",{value:!0}),j.getAceInstance=j.debounce=j.editorEvents=j.editorOptions=void 0;var _=["minLines","maxLines","readOnly","highlightActiveLine","tabSize","enableBasicAutocompletion","enableLiveAutocompletion","enableSnippets"];j.editorOptions=_;var L=["onChange","onFocus","onInput","onBlur","onCopy","onPaste","onSelectionChange","onCursorChange","onScroll","handleOptions","updateRef"];j.editorEvents=L;var E=function(){var w;return typeof window=="undefined"?(J.g.window={},w=J(6990),delete J.g.window):window.ace?(w=window.ace,w.acequire=window.ace.require||window.ace.acequire):w=J(6990),w};j.getAceInstance=E;var y=function(w,v){var s=null;return function(){var l=this,i=arguments;clearTimeout(s),s=setTimeout(function(){w.apply(l,i)},v)}};j.debounce=y},9017:(pe,j,J)=>{"use strict";Object.defineProperty(j,"__esModule",{value:!0}),j.diff=j.split=void 0;var _=J(1666),L=J(1570);j.diff=L.default;var E=J(1349);j.split=E.default,j.default=_.default},1349:function(pe,j,J){"use strict";var _=this&&this.__extends||function(){var t=function(e,o){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var u in c)Object.prototype.hasOwnProperty.call(c,u)&&(a[u]=c[u])},t(e,o)};return function(e,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");t(e,o);function a(){this.constructor=e}e.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}}(),L=this&&this.__assign||function(){return L=Object.assign||function(t){for(var e,o=1,a=arguments.length;o0&&o.handleMarkers(Z,H);for(var K=0;K{pe=J.nmd(pe),function(){var _="ace",L=function(){return this}();if(!L&&typeof window!="undefined"&&(L=window),!_&&typeof requirejs!="undefined")return;var E=function(i,r,n){if(typeof i!="string"){E.original?E.original.apply(this,arguments):(console.error("dropping module because define wasn't a string."),console.trace());return}arguments.length==2&&(n=r),E.modules[i]||(E.payloads[i]=n,E.modules[i]=null)};E.modules={},E.payloads={};var y=function(i,r,n){if(typeof r=="string"){var t=s(i,r);if(t!=null)return n&&n(),t}else if(Object.prototype.toString.call(r)==="[object Array]"){for(var e=[],o=0,a=r.length;os.length)&&(v=s.length),v-=w.length;var l=s.indexOf(w,v);return l!==-1&&l===v}),String.prototype.repeat||y(String.prototype,"repeat",function(w){for(var v="",s=this;w>0;)w&1&&(v+=s),(w>>=1)&&(s+=s);return v}),String.prototype.includes||y(String.prototype,"includes",function(w,v){return this.indexOf(w,v)!=-1}),Object.assign||(Object.assign=function(w){if(w==null)throw new TypeError("Cannot convert undefined or null to object");for(var v=Object(w),s=1;s>>0,l=arguments[1],i=l>>0,r=i<0?Math.max(s+i,0):Math.min(i,s),n=arguments[2],t=n===void 0?s:n>>0,e=t<0?Math.max(s+t,0):Math.min(t,s);r0;)s&1&&(l+=v),(s>>=1)&&(v+=v);return l};var y=/^\s\s*/,w=/\s\s*$/;L.stringTrimLeft=function(v){return v.replace(y,"")},L.stringTrimRight=function(v){return v.replace(w,"")},L.copyObject=function(v){var s={};for(var l in v)s[l]=v[l];return s},L.copyArray=function(v){for(var s=[],l=0,i=v.length;l65535?2:1}}),ace.define("ace/lib/useragent",["require","exports","module"],function(_,L,E){"use strict";L.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"},L.getOS=function(){return L.isMac?L.OS.MAC:L.isLinux?L.OS.LINUX:L.OS.WINDOWS};var y=typeof navigator=="object"?navigator:{},w=(/mac|win|linux/i.exec(y.platform)||["other"])[0].toLowerCase(),v=y.userAgent||"",s=y.appName||"";L.isWin=w=="win",L.isMac=w=="mac",L.isLinux=w=="linux",L.isIE=s=="Microsoft Internet Explorer"||s.indexOf("MSAppHost")>=0?parseFloat((v.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((v.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),L.isOldIE=L.isIE&&L.isIE<9,L.isGecko=L.isMozilla=v.match(/ Gecko\/\d+/),L.isOpera=typeof opera=="object"&&Object.prototype.toString.call(window.opera)=="[object Opera]",L.isWebKit=parseFloat(v.split("WebKit/")[1])||void 0,L.isChrome=parseFloat(v.split(" Chrome/")[1])||void 0,L.isSafari=parseFloat(v.split(" Safari/")[1])&&!L.isChrome||void 0,L.isEdge=parseFloat(v.split(" Edge/")[1])||void 0,L.isAIR=v.indexOf("AdobeAIR")>=0,L.isAndroid=v.indexOf("Android")>=0,L.isChromeOS=v.indexOf(" CrOS ")>=0,L.isIOS=/iPad|iPhone|iPod/.test(v)&&!window.MSStream,L.isIOS&&(L.isMac=!0),L.isMobile=L.isIOS||L.isAndroid}),ace.define("ace/lib/dom",["require","exports","module","ace/lib/useragent"],function(_,L,E){"use strict";var y=_("./useragent"),w="http://www.w3.org/1999/xhtml";L.buildDom=function n(t,e,o){if(typeof t=="string"&&t){var a=document.createTextNode(t);return e&&e.appendChild(a),a}if(!Array.isArray(t))return t&&t.appendChild&&e&&e.appendChild(t),t;if(typeof t[0]!="string"||!t[0]){for(var c=[],u=0;u=1.5:!0,y.isChromeOS&&(L.HI_DPI=!1),typeof document!="undefined"){var r=document.createElement("div");L.HI_DPI&&r.style.transform!==void 0&&(L.HAS_CSS_TRANSFORMS=!0),!y.isEdge&&typeof r.style.animationName!="undefined"&&(L.HAS_CSS_ANIMATION=!0),r=null}L.HAS_CSS_TRANSFORMS?L.translate=function(n,t,e){n.style.transform="translate("+Math.round(t)+"px, "+Math.round(e)+"px)"}:L.translate=function(n,t,e){n.style.top=Math.round(e)+"px",n.style.left=Math.round(t)+"px"}}),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],function(_,L,E){/* +* based on code from: +* +* @license RequireJS text 0.25.0 Copyright (c) 2010-2011, The Dojo Foundation All Rights Reserved. +* Available via the MIT or new BSD license. +* see: http://github.com/jrburke/requirejs for details +*/"use strict";var y=_("./dom");L.get=function(w,v){var s=new XMLHttpRequest;s.open("GET",w,!0),s.onreadystatechange=function(){s.readyState===4&&v(s.responseText)},s.send(null)},L.loadScript=function(w,v){var s=y.getDocumentHead(),l=document.createElement("script");l.src=w,s.appendChild(l),l.onload=l.onreadystatechange=function(i,r){(r||!l.readyState||l.readyState=="loaded"||l.readyState=="complete")&&(l=l.onload=l.onreadystatechange=null,r||v())}},L.qualifyURL=function(w){var v=document.createElement("a");return v.href=w,v.href}}),ace.define("ace/lib/oop",["require","exports","module"],function(_,L,E){"use strict";L.inherits=function(y,w){y.super_=w,y.prototype=Object.create(w.prototype,{constructor:{value:y,enumerable:!1,writable:!0,configurable:!0}})},L.mixin=function(y,w){for(var v in w)y[v]=w[v];return y},L.implement=function(y,w){L.mixin(y,w)}}),ace.define("ace/lib/event_emitter",["require","exports","module"],function(_,L,E){"use strict";var y={},w=function(){this.propagationStopped=!0},v=function(){this.defaultPrevented=!0};y._emit=y._dispatchEvent=function(s,l){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var i=this._eventRegistry[s]||[],r=this._defaultHandlers[s];if(!(!i.length&&!r)){(typeof l!="object"||!l)&&(l={}),l.type||(l.type=s),l.stopPropagation||(l.stopPropagation=w),l.preventDefault||(l.preventDefault=v),i=i.slice();for(var n=0;n1&&(c=o[o.length-2]);var p=l[e+"Path"];return p==null?p=l.basePath:a=="/"&&(e=a=""),p&&p.slice(-1)!="/"&&(p+="/"),p+e+a+c+this.get("suffix")},L.setModuleUrl=function(t,e){return l.$moduleUrls[t]=e};var i=function(t,e){if(t==="ace/theme/textmate"||t==="./theme/textmate")return e(null,_("./theme/textmate"));if(r)return r(t,e);console.error("loader is not configured")},r;L.setLoader=function(t){r=t},L.dynamicModules=Object.create(null),L.$loading={},L.$loaded={},L.loadModule=function(t,e){var o;if(Array.isArray(t))var a=t[0],c=t[1];else if(typeof t=="string")var c=t;var u=function(p){if(p&&!L.$loading[c])return e&&e(p);if(L.$loading[c]||(L.$loading[c]=[]),L.$loading[c].push(e),!(L.$loading[c].length>1)){var m=function(){i(c,function($,C){C&&(L.$loaded[c]=C),L._emit("load.module",{name:c,module:C});var g=L.$loading[c];L.$loading[c]=null,g.forEach(function(M){M&&M(C)})})};if(!L.get("packaged"))return m();w.loadScript(L.moduleUrl(c,a),m),n()}};if(L.dynamicModules[c])L.dynamicModules[c]().then(function(p){p.default?u(p.default):u(p)});else{try{o=this.$require(c)}catch(p){}u(o||L.$loaded[c])}},L.$require=function(t){if(typeof E.require=="function"){var e="require";return E[e](t)}},L.setModuleLoader=function(t,e){L.dynamicModules[t]=e};var n=function(){!l.basePath&&!l.workerPath&&!l.modePath&&!l.themePath&&!Object.keys(l.$moduleUrls).length&&(console.error("Unable to infer path to ace from script src,","use ace.config.set('basePath', 'path') to enable dynamic loading of modes and themes","or with webpack use ace/webpack-resolver"),n=function(){})};L.version="1.36.5"}),ace.define("ace/loader_build",["require","exports","module","ace/lib/fixoldbrowsers","ace/config"],function(_,L,E){"use strict";_("./lib/fixoldbrowsers");var y=_("./config");y.setLoader(function(l,i){_([l],function(r){i(null,r)})});var w=function(){return this||typeof window!="undefined"&&window}();E.exports=function(l){y.init=v,y.$require=_,l.require=_,l.define=J.amdD},v(!0);function v(l){if(!(!w||!w.document)){y.set("packaged",l||_.packaged||E.packaged||w.define&&J.amdD.packaged);var i={},r="",n=document.currentScript||document._currentScript,t=n&&n.ownerDocument||document;n&&n.src&&(r=n.src.split(/[?#]/)[0].split("/").slice(0,-1).join("/")||"");for(var e=t.getElementsByTagName("script"),o=0;o ["+this.end.row+"/"+this.end.column+"]"},w.prototype.contains=function(v,s){return this.compare(v,s)==0},w.prototype.compareRange=function(v){var s,l=v.end,i=v.start;return s=this.compare(l.row,l.column),s==1?(s=this.compare(i.row,i.column),s==1?2:s==0?1:0):s==-1?-2:(s=this.compare(i.row,i.column),s==-1?-1:s==1?42:0)},w.prototype.comparePoint=function(v){return this.compare(v.row,v.column)},w.prototype.containsRange=function(v){return this.comparePoint(v.start)==0&&this.comparePoint(v.end)==0},w.prototype.intersects=function(v){var s=this.compareRange(v);return s==-1||s==0||s==1},w.prototype.isEnd=function(v,s){return this.end.row==v&&this.end.column==s},w.prototype.isStart=function(v,s){return this.start.row==v&&this.start.column==s},w.prototype.setStart=function(v,s){typeof v=="object"?(this.start.column=v.column,this.start.row=v.row):(this.start.row=v,this.start.column=s)},w.prototype.setEnd=function(v,s){typeof v=="object"?(this.end.column=v.column,this.end.row=v.row):(this.end.row=v,this.end.column=s)},w.prototype.inside=function(v,s){return this.compare(v,s)==0?!(this.isEnd(v,s)||this.isStart(v,s)):!1},w.prototype.insideStart=function(v,s){return this.compare(v,s)==0?!this.isEnd(v,s):!1},w.prototype.insideEnd=function(v,s){return this.compare(v,s)==0?!this.isStart(v,s):!1},w.prototype.compare=function(v,s){return!this.isMultiLine()&&v===this.start.row?sthis.end.column?1:0:vthis.end.row?1:this.start.row===v?s>=this.start.column?0:-1:this.end.row===v?s<=this.end.column?0:1:0},w.prototype.compareStart=function(v,s){return this.start.row==v&&this.start.column==s?-1:this.compare(v,s)},w.prototype.compareEnd=function(v,s){return this.end.row==v&&this.end.column==s?1:this.compare(v,s)},w.prototype.compareInside=function(v,s){return this.end.row==v&&this.end.column==s?1:this.start.row==v&&this.start.column==s?-1:this.compare(v,s)},w.prototype.clipRows=function(v,s){if(this.end.row>s)var l={row:s+1,column:0};else if(this.end.rows)var i={row:s+1,column:0};else if(this.start.row1?(M++,M>4&&(M=1)):M=1,w.isIE){var b=Math.abs(f.clientX-A)>5||Math.abs(f.clientY-S)>5;(!k||b)&&(M=1),k&&clearTimeout(k),k=setTimeout(function(){k=null},m[M-1]||600),M==1&&(A=f.clientX,S=f.clientY)}if(f._clicks=M,$[C]("mousedown",f),M>4)M=0;else if(M>1)return $[C](d[M],f)}Array.isArray(p)||(p=[p]),p.forEach(function(f){t(f,"mousedown",h,g)})};function o(p){return 0|(p.ctrlKey?1:0)|(p.altKey?2:0)|(p.shiftKey?4:0)|(p.metaKey?8:0)}L.getModifierString=function(p){return y.KEY_MODS[o(p)]};function a(p,m,$){var C=o(m);if(!$&&m.code&&($=y.$codeToKeyCode[m.code]||$),!w.isMac&&v){if(m.getModifierState&&(m.getModifierState("OS")||m.getModifierState("Win"))&&(C|=8),v.altGr)if((3&C)!=3)v.altGr=0;else return;if($===18||$===17){var g=m.location;if($===17&&g===1)v[$]==1&&(s=m.timeStamp);else if($===18&&C===3&&g===2){var M=m.timeStamp-s;M<50&&(v.altGr=!0)}}}if($ in y.MODIFIER_KEYS&&($=-1),!(!C&&$===13&&m.location===3&&(p(m,C,-$),m.defaultPrevented))){if(w.isChromeOS&&C&8){if(p(m,C,$),m.defaultPrevented)return;C&=-9}return!C&&!($ in y.FUNCTION_KEYS)&&!($ in y.PRINTABLE_KEYS)?!1:p(m,C,$)}}L.addCommandKeyListener=function(p,m,$){var C=null;t(p,"keydown",function(g){v[g.keyCode]=(v[g.keyCode]||0)+1;var M=a(m,g,g.keyCode);return C=g.defaultPrevented,M},$),t(p,"keypress",function(g){C&&(g.ctrlKey||g.altKey||g.shiftKey||g.metaKey)&&(L.stopEvent(g),C=null)},$),t(p,"keyup",function(g){v[g.keyCode]=null},$),v||(c(),t(window,"focus",c))};function c(){v=Object.create(null)}if(typeof window=="object"&&window.postMessage&&!w.isOldIE){var u=1;L.nextTick=function(p,m){m=m||window;var $="zero-timeout-message-"+u++,C=function(g){g.data==$&&(L.stopPropagation(g),e(m,"message",C),p())};t(m,"message",C),m.postMessage($,"*")}}L.$idleBlocked=!1,L.onIdle=function(p,m){return setTimeout(function $(){L.$idleBlocked?setTimeout($,100):p()},m)},L.$idleBlockId=null,L.blockIdle=function(p){L.$idleBlockId&&clearTimeout(L.$idleBlockId),L.$idleBlocked=!0,L.$idleBlockId=setTimeout(function(){L.$idleBlocked=!1},p||100)},L.nextFrame=typeof window=="object"&&(window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame),L.nextFrame?L.nextFrame=L.nextFrame.bind(window):L.nextFrame=function(p){setTimeout(p,17)}}),ace.define("ace/clipboard",["require","exports","module"],function(_,L,E){"use strict";var y;E.exports={lineMode:!1,pasteCancelled:function(){return y&&y>Date.now()-50?!0:y=!1},cancel:function(){y=Date.now()}}}),ace.define("ace/keyboard/textinput",["require","exports","module","ace/lib/event","ace/config","ace/lib/useragent","ace/lib/dom","ace/lib/lang","ace/clipboard","ace/lib/keys"],function(_,L,E){"use strict";var y=_("../lib/event"),w=_("../config").nls,v=_("../lib/useragent"),s=_("../lib/dom"),l=_("../lib/lang"),i=_("../clipboard"),r=v.isChrome<18,n=v.isIE,t=v.isChrome>63,e=400,o=_("../lib/keys"),a=o.KEY_MODS,c=v.isIOS,u=c?/\s/:/\n/,p=v.isMobile,m;m=function($,C){var g=s.createElement("textarea");g.className="ace_text-input",g.setAttribute("wrap","off"),g.setAttribute("autocorrect","off"),g.setAttribute("autocapitalize","off"),g.setAttribute("spellcheck","false"),g.style.opacity="0",$.insertBefore(g,$.firstChild);var M=!1,A=!1,S=!1,k=!1,d="";p||(g.style.fontSize="1px");var h=!1,f=!1,b="",T=0,x=0,R=0,I=Number.MAX_SAFE_INTEGER,N=Number.MIN_SAFE_INTEGER,D=0;try{var B=document.activeElement===g}catch(G){}this.setNumberOfExtraLines=function(G){if(I=Number.MAX_SAFE_INTEGER,N=Number.MIN_SAFE_INTEGER,G<0){D=0;return}D=G},this.setAriaLabel=function(){var G="";if(C.$textInputAriaLabel&&(G+="".concat(C.$textInputAriaLabel,", ")),C.session){var te=C.session.selection.cursor.row;G+=w("text-input.aria-label","Cursor at row $0",[te+1])}g.setAttribute("aria-label",G)},this.setAriaOptions=function(G){G.activeDescendant?(g.setAttribute("aria-haspopup","true"),g.setAttribute("aria-autocomplete",G.inline?"both":"list"),g.setAttribute("aria-activedescendant",G.activeDescendant)):(g.setAttribute("aria-haspopup","false"),g.setAttribute("aria-autocomplete","both"),g.removeAttribute("aria-activedescendant")),G.role&&g.setAttribute("role",G.role),G.setLabel&&(g.setAttribute("aria-roledescription",w("text-input.aria-roledescription","editor")),this.setAriaLabel())},this.setAriaOptions({role:"textbox"}),y.addListener(g,"blur",function(G){f||(C.onBlur(G),B=!1)},C),y.addListener(g,"focus",function(G){if(!f){if(B=!0,v.isEdge)try{if(!document.hasFocus())return}catch(te){}C.onFocus(G),v.isEdge?setTimeout(z):z()}},C),this.$focusScroll=!1,this.focus=function(){if(this.setAriaOptions({setLabel:C.renderer.enableKeyboardAccessibility}),d||t||this.$focusScroll=="browser")return g.focus({preventScroll:!0});var G=g.style.top;g.style.position="fixed",g.style.top="0px";try{var te=g.getBoundingClientRect().top!=0}catch(se){return}var ie=[];if(te)for(var he=g.parentElement;he&&he.nodeType==1;)ie.push(he),he.setAttribute("ace_nocontext","true"),!he.parentElement&&he.getRootNode?he=he.getRootNode().host:he=he.parentElement;g.focus({preventScroll:!0}),te&&ie.forEach(function(se){se.removeAttribute("ace_nocontext")}),setTimeout(function(){g.style.position="",g.style.top=="0px"&&(g.style.top=G)},0)},this.blur=function(){g.blur()},this.isFocused=function(){return B},C.on("beforeEndOperation",function(){var G=C.curOp,te=G&&G.command&&G.command.name;if(te!="insertstring"){var ie=te&&(G.docChanged||G.selectionChanged);S&&ie&&(b=g.value="",ke()),z()}}),C.on("changeSelection",this.setAriaLabel);var F=function(G,te){for(var ie=te,he=1;he<=G-I&&he<2*D+1;he++)ie+=C.session.getLine(G-he).length+1;return ie},z=c?function(G){if(!(!B||M&&!G||k)){G||(G="");var te=` + ab`+G+`cde fg +`;te!=g.value&&(g.value=b=te);var ie=4,he=4+(G.length||(C.selection.isEmpty()?0:1));(T!=ie||x!=he)&&g.setSelectionRange(ie,he),T=ie,x=he}}:function(){if(!(S||k)&&!(!B&&!q)){S=!0;var G=0,te=0,ie="";if(C.session){var he=C.selection,se=he.getRange(),ve=he.cursor.row;ve===N+1?(I=N+1,N=I+2*D):ve===I-1?(N=I-1,I=N-2*D):(veN+1)&&(I=ve>D?ve-D:0,N=ve>D?ve+D:2*D);for(var ye=[],we=I;we<=N;we++)ye.push(C.session.getLine(we));if(ie=ye.join(` +`),G=F(se.start.row,se.start.column),te=F(se.end.row,se.end.column),se.start.rowN){var ue=C.session.getLine(N+1);te=se.end.row>N+1?ue.length:se.end.column,te+=ie.length+1,ie=ie+` +`+ue}else p&&ve>0&&(ie=` +`+ie,te+=1,G+=1);ie.length>e&&(G=b.length&&G.value===b&&b&&G.selectionEnd!==x},U=function(G){S||(M?M=!1:H(g)?(C.selectAll(),z()):p&&g.selectionStart!=T&&z())},K=null;this.setInputHandler=function(G){K=G},this.getInputHandler=function(){return K};var q=!1,ee=function(G,te){if(q&&(q=!1),A)return z(),G&&C.onPaste(G),A=!1,"";for(var ie=g.selectionStart,he=g.selectionEnd,se=T,ve=b.length-x,ye=G,we=G.length-ie,ge=G.length-he,ue=0;se>0&&b[ue]==G[ue];)ue++,se--;for(ye=ye.slice(ue),ue=1;ve>0&&b.length-ue>T-1&&b[b.length-ue]==G[G.length-ue];)ue++,ve--;we-=ue-1,ge-=ue-1;var Ae=ye.length-ue+1;if(Ae<0&&(se=-Ae,Ae=0),ye=ye.slice(0,Ae),!te&&!ye&&!we&&!se&&!ve&&!ge)return"";k=!0;var He=!1;return v.isAndroid&&ye==". "&&(ye=" ",He=!0),ye&&!se&&!ve&&!we&&!ge||h?C.onTextInput(ye):C.onTextInput(ye,{extendLeft:se,extendRight:ve,restoreStart:we,restoreEnd:ge}),k=!1,b=G,T=ie,x=he,R=ge,He?` +`:ye},Y=function(G){if(S)return fe();if(G&&G.inputType){if(G.inputType=="historyUndo")return C.execCommand("undo");if(G.inputType=="historyRedo")return C.execCommand("redo")}var te=g.value,ie=ee(te,!0);(te.length>e+100||u.test(ie)||p&&T<1&&T==x)&&z()},Z=function(G,te,ie){var he=G.clipboardData||window.clipboardData;if(!(!he||r)){var se=n||ie?"Text":"text/plain";try{return te?he.setData(se,te)!==!1:he.getData(se)}catch(ve){if(!ie)return Z(ve,te,!0)}}},X=function(G,te){var ie=C.getCopyText();if(!ie)return y.preventDefault(G);Z(G,ie)?(c&&(z(ie),M=ie,setTimeout(function(){M=!1},10)),te?C.onCut():C.onCopy(),y.preventDefault(G)):(M=!0,g.value=ie,g.select(),setTimeout(function(){M=!1,z(),te?C.onCut():C.onCopy()}))},ae=function(G){X(G,!0)},ce=function(G){X(G,!1)},de=function(G){var te=Z(G);i.pasteCancelled()||(typeof te=="string"?(te&&C.onPaste(te,G),v.isIE&&setTimeout(z),y.preventDefault(G)):(g.value="",A=!0))};y.addCommandKeyListener(g,function(G,te,ie){if(!S)return C.onCommandKey(G,te,ie)},C),y.addListener(g,"select",U,C),y.addListener(g,"input",Y,C),y.addListener(g,"cut",ae,C),y.addListener(g,"copy",ce,C),y.addListener(g,"paste",de,C),(!("oncut"in g)||!("oncopy"in g)||!("onpaste"in g))&&y.addListener($,"keydown",function(G){if(!(v.isMac&&!G.metaKey||!G.ctrlKey))switch(G.keyCode){case 67:ce(G);break;case 86:de(G);break;case 88:ae(G);break}},C);var oe=function(G){if(!(S||!C.onCompositionStart||C.$readOnly)&&(S={},!h)){G.data&&(S.useTextareaForIME=!1),setTimeout(fe,0),C._signal("compositionStart"),C.on("mousedown",Re);var te=C.getSelectionRange();te.end.row=te.start.row,te.end.column=te.start.column,S.markerRange=te,S.selectionStart=T,C.onCompositionStart(S),S.useTextareaForIME?(b=g.value="",T=0,x=0):(g.msGetInputContext&&(S.context=g.msGetInputContext()),g.getInputContext&&(S.context=g.getInputContext()))}},fe=function(){if(!(!S||!C.onCompositionUpdate||C.$readOnly)){if(h)return Re();if(S.useTextareaForIME)C.onCompositionUpdate(g.value);else{var G=g.value;ee(G),S.markerRange&&(S.context&&(S.markerRange.start.column=S.selectionStart=S.context.compositionStartOffset),S.markerRange.end.column=S.markerRange.start.column+x-S.selectionStart+R)}}},ke=function(G){!C.onCompositionEnd||C.$readOnly||(S=!1,C.onCompositionEnd(),C.off("mousedown",Re),G&&Y())};function Re(){f=!0,g.blur(),g.focus(),f=!1}var _e=l.delayedCall(fe,50).schedule.bind(null,null);function be(G){G.keyCode==27&&g.value.lengthx&&b[ge]==` +`?ue=o.end:wex&&b.slice(0,ge).split(` +`).length>2?ue=o.down:ge>x&&b[ge-1]==" "?(ue=o.right,Ae=a.option):(ge>x||ge==x&&x!=T&&we==ge)&&(ue=o.right),we!==ge&&(Ae|=a.shift),ue){var He=te.onCommandKey({},Ae,ue);if(!He&&te.commands){ue=o.keyCodeToString(ue);var Ze=te.commands.findKeyCommand(Ae,ue);Ze&&te.execCommand(Ze)}T=we,x=ge,z("")}}};document.addEventListener("selectionchange",ve),te.on("destroy",function(){document.removeEventListener("selectionchange",ve)})}this.destroy=function(){g.parentElement&&g.parentElement.removeChild(g)}},L.TextInput=m,L.$setUserAgentForTests=function($,C){p=$,c=C}}),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/useragent"],function(_,L,E){"use strict";var y=_("../lib/useragent"),w=0,v=550,s=function(){function r(n){n.$clickSelection=null;var t=n.editor;t.setDefaultHandler("mousedown",this.onMouseDown.bind(n)),t.setDefaultHandler("dblclick",this.onDoubleClick.bind(n)),t.setDefaultHandler("tripleclick",this.onTripleClick.bind(n)),t.setDefaultHandler("quadclick",this.onQuadClick.bind(n)),t.setDefaultHandler("mousewheel",this.onMouseWheel.bind(n));var e=["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"];e.forEach(function(o){n[o]=this[o]},this),n.selectByLines=this.extendSelectionBy.bind(n,"getLineRange"),n.selectByWords=this.extendSelectionBy.bind(n,"getWordRange")}return r.prototype.onMouseDown=function(n){var t=n.inSelection(),e=n.getDocumentPosition();this.mousedownEvent=n;var o=this.editor,a=n.getButton();if(a!==0){var c=o.getSelectionRange(),u=c.isEmpty();(u||a==1)&&o.selection.moveToPosition(e),a==2&&(o.textInput.onContextMenu(n.domEvent),y.isMozilla||n.preventDefault());return}if(this.mousedownEvent.time=Date.now(),t&&!o.isFocused()&&(o.focus(),this.$focusTimeout&&!this.$clickSelection&&!o.inMultiSelectMode)){this.setState("focusWait"),this.captureMouse(n);return}return this.captureMouse(n),this.startSelect(e,n.domEvent._clicks>1),n.preventDefault()},r.prototype.startSelect=function(n,t){n=n||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var e=this.editor;this.mousedownEvent&&(this.mousedownEvent.getShiftKey()?e.selection.selectToPosition(n):t||e.selection.moveToPosition(n),t||this.select(),e.setStyle("ace_selecting"),this.setState("select"))},r.prototype.select=function(){var n,t=this.editor,e=t.renderer.screenToTextCoordinates(this.x,this.y);if(this.$clickSelection){var o=this.$clickSelection.comparePoint(e);if(o==-1)n=this.$clickSelection.end;else if(o==1)n=this.$clickSelection.start;else{var a=i(this.$clickSelection,e);e=a.cursor,n=a.anchor}t.selection.setSelectionAnchor(n.row,n.column)}t.selection.selectToPosition(e),t.renderer.scrollCursorIntoView()},r.prototype.extendSelectionBy=function(n){var t,e=this.editor,o=e.renderer.screenToTextCoordinates(this.x,this.y),a=e.selection[n](o.row,o.column);if(this.$clickSelection){var c=this.$clickSelection.comparePoint(a.start),u=this.$clickSelection.comparePoint(a.end);if(c==-1&&u<=0)t=this.$clickSelection.end,(a.end.row!=o.row||a.end.column!=o.column)&&(o=a.start);else if(u==1&&c>=0)t=this.$clickSelection.start,(a.start.row!=o.row||a.start.column!=o.column)&&(o=a.end);else if(c==-1&&u==1)o=a.end,t=a.start;else{var p=i(this.$clickSelection,o);o=p.cursor,t=p.anchor}e.selection.setSelectionAnchor(t.row,t.column)}e.selection.selectToPosition(o),e.renderer.scrollCursorIntoView()},r.prototype.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting")},r.prototype.focusWait=function(){var n=l(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y),t=Date.now();(n>w||t-this.mousedownEvent.time>this.$focusTimeout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},r.prototype.onDoubleClick=function(n){var t=n.getDocumentPosition(),e=this.editor,o=e.session,a=o.getBracketRange(t);a?(a.isEmpty()&&(a.start.column--,a.end.column++),this.setState("select")):(a=e.selection.getWordRange(t.row,t.column),this.setState("selectByWords")),this.$clickSelection=a,this.select()},r.prototype.onTripleClick=function(n){var t=n.getDocumentPosition(),e=this.editor;this.setState("selectByLines");var o=e.getSelectionRange();o.isMultiLine()&&o.contains(t.row,t.column)?(this.$clickSelection=e.selection.getLineRange(o.start.row),this.$clickSelection.end=e.selection.getLineRange(o.end.row).end):this.$clickSelection=e.selection.getLineRange(t.row),this.select()},r.prototype.onQuadClick=function(n){var t=this.editor;t.selectAll(),this.$clickSelection=t.getSelectionRange(),this.setState("selectAll")},r.prototype.onMouseWheel=function(n){if(!n.getAccelKey()){n.getShiftKey()&&n.wheelY&&!n.wheelX&&(n.wheelX=n.wheelY,n.wheelY=0);var t=this.editor;this.$lastScroll||(this.$lastScroll={t:0,vx:0,vy:0,allowed:0});var e=this.$lastScroll,o=n.domEvent.timeStamp,a=o-e.t,c=a?n.wheelX/a:e.vx,u=a?n.wheelY/a:e.vy;a=1&&t.renderer.isScrollableBy(n.wheelX*n.speed,0)&&(m=!0),p<=1&&t.renderer.isScrollableBy(0,n.wheelY*n.speed)&&(m=!0),m)e.allowed=o;else if(o-e.allowedv.clientHeight;s||w.preventDefault()}}),ace.define("ace/tooltip",["require","exports","module","ace/lib/dom","ace/lib/event","ace/range","ace/lib/scroll"],function(_,L,E){"use strict";var y=this&&this.__extends||function(){var a=function(c,u){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,m){p.__proto__=m}||function(p,m){for(var $ in m)Object.prototype.hasOwnProperty.call(m,$)&&(p[$]=m[$])},a(c,u)};return function(c,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");a(c,u);function p(){this.constructor=c}c.prototype=u===null?Object.create(u):(p.prototype=u.prototype,new p)}}(),w=this&&this.__values||function(a){var c=typeof Symbol=="function"&&Symbol.iterator,u=c&&a[c],p=0;if(u)return u.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&p>=a.length&&(a=void 0),{value:a&&a[p++],done:!a}}};throw new TypeError(c?"Object is not iterable.":"Symbol.iterator is not defined.")},v=_("./lib/dom"),s=_("./lib/event"),l=_("./range").Range,i=_("./lib/scroll").preventParentScroll,r="ace_tooltip",n=function(){function a(c){this.isOpen=!1,this.$element=null,this.$parentNode=c}return a.prototype.$init=function(){return this.$element=v.createElement("div"),this.$element.className=r,this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},a.prototype.getElement=function(){return this.$element||this.$init()},a.prototype.setText=function(c){this.getElement().textContent=c},a.prototype.setHtml=function(c){this.getElement().innerHTML=c},a.prototype.setPosition=function(c,u){this.getElement().style.left=c+"px",this.getElement().style.top=u+"px"},a.prototype.setClassName=function(c){v.addCssClass(this.getElement(),c)},a.prototype.setTheme=function(c){this.$element.className=r+" "+(c.isDark?"ace_dark ":"")+(c.cssClass||"")},a.prototype.show=function(c,u,p){c!=null&&this.setText(c),u!=null&&p!=null&&this.setPosition(u,p),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},a.prototype.hide=function(c){this.isOpen&&(this.getElement().style.display="none",this.getElement().className=r,this.isOpen=!1)},a.prototype.getHeight=function(){return this.getElement().offsetHeight},a.prototype.getWidth=function(){return this.getElement().offsetWidth},a.prototype.destroy=function(){this.isOpen=!1,this.$element&&this.$element.parentNode&&this.$element.parentNode.removeChild(this.$element)},a}(),t=function(){function a(){this.popups=[]}return a.prototype.addPopup=function(c){this.popups.push(c),this.updatePopups()},a.prototype.removePopup=function(c){var u=this.popups.indexOf(c);u!==-1&&(this.popups.splice(u,1),this.updatePopups())},a.prototype.updatePopups=function(){var c,u,p,m;this.popups.sort(function(h,f){return f.priority-h.priority});var $=[];try{for(var C=w(this.popups),g=C.next();!g.done;g=C.next()){var M=g.value,A=!0;try{for(var S=(p=void 0,w($)),k=S.next();!k.done;k=S.next()){var d=k.value;if(this.doPopupsOverlap(d,M)){A=!1;break}}}catch(h){p={error:h}}finally{try{k&&!k.done&&(m=S.return)&&m.call(S)}finally{if(p)throw p.error}}A?$.push(M):M.hide()}}catch(h){c={error:h}}finally{try{g&&!g.done&&(u=C.return)&&u.call(C)}finally{if(c)throw c.error}}},a.prototype.doPopupsOverlap=function(c,u){var p=c.getElement().getBoundingClientRect(),m=u.getElement().getBoundingClientRect();return p.leftm.left&&p.topm.top},a}(),e=new t;L.popupManager=e,L.Tooltip=n;var o=function(a){y(c,a);function c(u){u===void 0&&(u=document.body);var p=a.call(this,u)||this;p.timeout=void 0,p.lastT=0,p.idleTime=350,p.lastEvent=void 0,p.onMouseOut=p.onMouseOut.bind(p),p.onMouseMove=p.onMouseMove.bind(p),p.waitForHover=p.waitForHover.bind(p),p.hide=p.hide.bind(p);var m=p.getElement();return m.style.whiteSpace="pre-wrap",m.style.pointerEvents="auto",m.addEventListener("mouseout",p.onMouseOut),m.tabIndex=-1,m.addEventListener("blur",function(){m.contains(document.activeElement)||this.hide()}.bind(p)),m.addEventListener("wheel",i),p}return c.prototype.addToEditor=function(u){u.on("mousemove",this.onMouseMove),u.on("mousedown",this.hide),u.renderer.getMouseEventTarget().addEventListener("mouseout",this.onMouseOut,!0)},c.prototype.removeFromEditor=function(u){u.off("mousemove",this.onMouseMove),u.off("mousedown",this.hide),u.renderer.getMouseEventTarget().removeEventListener("mouseout",this.onMouseOut,!0),this.timeout&&(clearTimeout(this.timeout),this.timeout=null)},c.prototype.onMouseMove=function(u,p){this.lastEvent=u,this.lastT=Date.now();var m=p.$mouseHandler.isMousePressed;if(this.isOpen){var $=this.lastEvent&&this.lastEvent.getDocumentPosition();(!this.range||!this.range.contains($.row,$.column)||m||this.isOutsideOfText(this.lastEvent))&&this.hide()}this.timeout||m||(this.lastEvent=u,this.timeout=setTimeout(this.waitForHover,this.idleTime))},c.prototype.waitForHover=function(){this.timeout&&clearTimeout(this.timeout);var u=Date.now()-this.lastT;if(this.idleTime-u>10){this.timeout=setTimeout(this.waitForHover,this.idleTime-u);return}this.timeout=null,this.lastEvent&&!this.isOutsideOfText(this.lastEvent)&&this.$gatherData(this.lastEvent,this.lastEvent.editor)},c.prototype.isOutsideOfText=function(u){var p=u.editor,m=u.getDocumentPosition(),$=p.session.getLine(m.row);if(m.column==$.length){var C=p.renderer.pixelToScreenCoordinates(u.clientX,u.clientY),g=p.session.documentToScreenPosition(m.row,m.column);if(g.column!=C.column||g.row!=C.row)return!0}return!1},c.prototype.setDataProvider=function(u){this.$gatherData=u},c.prototype.showForRange=function(u,p,m,$){var C=10;if(!($&&$!=this.lastEvent)&&!(this.isOpen&&document.activeElement==this.getElement())){var g=u.renderer;this.isOpen||(e.addPopup(this),this.$registerCloseEvents(),this.setTheme(g.theme)),this.isOpen=!0,this.addMarker(p,u.session),this.range=l.fromPoints(p.start,p.end);var M=g.textToScreenCoordinates(p.start.row,p.start.column),A=g.scroller.getBoundingClientRect();M.pageX=e.length&&(e=void 0),{value:e&&e[c++],done:!e}}};throw new TypeError(o?"Object is not iterable.":"Symbol.iterator is not defined.")},v=_("../lib/dom"),s=_("../lib/event"),l=_("../tooltip").Tooltip,i=_("../config").nls,r=_("../lib/lang");function n(e){var o=e.editor,a=o.renderer.$gutterLayer,c=new t(o);e.editor.setDefaultHandler("guttermousedown",function(g){if(!(!o.isFocused()||g.getButton()!=0)){var M=a.getRegion(g);if(M!="foldWidgets"){var A=g.getDocumentPosition().row,S=o.session.selection;if(g.getShiftKey())S.selectTo(A,0);else{if(g.domEvent.detail==2)return o.selectAll(),g.preventDefault();e.$clickSelection=o.selection.getLineRange(A)}return e.setState("selectByLines"),e.captureMouse(g),g.preventDefault()}}});var u,p;function m(){var g=p.getDocumentPosition().row,M=o.session.getLength();if(g==M){var A=o.renderer.pixelToScreenCoordinates(0,p.y).row,S=p.$pos;if(A>o.session.documentToScreenRow(S.row,S.column))return $()}if(c.showTooltip(g),!!c.isOpen)if(o.on("mousewheel",$),e.$tooltipFollowsMouse)C(p);else{var k=p.getGutterRow(),d=a.$lines.get(k);if(d){var h=d.element.querySelector(".ace_gutter_annotation"),f=h.getBoundingClientRect(),b=c.getElement().style;b.left=f.right+"px",b.top=f.bottom+"px"}else C(p)}}function $(){u&&(u=clearTimeout(u)),c.isOpen&&(c.hideTooltip(),o.off("mousewheel",$))}function C(g){c.setPosition(g.x,g.y)}e.editor.setDefaultHandler("guttermousemove",function(g){var M=g.domEvent.target||g.domEvent.srcElement;if(v.hasCssClass(M,"ace_fold-widget"))return $();c.isOpen&&e.$tooltipFollowsMouse&&C(g),p=g,!u&&(u=setTimeout(function(){u=null,p&&!e.isMousePressed?m():$()},50))}),s.addListener(o.renderer.$gutter,"mouseout",function(g){p=null,!(!c.isOpen||u)&&(u=setTimeout(function(){u=null,$()},50))},o),o.on("changeSession",$),o.on("input",$)}L.GutterHandler=n;var t=function(e){y(o,e);function o(a){var c=e.call(this,a.container)||this;return c.editor=a,c}return o.prototype.setPosition=function(a,c){var u=window.innerWidth||document.documentElement.clientWidth,p=window.innerHeight||document.documentElement.clientHeight,m=this.getWidth(),$=this.getHeight();a+=15,c+=15,a+m>u&&(a-=a+m-u),c+$>p&&(c-=20+$),l.prototype.setPosition.call(this,a,c)},Object.defineProperty(o,"annotationLabels",{get:function(){return{error:{singular:i("gutter-tooltip.aria-label.error.singular","error"),plural:i("gutter-tooltip.aria-label.error.plural","errors")},security:{singular:i("gutter-tooltip.aria-label.security.singular","security finding"),plural:i("gutter-tooltip.aria-label.security.plural","security findings")},warning:{singular:i("gutter-tooltip.aria-label.warning.singular","warning"),plural:i("gutter-tooltip.aria-label.warning.plural","warnings")},info:{singular:i("gutter-tooltip.aria-label.info.singular","information message"),plural:i("gutter-tooltip.aria-label.info.plural","information messages")},hint:{singular:i("gutter-tooltip.aria-label.hint.singular","suggestion"),plural:i("gutter-tooltip.aria-label.hint.plural","suggestions")}}},enumerable:!1,configurable:!0}),o.prototype.showTooltip=function(a){var c,u=this.editor.renderer.$gutterLayer,p=u.$annotations[a],m;p?m={displayText:Array.from(p.displayText),type:Array.from(p.type)}:m={displayText:[],type:[]};var $=u.session.getFoldLine(a);if($&&u.$showFoldedAnnotations){for(var C={error:[],security:[],warning:[],info:[],hint:[]},g={error:1,security:2,warning:3,info:4,hint:5},M,A=a+1;A<=$.end.row;A++)if(u.$annotations[A])for(var S=0;Si?d=null:H-d>=l&&(e.renderer.scrollCursorIntoView(),d=null)}}function b(F,z){var H=Date.now(),U=e.renderer.layerConfig.lineHeight,K=e.renderer.layerConfig.characterWidth,q=e.renderer.scroller.getBoundingClientRect(),ee={x:{left:p-q.left,right:q.right-p},y:{top:m-q.top,bottom:q.bottom-m}},Y=Math.min(ee.x.left,ee.x.right),Z=Math.min(ee.y.top,ee.y.bottom),X={row:F.row,column:F.column};Y/K<=2&&(X.column+=ee.x.left=s&&e.renderer.scrollCursorIntoView(X):k=H:k=null}function T(){var F=g;g=e.renderer.screenToTextCoordinates(p,m),f(g,F),b(g,F)}function x(){C=e.selection.toOrientedRange(),u=e.session.addMarker(C,"ace_selection",e.getSelectionStyle()),e.clearSelection(),e.isFocused()&&e.renderer.$cursorLayer.setBlinking(!1),clearInterval($),T(),$=setInterval(T,20),M=0,w.addListener(document,"mousemove",N)}function R(){clearInterval($),e.session.removeMarker(u),u=null,e.selection.fromOrientedRange(C),e.isFocused()&&!S&&e.$resetCursorStyle(),C=null,g=null,M=0,k=null,d=null,w.removeListener(document,"mousemove",N)}var I=null;function N(){I==null&&(I=setTimeout(function(){I!=null&&u&&R()},20))}function D(F){var z=F.types;return!z||Array.prototype.some.call(z,function(H){return H=="text/plain"||H=="Text"})}function B(F){var z=["copy","copymove","all","uninitialized"],H=["move","copymove","linkmove","all","uninitialized"],U=v.isMac?F.altKey:F.ctrlKey,K="uninitialized";try{K=F.dataTransfer.effectAllowed.toLowerCase()}catch(ee){}var q="none";return U&&z.indexOf(K)>=0?q="copy":H.indexOf(K)>=0?q="move":z.indexOf(K)>=0&&(q="copy"),q}}(function(){this.dragWait=function(){var t=Date.now()-this.mousedownEvent.time;t>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){var t=this.editor.container;t.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(t){this.editor.$resetCursorStyle(),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var t=this.editor,e=t.container;e.draggable=!0,t.renderer.$cursorLayer.setBlinking(!1),t.setStyle("ace_dragging");var o=v.isWin?"default":"move";t.renderer.setCursorStyle(o),this.setState("dragReady")},this.onMouseDrag=function(t){var e=this.editor.container;if(v.isIE&&this.state=="dragReady"){var o=n(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);o>3&&e.dragDrop()}if(this.state==="dragWait"){var o=n(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);o>0&&(e.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))}},this.onMouseDown=function(t){if(this.$dragEnabled){this.mousedownEvent=t;var e=this.editor,o=t.inSelection(),a=t.getButton(),c=t.domEvent.detail||1;if(c===1&&a===0&&o){if(t.editor.inMultiSelectMode&&(t.getAccelKey()||t.getShiftKey()))return;this.mousedownEvent.time=Date.now();var u=t.domEvent.target||t.domEvent.srcElement;if("unselectable"in u&&(u.unselectable="on"),e.getDragDelay()){if(v.isWebKit){this.cancelDrag=!0;var p=e.container;p.draggable=!0}this.setState("dragWait")}else this.startDrag();this.captureMouse(t,this.onMouseDrag.bind(this)),t.defaultPrevented=!0}}}}).call(r.prototype);function n(t,e,o,a){return Math.sqrt(Math.pow(o-t,2)+Math.pow(a-e,2))}L.DragdropHandler=r}),ace.define("ace/mouse/touch_handler",["require","exports","module","ace/mouse/mouse_event","ace/lib/event","ace/lib/dom"],function(_,L,E){"use strict";var y=_("./mouse_event").MouseEvent,w=_("../lib/event"),v=_("../lib/dom");L.addTouchListeners=function(s,l){var i="scroll",r,n,t,e,o,a,c=0,u,p=0,m=0,$=0,C,g;function M(){var f=window.navigator&&window.navigator.clipboard,b=!1,T=function(){var I=l.getCopyText(),N=l.session.getUndoManager().hasUndo();g.replaceChild(v.buildDom(b?["span",!I&&x("selectall")&&["span",{class:"ace_mobile-button",action:"selectall"},"Select All"],I&&x("copy")&&["span",{class:"ace_mobile-button",action:"copy"},"Copy"],I&&x("cut")&&["span",{class:"ace_mobile-button",action:"cut"},"Cut"],f&&x("paste")&&["span",{class:"ace_mobile-button",action:"paste"},"Paste"],N&&x("undo")&&["span",{class:"ace_mobile-button",action:"undo"},"Undo"],x("find")&&["span",{class:"ace_mobile-button",action:"find"},"Find"],x("openCommandPalette")&&["span",{class:"ace_mobile-button",action:"openCommandPalette"},"Palette"]]:["span"]),g.firstChild)},x=function(I){return l.commands.canExecute(I,l)},R=function(I){var N=I.target.getAttribute("action");if(N=="more"||!b)return b=!b,T();N=="paste"?f.readText().then(function(D){l.execCommand(N,D)}):N&&((N=="cut"||N=="copy")&&(f?f.writeText(l.getCopyText()):document.execCommand("copy")),l.execCommand(N)),g.firstChild.style.display="none",b=!1,N!="openCommandPalette"&&l.focus()};g=v.buildDom(["div",{class:"ace_mobile-menu",ontouchstart:function(I){i="menu",I.stopPropagation(),I.preventDefault(),l.textInput.focus()},ontouchend:function(I){I.stopPropagation(),I.preventDefault(),R(I)},onclick:R},["span"],["span",{class:"ace_mobile-button",action:"more"},"..."]],l.container)}function A(){if(!l.getOption("enableMobileMenu")){g&&S();return}g||M();var f=l.selection.cursor,b=l.renderer.textToScreenCoordinates(f.row,f.column),T=l.renderer.textToScreenCoordinates(0,0).pageX,x=l.renderer.scrollLeft,R=l.container.getBoundingClientRect();g.style.top=b.pageY-R.top-3+"px",b.pageX-R.left=2?l.selection.getLineRange(u.row):l.session.getBracketRange(u);f&&!f.isEmpty()?l.selection.setRange(f):l.selection.selectWord(),i="wait"}w.addListener(s,"contextmenu",function(f){if(C){var b=l.textInput.getElement();b.focus()}},l),w.addListener(s,"touchstart",function(f){var b=f.touches;if(o||b.length>1){clearTimeout(o),o=null,t=-1,i="zoom";return}C=l.$mouseHandler.isMousePressed=!0;var T=l.renderer.layerConfig.lineHeight,x=l.renderer.layerConfig.lineHeight,R=f.timeStamp;e=R;var I=b[0],N=I.clientX,D=I.clientY;Math.abs(r-N)+Math.abs(n-D)>T&&(t=-1),r=f.clientX=N,n=f.clientY=D,m=$=0;var B=new y(f,l);if(u=B.getDocumentPosition(),R-t<500&&b.length==1&&!c)p++,f.preventDefault(),f.button=0,d();else{p=0;var F=l.selection.cursor,z=l.selection.isEmpty()?F:l.selection.anchor,H=l.renderer.$cursorLayer.getPixelPosition(F,!0),U=l.renderer.$cursorLayer.getPixelPosition(z,!0),K=l.renderer.scroller.getBoundingClientRect(),q=l.renderer.layerConfig.offset,ee=l.renderer.scrollLeft,Y=function(ae,ce){return ae=ae/x,ce=ce/T-.75,ae*ae+ce*ce};if(f.clientXX?"cursor":"anchor"),X<3.5?i="anchor":Z<3.5?i="cursor":i="scroll",o=setTimeout(k,450)}t=R},l),w.addListener(s,"touchend",function(f){C=l.$mouseHandler.isMousePressed=!1,a&&clearInterval(a),i=="zoom"?(i="",c=0):o?(l.selection.moveToPosition(u),c=0,A()):i=="scroll"?(h(),S()):A(),clearTimeout(o),o=null},l),w.addListener(s,"touchmove",function(f){o&&(clearTimeout(o),o=null);var b=f.touches;if(!(b.length>1||i=="zoom")){var T=b[0],x=r-T.clientX,R=n-T.clientY;if(i=="wait")if(x*x+R*R>4)i="cursor";else return f.preventDefault();r=T.clientX,n=T.clientY,f.clientX=T.clientX,f.clientY=T.clientY;var I=f.timeStamp,N=I-e;if(e=I,i=="scroll"){var D=new y(f,l);D.speed=1,D.wheelX=x,D.wheelY=R,10*Math.abs(x)0)if(ke==16){for(be=_e;be-1){for(be=_e;be=0&&X[De]==k;De--)Y[De]=v}}}function H(ee,Y,Z){if(!(s=ee){for(ce=ae+1;ce=ee;)ce++;for(de=ae,oe=ce-1;de=Y.length||(ce=Z[X-1])!=$&&ce!=C||(de=Y[X+1])!=$&&de!=C?g:(l&&(de=C),de==ce?de:g);case h:return ce=X>0?Z[X-1]:M,ce==$&&X+10&&Z[X-1]==$)return $;if(l)return g;for(fe=X+1,oe=Y.length;fe=1425&&ke<=2303||ke==64286;if(ce=Y[fe],Re&&(ce==m||ce==S))return m}return X<1||(ce=Y[X-1])==M?g:Z[X-1];case M:return l=!1,r=!0,v;case A:return n=!0,g;case T:case x:case I:case N:case R:l=!1;case D:return g}}function K(ee){var Y=ee.charCodeAt(0),Z=Y>>8;return Z==0?Y>191?p:B[Y]:Z==5?/[\u0591-\u05f4]/.test(ee)?m:p:Z==6?/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(ee)?b:/[\u0660-\u0669\u066b-\u066c]/.test(ee)?C:Y==1642?f:/[\u06f0-\u06f9]/.test(ee)?$:S:Z==32&&Y<=8287?F[Y&255]:Z==254&&Y>=65136?S:g}function q(ee){return ee>="\u064B"&&ee<="\u0655"}L.L=p,L.R=m,L.EN=$,L.ON_R=3,L.AN=4,L.R_H=5,L.B=6,L.RLE=7,L.DOT="\xB7",L.doBidiReorder=function(ee,Y,Z){if(ee.length<2)return{};var X=ee.split(""),ae=new Array(X.length),ce=new Array(X.length),de=[];v=Z?u:c,z(X,de,X.length,Y);for(var oe=0;oeS&&Y[oe]0&&X[oe-1]==="\u0644"&&/\u0622|\u0623|\u0625|\u0627/.test(X[oe])&&(de[oe-1]=de[oe]=L.R_H,oe++);X[X.length-1]===L.DOT&&(de[X.length-1]=L.B),X[0]==="\u202B"&&(de[0]=L.RLE);for(var oe=0;oe=0&&(i=this.session.$docRowCache[n])}return i},l.prototype.getSplitIndex=function(){var i=0,r=this.session.$screenRowCache;if(r.length)for(var n,t=this.session.$getRowCacheIndex(r,this.currentRow);this.currentRow-i>0&&(n=this.session.$getRowCacheIndex(r,this.currentRow-i-1),n===t);)t=n,i++;else i=this.currentRow;return i},l.prototype.updateRowLine=function(i,r){i===void 0&&(i=this.getDocumentRow());var n=i===this.session.getLength()-1,t=n?this.EOF:this.EOL;if(this.wrapIndent=0,this.line=this.session.getLine(i),this.isRtlDir=this.$isRtl||this.line.charAt(0)===this.RLE,this.session.$useWrapMode){var e=this.session.$wrapData[i];e&&(r===void 0&&(r=this.getSplitIndex()),r>0&&e.length?(this.wrapIndent=e.indent,this.wrapOffset=this.wrapIndent*this.charWidths[y.L],this.line=rr?this.session.getOverwrite()?i:i-1:r,t=y.getVisualFromLogicalIdx(n,this.bidiMap),e=this.bidiMap.bidiLevels,o=0;!this.session.getOverwrite()&&i<=r&&e[t]%2!==0&&t++;for(var a=0;ar&&e[t]%2===0&&(o+=this.charWidths[e[t]]),this.wrapIndent&&(o+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset),this.isRtlDir&&(o+=this.rtlLineOffset),o},l.prototype.getSelections=function(i,r){var n=this.bidiMap,t=n.bidiLevels,e,o=[],a=0,c=Math.min(i,r)-this.wrapIndent,u=Math.max(i,r)-this.wrapIndent,p=!1,m=!1,$=0;this.wrapIndent&&(a+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);for(var C,g=0;g=c&&Ct+a/2;){if(t+=a,e===o.length-1){a=0;break}a=this.charWidths[o[++e]]}return e>0&&o[e-1]%2!==0&&o[e]%2===0?(n0&&o[e-1]%2===0&&o[e]%2!==0?r=1+(n>t?this.bidiMap.logicalFromVisual[e]:this.bidiMap.logicalFromVisual[e-1]):this.isRtlDir&&e===o.length-1&&a===0&&o[e-1]%2===0||!this.isRtlDir&&e===0&&o[e]%2!==0?r=1+this.bidiMap.logicalFromVisual[e]:(e>0&&o[e-1]%2!==0&&a!==0&&e--,r=this.bidiMap.logicalFromVisual[e]),r===0&&this.isRtlDir&&r++,r+this.wrapIndent},l}();L.BidiHandler=s}),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],function(_,L,E){"use strict";var y=_("./lib/oop"),w=_("./lib/lang"),v=_("./lib/event_emitter").EventEmitter,s=_("./range").Range,l=function(){function i(r){this.session=r,this.doc=r.getDocument(),this.clearSelection(),this.cursor=this.lead=this.doc.createAnchor(0,0),this.anchor=this.doc.createAnchor(0,0),this.$silent=!1;var n=this;this.cursor.on("change",function(t){n.$cursorChanged=!0,n.$silent||n._emit("changeCursor"),!n.$isEmpty&&!n.$silent&&n._emit("changeSelection"),!n.$keepDesiredColumnOnChange&&t.old.column!=t.value.column&&(n.$desiredColumn=null)}),this.anchor.on("change",function(){n.$anchorChanged=!0,!n.$isEmpty&&!n.$silent&&n._emit("changeSelection")})}return i.prototype.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column},i.prototype.isMultiLine=function(){return!this.$isEmpty&&this.anchor.row!=this.cursor.row},i.prototype.getCursor=function(){return this.lead.getPosition()},i.prototype.setAnchor=function(r,n){this.$isEmpty=!1,this.anchor.setPosition(r,n)},i.prototype.getAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},i.prototype.getSelectionLead=function(){return this.lead.getPosition()},i.prototype.isBackwards=function(){var r=this.anchor,n=this.lead;return r.row>n.row||r.row==n.row&&r.column>n.column},i.prototype.getRange=function(){var r=this.anchor,n=this.lead;return this.$isEmpty?s.fromPoints(n,n):this.isBackwards()?s.fromPoints(n,r):s.fromPoints(r,n)},i.prototype.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))},i.prototype.selectAll=function(){this.$setSelection(0,0,Number.MAX_VALUE,Number.MAX_VALUE)},i.prototype.setRange=function(r,n){var t=n?r.end:r.start,e=n?r.start:r.end;this.$setSelection(t.row,t.column,e.row,e.column)},i.prototype.$setSelection=function(r,n,t,e){if(!this.$silent){var o=this.$isEmpty,a=this.inMultiSelectMode;this.$silent=!0,this.$cursorChanged=this.$anchorChanged=!1,this.anchor.setPosition(r,n),this.cursor.setPosition(t,e),this.$isEmpty=!s.comparePoints(this.anchor,this.cursor),this.$silent=!1,this.$cursorChanged&&this._emit("changeCursor"),(this.$cursorChanged||this.$anchorChanged||o!=this.$isEmpty||a)&&this._emit("changeSelection")}},i.prototype.$moveSelection=function(r){var n=this.lead;this.$isEmpty&&this.setSelectionAnchor(n.row,n.column),r.call(this)},i.prototype.selectTo=function(r,n){this.$moveSelection(function(){this.moveCursorTo(r,n)})},i.prototype.selectToPosition=function(r){this.$moveSelection(function(){this.moveCursorToPosition(r)})},i.prototype.moveTo=function(r,n){this.clearSelection(),this.moveCursorTo(r,n)},i.prototype.moveToPosition=function(r){this.clearSelection(),this.moveCursorToPosition(r)},i.prototype.selectUp=function(){this.$moveSelection(this.moveCursorUp)},i.prototype.selectDown=function(){this.$moveSelection(this.moveCursorDown)},i.prototype.selectRight=function(){this.$moveSelection(this.moveCursorRight)},i.prototype.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)},i.prototype.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)},i.prototype.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)},i.prototype.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)},i.prototype.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)},i.prototype.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)},i.prototype.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)},i.prototype.getWordRange=function(r,n){if(typeof n=="undefined"){var t=r||this.lead;r=t.row,n=t.column}return this.session.getWordRange(r,n)},i.prototype.selectWord=function(){this.setSelectionRange(this.getWordRange())},i.prototype.selectAWord=function(){var r=this.getCursor(),n=this.session.getAWordRange(r.row,r.column);this.setSelectionRange(n)},i.prototype.getLineRange=function(r,n){var t=typeof r=="number"?r:this.lead.row,e,o=this.session.getFoldLine(t);return o?(t=o.start.row,e=o.end.row):e=t,n===!0?new s(t,0,e,this.session.getLine(e).length):new s(t,0,e+1,0)},i.prototype.selectLine=function(){this.setSelectionRange(this.getLineRange())},i.prototype.moveCursorUp=function(){this.moveCursorBy(-1,0)},i.prototype.moveCursorDown=function(){this.moveCursorBy(1,0)},i.prototype.wouldMoveIntoSoftTab=function(r,n,t){var e=r.column,o=r.column+n;return t<0&&(e=r.column-n,o=r.column),this.session.isTabStop(r)&&this.doc.getLine(r.row).slice(e,o).split(" ").length-1==n},i.prototype.moveCursorLeft=function(){var r=this.lead.getPosition(),n;if(n=this.session.getFoldAt(r.row,r.column,-1))this.moveCursorTo(n.start.row,n.start.column);else if(r.column===0)r.row>0&&this.moveCursorTo(r.row-1,this.doc.getLine(r.row-1).length);else{var t=this.session.getTabSize();this.wouldMoveIntoSoftTab(r,t,-1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,-t):this.moveCursorBy(0,-1)}},i.prototype.moveCursorRight=function(){var r=this.lead.getPosition(),n;if(n=this.session.getFoldAt(r.row,r.column,1))this.moveCursorTo(n.end.row,n.end.column);else if(this.lead.column==this.doc.getLine(this.lead.row).length)this.lead.row0&&(n.column=e)}}this.moveCursorTo(n.row,n.column)},i.prototype.moveCursorFileEnd=function(){var r=this.doc.getLength()-1,n=this.doc.getLine(r).length;this.moveCursorTo(r,n)},i.prototype.moveCursorFileStart=function(){this.moveCursorTo(0,0)},i.prototype.moveCursorLongWordRight=function(){var r=this.lead.row,n=this.lead.column,t=this.doc.getLine(r),e=t.substring(n);this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var o=this.session.getFoldAt(r,n,1);if(o){this.moveCursorTo(o.end.row,o.end.column);return}if(this.session.nonTokenRe.exec(e)&&(n+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,e=t.substring(n)),n>=t.length){this.moveCursorTo(r,t.length),this.moveCursorRight(),r0&&this.moveCursorWordLeft();return}this.session.tokenRe.exec(o)&&(n-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(r,n)},i.prototype.$shortWordEndIndex=function(r){var n=0,t,e=/\s/,o=this.session.tokenRe;if(o.lastIndex=0,this.session.tokenRe.exec(r))n=this.session.tokenRe.lastIndex;else{for(;(t=r[n])&&e.test(t);)n++;if(n<1){for(o.lastIndex=0;(t=r[n])&&!o.test(t);)if(o.lastIndex=0,n++,e.test(t))if(n>2){n--;break}else{for(;(t=r[n])&&e.test(t);)n++;if(n>2)break}}}return o.lastIndex=0,n},i.prototype.moveCursorShortWordRight=function(){var r=this.lead.row,n=this.lead.column,t=this.doc.getLine(r),e=t.substring(n),o=this.session.getFoldAt(r,n,1);if(o)return this.moveCursorTo(o.end.row,o.end.column);if(n==t.length){var a=this.doc.getLength();do r++,e=this.doc.getLine(r);while(r0&&/^\s*$/.test(e));n=e.length,/\s+$/.test(e)||(e="")}var o=w.stringReverse(e),a=this.$shortWordEndIndex(o);return this.moveCursorTo(r,n-a)},i.prototype.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},i.prototype.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},i.prototype.moveCursorBy=function(r,n){var t=this.session.documentToScreenPosition(this.lead.row,this.lead.column),e;if(n===0&&(r!==0&&(this.session.$bidiHandler.isBidiRow(t.row,this.lead.row)?(e=this.session.$bidiHandler.getPosLeft(t.column),t.column=Math.round(e/this.session.$bidiHandler.charWidths[0])):e=t.column*this.session.$bidiHandler.charWidths[0]),this.$desiredColumn?t.column=this.$desiredColumn:this.$desiredColumn=t.column),r!=0&&this.session.lineWidgets&&this.session.lineWidgets[this.lead.row]){var o=this.session.lineWidgets[this.lead.row];r<0?r-=o.rowsAbove||0:r>0&&(r+=o.rowCount-(o.rowsAbove||0))}var a=this.session.screenToDocumentPosition(t.row+r,t.column,e);r!==0&&n===0&&a.row===this.lead.row&&(a.column,this.lead.column),this.moveCursorTo(a.row,a.column+n,n===0)},i.prototype.moveCursorToPosition=function(r){this.moveCursorTo(r.row,r.column)},i.prototype.moveCursorTo=function(r,n,t){var e=this.session.getFoldAt(r,n,1);e&&(r=e.start.row,n=e.start.column),this.$keepDesiredColumnOnChange=!0;var o=this.session.getLine(r);/[\uDC00-\uDFFF]/.test(o.charAt(n))&&o.charAt(n-1)&&(this.lead.row==r&&this.lead.column==n+1?n=n-1:n=n+1),this.lead.setPosition(r,n),this.$keepDesiredColumnOnChange=!1,t||(this.$desiredColumn=null)},i.prototype.moveCursorToScreen=function(r,n,t){var e=this.session.screenToDocumentPosition(r,n);this.moveCursorTo(e.row,e.column,t)},i.prototype.detach=function(){this.lead.detach(),this.anchor.detach()},i.prototype.fromOrientedRange=function(r){this.setSelectionRange(r,r.cursor==r.start),this.$desiredColumn=r.desiredColumn||this.$desiredColumn},i.prototype.toOrientedRange=function(r){var n=this.getRange();return r?(r.start.column=n.start.column,r.start.row=n.start.row,r.end.column=n.end.column,r.end.row=n.end.row):r=n,r.cursor=this.isBackwards()?r.start:r.end,r.desiredColumn=this.$desiredColumn,r},i.prototype.getRangeOfMovements=function(r){var n=this.getCursor();try{r(this);var t=this.getCursor();return s.fromPoints(n,t)}catch(e){return s.fromPoints(n,n)}finally{this.moveCursorToPosition(n)}},i.prototype.toJSON=function(){if(this.rangeCount)var r=this.ranges.map(function(n){var t=n.clone();return t.isBackwards=n.cursor==n.start,t});else{var r=this.getRange();r.isBackwards=this.isBackwards()}return r},i.prototype.fromJSON=function(r){if(r.start==null)if(this.rangeList&&r.length>1){this.toSingleRange(r[0]);for(var n=r.length;n--;){var t=s.fromPoints(r[n].start,r[n].end);r[n].isBackwards&&(t.cursor=t.start),this.addRange(t,!0)}return}else r=r[0];this.rangeList&&this.toSingleRange(r),this.setSelectionRange(r,r.isBackwards)},i.prototype.isEqual=function(r){if((r.length||this.rangeCount)&&r.length!=this.rangeCount)return!1;if(!r.length||!this.ranges)return this.getRange().isEqual(r);for(var n=this.ranges.length;n--;)if(!this.ranges[n].isEqual(r[n]))return!1;return!0},i}();l.prototype.setSelectionAnchor=l.prototype.setAnchor,l.prototype.getSelectionAnchor=l.prototype.getAnchor,l.prototype.setSelectionRange=l.prototype.setRange,y.implement(l.prototype,v),L.Selection=l}),ace.define("ace/tokenizer",["require","exports","module","ace/lib/report_error"],function(_,L,E){"use strict";var y=_("./lib/report_error").reportError,w=2e3,v=function(){function s(l){this.splitRegex,this.states=l,this.regExps={},this.matchMappings={};for(var i in this.states){for(var r=this.states[i],n=[],t=0,e=this.matchMappings[i]={defaultToken:"text"},o="g",a=[],c=0;c1?u.onMatch=this.$applyToken:u.onMatch=u.token),m>1&&(/\\\d/.test(u.regex)?p=u.regex.replace(/\\([0-9]+)/g,function($,C){return"\\"+(parseInt(C,10)+t+1)}):(m=1,p=this.removeCapturingGroups(u.regex)),!u.splitRegex&&typeof u.token!="string"&&a.push(u)),e[t]=c,t+=m,n.push(p),u.onMatch||(u.onMatch=null)}}n.length||(e[0]=0,n.push("$")),a.forEach(function($){$.splitRegex=this.createSplitterRegexp($.regex,o)},this),this.regExps[i]=new RegExp("("+n.join(")|(")+")|($)",o)}}return s.prototype.$setMaxTokenCount=function(l){w=l|0},s.prototype.$applyToken=function(l){var i=this.splitRegex.exec(l).slice(1),r=this.token.apply(this,i);if(typeof r=="string")return[{type:r,value:l}];for(var n=[],t=0,e=r.length;tu){var A=l.substring(u,M-g.length);m.type==$?m.value+=A:(m.type&&c.push(m),m={type:$,value:A})}for(var S=0;Sw){for(p>2*l.length&&this.reportError("infinite loop with in ace tokenizer",{startState:i,line:l});u1&&r[0]!==n&&r.unshift("#tmp",n),{tokens:c,state:r.length?r:n}},s}();v.prototype.reportError=y,L.Tokenizer=v}),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/deep_copy"],function(_,L,E){"use strict";var y=_("../lib/deep_copy").deepCopy,w;w=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}},function(){this.addRules=function(l,i){if(!i){for(var r in l)this.$rules[r]=l[r];return}for(var r in l){for(var n=l[r],t=0;t=this.$rowTokens.length;){if(this.$row+=1,s||(s=this.$session.getLength()),this.$row>=s)return this.$row=s-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},v.prototype.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},v.prototype.getCurrentTokenRow=function(){return this.$row},v.prototype.getCurrentTokenColumn=function(){var s=this.$rowTokens,l=this.$tokenIndex,i=s[l].start;if(i!==void 0)return i;for(i=0;l>0;)l-=1,i+=s[l].value.length;return i},v.prototype.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}},v.prototype.getCurrentTokenRange=function(){var s=this.$rowTokens[this.$tokenIndex],l=this.getCurrentTokenColumn();return new y(this.$row,l,this.$row,l+s.value.length)},v}();L.TokenIterator=w}),ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"],function(_,L,E){"use strict";var y=_("../../lib/oop"),w=_("../behaviour").Behaviour,v=_("../../token_iterator").TokenIterator,s=_("../../lib/lang"),l=["text","paren.rparen","rparen","paren","punctuation.operator"],i=["text","paren.rparen","rparen","paren","punctuation.operator","comment"],r,n={},t={'"':'"',"'":"'"},e=function(c){var u=-1;if(c.multiSelect&&(u=c.selection.index,n.rangeCount!=c.multiSelect.rangeCount&&(n={rangeCount:c.multiSelect.rangeCount})),n[u])return r=n[u];r=n[u]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}},o=function(c,u,p,m){var $=c.end.row-c.start.row;return{text:p+u+m,selection:[0,c.start.column+1,$,c.end.column+($?0:1)]}},a;a=function(c){c=c||{},this.add("braces","insertion",function(u,p,m,$,C){var g=m.getCursorPosition(),M=$.doc.getLine(g.row);if(C=="{"){e(m);var A=m.getSelectionRange(),S=$.doc.getTextRange(A),k=$.getTokenAt(g.row,g.column);if(S!==""&&S!=="{"&&m.getWrapBehavioursEnabled())return o(A,S,"{","}");if(k&&/(?:string)\.quasi|\.xml/.test(k.type)){var d=[/tag\-(?:open|name)/,/attribute\-name/];return d.some(function(I){return I.test(k.type)})||/(string)\.quasi/.test(k.type)&&k.value[g.column-k.start-1]!=="$"?void 0:(a.recordAutoInsert(m,$,"}"),{text:"{}",selection:[1,1]})}else if(a.isSaneInsertion(m,$))return/[\]\}\)]/.test(M[g.column])||m.inMultiSelectMode||c.braces?(a.recordAutoInsert(m,$,"}"),{text:"{}",selection:[1,1]}):(a.recordMaybeInsert(m,$,"{"),{text:"{",selection:[1,1]})}else if(C=="}"){e(m);var h=M.substring(g.column,g.column+1);if(h=="}"){var f=$.$findOpeningBracket("}",{column:g.column+1,row:g.row});if(f!==null&&a.isAutoInsertedClosing(g,M,C))return a.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}else if(C==` +`||C==`\r +`){e(m);var b="";a.isMaybeInsertedClosing(g,M)&&(b=s.stringRepeat("}",r.maybeInsertedBrackets),a.clearMaybeInsertedClosing());var h=M.substring(g.column,g.column+1);if(h==="}"){var T=$.findMatchingBracket({row:g.row,column:g.column+1},"}");if(!T)return null;var x=this.$getIndent($.getLine(T.row))}else if(b)var x=this.$getIndent(M);else{a.clearMaybeInsertedClosing();return}var R=x+$.getTabString();return{text:` +`+R+` +`+x+b,selection:[1,R.length,1,R.length]}}else a.clearMaybeInsertedClosing()}),this.add("braces","deletion",function(u,p,m,$,C){var g=$.doc.getTextRange(C);if(!C.isMultiLine()&&g=="{"){e(m);var M=$.doc.getLine(C.start.row),A=M.substring(C.end.column,C.end.column+1);if(A=="}")return C.end.column++,C;r.maybeInsertedBrackets--}}),this.add("parens","insertion",function(u,p,m,$,C){if(C=="("){e(m);var g=m.getSelectionRange(),M=$.doc.getTextRange(g);if(M!==""&&m.getWrapBehavioursEnabled())return o(g,M,"(",")");if(a.isSaneInsertion(m,$))return a.recordAutoInsert(m,$,")"),{text:"()",selection:[1,1]}}else if(C==")"){e(m);var A=m.getCursorPosition(),S=$.doc.getLine(A.row),k=S.substring(A.column,A.column+1);if(k==")"){var d=$.$findOpeningBracket(")",{column:A.column+1,row:A.row});if(d!==null&&a.isAutoInsertedClosing(A,S,C))return a.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("parens","deletion",function(u,p,m,$,C){var g=$.doc.getTextRange(C);if(!C.isMultiLine()&&g=="("){e(m);var M=$.doc.getLine(C.start.row),A=M.substring(C.start.column+1,C.start.column+2);if(A==")")return C.end.column++,C}}),this.add("brackets","insertion",function(u,p,m,$,C){if(C=="["){e(m);var g=m.getSelectionRange(),M=$.doc.getTextRange(g);if(M!==""&&m.getWrapBehavioursEnabled())return o(g,M,"[","]");if(a.isSaneInsertion(m,$))return a.recordAutoInsert(m,$,"]"),{text:"[]",selection:[1,1]}}else if(C=="]"){e(m);var A=m.getCursorPosition(),S=$.doc.getLine(A.row),k=S.substring(A.column,A.column+1);if(k=="]"){var d=$.$findOpeningBracket("]",{column:A.column+1,row:A.row});if(d!==null&&a.isAutoInsertedClosing(A,S,C))return a.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("brackets","deletion",function(u,p,m,$,C){var g=$.doc.getTextRange(C);if(!C.isMultiLine()&&g=="["){e(m);var M=$.doc.getLine(C.start.row),A=M.substring(C.start.column+1,C.start.column+2);if(A=="]")return C.end.column++,C}}),this.add("string_dquotes","insertion",function(u,p,m,$,C){var g=$.$mode.$quotes||t;if(C.length==1&&g[C]){if(this.lineCommentStart&&this.lineCommentStart.indexOf(C)!=-1)return;e(m);var M=C,A=m.getSelectionRange(),S=$.doc.getTextRange(A);if(S!==""&&(S.length!=1||!g[S])&&m.getWrapBehavioursEnabled())return o(A,S,M,M);if(!S){var k=m.getCursorPosition(),d=$.doc.getLine(k.row),h=d.substring(k.column-1,k.column),f=d.substring(k.column,k.column+1),b=$.getTokenAt(k.row,k.column),T=$.getTokenAt(k.row,k.column+1);if(h=="\\"&&b&&/escape/.test(b.type))return null;var x=b&&/string|escape/.test(b.type),R=!T||/string|escape/.test(T.type),I;if(f==M)I=x!==R,I&&/string\.end/.test(T.type)&&(I=!1);else{if(x&&!R||x&&R)return null;var N=$.$mode.tokenRe;N.lastIndex=0;var D=N.test(h);N.lastIndex=0;var B=N.test(f),F=$.$mode.$pairQuotesAfter,z=F&&F[M]&&F[M].test(h);if(!z&&D||B||f&&!/[\s;,.})\]\\]/.test(f))return null;var H=d[k.column-2];if(h==M&&(H==M||N.test(H)))return null;I=!0}return{text:I?M+M:"",selection:[1,1]}}}}),this.add("string_dquotes","deletion",function(u,p,m,$,C){var g=$.$mode.$quotes||t,M=$.doc.getTextRange(C);if(!C.isMultiLine()&&g.hasOwnProperty(M)){e(m);var A=$.doc.getLine(C.start.row),S=A.substring(C.start.column+1,C.start.column+2);if(S==M)return C.end.column++,C}}),c.closeDocComment!==!1&&this.add("doc comment end","insertion",function(u,p,m,$,C){if(u==="doc-start"&&(C===` +`||C===`\r +`)&&m.selection.isEmpty()){var g=m.getCursorPosition();if(g.column===0)return;for(var M=$.doc.getLine(g.row),A=$.doc.getLine(g.row+1),S=$.getTokens(g.row),k=0,d=0;d=g.column){if(k===g.column){if(!/\.doc/.test(h.type))return;if(/\*\//.test(h.value)){var f=S[d+1];if(!f||!/\.doc/.test(f.type))return}}var b=g.column-(k-h.value.length),T=h.value.indexOf("*/"),x=h.value.indexOf("/**",T>-1?T+2:0);if(x!==-1&&b>x&&b=T&&b<=x||!/\.doc/.test(h.type))return;break}}var R=this.$getIndent(M);if(/\s*\*/.test(A))return/^\s*\*/.test(M)?{text:C+R+"* ",selection:[1,2+R.length,1,2+R.length]}:{text:C+R+" * ",selection:[1,3+R.length,1,3+R.length]};if(/\/\*\*/.test(M.substring(0,g.column)))return{text:C+R+" * "+C+" "+R+"*/",selection:[1,4+R.length,1,4+R.length]}}})},a.isSaneInsertion=function(c,u){var p=c.getCursorPosition(),m=new v(u,p.row,p.column);if(!this.$matchTokenType(m.getCurrentToken()||"text",l)){if(/[)}\]]/.test(c.session.getLine(p.row)[p.column]))return!0;var $=new v(u,p.row,p.column+1);if(!this.$matchTokenType($.getCurrentToken()||"text",l))return!1}return m.stepForward(),m.getCurrentTokenRow()!==p.row||this.$matchTokenType(m.getCurrentToken()||"text",i)},a.$matchTokenType=function(c,u){return u.indexOf(c.type||c)>-1},a.recordAutoInsert=function(c,u,p){var m=c.getCursorPosition(),$=u.doc.getLine(m.row);this.isAutoInsertedClosing(m,$,r.autoInsertedLineEnd[0])||(r.autoInsertedBrackets=0),r.autoInsertedRow=m.row,r.autoInsertedLineEnd=p+$.substr(m.column),r.autoInsertedBrackets++},a.recordMaybeInsert=function(c,u,p){var m=c.getCursorPosition(),$=u.doc.getLine(m.row);this.isMaybeInsertedClosing(m,$)||(r.maybeInsertedBrackets=0),r.maybeInsertedRow=m.row,r.maybeInsertedLineStart=$.substr(0,m.column)+p,r.maybeInsertedLineEnd=$.substr(m.column),r.maybeInsertedBrackets++},a.isAutoInsertedClosing=function(c,u,p){return r.autoInsertedBrackets>0&&c.row===r.autoInsertedRow&&p===r.autoInsertedLineEnd[0]&&u.substr(c.column)===r.autoInsertedLineEnd},a.isMaybeInsertedClosing=function(c,u){return r.maybeInsertedBrackets>0&&c.row===r.maybeInsertedRow&&u.substr(c.column)===r.maybeInsertedLineEnd&&u.substr(0,c.column)==r.maybeInsertedLineStart},a.popAutoInsertedClosing=function(){r.autoInsertedLineEnd=r.autoInsertedLineEnd.substr(1),r.autoInsertedBrackets--},a.clearMaybeInsertedClosing=function(){r&&(r.maybeInsertedBrackets=0,r.maybeInsertedRow=-1)},y.inherits(a,w),L.CstyleBehaviour=a}),ace.define("ace/unicode",["require","exports","module"],function(_,L,E){"use strict";for(var y=[48,9,8,25,5,0,2,25,48,0,11,0,5,0,6,22,2,30,2,457,5,11,15,4,8,0,2,0,18,116,2,1,3,3,9,0,2,2,2,0,2,19,2,82,2,138,2,4,3,155,12,37,3,0,8,38,10,44,2,0,2,1,2,1,2,0,9,26,6,2,30,10,7,61,2,9,5,101,2,7,3,9,2,18,3,0,17,58,3,100,15,53,5,0,6,45,211,57,3,18,2,5,3,11,3,9,2,1,7,6,2,2,2,7,3,1,3,21,2,6,2,0,4,3,3,8,3,1,3,3,9,0,5,1,2,4,3,11,16,2,2,5,5,1,3,21,2,6,2,1,2,1,2,1,3,0,2,4,5,1,3,2,4,0,8,3,2,0,8,15,12,2,2,8,2,2,2,21,2,6,2,1,2,4,3,9,2,2,2,2,3,0,16,3,3,9,18,2,2,7,3,1,3,21,2,6,2,1,2,4,3,8,3,1,3,2,9,1,5,1,2,4,3,9,2,0,17,1,2,5,4,2,2,3,4,1,2,0,2,1,4,1,4,2,4,11,5,4,4,2,2,3,3,0,7,0,15,9,18,2,2,7,2,2,2,22,2,9,2,4,4,7,2,2,2,3,8,1,2,1,7,3,3,9,19,1,2,7,2,2,2,22,2,9,2,4,3,8,2,2,2,3,8,1,8,0,2,3,3,9,19,1,2,7,2,2,2,22,2,15,4,7,2,2,2,3,10,0,9,3,3,9,11,5,3,1,2,17,4,23,2,8,2,0,3,6,4,0,5,5,2,0,2,7,19,1,14,57,6,14,2,9,40,1,2,0,3,1,2,0,3,0,7,3,2,6,2,2,2,0,2,0,3,1,2,12,2,2,3,4,2,0,2,5,3,9,3,1,35,0,24,1,7,9,12,0,2,0,2,0,5,9,2,35,5,19,2,5,5,7,2,35,10,0,58,73,7,77,3,37,11,42,2,0,4,328,2,3,3,6,2,0,2,3,3,40,2,3,3,32,2,3,3,6,2,0,2,3,3,14,2,56,2,3,3,66,5,0,33,15,17,84,13,619,3,16,2,25,6,74,22,12,2,6,12,20,12,19,13,12,2,2,2,1,13,51,3,29,4,0,5,1,3,9,34,2,3,9,7,87,9,42,6,69,11,28,4,11,5,11,11,39,3,4,12,43,5,25,7,10,38,27,5,62,2,28,3,10,7,9,14,0,89,75,5,9,18,8,13,42,4,11,71,55,9,9,4,48,83,2,2,30,14,230,23,280,3,5,3,37,3,5,3,7,2,0,2,0,2,0,2,30,3,52,2,6,2,0,4,2,2,6,4,3,3,5,5,12,6,2,2,6,67,1,20,0,29,0,14,0,17,4,60,12,5,0,4,11,18,0,5,0,3,9,2,0,4,4,7,0,2,0,2,0,2,3,2,10,3,3,6,4,5,0,53,1,2684,46,2,46,2,132,7,6,15,37,11,53,10,0,17,22,10,6,2,6,2,6,2,6,2,6,2,6,2,6,2,6,2,31,48,0,470,1,36,5,2,4,6,1,5,85,3,1,3,2,2,89,2,3,6,40,4,93,18,23,57,15,513,6581,75,20939,53,1164,68,45,3,268,4,27,21,31,3,13,13,1,2,24,9,69,11,1,38,8,3,102,3,1,111,44,25,51,13,68,12,9,7,23,4,0,5,45,3,35,13,28,4,64,15,10,39,54,10,13,3,9,7,22,4,1,5,66,25,2,227,42,2,1,3,9,7,11171,13,22,5,48,8453,301,3,61,3,105,39,6,13,4,6,11,2,12,2,4,2,0,2,1,2,1,2,107,34,362,19,63,3,53,41,11,5,15,17,6,13,1,25,2,33,4,2,134,20,9,8,25,5,0,2,25,12,88,4,5,3,5,3,5,3,2],w=0,v=[],s=0;s2?H%C!=C-1:H%C==0}}else{if(!this.blockComment)return!1;var M=this.blockComment.start,A=this.blockComment.end,S=new RegExp("^(\\s*)(?:"+i.escapeRegExp(M)+")"),k=new RegExp("(?:"+i.escapeRegExp(A)+")\\s*$"),d=function(I,N){f(I,N)||(!p||/\S/.test(I))&&(u.insertInLine({row:N,column:I.length},A),u.insertInLine({row:N,column:$},M))},h=function(I,N){var D;(D=I.match(k))&&u.removeInLine(N,I.length-D[0].length,I.length),(D=I.match(S))&&u.removeInLine(N,D[1].length,D[0].length)},f=function(I,N){if(S.test(I))return!0;for(var D=o.getTokens(N),B=0;BI.length&&(R=I.length)}),$==1/0&&($=R,p=!1,m=!1),g&&$%C!=0&&($=Math.floor($/C)*C),x(m?h:d)},this.toggleBlockComment=function(e,o,a,c){var u=this.blockComment;if(u){!u.start&&u[0]&&(u=u[0]);var p=new r(o,c.row,c.column),m=p.getCurrentToken(),$=o.selection,C=o.selection.toOrientedRange(),g,M;if(m&&/comment/.test(m.type)){for(var A,S;m&&/comment/.test(m.type);){var k=m.value.indexOf(u.start);if(k!=-1){var d=p.getCurrentTokenRow(),h=p.getCurrentTokenColumn()+k;A=new n(d,h,d,h+u.start.length);break}m=p.stepBackward()}for(var p=new r(o,c.row,c.column),m=p.getCurrentToken();m&&/comment/.test(m.type);){var k=m.value.indexOf(u.end);if(k!=-1){var d=p.getCurrentTokenRow(),h=p.getCurrentTokenColumn()+k;S=new n(d,h,d,h+u.end.length);break}m=p.stepForward()}S&&o.remove(S),A&&(o.remove(A),g=A.start.row,M=-u.start.length)}else M=u.start.length,g=a.start.row,o.insert(a.end,u.end),o.insert(a.start,u.start);C.start.row==g&&(C.start.column+=M),C.end.row==g&&(C.end.column+=M),o.selection.fromOrientedRange(C)}},this.getNextLineIndent=function(e,o,a){return this.$getIndent(o)},this.checkOutdent=function(e,o,a){return!1},this.autoOutdent=function(e,o,a){},this.$getIndent=function(e){return e.match(/^\s*/)[0]},this.createWorker=function(e){return null},this.createModeDelegates=function(e){this.$embeds=[],this.$modes={};for(var o in e)if(e[o]){var a=e[o],c=a.prototype.$id,u=y.$modes[c];u||(y.$modes[c]=u=new a),y.$modes[o]||(y.$modes[o]=u),this.$embeds.push(o),this.$modes[o]=u}for(var p=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"],m=function(C){(function(g){var M=p[C],A=g[M];g[p[C]]=function(){return this.$delegator(M,arguments,A)}})($)},$=this,o=0;ol[i].column&&i++,t.unshift(i,0),l.splice.apply(l,t),this.$updateRows()}}},v.prototype.$updateRows=function(){var s=this.session.lineWidgets;if(s){var l=!0;s.forEach(function(i,r){if(i)for(l=!1,i.row=r;i.$oldWidget;)i.$oldWidget.row=r,i=i.$oldWidget}),l&&(this.session.lineWidgets=null)}},v.prototype.$registerLineWidget=function(s){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength()));var l=this.session.lineWidgets[s.row];return l&&(s.$oldWidget=l,l.el&&l.el.parentNode&&(l.el.parentNode.removeChild(l.el),l._inDocument=!1)),this.session.lineWidgets[s.row]=s,s},v.prototype.addLineWidget=function(s){if(this.$registerLineWidget(s),s.session=this.session,!this.editor)return s;var l=this.editor.renderer;s.html&&!s.el&&(s.el=y.createElement("div"),s.el.innerHTML=s.html),s.text&&!s.el&&(s.el=y.createElement("div"),s.el.textContent=s.text),s.el&&(y.addCssClass(s.el,"ace_lineWidgetContainer"),s.className&&y.addCssClass(s.el,s.className),s.el.style.position="absolute",s.el.style.zIndex="5",l.container.appendChild(s.el),s._inDocument=!0,s.coverGutter||(s.el.style.zIndex="3"),s.pixelHeight==null&&(s.pixelHeight=s.el.offsetHeight)),s.rowCount==null&&(s.rowCount=s.pixelHeight/l.layerConfig.lineHeight);var i=this.session.getFoldAt(s.row,0);if(s.$fold=i,i){var r=this.session.lineWidgets;s.row==i.end.row&&!r[i.start.row]?r[i.start.row]=s:s.hidden=!0}return this.session._emit("changeFold",{data:{start:{row:s.row}}}),this.$updateRows(),this.renderWidgets(null,l),this.onWidgetChanged(s),s},v.prototype.removeLineWidget=function(s){if(s._inDocument=!1,s.session=null,s.el&&s.el.parentNode&&s.el.parentNode.removeChild(s.el),s.editor&&s.editor.destroy)try{s.editor.destroy()}catch(i){}if(this.session.lineWidgets){var l=this.session.lineWidgets[s.row];if(l==s)this.session.lineWidgets[s.row]=s.$oldWidget,s.$oldWidget&&this.onWidgetChanged(s.$oldWidget);else for(;l;){if(l.$oldWidget==s){l.$oldWidget=s.$oldWidget;break}l=l.$oldWidget}}this.session._emit("changeFold",{data:{start:{row:s.row}}}),this.$updateRows()},v.prototype.getWidgetsAtRow=function(s){for(var l=this.session.lineWidgets,i=l&&l[s],r=[];i;)r.push(i),i=i.$oldWidget;return r},v.prototype.onWidgetChanged=function(s){this.session._changedWidgets.push(s),this.editor&&this.editor.renderer.updateFull()},v.prototype.measureWidgets=function(s,l){var i=this.session._changedWidgets,r=l.layerConfig;if(!(!i||!i.length)){for(var n=1/0,t=0;t0&&!r[n];)n--;this.firstRow=i.firstRow,this.lastRow=i.lastRow,l.$cursorLayer.config=i;for(var e=n;e<=t;e++){var o=r[e];if(!(!o||!o.el)){if(o.hidden){o.el.style.top=-100-(o.pixelHeight||0)+"px";continue}o._inDocument||(o._inDocument=!0,l.container.appendChild(o.el));var a=l.$cursorLayer.getPixelPosition({row:e,column:0},!0).top;o.coverLine||(a+=i.lineHeight*this.session.getRowLineCount(o.row)),o.el.style.top=a-i.offset+"px";var c=o.coverGutter?0:l.gutterWidth;o.fixedWidth||(c-=l.scrollLeft),o.el.style.left=c+"px",o.fullWidth&&o.screenWidth&&(o.el.style.minWidth=i.width+2*i.padding+"px"),o.fixedWidth?o.el.style.right=l.scrollBar.getWidth()+"px":o.el.style.right=""}}}},v}();L.LineWidgets=w}),ace.define("ace/apply_delta",["require","exports","module"],function(_,L,E){"use strict";function y(s,l){throw console.log("Invalid Delta:",s),"Invalid Delta: "+l}function w(s,l){return l.row>=0&&l.row=0&&l.column<=s[l.row].length}function v(s,l){l.action!="insert"&&l.action!="remove"&&y(l,"delta.action must be 'insert' or 'remove'"),l.lines instanceof Array||y(l,"delta.lines must be an Array"),(!l.start||!l.end)&&y(l,"delta.start/end must be an present");var i=l.start;w(s,l.start)||y(l,"delta.start must be contained in document");var r=l.end;l.action=="remove"&&!w(s,r)&&y(l,"delta.end must contained in document for 'remove' actions");var n=r.row-i.row,t=r.column-(n==0?i.column:0);(n!=l.lines.length-1||l.lines[n].length!=t)&&y(l,"delta.range must match delta lines")}L.applyDelta=function(s,l,i){var r=l.start.row,n=l.start.column,t=s[r]||"";switch(l.action){case"insert":var e=l.lines;if(e.length===1)s[r]=t.substring(0,n)+l.lines[0]+t.substring(n);else{var o=[r,1].concat(l.lines);s.splice.apply(s,o),s[r]=t.substring(0,n)+s[r],s[r+l.lines.length-1]+=t.substring(n)}break;case"remove":var a=l.end.column,c=l.end.row;r===c?s[r]=t.substring(0,n)+t.substring(a):s.splice(r,c-r+1,t.substring(0,n)+s[c].substring(a));break}}}),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(_,L,E){"use strict";var y=_("./lib/oop"),w=_("./lib/event_emitter").EventEmitter,v=function(){function i(r,n,t){this.$onChange=this.onChange.bind(this),this.attach(r),typeof n!="number"?this.setPosition(n.row,n.column):this.setPosition(n,t)}return i.prototype.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},i.prototype.getDocument=function(){return this.document},i.prototype.onChange=function(r){if(!(r.start.row==r.end.row&&r.start.row!=this.row)&&!(r.start.row>this.row)){var n=l(r,{row:this.row,column:this.column},this.$insertRight);this.setPosition(n.row,n.column,!0)}},i.prototype.setPosition=function(r,n,t){var e;if(t?e={row:r,column:n}:e=this.$clipPositionToDocument(r,n),!(this.row==e.row&&this.column==e.column)){var o={row:this.row,column:this.column};this.row=e.row,this.column=e.column,this._signal("change",{old:o,value:e})}},i.prototype.detach=function(){this.document.off("change",this.$onChange)},i.prototype.attach=function(r){this.document=r||this.document,this.document.on("change",this.$onChange)},i.prototype.$clipPositionToDocument=function(r,n){var t={};return r>=this.document.getLength()?(t.row=Math.max(0,this.document.getLength()-1),t.column=this.document.getLine(t.row).length):r<0?(t.row=0,t.column=0):(t.row=r,t.column=Math.min(this.document.getLine(t.row).length,Math.max(0,n))),n<0&&(t.column=0),t},i}();v.prototype.$insertRight=!1,y.implement(v.prototype,w);function s(i,r,n){var t=n?i.column<=r.column:i.column=e&&(n=e-1,t=void 0);var o=this.getLine(n);return t==null&&(t=o.length),t=Math.min(Math.max(t,0),o.length),{row:n,column:t}},r.prototype.clonePos=function(n){return{row:n.row,column:n.column}},r.prototype.pos=function(n,t){return{row:n,column:t}},r.prototype.$clipPosition=function(n){var t=this.getLength();return n.row>=t?(n.row=Math.max(0,t-1),n.column=this.getLine(t-1).length):(n.row=Math.max(0,n.row),n.column=Math.min(Math.max(n.column,0),this.getLine(n.row).length)),n},r.prototype.insertFullLines=function(n,t){n=Math.min(Math.max(n,0),this.getLength());var e=0;n0,o=t=0&&this.applyDelta({start:this.pos(n,this.getLine(n).length),end:this.pos(n+1,0),action:"remove",lines:["",""]})},r.prototype.replace=function(n,t){if(n instanceof s||(n=s.fromPoints(n.start,n.end)),t.length===0&&n.isEmpty())return n.start;if(t==this.getTextRange(n))return n.end;this.remove(n);var e;return t?e=this.insert(n.start,t):e=n.start,e},r.prototype.applyDeltas=function(n){for(var t=0;t=0;t--)this.revertDelta(n[t])},r.prototype.applyDelta=function(n,t){var e=n.action=="insert";(e?n.lines.length<=1&&!n.lines[0]:!s.comparePoints(n.start,n.end))||(e&&n.lines.length>2e4?this.$splitAndapplyLargeDelta(n,2e4):(w(this.$lines,n,t),this._signal("change",n)))},r.prototype.$safeApplyDelta=function(n){var t=this.$lines.length;(n.action=="remove"&&n.start.row20){r.running=setTimeout(r.$worker,20);break}}r.currentLine=t,e==-1&&(e=t),a<=e&&r.fireUpdateEvent(a,e)}}}return s.prototype.setTokenizer=function(l){this.tokenizer=l,this.lines=[],this.states=[],this.start(0)},s.prototype.setDocument=function(l){this.doc=l,this.lines=[],this.states=[],this.stop()},s.prototype.fireUpdateEvent=function(l,i){var r={first:l,last:i};this._signal("update",{data:r})},s.prototype.start=function(l){this.currentLine=Math.min(l||0,this.currentLine,this.doc.getLength()),this.lines.splice(this.currentLine,this.lines.length),this.states.splice(this.currentLine,this.states.length),this.stop(),this.running=setTimeout(this.$worker,700)},s.prototype.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},s.prototype.$updateOnChange=function(l){var i=l.start.row,r=l.end.row-i;if(r===0)this.lines[i]=null;else if(l.action=="remove")this.lines.splice(i,r+1,null),this.states.splice(i,r+1,null);else{var n=Array(r+1);n.unshift(i,1),this.lines.splice.apply(this.lines,n),this.states.splice.apply(this.states,n)}this.currentLine=Math.min(i,this.currentLine,this.doc.getLength()),this.stop()},s.prototype.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},s.prototype.getTokens=function(l){return this.lines[l]||this.$tokenizeRow(l)},s.prototype.getState=function(l){return this.currentLine==l&&this.$tokenizeRow(l),this.states[l]||"start"},s.prototype.$tokenizeRow=function(l){var i=this.doc.getLine(l),r=this.states[l-1],n=this.tokenizer.getLineTokens(i,r,l);return this.states[l]+""!=n.state+""?(this.states[l]=n.state,this.lines[l+1]=null,this.currentLine>l+1&&(this.currentLine=l+1)):this.currentLine==l&&(this.currentLine=l+1),this.lines[l]=n.tokens},s.prototype.cleanup=function(){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.removeAllListeners()},s}();y.implement(v.prototype,w),L.BackgroundTokenizer=v}),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/range"],function(_,L,E){"use strict";var y=_("./lib/lang"),w=_("./range").Range,v=function(){function s(l,i,r){r===void 0&&(r="text"),this.setRegexp(l),this.clazz=i,this.type=r}return s.prototype.setRegexp=function(l){this.regExp+""!=l+""&&(this.regExp=l,this.cache=[])},s.prototype.update=function(l,i,r,n){if(this.regExp)for(var t=n.firstRow,e=n.lastRow,o={},a=t;a<=e;a++){var c=this.cache[a];c==null&&(c=y.getMatchOffsets(r.getLine(a),this.regExp),c.length>this.MAX_RANGES&&(c=c.slice(0,this.MAX_RANGES)),c=c.map(function($){return new w(a,$.offset,a,$.offset+$.length)}),this.cache[a]=c.length?c:"");for(var u=c.length;u--;){var p=c[u].toScreenRange(r),m=p.toString();o[m]||(o[m]=!0,i.drawSingleLineMarker(l,p,this.clazz,n))}}},s}();v.prototype.MAX_RANGES=500,L.SearchHighlight=v}),ace.define("ace/undomanager",["require","exports","module","ace/range"],function(_,L,E){"use strict";var y=function(){function g(){this.$keepRedoStack,this.$maxRev=0,this.$fromUndo=!1,this.$undoDepth=1/0,this.reset()}return g.prototype.addSession=function(M){this.$session=M},g.prototype.add=function(M,A,S){if(!this.$fromUndo&&M!=this.$lastDelta){if(this.$keepRedoStack||(this.$redoStack.length=0),A===!1||!this.lastDeltas){this.lastDeltas=[];var k=this.$undoStack.length;k>this.$undoDepth-1&&this.$undoStack.splice(0,k-this.$undoDepth+1),this.$undoStack.push(this.lastDeltas),M.id=this.$rev=++this.$maxRev}(M.action=="remove"||M.action=="insert")&&(this.$lastDelta=M),this.lastDeltas.push(M)}},g.prototype.addSelection=function(M,A){this.selections.push({value:M,rev:A||this.$rev})},g.prototype.startNewGroup=function(){return this.lastDeltas=null,this.$rev},g.prototype.markIgnored=function(M,A){A==null&&(A=this.$rev+1);for(var S=this.$undoStack,k=S.length;k--;){var d=S[k][0];if(d.id<=M)break;d.id0},g.prototype.canRedo=function(){return this.$redoStack.length>0},g.prototype.bookmark=function(M){M==null&&(M=this.$rev),this.mark=M},g.prototype.isAtBookmark=function(){return this.$rev===this.mark},g.prototype.toJSON=function(){return{$redoStack:this.$redoStack,$undoStack:this.$undoStack}},g.prototype.fromJSON=function(M){this.reset(),this.$undoStack=M.$undoStack,this.$redoStack=M.$redoStack},g.prototype.$prettyPrint=function(M){return M?t(M):t(this.$undoStack)+` +--- +`+t(this.$redoStack)},g}();y.prototype.hasUndo=y.prototype.canUndo,y.prototype.hasRedo=y.prototype.canRedo,y.prototype.isClean=y.prototype.isAtBookmark,y.prototype.markClean=y.prototype.bookmark;function w(g,M){for(var A=M;A--;){var S=g[A];if(S&&!S[0].ignore){for(;A0){f.row+=k,f.column+=f.row==S.row?d:0;continue}!M&&T<=0&&(f.row=A.row,f.column=A.column,T===0&&(f.bias=1))}}}function r(g){return{row:g.row,column:g.column}}function n(g){return{start:r(g.start),end:r(g.end),action:g.action,lines:g.lines.slice()}}function t(g){if(g=g||this,Array.isArray(g))return g.map(t).join(` +`);var M="";return g.action?(M=g.action=="insert"?"+":"-",M+="["+g.lines+"]"):g.value&&(Array.isArray(g.value)?M=g.value.map(e).join(` +`):M=e(g.value)),g.start&&(M+=e(g)),(g.id||g.rev)&&(M+=" ("+(g.id||g.rev)+")"),M}function e(g){return g.start.row+":"+g.start.column+"=>"+g.end.row+":"+g.end.column}function o(g,M){var A=g.action=="insert",S=M.action=="insert";if(A&&S)if(s(M.start,g.end)>=0)u(M,g,-1);else if(s(M.start,g.start)<=0)u(g,M,1);else return null;else if(A&&!S)if(s(M.start,g.end)>=0)u(M,g,-1);else if(s(M.end,g.start)<=0)u(g,M,-1);else return null;else if(!A&&S)if(s(M.start,g.start)>=0)u(M,g,1);else if(s(M.start,g.start)<=0)u(g,M,1);else return null;else if(!A&&!S)if(s(M.start,g.start)>=0)u(M,g,1);else if(s(M.end,g.start)<=0)u(g,M,-1);else return null;return[M,g]}function a(g,M){for(var A=g.length;A--;)for(var S=0;S=0?u(g,M,-1):(s(g.start,M.start)<=0||u(g,v.fromPoints(M.start,g.start),-1),u(M,g,1));else if(!A&&S)s(M.start,g.end)>=0?u(M,g,-1):(s(M.start,g.start)<=0||u(M,v.fromPoints(g.start,M.start),-1),u(g,M,1));else if(!A&&!S)if(s(M.start,g.end)>=0)u(M,g,-1);else if(s(M.end,g.start)<=0)u(g,M,-1);else{var k,d;return s(g.start,M.start)<0&&(k=g,g=m(g,M.start)),s(g.end,M.end)>0&&(d=m(g,M.end)),p(M.end,g.start,g.end,-1),d&&!k&&(g.lines=d.lines,g.start=d.start,g.end=d.end,d=g),[M,k,d].filter(Boolean)}return[M,g]}function u(g,M,A){p(g.start,M.start,M.end,A),p(g.end,M.start,M.end,A)}function p(g,M,A,S){g.row==(S==1?M:A).row&&(g.column+=S*(A.column-M.column)),g.row+=S*(A.row-M.row)}function m(g,M){var A=g.lines,S=g.end;g.end=r(M);var k=g.end.row-g.start.row,d=A.splice(k,A.length),h=k?M.column:M.column-g.start.column;A.push(d[0].substring(0,h)),d[0]=d[0].substr(h);var f={start:r(M),end:S,lines:d,action:g.action};return f}function $(g,M){M=n(M);for(var A=g.length;A--;){for(var S=g[A],k=0;kthis.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(s),this.folds.sort(function(l,i){return-l.range.compareEnd(i.start.row,i.start.column)}),this.range.compareEnd(s.start.row,s.start.column)>0?(this.end.row=s.end.row,this.end.column=s.end.column):this.range.compareStart(s.end.row,s.end.column)<0&&(this.start.row=s.start.row,this.start.column=s.start.column)}else if(s.start.row==this.end.row)this.folds.push(s),this.end.row=s.end.row,this.end.column=s.end.column;else if(s.end.row==this.start.row)this.folds.unshift(s),this.start.row=s.start.row,this.start.column=s.start.column;else throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");s.foldLine=this},v.prototype.containsRow=function(s){return s>=this.start.row&&s<=this.end.row},v.prototype.walk=function(s,l,i){var r=0,n=this.folds,t,e,o,a=!0;l==null&&(l=this.end.row,i=this.end.column);for(var c=0;c0)){var a=w(l,e.start);return o===0?i&&a!==0?-t-2:t:a>0||a===0&&!i?t:-t-1}}return-t-1},s.prototype.add=function(l){var i=!l.isEmpty(),r=this.pointIndex(l.start,i);r<0&&(r=-r-1);var n=this.pointIndex(l.end,i,r);return n<0?n=-n-1:n++,this.ranges.splice(r,n-r,l)},s.prototype.addList=function(l){for(var i=[],r=l.length;r--;)i.push.apply(i,this.add(l[r]));return i},s.prototype.substractPoint=function(l){var i=this.pointIndex(l);if(i>=0)return this.ranges.splice(i,1)},s.prototype.merge=function(){var l=[],i=this.ranges;i=i.sort(function(o,a){return w(o.start,a.start)});for(var r=i[0],n,t=1;t=0},s.prototype.containsPoint=function(l){return this.pointIndex(l)>=0},s.prototype.rangeAtPoint=function(l){var i=this.pointIndex(l);if(i>=0)return this.ranges[i]},s.prototype.clipRows=function(l,i){var r=this.ranges;if(r[0].start.row>i||r[r.length-1].start.row=n)break}if(l.action=="insert")for(var u=t-n,p=-i.column+r.column;on)break;if(c.start.row==n&&c.start.column>=i.column&&(c.start.column==i.column&&this.$bias<=0||(c.start.column+=p,c.start.row+=u)),c.end.row==n&&c.end.column>=i.column){if(c.end.column==i.column&&this.$bias<0)continue;c.end.column==i.column&&p>0&&oc.start.column&&c.end.column==e[o+1].start.column&&(c.end.column-=p),c.end.column+=p,c.end.row+=u}}else for(var u=n-t,p=i.column-r.column;ot)break;c.end.rowi.column)&&(c.end.column=i.column,c.end.row=i.row):(c.end.column+=p,c.end.row+=u):c.end.row>t&&(c.end.row+=u),c.start.rowi.column)&&(c.start.column=i.column,c.start.row=i.row):(c.start.column+=p,c.start.row+=u):c.start.row>t&&(c.start.row+=u)}if(u!=0&&o=r)return o;if(o.end.row>r)return null}return null},this.getNextFoldLine=function(r,n){var t=this.$foldData,e=0;for(n&&(e=t.indexOf(n)),e==-1&&(e=0),e;e=r)return o}return null},this.getFoldedRowCount=function(r,n){for(var t=this.$foldData,e=n-r+1,o=0;o=n){u=r?e-=n-u:e=0);break}else c>=r&&(u>=r?e-=c-u:e-=c-r+1)}return e},this.$addFoldLine=function(r){return this.$foldData.push(r),this.$foldData.sort(function(n,t){return n.start.row-t.start.row}),r},this.addFold=function(r,n){var t=this.$foldData,e=!1,o;r instanceof v?o=r:(o=new v(n,r),o.collapseChildren=n.collapseChildren),this.$clipRangeToDocument(o.range);var a=o.start.row,c=o.start.column,u=o.end.row,p=o.end.column,m=this.getFoldAt(a,c,1),$=this.getFoldAt(u,p,-1);if(m&&$==m)return m.addSubFold(o);m&&!m.range.isStart(a,c)&&this.removeFold(m),$&&!$.range.isEnd(u,p)&&this.removeFold($);var C=this.getFoldsInRange(o.range);C.length>0&&(this.removeFolds(C),o.collapseChildren||C.forEach(function(S){o.addSubFold(S)}));for(var g=0;g0&&this.foldAll(r.start.row+1,r.end.row,r.collapseChildren-1),r.subFolds=[]},this.expandFolds=function(r){r.forEach(function(n){this.expandFold(n)},this)},this.unfold=function(r,n){var t,e;if(r==null)t=new y(0,0,this.getLength(),0),n==null&&(n=!0);else if(typeof r=="number")t=new y(r,0,r,this.getLine(r).length);else if("row"in r)t=y.fromPoints(r,r);else{if(Array.isArray(r))return e=[],r.forEach(function(a){e=e.concat(this.unfold(a))},this),e;t=r}e=this.getFoldsInRangeList(t);for(var o=e;e.length==1&&y.comparePoints(e[0].start,t.start)<0&&y.comparePoints(e[0].end,t.end)>0;)this.expandFolds(e),e=this.getFoldsInRangeList(t);if(n!=!1?this.removeFolds(e):this.expandFolds(e),o.length)return o},this.isRowFolded=function(r,n){return!!this.getFoldLine(r,n)},this.getRowFoldEnd=function(r,n){var t=this.getFoldLine(r,n);return t?t.end.row:r},this.getRowFoldStart=function(r,n){var t=this.getFoldLine(r,n);return t?t.start.row:r},this.getFoldDisplayLine=function(r,n,t,e,o){e==null&&(e=r.start.row),o==null&&(o=0),n==null&&(n=r.end.row),t==null&&(t=this.getLine(n).length);var a=this.doc,c="";return r.walk(function(u,p,m,$){if(!(pm)break;while(o&&c.test(o.type));o=e.stepBackward()}else o=e.getCurrentToken();return u.end.row=e.getCurrentTokenRow(),u.end.column=e.getCurrentTokenColumn(),u}},this.foldAll=function(r,n,t,e){t==null&&(t=1e5);var o=this.foldWidgets;if(o){n=n||this.getLength(),r=r||0;for(var a=r;a=r&&(a=c.end.row,c.collapseChildren=t,this.addFold("...",c))}}},this.foldToLevel=function(r){for(this.foldAll();r-- >0;)this.unfold(null,!1)},this.foldAllComments=function(){var r=this;this.foldAll(null,null,null,function(n){for(var t=r.getTokens(n),e=0;e=0;){var a=t[e];if(a==null&&(a=t[e]=this.getFoldWidget(e)),a=="start"){var c=this.getFoldWidgetRange(e);if(o||(o=c),c&&c.end.row>=r)break}e--}return{range:e!==-1&&c,firstRange:o}},this.onFoldWidgetClick=function(r,n){n instanceof l&&(n=n.domEvent);var t={children:n.shiftKey,all:n.ctrlKey||n.metaKey,siblings:n.altKey},e=this.$toggleFoldWidget(r,t);if(!e){var o=n.target||n.srcElement;o&&/ace_fold-widget/.test(o.className)&&(o.className+=" ace_invalid")}},this.$toggleFoldWidget=function(r,n){if(this.getFoldWidget){var t=this.getFoldWidget(r),e=this.getLine(r),o=t==="end"?-1:1,a=this.getFoldAt(r,o===-1?0:e.length,o);if(a)return n.children||n.all?this.removeFold(a):this.expandFold(a),a;var c=this.getFoldWidgetRange(r,!0);if(c&&!c.isMultiLine()&&(a=this.getFoldAt(c.start.row,c.start.column,1),a&&c.isEqual(a.range)))return this.removeFold(a),a;if(n.siblings){var u=this.getParentFoldRangeData(r);if(u.range)var p=u.range.start.row+1,m=u.range.end.row;this.foldAll(p,m,n.all?1e4:0)}else n.children?(m=c?c.end.row:this.getLength(),this.foldAll(r+1,m,n.all?1e4:0)):c&&(n.all&&(c.collapseChildren=1e4),this.addFold("...",c));return c}},this.toggleFoldWidget=function(r){var n=this.selection.getCursor().row;n=this.getRowFoldStart(n);var t=this.$toggleFoldWidget(n,{});if(!t){var e=this.getParentFoldRangeData(n,!0);if(t=e.range||e.firstRange,t){n=t.start.row;var o=this.getFoldAt(n,this.getLine(n).length,1);o?this.removeFold(o):this.addFold("...",t)}}},this.updateFoldWidgets=function(r){var n=r.start.row,t=r.end.row-n;if(t===0)this.foldWidgets[n]=null;else if(r.action=="remove")this.foldWidgets.splice(n,t+1,null);else{var e=Array(t+1);e.unshift(n,1),this.foldWidgets.splice.apply(this.foldWidgets,e)}},this.tokenizerUpdateFoldWidgets=function(r){var n=r.data;n.first!=n.last&&this.foldWidgets.length>n.first&&this.foldWidgets.splice(n.first,this.foldWidgets.length)}}L.Folding=i}),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(_,L,E){"use strict";var y=_("../token_iterator").TokenIterator,w=_("../range").Range;function v(){this.findMatchingBracket=function(s,l){if(s.column==0)return null;var i=l||this.getLine(s.row).charAt(s.column-1);if(i=="")return null;var r=i.match(/([\(\[\{])|([\)\]\}])/);return r?r[1]?this.$findClosingBracket(r[1],s):this.$findOpeningBracket(r[2],s):null},this.getBracketRange=function(s){var l=this.getLine(s.row),i=!0,r,n=l.charAt(s.column-1),t=n&&n.match(/([\(\[\{])|([\)\]\}])/);if(t||(n=l.charAt(s.column),s={row:s.row,column:s.column+1},t=n&&n.match(/([\(\[\{])|([\)\]\}])/),i=!1),!t)return null;if(t[1]){var e=this.$findClosingBracket(t[1],s);if(!e)return null;r=w.fromPoints(s,e),i||(r.end.column++,r.start.column--),r.cursor=r.end}else{var e=this.$findOpeningBracket(t[2],s);if(!e)return null;r=w.fromPoints(e,s),i||(r.start.column++,r.end.column--),r.cursor=r.start}return r},this.getMatchingBracketRanges=function(s,l){var i=this.getLine(s.row),r=/([\(\[\{])|([\)\]\}])/,n=!l&&i.charAt(s.column-1),t=n&&n.match(r);if(t||(n=(l===void 0||l)&&i.charAt(s.column),s={row:s.row,column:s.column+1},t=n&&n.match(r)),!t)return null;var e=new w(s.row,s.column-1,s.row,s.column),o=t[1]?this.$findClosingBracket(t[1],s):this.$findOpeningBracket(t[2],s);if(!o)return[e];var a=new w(o.row,o.column,o.row,o.column+1);return[e,a]},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{","<":">",">":"<"},this.$findOpeningBracket=function(s,l,i){var r=this.$brackets[s],n=1,t=new y(this,l.row,l.column),e=t.getCurrentToken();if(e||(e=t.stepForward()),!!e){i||(i=new RegExp("(\\.?"+e.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end)\b/,"(?:start|begin|end)").replace(/-close\b/,"-(close|open)")+")+"));for(var o=l.column-t.getCurrentTokenColumn()-2,a=e.value;;){for(;o>=0;){var c=a.charAt(o);if(c==r){if(n-=1,n==0)return{row:t.getCurrentTokenRow(),column:o+t.getCurrentTokenColumn()}}else c==s&&(n+=1);o-=1}do e=t.stepBackward();while(e&&!i.test(e.type));if(e==null)break;a=e.value,o=a.length-1}return null}},this.$findClosingBracket=function(s,l,i){var r=this.$brackets[s],n=1,t=new y(this,l.row,l.column),e=t.getCurrentToken();if(e||(e=t.stepForward()),!!e){i||(i=new RegExp("(\\.?"+e.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:start|begin)\b/,"(?:start|begin|end)").replace(/-open\b/,"-(close|open)")+")+"));for(var o=l.column-t.getCurrentTokenColumn();;){for(var a=e.value,c=a.length;o"?r=!0:l.type.indexOf("tag-name")!==-1&&(i=!0));while(l&&!i);return l},this.$findClosingTag=function(s,l){var i,r=l.value,n=l.value,t=0,e=new w(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);l=s.stepForward();var o=new w(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+l.value.length),a=!1;do{if(i=l,i.type.indexOf("tag-close")!==-1&&!a){var c=new w(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);a=!0}if(l=s.stepForward(),l){if(l.value===">"&&!a){var c=new w(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);a=!0}if(l.type.indexOf("tag-name")!==-1){if(r=l.value,n===r){if(i.value==="<")t++;else if(i.value==="")var m=new w(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);else return}}}else if(n===r&&l.value==="/>"&&(t--,t<0))var u=new w(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+2),p=u,m=p,c=new w(o.end.row,o.end.column,o.end.row,o.end.column+1)}}while(l&&t>=0);if(e&&c&&u&&m&&o&&p)return{openTag:new w(e.start.row,e.start.column,c.end.row,c.end.column),closeTag:new w(u.start.row,u.start.column,m.end.row,m.end.column),openTagName:o,closeTagName:p}},this.$findOpeningTag=function(s,l){var i=s.getCurrentToken(),r=l.value,n=0,t=s.getCurrentTokenRow(),e=s.getCurrentTokenColumn(),o=e+2,a=new w(t,e,t,o);s.stepForward();var c=new w(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+l.value.length);if(l.type.indexOf("tag-close")===-1&&(l=s.stepForward()),!(!l||l.value!==">")){var u=new w(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);s.stepBackward(),s.stepBackward();do if(l=i,t=s.getCurrentTokenRow(),e=s.getCurrentTokenColumn(),o=e+l.value.length,i=s.stepBackward(),l){if(l.type.indexOf("tag-name")!==-1){if(r===l.value)if(i.value==="<"){if(n++,n>0){var p=new w(t,e,t,o),m=new w(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);do l=s.stepForward();while(l&&l.value!==">");var $=new w(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1)}}else i.value===""){for(var C=0,g=i;g;){if(g.type.indexOf("tag-name")!==-1&&g.value===r){n--;break}else if(g.value==="<")break;g=s.stepBackward(),C++}for(var M=0;Mb&&(this.$docRowCache.splice(b,f),this.$screenRowCache.splice(b,f))},d.prototype.$getRowCacheIndex=function(h,f){for(var b=0,T=h.length-1;b<=T;){var x=b+T>>1,R=h[x];if(f>R)b=x+1;else if(f=f));R++);return T=b[R],T?(T.index=R,T.start=x-T.value.length,T):null},d.prototype.setUndoManager=function(h){if(this.$undoManager=h,this.$informUndoManager&&this.$informUndoManager.cancel(),h){var f=this;h.addSession(this),this.$syncInformUndoManager=function(){f.$informUndoManager.cancel(),f.mergeUndoDeltas=!1},this.$informUndoManager=w.delayedCall(this.$syncInformUndoManager)}else this.$syncInformUndoManager=function(){}},d.prototype.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},d.prototype.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},d.prototype.getTabString=function(){return this.getUseSoftTabs()?w.stringRepeat(" ",this.getTabSize()):" "},d.prototype.setUseSoftTabs=function(h){this.setOption("useSoftTabs",h)},d.prototype.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},d.prototype.setTabSize=function(h){this.setOption("tabSize",h)},d.prototype.getTabSize=function(){return this.$tabSize},d.prototype.isTabStop=function(h){return this.$useSoftTabs&&h.column%this.$tabSize===0},d.prototype.setNavigateWithinSoftTabs=function(h){this.setOption("navigateWithinSoftTabs",h)},d.prototype.getNavigateWithinSoftTabs=function(){return this.$navigateWithinSoftTabs},d.prototype.setOverwrite=function(h){this.setOption("overwrite",h)},d.prototype.getOverwrite=function(){return this.$overwrite},d.prototype.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},d.prototype.addGutterDecoration=function(h,f){this.$decorations[h]||(this.$decorations[h]=""),this.$decorations[h]+=" "+f,this._signal("changeBreakpoint",{})},d.prototype.removeGutterDecoration=function(h,f){this.$decorations[h]=(this.$decorations[h]||"").replace(" "+f,""),this._signal("changeBreakpoint",{})},d.prototype.getBreakpoints=function(){return this.$breakpoints},d.prototype.setBreakpoints=function(h){this.$breakpoints=[];for(var f=0;f0&&(T=!!b.charAt(f-1).match(this.tokenRe)),T||(T=!!b.charAt(f).match(this.tokenRe)),T)var x=this.tokenRe;else if(/^\s+$/.test(b.slice(f-1,f+1)))var x=/\s/;else var x=this.nonTokenRe;var R=f;if(R>0){do R--;while(R>=0&&b.charAt(R).match(x));R++}for(var I=f;Ih&&(h=f.screenWidth)}),this.lineWidgetWidth=h},d.prototype.$computeWidth=function(h){if(this.$modified||h){if(this.$modified=!1,this.$useWrapMode)return this.screenWidth=this.$wrapLimit;for(var f=this.doc.getAllLines(),b=this.$rowLengthCache,T=0,x=0,R=this.$foldData[x],I=R?R.start.row:1/0,N=f.length,D=0;DI){if(D=R.end.row+1,D>=N)break;R=this.$foldData[x++],I=R?R.start.row:1/0}b[D]==null&&(b[D]=this.$getStringScreenWidth(f[D])[0]),b[D]>T&&(T=b[D])}this.screenWidth=T}},d.prototype.getLine=function(h){return this.doc.getLine(h)},d.prototype.getLines=function(h,f){return this.doc.getLines(h,f)},d.prototype.getLength=function(){return this.doc.getLength()},d.prototype.getTextRange=function(h){return this.doc.getTextRange(h||this.selection.getRange())},d.prototype.insert=function(h,f){return this.doc.insert(h,f)},d.prototype.remove=function(h){return this.doc.remove(h)},d.prototype.removeFullLines=function(h,f){return this.doc.removeFullLines(h,f)},d.prototype.undoChanges=function(h,f){if(h.length){this.$fromUndo=!0;for(var b=h.length-1;b!=-1;b--){var T=h[b];T.action=="insert"||T.action=="remove"?this.doc.revertDelta(T):T.folds&&this.addFolds(T.folds)}!f&&this.$undoSelect&&(h.selectionBefore?this.selection.fromJSON(h.selectionBefore):this.selection.setRange(this.$getUndoSelection(h,!0))),this.$fromUndo=!1}},d.prototype.redoChanges=function(h,f){if(h.length){this.$fromUndo=!0;for(var b=0;bh.end.column&&(R.start.column+=N),R.end.row==h.end.row&&R.end.column>h.end.column&&(R.end.column+=N)),I&&R.start.row>=h.end.row&&(R.start.row+=I,R.end.row+=I)}if(R.end=this.insert(R.start,T),x.length){var D=h.start,B=R.start,I=B.row-D.row,N=B.column-D.column;this.addFolds(x.map(function(H){return H=H.clone(),H.start.row==D.row&&(H.start.column+=N),H.end.row==D.row&&(H.end.column+=N),H.start.row+=I,H.end.row+=I,H}))}return R},d.prototype.indentRows=function(h,f,b){b=b.replace(/\t/g,this.getTabString());for(var T=h;T<=f;T++)this.doc.insertInLine({row:T,column:0},b)},d.prototype.outdentRows=function(h){for(var f=h.collapseRows(),b=new n(0,0,0,0),T=this.getTabSize(),x=f.start.row;x<=f.end.row;++x){var R=this.getLine(x);b.start.row=x,b.end.row=x;for(var I=0;I0){var T=this.getRowFoldEnd(f+b);if(T>this.doc.getLength()-1)return 0;var x=T-f}else{h=this.$clipRowToDocument(h),f=this.$clipRowToDocument(f);var x=f-h+1}var R=new n(h,0,f,Number.MAX_VALUE),I=this.getFoldsInRange(R).map(function(D){return D=D.clone(),D.start.row+=x,D.end.row+=x,D}),N=b==0?this.doc.getLines(h,f):this.doc.removeFullLines(h,f);return this.doc.insertFullLines(h+x,N),I.length&&this.addFolds(I),x},d.prototype.moveLinesUp=function(h,f){return this.$moveLines(h,f,-1)},d.prototype.moveLinesDown=function(h,f){return this.$moveLines(h,f,1)},d.prototype.duplicateLines=function(h,f){return this.$moveLines(h,f,0)},d.prototype.$clipRowToDocument=function(h){return Math.max(0,Math.min(h,this.doc.getLength()-1))},d.prototype.$clipColumnToRow=function(h,f){return f<0?0:Math.min(this.doc.getLine(h).length,f)},d.prototype.$clipPositionToDocument=function(h,f){if(f=Math.max(0,f),h<0)h=0,f=0;else{var b=this.doc.getLength();h>=b?(h=b-1,f=this.doc.getLine(b-1).length):f=Math.min(this.doc.getLine(h).length,f)}return{row:h,column:f}},d.prototype.$clipRangeToDocument=function(h){h.start.row<0?(h.start.row=0,h.start.column=0):h.start.column=this.$clipColumnToRow(h.start.row,h.start.column);var f=this.doc.getLength()-1;return h.end.row>f?(h.end.row=f,h.end.column=this.doc.getLine(f).length):h.end.column=this.$clipColumnToRow(h.end.row,h.end.column),h},d.prototype.setUseWrapMode=function(h){if(h!=this.$useWrapMode){if(this.$useWrapMode=h,this.$modified=!0,this.$resetRowCache(0),h){var f=this.getLength();this.$wrapData=Array(f),this.$updateWrapData(0,f-1)}this._signal("changeWrapMode")}},d.prototype.getUseWrapMode=function(){return this.$useWrapMode},d.prototype.setWrapLimitRange=function(h,f){(this.$wrapLimitRange.min!==h||this.$wrapLimitRange.max!==f)&&(this.$wrapLimitRange={min:h,max:f},this.$modified=!0,this.$bidiHandler.markAsDirty(),this.$useWrapMode&&this._signal("changeWrapMode"))},d.prototype.adjustWrapLimit=function(h,f){var b=this.$wrapLimitRange;b.max<0&&(b={min:f,max:f});var T=this.$constrainWrapLimit(h,b.min,b.max);return T!=this.$wrapLimit&&T>1?(this.$wrapLimit=T,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0):!1},d.prototype.$constrainWrapLimit=function(h,f,b){return f&&(h=Math.max(f,h)),b&&(h=Math.min(b,h)),h},d.prototype.getWrapLimit=function(){return this.$wrapLimit},d.prototype.setWrapLimit=function(h){this.setWrapLimitRange(h,h)},d.prototype.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},d.prototype.$updateInternalDataOnChange=function(h){var f=this.$useWrapMode,b=h.action,T=h.start,x=h.end,R=T.row,I=x.row,N=I-R,D=null;if(this.$updating=!0,N!=0)if(b==="remove"){this[f?"$wrapData":"$rowLengthCache"].splice(R,N);var B=this.$foldData;D=this.getFoldsInRange(h),this.removeFolds(D);var F=this.getFoldLine(x.row),z=0;if(F){F.addRemoveChars(x.row,x.column,T.column-x.column),F.shiftRow(-N);var H=this.getFoldLine(R);H&&H!==F&&(H.merge(F),F=H),z=B.indexOf(F)+1}for(z;z=x.row&&F.shiftRow(-N)}I=R}else{var U=Array(N);U.unshift(R,0);var K=f?this.$wrapData:this.$rowLengthCache;K.splice.apply(K,U);var B=this.$foldData,F=this.getFoldLine(R),z=0;if(F){var q=F.range.compareInside(T.row,T.column);q==0?(F=F.split(T.row,T.column),F&&(F.shiftRow(N),F.addRemoveChars(I,0,x.column-T.column))):q==-1&&(F.addRemoveChars(R,0,x.column-T.column),F.shiftRow(N)),z=B.indexOf(F)+1}for(z;z=R&&F.shiftRow(N)}}else{N=Math.abs(h.start.column-h.end.column),b==="remove"&&(D=this.getFoldsInRange(h),this.removeFolds(D),N=-N);var F=this.getFoldLine(R);F&&F.addRemoveChars(R,T.column,N)}return f&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,f?this.$updateWrapData(R,I):this.$updateRowLengthCache(R,I),D},d.prototype.$updateRowLengthCache=function(h,f){this.$rowLengthCache[h]=null,this.$rowLengthCache[f]=null},d.prototype.$updateWrapData=function(h,f){var b=this.doc.getAllLines(),T=this.getTabSize(),x=this.$wrapData,R=this.$wrapLimit,I,N,D=h;for(f=Math.min(f,b.length-1);D<=f;)N=this.getFoldLine(D,N),N?(I=[],N.walk(function(B,F,z,H){var U;if(B!=null){U=this.$getDisplayTokens(B,I.length),U[0]=$;for(var K=1;Kf-H;){var U=R+f-H;if(h[U-1]>=M&&h[U]>=M){z(U);continue}if(h[U]==$||h[U]==C){for(U;U!=R-1&&h[U]!=$;U--);if(U>R){z(U);continue}for(U=R+f,U;U>2)),R-1);U>K&&h[U]<$;)U--;if(N){for(;U>K&&h[U]<$;)U--;for(;U>K&&h[U]==g;)U--}else for(;U>K&&h[U]K){z(++U);continue}U=R+f,h[U]==m&&U--,z(U-H)}return T},d.prototype.$getDisplayTokens=function(h,f){var b=[],T;f=f||0;for(var x=0;x39&&R<48||R>57&&R<64?b.push(g):R>=4352&&k(R)?b.push(p,m):b.push(p)}return b},d.prototype.$getStringScreenWidth=function(h,f,b){if(f==0)return[0,0];f==null&&(f=1/0),b=b||0;var T,x;for(x=0;x=4352&&k(T)?b+=2:b+=1,!(b>f));x++);return[b,x]},d.prototype.getRowLength=function(h){var f=1;return this.lineWidgets&&(f+=this.lineWidgets[h]&&this.lineWidgets[h].rowCount||0),!this.$useWrapMode||!this.$wrapData[h]?f:this.$wrapData[h].length+f},d.prototype.getRowLineCount=function(h){return!this.$useWrapMode||!this.$wrapData[h]?1:this.$wrapData[h].length+1},d.prototype.getRowWrapIndent=function(h){if(this.$useWrapMode){var f=this.screenToDocumentPosition(h,Number.MAX_VALUE),b=this.$wrapData[f.row];return b.length&&b[0]=0)var N=B[F],x=this.$docRowCache[F],H=h>B[z-1];else var H=!z;for(var U=this.getLength()-1,K=this.getNextFoldLine(x),q=K?K.start.row:1/0;N<=h&&(D=this.getRowLength(x),!(N+D>h||x>=U));)N+=D,x++,x>q&&(x=K.end.row+1,K=this.getNextFoldLine(x,K),q=K?K.start.row:1/0),H&&(this.$docRowCache.push(x),this.$screenRowCache.push(N));if(K&&K.start.row<=x)T=this.getFoldDisplayLine(K),x=K.start.row;else{if(N+D<=h||x>U)return{row:U,column:this.getLine(U).length};T=this.getLine(x),K=null}var ee=0,Y=Math.floor(h-N);if(this.$useWrapMode){var Z=this.$wrapData[x];Z&&(I=Z[Y],Y>0&&Z.length&&(ee=Z.indent,R=Z[Y-1]||Z[Z.length-1],T=T.substring(R)))}return b!==void 0&&this.$bidiHandler.isBidiRow(N+Y,x,Y)&&(f=this.$bidiHandler.offsetToCol(b)),R+=this.$getStringScreenWidth(T,f-ee)[1],this.$useWrapMode&&R>=I&&(R=I-1),K?K.idxToPosition(R):{row:x,column:R}},d.prototype.documentToScreenPosition=function(h,f){if(typeof f=="undefined")var b=this.$clipPositionToDocument(h.row,h.column);else b=this.$clipPositionToDocument(h,f);h=b.row,f=b.column;var T=0,x=null,R=null;R=this.getFoldAt(h,f,1),R&&(h=R.start.row,f=R.start.column);var I,N=0,D=this.$docRowCache,B=this.$getRowCacheIndex(D,h),F=D.length;if(F&&B>=0)var N=D[B],T=this.$screenRowCache[B],z=h>D[F-1];else var z=!F;for(var H=this.getNextFoldLine(N),U=H?H.start.row:1/0;N=U){if(I=H.end.row+1,I>h)break;H=this.getNextFoldLine(I,H),U=H?H.start.row:1/0}else I=N+1;T+=this.getRowLength(N),N=I,z&&(this.$docRowCache.push(N),this.$screenRowCache.push(T))}var K="";H&&N>=U?(K=this.getFoldDisplayLine(H,h,f),x=H.start.row):(K=this.getLine(h).substring(0,f),x=h);var q=0;if(this.$useWrapMode){var ee=this.$wrapData[x];if(ee){for(var Y=0;K.length>=ee[Y];)T++,Y++;K=K.substring(ee[Y-1]||0,K.length),q=Y>0?ee.indent:0}}return this.lineWidgets&&this.lineWidgets[N]&&this.lineWidgets[N].rowsAbove&&(T+=this.lineWidgets[N].rowsAbove),{row:T,column:q+this.$getStringScreenWidth(K)[0]}},d.prototype.documentToScreenColumn=function(h,f){return this.documentToScreenPosition(h,f).column},d.prototype.documentToScreenRow=function(h,f){return this.documentToScreenPosition(h,f).row},d.prototype.getScreenLength=function(){var h=0,f=null;if(this.$useWrapMode)for(var x=this.$wrapData.length,R=0,T=0,f=this.$foldData[T++],I=f?f.start.row:1/0;RI&&(R=f.end.row+1,f=this.$foldData[T++],I=f?f.start.row:1/0)}else{h=this.getLength();for(var b=this.$foldData,T=0;Tb));R++);return[T,R]})},d.prototype.getPrecedingCharacter=function(){var h=this.selection.getCursor();if(h.column===0)return h.row===0?"":this.doc.getNewLineCharacter();var f=this.getLine(h.row);return f[h.column-1]},d.prototype.destroy=function(){this.destroyed||(this.bgTokenizer.setDocument(null),this.bgTokenizer.cleanup(),this.destroyed=!0),this.endOperation(),this.$stopWorker(),this.removeAllListeners(),this.doc&&this.doc.off("change",this.$onChange),this.selection&&(this.selection.off("changeCursor",this.$onSelectionChange),this.selection.off("changeSelection",this.$onSelectionChange)),this.selection.detach()},d}();u.$uid=0,u.prototype.$modes=s.$modes,u.prototype.getValue=u.prototype.toString,u.prototype.$defaultUndoManager={undo:function(){},redo:function(){},hasUndo:function(){},hasRedo:function(){},reset:function(){},add:function(){},addSelection:function(){},startNewGroup:function(){},addSession:function(){}},u.prototype.$overwrite=!1,u.prototype.$mode=null,u.prototype.$modeId=null,u.prototype.$scrollTop=0,u.prototype.$scrollLeft=0,u.prototype.$wrapLimit=80,u.prototype.$useWrapMode=!1,u.prototype.$wrapLimitRange={min:null,max:null},u.prototype.lineWidgets=null,u.prototype.isFullWidth=k,y.implement(u.prototype,l);var p=1,m=2,$=3,C=4,g=9,M=10,A=11,S=12;function k(d){return d<4352?!1:d>=4352&&d<=4447||d>=4515&&d<=4519||d>=4602&&d<=4607||d>=9001&&d<=9002||d>=11904&&d<=11929||d>=11931&&d<=12019||d>=12032&&d<=12245||d>=12272&&d<=12283||d>=12288&&d<=12350||d>=12353&&d<=12438||d>=12441&&d<=12543||d>=12549&&d<=12589||d>=12593&&d<=12686||d>=12688&&d<=12730||d>=12736&&d<=12771||d>=12784&&d<=12830||d>=12832&&d<=12871||d>=12880&&d<=13054||d>=13056&&d<=19903||d>=19968&&d<=42124||d>=42128&&d<=42182||d>=43360&&d<=43388||d>=44032&&d<=55203||d>=55216&&d<=55238||d>=55243&&d<=55291||d>=63744&&d<=64255||d>=65040&&d<=65049||d>=65072&&d<=65106||d>=65108&&d<=65126||d>=65128&&d<=65131||d>=65281&&d<=65376||d>=65504&&d<=65510}_("./edit_session/folding").Folding.call(u.prototype),_("./edit_session/bracket_match").BracketMatch.call(u.prototype),s.defineOptions(u.prototype,"session",{wrap:{set:function(d){if(!d||d=="off"?d=!1:d=="free"?d=!0:d=="printMargin"?d=-1:typeof d=="string"&&(d=parseInt(d,10)||!1),this.$wrap!=d)if(this.$wrap=d,!d)this.setUseWrapMode(!1);else{var h=typeof d=="number"?d:null;this.setWrapLimitRange(h,h),this.setUseWrapMode(!0)}},get:function(){return this.getUseWrapMode()?this.$wrap==-1?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(d){d=d=="auto"?this.$mode.type!="text":d!="text",d!=this.$wrapAsCode&&(this.$wrapAsCode=d,this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0)))},initialValue:"auto"},indentedSoftWrap:{set:function(){this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0))},initialValue:!0},firstLineNumber:{set:function(){this._signal("changeBreakpoint")},initialValue:1},useWorker:{set:function(d){this.$useWorker=d,this.$stopWorker(),d&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(d){d=parseInt(d),d>0&&this.$tabSize!==d&&(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=d,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},navigateWithinSoftTabs:{initialValue:!1},foldStyle:{set:function(d){this.setFoldStyle(d)},handlesSet:!0},overwrite:{set:function(d){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(d){this.doc.setNewLineMode(d)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(d){this.setMode(d)},get:function(){return this.$modeId},handlesSet:!0}}),L.EditSession=u}),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(_,L,E){"use strict";var y=_("./lib/lang"),w=_("./lib/oop"),v=_("./range").Range,s=function(){function i(){this.$options={}}return i.prototype.set=function(r){return w.mixin(this.$options,r),this},i.prototype.getOptions=function(){return y.copyObject(this.$options)},i.prototype.setOptions=function(r){this.$options=r},i.prototype.find=function(r){var n=this.$options,t=this.$matchIterator(r,n);if(!t)return!1;var e=null;return t.forEach(function(o,a,c,u){return e=new v(o,a,c,u),a==u&&n.start&&n.start.start&&n.skipCurrent!=!1&&e.isEqual(n.start)?(e=null,!1):!0}),e},i.prototype.findAll=function(r){var n=this.$options;if(!n.needle)return[];this.$assembleRegExp(n);var t=n.range,e=t?r.getLines(t.start.row,t.end.row):r.doc.getAllLines(),o=[],a=n.re;if(n.$isMultiLine){var c=a.length,u=e.length-c,p;e:for(var m=a.offset||0;m<=u;m++){for(var $=0;$M||(o.push(p=new v(m,M,m+c-1,A)),c>2&&(m=m+c-2))}}else for(var S=0;Sf&&o[$].end.row==b;)$--;for(o=o.slice(S,$+1),S=0,$=o.length;S<$;S++)o[S].start.row+=t.start.row,o[S].end.row+=t.start.row}return o},i.prototype.replace=function(r,n){var t=this.$options,e=this.$assembleRegExp(t);if(t.$isMultiLine)return n;if(e){var o=e.exec(r);if(!o||o[0].length!=r.length)return null;if(t.regExp||(n=n.replace(/\$/g,"$$$$")),n=r.replace(e,n),t.preserveCase){n=n.split("");for(var a=Math.min(r.length,r.length);a--;){var c=r[a];c&&c.toLowerCase()!=c?n[a]=n[a].toUpperCase():n[a]=n[a].toLowerCase()}n=n.join("")}return n}},i.prototype.$assembleRegExp=function(r,n){if(r.needle instanceof RegExp)return r.re=r.needle;var t=r.needle;if(!r.needle)return r.re=!1;r.regExp||(t=y.escapeRegExp(t));var e=r.caseSensitive?"gm":"gmi";try{new RegExp(t,"u"),r.$supportsUnicodeFlag=!0,e+="u"}catch(a){r.$supportsUnicodeFlag=!1}if(r.wholeWord&&(t=l(t,r)),r.$isMultiLine=!n&&/[\n\r]/.test(t),r.$isMultiLine)return r.re=this.$assembleMultilineRegExp(t,e);try{var o=new RegExp(t,e)}catch(a){o=!1}return r.re=o},i.prototype.$assembleMultilineRegExp=function(r,n){for(var t=r.replace(/\r\n|\r|\n/g,`$ +^`).split(` +`),e=[],o=0;o=p;A--)if(g(A,Number.MAX_VALUE,M))return;if(n.wrap!=!1){for(A=m,p=u.row;A>=p;A--)if(g(A,Number.MAX_VALUE,M))return}}};else var $=function(A){var S=u.row;if(!g(S,u.column,A)){for(S=S+1;S<=m;S++)if(g(S,0,A))return;if(n.wrap!=!1){for(S=p,m=u.row;S<=m;S++)if(g(S,0,A))return}}};if(n.$isMultiLine)var C=t.length,g=function(M,A,S){var k=e?M-C+1:M;if(!(k<0||k+C>r.getLength())){var d=r.getLine(k),h=d.search(t[0]);if(!(!e&&hA)&&S(k,h,k+C-1,b))return!0}}};else if(e)var g=function(A,S,k){var d=r.getLine(A),h=[],f,b=0;for(t.lastIndex=0;f=t.exec(d);){var T=f[0].length;if(b=f.index,!T){if(b>=d.length)break;t.lastIndex=b+=y.skipEmptyMatch(d,b,a)}if(f.index+T>S)break;h.push(f.index,T)}for(var x=h.length-1;x>=0;x-=2){var R=h[x-1],T=h[x];if(k(A,R,A,R+T))return!0}};else var g=function(A,S,k){var d=r.getLine(A),h,f;for(t.lastIndex=S;f=t.exec(d);){var b=f[0].length;if(h=f.index,k(A,h,A,h+b))return!0;if(!b&&(t.lastIndex=h+=y.skipEmptyMatch(d,h,a),h>=d.length))return!1}};return{forEach:$}},i}();function l(i,r){var n=y.supportsLookbehind();function t(c,u){u===void 0&&(u=!0);var p=n&&r.$supportsUnicodeFlag?new RegExp("[\\p{L}\\p{N}_]","u"):new RegExp("\\w");return p.test(c)||r.regExp?n&&r.$supportsUnicodeFlag?u?"(?<=^|[^\\p{L}\\p{N}_])":"(?=[^\\p{L}\\p{N}_]|$)":"\\b":""}var e=Array.from(i),o=e[0],a=e[e.length-1];return t(o)+i+t(a,!1)}L.Search=s}),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(_,L,E){"use strict";var y=this&&this.__extends||function(){var n=function(t,e){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,a){o.__proto__=a}||function(o,a){for(var c in a)Object.prototype.hasOwnProperty.call(a,c)&&(o[c]=a[c])},n(t,e)};return function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");n(t,e);function o(){this.constructor=t}t.prototype=e===null?Object.create(e):(o.prototype=e.prototype,new o)}}(),w=_("../lib/keys"),v=_("../lib/useragent"),s=w.KEY_MODS,l=function(){function n(t,e){this.$init(t,e,!1)}return n.prototype.$init=function(t,e,o){this.platform=e||(v.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(t),this.$singleCommand=o},n.prototype.addCommand=function(t){this.commands[t.name]&&this.removeCommand(t),this.commands[t.name]=t,t.bindKey&&this._buildKeyHash(t)},n.prototype.removeCommand=function(t,e){var o=t&&(typeof t=="string"?t:t.name);t=this.commands[o],e||delete this.commands[o];var a=this.commandKeyBinding;for(var c in a){var u=a[c];if(u==t)delete a[c];else if(Array.isArray(u)){var p=u.indexOf(t);p!=-1&&(u.splice(p,1),u.length==1&&(a[c]=u[0]))}}},n.prototype.bindKey=function(t,e,o){if(typeof t=="object"&&t&&(o==null&&(o=t.position),t=t[this.platform]),!!t){if(typeof e=="function")return this.addCommand({exec:e,bindKey:t,name:e.name||t});t.split("|").forEach(function(a){var c="";if(a.indexOf(" ")!=-1){var u=a.split(/\s+/);a=u.pop(),u.forEach(function($){var C=this.parseKeys($),g=s[C.hashId]+C.key;c+=(c?" ":"")+g,this._addCommandToBinding(c,"chainKeys")},this),c+=" "}var p=this.parseKeys(a),m=s[p.hashId]+p.key;this._addCommandToBinding(c+m,e,o)},this)}},n.prototype._addCommandToBinding=function(t,e,o){var a=this.commandKeyBinding,c;if(!e)delete a[t];else if(!a[t]||this.$singleCommand)a[t]=e;else{Array.isArray(a[t])?(c=a[t].indexOf(e))!=-1&&a[t].splice(c,1):a[t]=[a[t]],typeof o!="number"&&(o=i(e));var u=a[t];for(c=0;co)break}u.splice(c,0,e)}},n.prototype.addCommands=function(t){t&&Object.keys(t).forEach(function(e){var o=t[e];if(o){if(typeof o=="string")return this.bindKey(o,e);typeof o=="function"&&(o={exec:o}),typeof o=="object"&&(o.name||(o.name=e),this.addCommand(o))}},this)},n.prototype.removeCommands=function(t){Object.keys(t).forEach(function(e){this.removeCommand(t[e])},this)},n.prototype.bindKeys=function(t){Object.keys(t).forEach(function(e){this.bindKey(e,t[e])},this)},n.prototype._buildKeyHash=function(t){this.bindKey(t.bindKey,t)},n.prototype.parseKeys=function(t){var e=t.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(m){return m}),o=e.pop(),a=w[o];if(w.FUNCTION_KEYS[a])o=w.FUNCTION_KEYS[a].toLowerCase();else if(e.length){if(e.length==1&&e[0]=="shift")return{key:o.toUpperCase(),hashId:-1}}else return{key:o,hashId:-1};for(var c=0,u=e.length;u--;){var p=w.KEY_MODS[e[u]];if(p==null)return typeof console!="undefined"&&console.error("invalid modifier "+e[u]+" in "+t),!1;c|=p}return{key:o,hashId:c}},n.prototype.findKeyCommand=function(t,e){var o=s[t]+e;return this.commandKeyBinding[o]},n.prototype.handleKeyboard=function(t,e,o,a){if(!(a<0)){var c=s[e]+o,u=this.commandKeyBinding[c];return t.$keyChain&&(t.$keyChain+=" "+c,u=this.commandKeyBinding[t.$keyChain]||u),u&&(u=="chainKeys"||u[u.length-1]=="chainKeys")?(t.$keyChain=t.$keyChain||c,{command:"null"}):(t.$keyChain&&((!e||e==4)&&o.length==1?t.$keyChain=t.$keyChain.slice(0,-c.length-1):(e==-1||a>0)&&(t.$keyChain="")),{command:u})}},n.prototype.getStatusText=function(t,e){return e.$keyChain||""},n}();function i(n){return typeof n=="object"&&n.bindKey&&n.bindKey.position||(n.isDefault?-100:0)}var r=function(n){y(t,n);function t(e,o){var a=n.call(this,e,o)||this;return a.$singleCommand=!0,a}return t}(l);r.call=function(n,t,e){l.prototype.$init.call(n,t,e,!0)},l.call=function(n,t,e){l.prototype.$init.call(n,t,e,!1)},L.HashHandler=r,L.MultiHashHandler=l}),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],function(_,L,E){"use strict";var y=this&&this.__extends||function(){var i=function(r,n){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])},i(r,n)};return function(r,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");i(r,n);function t(){this.constructor=r}r.prototype=n===null?Object.create(n):(t.prototype=n.prototype,new t)}}(),w=_("../lib/oop"),v=_("../keyboard/hash_handler").MultiHashHandler,s=_("../lib/event_emitter").EventEmitter,l=function(i){y(r,i);function r(n,t){var e=i.call(this,t,n)||this;return e.byName=e.commands,e.setDefaultHandler("exec",function(o){return o.args?o.command.exec(o.editor,o.args,o.event,!1):o.command.exec(o.editor,{},o.event,!0)}),e}return r.prototype.exec=function(n,t,e){if(Array.isArray(n)){for(var o=n.length;o--;)if(this.exec(n[o],t,e))return!0;return!1}if(typeof n=="string"&&(n=this.commands[n]),!this.canExecute(n,t))return!1;var a={editor:t,command:n,args:e};return a.returnValue=this._emit("exec",a),this._signal("afterExec",a),a.returnValue!==!1},r.prototype.canExecute=function(n,t){return typeof n=="string"&&(n=this.commands[n]),!(!n||t&&t.$readOnly&&!n.readOnly||this.$checkCommandState!=!1&&n.isAvailable&&!n.isAvailable(t))},r.prototype.toggleRecording=function(n){if(!this.$inReplay)return n&&n._emit("changeStatus"),this.recording?(this.macro.pop(),this.off("exec",this.$addCommandToMacro),this.macro.length||(this.macro=this.oldMacro),this.recording=!1):(this.$addCommandToMacro||(this.$addCommandToMacro=function(t){this.macro.push([t.command,t.args])}.bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},r.prototype.replay=function(n){if(!(this.$inReplay||!this.macro)){if(this.recording)return this.toggleRecording(n);try{this.$inReplay=!0,this.macro.forEach(function(t){typeof t=="string"?this.exec(t,n):this.exec(t[0],n,t[1])},this)}finally{this.$inReplay=!1}}},r.prototype.trimMacro=function(n){return n.map(function(t){return typeof t[0]!="string"&&(t[0]=t[0].name),t[1]||(t=t[0]),t})},r}(v);w.implement(l.prototype,s),L.CommandManager=l}),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],function(_,L,E){"use strict";var y=_("../lib/lang"),w=_("../config"),v=_("../range").Range;function s(i,r){return{win:i,mac:r}}L.commands=[{name:"showSettingsMenu",description:"Show settings menu",bindKey:s("Ctrl-,","Command-,"),exec:function(i){w.loadModule("ace/ext/settings_menu",function(r){r.init(i),i.showSettingsMenu()})},readOnly:!0},{name:"goToNextError",description:"Go to next error",bindKey:s("Alt-E","F4"),exec:function(i){w.loadModule("ace/ext/error_marker",function(r){r.showErrorMarker(i,1)})},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",description:"Go to previous error",bindKey:s("Alt-Shift-E","Shift-F4"),exec:function(i){w.loadModule("ace/ext/error_marker",function(r){r.showErrorMarker(i,-1)})},scrollIntoView:"animate",readOnly:!0},{name:"selectall",description:"Select all",bindKey:s("Ctrl-A","Command-A"),exec:function(i){i.selectAll()},readOnly:!0},{name:"centerselection",description:"Center selection",bindKey:s(null,"Ctrl-L"),exec:function(i){i.centerSelection()},readOnly:!0},{name:"gotoline",description:"Go to line...",bindKey:s("Ctrl-L","Command-L"),exec:function(i,r){typeof r=="number"&&!isNaN(r)&&i.gotoLine(r),i.prompt({$type:"gotoLine"})},readOnly:!0},{name:"fold",bindKey:s("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(i){i.session.toggleFold(!1)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:s("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(i){i.session.toggleFold(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",description:"Toggle fold widget",bindKey:s("F2","F2"),exec:function(i){i.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",description:"Toggle parent fold widget",bindKey:s("Alt-F2","Alt-F2"),exec:function(i){i.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",description:"Fold all",bindKey:s(null,"Ctrl-Command-Option-0"),exec:function(i){i.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldAllComments",description:"Fold all comments",bindKey:s(null,"Ctrl-Command-Option-0"),exec:function(i){i.session.foldAllComments()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",description:"Fold other",bindKey:s("Alt-0","Command-Option-0"),exec:function(i){i.session.foldAll(),i.session.unfold(i.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",description:"Unfold all",bindKey:s("Alt-Shift-0","Command-Option-Shift-0"),exec:function(i){i.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",description:"Find next",bindKey:s("Ctrl-K","Command-G"),exec:function(i){i.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",description:"Find previous",bindKey:s("Ctrl-Shift-K","Command-Shift-G"),exec:function(i){i.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",description:"Select or find next",bindKey:s("Alt-K","Ctrl-G"),exec:function(i){i.selection.isEmpty()?i.selection.selectWord():i.findNext()},readOnly:!0},{name:"selectOrFindPrevious",description:"Select or find previous",bindKey:s("Alt-Shift-K","Ctrl-Shift-G"),exec:function(i){i.selection.isEmpty()?i.selection.selectWord():i.findPrevious()},readOnly:!0},{name:"find",description:"Find",bindKey:s("Ctrl-F","Command-F"),exec:function(i){w.loadModule("ace/ext/searchbox",function(r){r.Search(i)})},readOnly:!0},{name:"overwrite",description:"Overwrite",bindKey:"Insert",exec:function(i){i.toggleOverwrite()},readOnly:!0},{name:"selecttostart",description:"Select to start",bindKey:s("Ctrl-Shift-Home","Command-Shift-Home|Command-Shift-Up"),exec:function(i){i.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",description:"Go to start",bindKey:s("Ctrl-Home","Command-Home|Command-Up"),exec:function(i){i.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",description:"Select up",bindKey:s("Shift-Up","Shift-Up|Ctrl-Shift-P"),exec:function(i){i.getSelection().selectUp()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",description:"Go line up",bindKey:s("Up","Up|Ctrl-P"),exec:function(i,r){i.navigateUp(r.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttoend",description:"Select to end",bindKey:s("Ctrl-Shift-End","Command-Shift-End|Command-Shift-Down"),exec:function(i){i.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",description:"Go to end",bindKey:s("Ctrl-End","Command-End|Command-Down"),exec:function(i){i.navigateFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",description:"Select down",bindKey:s("Shift-Down","Shift-Down|Ctrl-Shift-N"),exec:function(i){i.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",description:"Go line down",bindKey:s("Down","Down|Ctrl-N"),exec:function(i,r){i.navigateDown(r.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",description:"Select word left",bindKey:s("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(i){i.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",description:"Go to word left",bindKey:s("Ctrl-Left","Option-Left"),exec:function(i){i.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",description:"Select to line start",bindKey:s("Alt-Shift-Left","Command-Shift-Left|Ctrl-Shift-A"),exec:function(i){i.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",description:"Go to line start",bindKey:s("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(i){i.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",description:"Select left",bindKey:s("Shift-Left","Shift-Left|Ctrl-Shift-B"),exec:function(i){i.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",description:"Go to left",bindKey:s("Left","Left|Ctrl-B"),exec:function(i,r){i.navigateLeft(r.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",description:"Select word right",bindKey:s("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(i){i.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",description:"Go to word right",bindKey:s("Ctrl-Right","Option-Right"),exec:function(i){i.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",description:"Select to line end",bindKey:s("Alt-Shift-Right","Command-Shift-Right|Shift-End|Ctrl-Shift-E"),exec:function(i){i.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",description:"Go to line end",bindKey:s("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(i){i.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",description:"Select right",bindKey:s("Shift-Right","Shift-Right"),exec:function(i){i.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",description:"Go to right",bindKey:s("Right","Right|Ctrl-F"),exec:function(i,r){i.navigateRight(r.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",description:"Select page down",bindKey:"Shift-PageDown",exec:function(i){i.selectPageDown()},readOnly:!0},{name:"pagedown",description:"Page down",bindKey:s(null,"Option-PageDown"),exec:function(i){i.scrollPageDown()},readOnly:!0},{name:"gotopagedown",description:"Go to page down",bindKey:s("PageDown","PageDown|Ctrl-V"),exec:function(i){i.gotoPageDown()},readOnly:!0},{name:"selectpageup",description:"Select page up",bindKey:"Shift-PageUp",exec:function(i){i.selectPageUp()},readOnly:!0},{name:"pageup",description:"Page up",bindKey:s(null,"Option-PageUp"),exec:function(i){i.scrollPageUp()},readOnly:!0},{name:"gotopageup",description:"Go to page up",bindKey:"PageUp",exec:function(i){i.gotoPageUp()},readOnly:!0},{name:"scrollup",description:"Scroll up",bindKey:s("Ctrl-Up",null),exec:function(i){i.renderer.scrollBy(0,-2*i.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",description:"Scroll down",bindKey:s("Ctrl-Down",null),exec:function(i){i.renderer.scrollBy(0,2*i.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",description:"Select line start",bindKey:"Shift-Home",exec:function(i){i.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",description:"Select line end",bindKey:"Shift-End",exec:function(i){i.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",description:"Toggle recording",bindKey:s("Ctrl-Alt-E","Command-Option-E"),exec:function(i){i.commands.toggleRecording(i)},readOnly:!0},{name:"replaymacro",description:"Replay macro",bindKey:s("Ctrl-Shift-E","Command-Shift-E"),exec:function(i){i.commands.replay(i)},readOnly:!0},{name:"jumptomatching",description:"Jump to matching",bindKey:s("Ctrl-\\|Ctrl-P","Command-\\"),exec:function(i){i.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",description:"Select to matching",bindKey:s("Ctrl-Shift-\\|Ctrl-Shift-P","Command-Shift-\\"),exec:function(i){i.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",description:"Expand to matching",bindKey:s("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(i){i.jumpToMatching(!0,!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"passKeysToBrowser",description:"Pass keys to browser",bindKey:s(null,null),exec:function(){},passEvent:!0,readOnly:!0},{name:"copy",description:"Copy",exec:function(i){},readOnly:!0},{name:"cut",description:"Cut",exec:function(i){var r=i.$copyWithEmptySelection&&i.selection.isEmpty(),n=r?i.selection.getLineRange():i.selection.getRange();i._emit("cut",n),n.isEmpty()||i.session.remove(n),i.clearSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"paste",description:"Paste",exec:function(i,r){i.$handlePaste(r)},scrollIntoView:"cursor"},{name:"removeline",description:"Remove line",bindKey:s("Ctrl-D","Command-D"),exec:function(i){i.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",description:"Duplicate selection",bindKey:s("Ctrl-Shift-D","Command-Shift-D"),exec:function(i){i.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",description:"Sort lines",bindKey:s("Ctrl-Alt-S","Command-Alt-S"),exec:function(i){i.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",description:"Toggle comment",bindKey:s("Ctrl-/","Command-/"),exec:function(i){i.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",description:"Toggle block comment",bindKey:s("Ctrl-Shift-/","Command-Shift-/"),exec:function(i){i.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",description:"Modify number up",bindKey:s("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(i){i.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",description:"Modify number down",bindKey:s("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(i){i.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",description:"Replace",bindKey:s("Ctrl-H","Command-Option-F"),exec:function(i){w.loadModule("ace/ext/searchbox",function(r){r.Search(i,!0)})}},{name:"undo",description:"Undo",bindKey:s("Ctrl-Z","Command-Z"),exec:function(i){i.undo()}},{name:"redo",description:"Redo",bindKey:s("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(i){i.redo()}},{name:"copylinesup",description:"Copy lines up",bindKey:s("Alt-Shift-Up","Command-Option-Up"),exec:function(i){i.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",description:"Move lines up",bindKey:s("Alt-Up","Option-Up"),exec:function(i){i.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",description:"Copy lines down",bindKey:s("Alt-Shift-Down","Command-Option-Down"),exec:function(i){i.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",description:"Move lines down",bindKey:s("Alt-Down","Option-Down"),exec:function(i){i.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",description:"Delete",bindKey:s("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(i){i.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",description:"Backspace",bindKey:s("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(i){i.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",description:"Cut or delete",bindKey:s("Shift-Delete",null),exec:function(i){if(i.selection.isEmpty())i.remove("left");else return!1},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",description:"Remove to line start",bindKey:s("Alt-Backspace","Command-Backspace"),exec:function(i){i.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",description:"Remove to line end",bindKey:s("Alt-Delete","Ctrl-K|Command-Delete"),exec:function(i){i.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestarthard",description:"Remove to line start hard",bindKey:s("Ctrl-Shift-Backspace",null),exec:function(i){var r=i.selection.getRange();r.start.column=0,i.session.remove(r)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineendhard",description:"Remove to line end hard",bindKey:s("Ctrl-Shift-Delete",null),exec:function(i){var r=i.selection.getRange();r.end.column=Number.MAX_VALUE,i.session.remove(r)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",description:"Remove word left",bindKey:s("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(i){i.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",description:"Remove word right",bindKey:s("Ctrl-Delete","Alt-Delete"),exec:function(i){i.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",description:"Outdent",bindKey:s("Shift-Tab","Shift-Tab"),exec:function(i){i.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",description:"Indent",bindKey:s("Tab","Tab"),exec:function(i){i.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",description:"Block outdent",bindKey:s("Ctrl-[","Ctrl-["),exec:function(i){i.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",description:"Block indent",bindKey:s("Ctrl-]","Ctrl-]"),exec:function(i){i.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",description:"Insert string",exec:function(i,r){i.insert(r)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",description:"Insert text",exec:function(i,r){i.insert(y.stringRepeat(r.text||"",r.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",description:"Split line",bindKey:s(null,"Ctrl-O"),exec:function(i){i.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",description:"Transpose letters",bindKey:s("Alt-Shift-X","Ctrl-T"),exec:function(i){i.transposeLetters()},multiSelectAction:function(i){i.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",description:"To uppercase",bindKey:s("Ctrl-U","Ctrl-U"),exec:function(i){i.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",description:"To lowercase",bindKey:s("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(i){i.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"autoindent",description:"Auto Indent",bindKey:s(null,null),exec:function(i){i.autoIndent()},scrollIntoView:"animate"},{name:"expandtoline",description:"Expand to line",bindKey:s("Ctrl-Shift-L","Command-Shift-L"),exec:function(i){var r=i.selection.getRange();r.start.column=r.end.column=0,r.end.row++,i.selection.setRange(r,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"openlink",bindKey:s("Ctrl+F3","F3"),exec:function(i){i.openLink()}},{name:"joinlines",description:"Join lines",bindKey:s(null,null),exec:function(i){for(var r=i.selection.isBackwards(),n=r?i.selection.getSelectionLead():i.selection.getSelectionAnchor(),t=r?i.selection.getSelectionAnchor():i.selection.getSelectionLead(),e=i.session.doc.getLine(n.row).length,o=i.session.doc.getTextRange(i.selection.getRange()),a=o.replace(/\n\s*/," ").length,c=i.session.doc.getLine(n.row),u=n.row+1;u<=t.row+1;u++){var p=y.stringTrimLeft(y.stringTrimRight(i.session.doc.getLine(u)));p.length!==0&&(p=" "+p),c+=p}t.row+10?(i.selection.moveCursorTo(n.row,n.column),i.selection.selectTo(n.row,n.column+a)):(e=i.session.doc.getLine(n.row).length>e?e+1:e,i.selection.moveCursorTo(n.row,e))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",description:"Invert selection",bindKey:s(null,null),exec:function(i){var r=i.session.doc.getLength()-1,n=i.session.doc.getLine(r).length,t=i.selection.rangeList.ranges,e=[];t.length<1&&(t=[i.selection.getRange()]);for(var o=0;o0||i+r=0&&this.$isFoldWidgetVisible(i-r))return i-r;if(i+r<=this.lines.getLength()-1&&this.$isFoldWidgetVisible(i+r))return i+r}return null},l.prototype.$findNearestAnnotation=function(i){if(this.$isAnnotationVisible(i))return i;for(var r=0;i-r>0||i+r=0&&this.$isAnnotationVisible(i-r))return i-r;if(i+r<=this.lines.getLength()-1&&this.$isAnnotationVisible(i+r))return i+r}return null},l.prototype.$focusFoldWidget=function(i){if(i!=null){var r=this.$getFoldWidget(i);r.classList.add(this.editor.renderer.keyboardFocusClassName),r.focus()}},l.prototype.$focusAnnotation=function(i){if(i!=null){var r=this.$getAnnotation(i);r.classList.add(this.editor.renderer.keyboardFocusClassName),r.focus()}},l.prototype.$blurFoldWidget=function(i){var r=this.$getFoldWidget(i);r.classList.remove(this.editor.renderer.keyboardFocusClassName),r.blur()},l.prototype.$blurAnnotation=function(i){var r=this.$getAnnotation(i);r.classList.remove(this.editor.renderer.keyboardFocusClassName),r.blur()},l.prototype.$moveFoldWidgetUp=function(){for(var i=this.activeRowIndex;i>0;)if(i--,this.$isFoldWidgetVisible(i)){this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=i,this.$focusFoldWidget(this.activeRowIndex);return}},l.prototype.$moveFoldWidgetDown=function(){for(var i=this.activeRowIndex;i0;)if(i--,this.$isAnnotationVisible(i)){this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=i,this.$focusAnnotation(this.activeRowIndex);return}},l.prototype.$moveAnnotationDown=function(){for(var i=this.activeRowIndex;i=d.length&&(d=void 0),{value:d&&d[b++],done:!d}}};throw new TypeError(h?"Object is not iterable.":"Symbol.iterator is not defined.")},w=_("./lib/oop"),v=_("./lib/dom"),s=_("./lib/lang"),l=_("./lib/useragent"),i=_("./keyboard/textinput").TextInput,r=_("./mouse/mouse_handler").MouseHandler,n=_("./mouse/fold_handler").FoldHandler,t=_("./keyboard/keybinding").KeyBinding,e=_("./edit_session").EditSession,o=_("./search").Search,a=_("./range").Range,c=_("./lib/event_emitter").EventEmitter,u=_("./commands/command_manager").CommandManager,p=_("./commands/default_commands").commands,m=_("./config"),$=_("./token_iterator").TokenIterator,C=_("./keyboard/gutter_handler").GutterKeyboardHandler,g=_("./config").nls,M=_("./clipboard"),A=_("./lib/keys"),S=function(){function d(h,f,b){this.session,this.$toDestroy=[];var T=h.getContainerElement();this.container=T,this.renderer=h,this.id="editor"+ ++d.$uid,this.commands=new u(l.isMac?"mac":"win",p),typeof document=="object"&&(this.textInput=new i(h.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.$mouseHandler=new r(this),new n(this)),this.keyBinding=new t(this),this.$search=new o().set({wrap:!0}),this.$historyTracker=this.$historyTracker.bind(this),this.commands.on("exec",this.$historyTracker),this.$initOperationListeners(),this._$emitInputEvent=s.delayedCall(function(){this._signal("input",{}),this.session&&!this.session.destroyed&&this.session.bgTokenizer.scheduleStart()}.bind(this)),this.on("change",function(x,R){R._$emitInputEvent.schedule(31)}),this.setSession(f||b&&b.session||new e("")),m.resetOptions(this),b&&this.setOptions(b),m._signal("editor",this)}return d.prototype.$initOperationListeners=function(){this.commands.on("exec",this.startOperation.bind(this),!0),this.commands.on("afterExec",this.endOperation.bind(this),!0)},d.prototype.startOperation=function(h){this.session.startOperation(h)},d.prototype.endOperation=function(h){this.session.endOperation(h)},d.prototype.onStartOperation=function(h){this.curOp=this.session.curOp,this.curOp.scrollTop=this.renderer.scrollTop,this.prevOp=this.session.prevOp,h||(this.previousCommand=null)},d.prototype.onEndOperation=function(h){if(this.curOp&&this.session){if(h&&h.returnValue===!1){this.curOp=null;return}if(this._signal("beforeEndOperation"),!this.curOp)return;var f=this.curOp.command,b=f&&f.scrollIntoView;if(b){switch(b){case"center-animate":b="animate";case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var T=this.selection.getRange(),x=this.renderer.layerConfig;(T.start.row>=x.lastRow||T.end.row<=x.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead);break;default:break}b=="animate"&&this.renderer.animateScrolling(this.curOp.scrollTop)}this.$lastSel=this.session.selection.toJSON(),this.prevOp=this.curOp,this.curOp=null}},d.prototype.$historyTracker=function(h){if(this.$mergeUndoDeltas){var f=this.prevOp,b=this.$mergeableCommands,T=f.command&&h.command.name==f.command.name;if(h.command.name=="insertstring"){var x=h.args;this.mergeNextCommand===void 0&&(this.mergeNextCommand=!0),T=T&&this.mergeNextCommand&&(!/\s/.test(x)||/\s/.test(f.args)),this.mergeNextCommand=!0}else T=T&&b.indexOf(h.command.name)!==-1;this.$mergeUndoDeltas!="always"&&Date.now()-this.sequenceStartTime>2e3&&(T=!1),T?this.session.mergeUndoDeltas=!0:b.indexOf(h.command.name)!==-1&&(this.sequenceStartTime=Date.now())}},d.prototype.setKeyboardHandler=function(h,f){if(h&&typeof h=="string"&&h!="ace"){this.$keybindingId=h;var b=this;m.loadModule(["keybinding",h],function(T){b.$keybindingId==h&&b.keyBinding.setKeyboardHandler(T&&T.handler),f&&f()})}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(h),f&&f()},d.prototype.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},d.prototype.setSession=function(h){if(this.session!=h){this.curOp&&this.endOperation(),this.curOp={};var f=this.session;if(f){this.session.off("change",this.$onDocumentChange),this.session.off("changeMode",this.$onChangeMode),this.session.off("tokenizerUpdate",this.$onTokenizerUpdate),this.session.off("changeTabSize",this.$onChangeTabSize),this.session.off("changeWrapLimit",this.$onChangeWrapLimit),this.session.off("changeWrapMode",this.$onChangeWrapMode),this.session.off("changeFold",this.$onChangeFold),this.session.off("changeFrontMarker",this.$onChangeFrontMarker),this.session.off("changeBackMarker",this.$onChangeBackMarker),this.session.off("changeBreakpoint",this.$onChangeBreakpoint),this.session.off("changeAnnotation",this.$onChangeAnnotation),this.session.off("changeOverwrite",this.$onCursorChange),this.session.off("changeScrollTop",this.$onScrollTopChange),this.session.off("changeScrollLeft",this.$onScrollLeftChange),this.session.off("startOperation",this.$onStartOperation),this.session.off("endOperation",this.$onEndOperation);var b=this.session.getSelection();b.off("changeCursor",this.$onCursorChange),b.off("changeSelection",this.$onSelectionChange)}this.session=h,h?(this.$onDocumentChange=this.onDocumentChange.bind(this),h.on("change",this.$onDocumentChange),this.renderer.setSession(h),this.$onChangeMode=this.onChangeMode.bind(this),h.on("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),h.on("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),h.on("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),h.on("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),h.on("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),h.on("changeFold",this.$onChangeFold),this.$onChangeFrontMarker=this.onChangeFrontMarker.bind(this),this.session.on("changeFrontMarker",this.$onChangeFrontMarker),this.$onChangeBackMarker=this.onChangeBackMarker.bind(this),this.session.on("changeBackMarker",this.$onChangeBackMarker),this.$onChangeBreakpoint=this.onChangeBreakpoint.bind(this),this.session.on("changeBreakpoint",this.$onChangeBreakpoint),this.$onChangeAnnotation=this.onChangeAnnotation.bind(this),this.session.on("changeAnnotation",this.$onChangeAnnotation),this.$onCursorChange=this.onCursorChange.bind(this),this.session.on("changeOverwrite",this.$onCursorChange),this.$onScrollTopChange=this.onScrollTopChange.bind(this),this.session.on("changeScrollTop",this.$onScrollTopChange),this.$onScrollLeftChange=this.onScrollLeftChange.bind(this),this.session.on("changeScrollLeft",this.$onScrollLeftChange),this.selection=h.getSelection(),this.selection.on("changeCursor",this.$onCursorChange),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.on("changeSelection",this.$onSelectionChange),this.$onStartOperation=this.onStartOperation.bind(this),this.session.on("startOperation",this.$onStartOperation),this.$onEndOperation=this.onEndOperation.bind(this),this.session.on("endOperation",this.$onEndOperation),this.onChangeMode(),this.onCursorChange(),this.onScrollTopChange(),this.onScrollLeftChange(),this.onSelectionChange(),this.onChangeFrontMarker(),this.onChangeBackMarker(),this.onChangeBreakpoint(),this.onChangeAnnotation(),this.session.getUseWrapMode()&&this.renderer.adjustWrapLimit(),this.renderer.updateFull()):(this.selection=null,this.renderer.setSession(h)),this._signal("changeSession",{session:h,oldSession:f}),this.curOp=null,f&&f._signal("changeEditor",{oldEditor:this}),f&&(f.$editor=null),h&&h._signal("changeEditor",{editor:this}),h&&(h.$editor=this),h&&!h.destroyed&&h.bgTokenizer.scheduleStart()}},d.prototype.getSession=function(){return this.session},d.prototype.setValue=function(h,f){return this.session.doc.setValue(h),f?f==1?this.navigateFileEnd():f==-1&&this.navigateFileStart():this.selectAll(),h},d.prototype.getValue=function(){return this.session.getValue()},d.prototype.getSelection=function(){return this.selection},d.prototype.resize=function(h){this.renderer.onResize(h)},d.prototype.setTheme=function(h,f){this.renderer.setTheme(h,f)},d.prototype.getTheme=function(){return this.renderer.getTheme()},d.prototype.setStyle=function(h){this.renderer.setStyle(h)},d.prototype.unsetStyle=function(h){this.renderer.unsetStyle(h)},d.prototype.getFontSize=function(){return this.getOption("fontSize")||v.computedStyle(this.container).fontSize},d.prototype.setFontSize=function(h){this.setOption("fontSize",h)},d.prototype.$highlightBrackets=function(){if(!this.$highlightPending){var h=this;this.$highlightPending=!0,setTimeout(function(){h.$highlightPending=!1;var f=h.session;if(!(!f||f.destroyed)){f.$bracketHighlight&&(f.$bracketHighlight.markerIds.forEach(function(F){f.removeMarker(F)}),f.$bracketHighlight=null);var b=h.getCursorPosition(),T=h.getKeyboardHandler(),x=T&&T.$getDirectionForHighlight&&T.$getDirectionForHighlight(h),R=f.getMatchingBracketRanges(b,x);if(!R){var I=new $(f,b.row,b.column),N=I.getCurrentToken();if(N&&/\b(?:tag-open|tag-name)/.test(N.type)){var D=f.getMatchingTags(b);D&&(R=[D.openTagName.isEmpty()?D.openTag:D.openTagName,D.closeTagName.isEmpty()?D.closeTag:D.closeTagName])}}if(!R&&f.$mode.getMatching&&(R=f.$mode.getMatching(h.session)),!R){h.getHighlightIndentGuides()&&h.renderer.$textLayer.$highlightIndentGuide();return}var B="ace_bracket";Array.isArray(R)?R.length==1&&(B="ace_error_bracket"):R=[R],R.length==2&&(a.comparePoints(R[0].end,R[1].start)==0?R=[a.fromPoints(R[0].start,R[1].end)]:a.comparePoints(R[0].start,R[1].end)==0&&(R=[a.fromPoints(R[1].start,R[0].end)])),f.$bracketHighlight={ranges:R,markerIds:R.map(function(F){return f.addMarker(F,B,"text")})},h.getHighlightIndentGuides()&&h.renderer.$textLayer.$highlightIndentGuide()}},50)}},d.prototype.focus=function(){this.textInput.focus()},d.prototype.isFocused=function(){return this.textInput.isFocused()},d.prototype.blur=function(){this.textInput.blur()},d.prototype.onFocus=function(h){this.$isFocused||(this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",h))},d.prototype.onBlur=function(h){this.$isFocused&&(this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",h))},d.prototype.$cursorChange=function(){this.renderer.updateCursor(),this.$highlightBrackets(),this.$updateHighlightActiveLine()},d.prototype.onDocumentChange=function(h){var f=this.session.$useWrapMode,b=h.start.row==h.end.row?h.end.row:1/0;this.renderer.updateLines(h.start.row,b,f),this._signal("change",h),this.$cursorChange()},d.prototype.onTokenizerUpdate=function(h){var f=h.data;this.renderer.updateLines(f.first,f.last)},d.prototype.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},d.prototype.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},d.prototype.onCursorChange=function(){this.$cursorChange(),this._signal("changeSelection")},d.prototype.$updateHighlightActiveLine=function(){var h=this.getSession(),f;if(this.$highlightActiveLine&&((this.$selectionStyle!="line"||!this.selection.isMultiLine())&&(f=this.getCursorPosition()),this.renderer.theme&&this.renderer.theme.$selectionColorConflict&&!this.selection.isEmpty()&&(f=!1),this.renderer.$maxLines&&this.session.getLength()===1&&!(this.renderer.$minLines>1)&&(f=!1)),h.$highlightLineMarker&&!f)h.removeMarker(h.$highlightLineMarker.id),h.$highlightLineMarker=null;else if(!h.$highlightLineMarker&&f){var b=new a(f.row,f.column,f.row,1/0);b.id=h.addMarker(b,"ace_active-line","screenLine"),h.$highlightLineMarker=b}else f&&(h.$highlightLineMarker.start.row=f.row,h.$highlightLineMarker.end.row=f.row,h.$highlightLineMarker.start.column=f.column,h._signal("changeBackMarker"))},d.prototype.onSelectionChange=function(h){var f=this.session;if(f.$selectionMarker&&f.removeMarker(f.$selectionMarker),f.$selectionMarker=null,this.selection.isEmpty())this.$updateHighlightActiveLine();else{var b=this.selection.getRange(),T=this.getSelectionStyle();f.$selectionMarker=f.addMarker(b,"ace_selection",T)}var x=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(x),this._signal("changeSelection")},d.prototype.$getSelectionHighLightRegexp=function(){var h=this.session,f=this.getSelectionRange();if(!(f.isEmpty()||f.isMultiLine())){var b=f.start.column,T=f.end.column,x=h.getLine(f.start.row),R=x.substring(b,T);if(!(R.length>5e3||!/[\w\d]/.test(R))){var I=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:R}),N=x.substring(b-1,T+1);if(I.test(N))return I}}},d.prototype.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},d.prototype.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},d.prototype.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},d.prototype.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},d.prototype.onChangeMode=function(h){this.renderer.updateText(),this._emit("changeMode",h)},d.prototype.onChangeWrapLimit=function(){this.renderer.updateFull()},d.prototype.onChangeWrapMode=function(){this.renderer.onResize(!0)},d.prototype.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},d.prototype.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},d.prototype.getCopyText=function(){var h=this.getSelectedText(),f=this.session.doc.getNewLineCharacter(),b=!1;if(!h&&this.$copyWithEmptySelection){b=!0;for(var T=this.selection.getAllRanges(),x=0;xF.search(/\S|$/)){var N=F.substr(x.column).search(/\S|$/);b.doc.removeInLine(x.row,x.column,x.column+N)}}this.clearSelection();var D=x.column,B=b.getState(x.row),F=b.getLine(x.row),z=T.checkOutdent(B,F,h);if(b.insert(x,h),R&&R.selection&&(R.selection.length==2?this.selection.setSelectionRange(new a(x.row,D+R.selection[0],x.row,D+R.selection[1])):this.selection.setSelectionRange(new a(x.row+R.selection[0],R.selection[1],x.row+R.selection[2],R.selection[3]))),this.$enableAutoIndent){if(b.getDocument().isNewLine(h)){var H=T.getNextLineIndent(B,F.slice(0,x.column),b.getTabString());b.insert({row:x.row+1,column:0},H)}z&&T.autoOutdent(B,b,x.row)}},d.prototype.autoIndent=function(){for(var h=this.session,f=h.getMode(),b=this.selection.isEmpty()?[new a(0,0,h.doc.getLength()-1,0)]:this.selection.getAllRanges(),T="",x="",R="",I=h.getTabString(),N=0;N0&&(T=h.getState(F-1),x=h.getLine(F-1),R=f.getNextLineIndent(T,x,I));var z=h.getLine(F),H=f.$getIndent(z);if(R!==H){if(H.length>0){var U=new a(F,0,F,H.length);h.remove(U)}R.length>0&&h.insert({row:F,column:0},R)}f.autoOutdent(T,h,F)}},d.prototype.onTextInput=function(h,f){if(!f)return this.keyBinding.onTextInput(h);this.startOperation({command:{name:"insertstring"}});var b=this.applyComposition.bind(this,h,f);this.selection.rangeCount?this.forEachSelection(b):b(),this.endOperation()},d.prototype.applyComposition=function(h,f){if(f.extendLeft||f.extendRight){var b=this.selection.getRange();b.start.column-=f.extendLeft,b.end.column+=f.extendRight,b.start.column<0&&(b.start.row--,b.start.column+=this.session.getLine(b.start.row).length+1),this.selection.setRange(b),!h&&!b.isEmpty()&&this.remove()}if((h||!this.selection.isEmpty())&&this.insert(h,!0),f.restoreStart||f.restoreEnd){var b=this.selection.getRange();b.start.column-=f.restoreStart,b.end.column-=f.restoreEnd,this.selection.setRange(b)}},d.prototype.onCommandKey=function(h,f,b){return this.keyBinding.onCommandKey(h,f,b)},d.prototype.setOverwrite=function(h){this.session.setOverwrite(h)},d.prototype.getOverwrite=function(){return this.session.getOverwrite()},d.prototype.toggleOverwrite=function(){this.session.toggleOverwrite()},d.prototype.setScrollSpeed=function(h){this.setOption("scrollSpeed",h)},d.prototype.getScrollSpeed=function(){return this.getOption("scrollSpeed")},d.prototype.setDragDelay=function(h){this.setOption("dragDelay",h)},d.prototype.getDragDelay=function(){return this.getOption("dragDelay")},d.prototype.setSelectionStyle=function(h){this.setOption("selectionStyle",h)},d.prototype.getSelectionStyle=function(){return this.getOption("selectionStyle")},d.prototype.setHighlightActiveLine=function(h){this.setOption("highlightActiveLine",h)},d.prototype.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},d.prototype.setHighlightGutterLine=function(h){this.setOption("highlightGutterLine",h)},d.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},d.prototype.setHighlightSelectedWord=function(h){this.setOption("highlightSelectedWord",h)},d.prototype.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},d.prototype.setAnimatedScroll=function(h){this.renderer.setAnimatedScroll(h)},d.prototype.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},d.prototype.setShowInvisibles=function(h){this.renderer.setShowInvisibles(h)},d.prototype.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},d.prototype.setDisplayIndentGuides=function(h){this.renderer.setDisplayIndentGuides(h)},d.prototype.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},d.prototype.setHighlightIndentGuides=function(h){this.renderer.setHighlightIndentGuides(h)},d.prototype.getHighlightIndentGuides=function(){return this.renderer.getHighlightIndentGuides()},d.prototype.setShowPrintMargin=function(h){this.renderer.setShowPrintMargin(h)},d.prototype.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},d.prototype.setPrintMarginColumn=function(h){this.renderer.setPrintMarginColumn(h)},d.prototype.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},d.prototype.setReadOnly=function(h){this.setOption("readOnly",h)},d.prototype.getReadOnly=function(){return this.getOption("readOnly")},d.prototype.setBehavioursEnabled=function(h){this.setOption("behavioursEnabled",h)},d.prototype.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},d.prototype.setWrapBehavioursEnabled=function(h){this.setOption("wrapBehavioursEnabled",h)},d.prototype.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},d.prototype.setShowFoldWidgets=function(h){this.setOption("showFoldWidgets",h)},d.prototype.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},d.prototype.setFadeFoldWidgets=function(h){this.setOption("fadeFoldWidgets",h)},d.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},d.prototype.remove=function(h){this.selection.isEmpty()&&(h=="left"?this.selection.selectLeft():this.selection.selectRight());var f=this.getSelectionRange();if(this.getBehavioursEnabled()){var b=this.session,T=b.getState(f.start.row),x=b.getMode().transformAction(T,"deletion",this,b,f);if(f.end.column===0){var R=b.getTextRange(f);if(R[R.length-1]==` +`){var I=b.getLine(f.end.row);/^\s+$/.test(I)&&(f.end.column=I.length)}}x&&(f=x)}this.session.remove(f),this.clearSelection()},d.prototype.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},d.prototype.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},d.prototype.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.selection.isEmpty()&&this.selection.selectLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},d.prototype.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var h=this.getSelectionRange();h.start.column==h.end.column&&h.start.row==h.end.row&&(h.end.column=0,h.end.row++),this.session.remove(h),this.clearSelection()},d.prototype.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var h=this.getCursorPosition();this.insert(` +`),this.moveCursorToPosition(h)},d.prototype.setGhostText=function(h,f){this.renderer.setGhostText(h,f)},d.prototype.removeGhostText=function(){this.renderer.removeGhostText()},d.prototype.transposeLetters=function(){if(this.selection.isEmpty()){var h=this.getCursorPosition(),f=h.column;if(f!==0){var b=this.session.getLine(h.row),T,x;fN.toLowerCase()?1:0});for(var x=new a(0,0,0,0),T=h.first;T<=h.last;T++){var R=f.getLine(T);x.start.row=T,x.end.row=T,x.end.column=R.length,f.replace(x,b[T-h.first])}},d.prototype.toggleCommentLines=function(){var h=this.session.getState(this.getCursorPosition().row),f=this.$getSelectedRows();this.session.getMode().toggleCommentLines(h,this.session,f.first,f.last)},d.prototype.toggleBlockComment=function(){var h=this.getCursorPosition(),f=this.session.getState(h.row),b=this.getSelectionRange();this.session.getMode().toggleBlockComment(f,this.session,b,h)},d.prototype.getNumberAt=function(h,f){var b=/[\-]?[0-9]+(?:\.[0-9]+)?/g;b.lastIndex=0;for(var T=this.session.getLine(h);b.lastIndex=f){var R={value:x[0],start:x.index,end:x.index+x[0].length};return R}}return null},d.prototype.modifyNumber=function(h){var f=this.selection.getCursor().row,b=this.selection.getCursor().column,T=new a(f,b-1,f,b),x=this.session.getTextRange(T);if(!isNaN(parseFloat(x))&&isFinite(x)){var R=this.getNumberAt(f,b);if(R){var I=R.value.indexOf(".")>=0?R.start+R.value.indexOf(".")+1:R.end,N=R.start+R.value.length-I,D=parseFloat(R.value);D*=Math.pow(10,N),I!==R.end&&b=I&&R<=N&&(b=Y,D.selection.clearSelection(),D.moveCursorTo(h,I+T),D.selection.selectTo(h,N+T)),I=N});for(var B=this.$toggleWordPairs,F,z=0;z=N&&I<=D&&H.match(/((?:https?|ftp):\/\/[\S]+)/)){B=H.replace(/[\s:.,'";}\]]+$/,"");break}N=D}}catch(U){b={error:U}}finally{try{z&&!z.done&&(T=F.return)&&T.call(F)}finally{if(b)throw b.error}}return B},d.prototype.openLink=function(){var h=this.selection.getCursor(),f=this.findLinkAt(h.row,h.column);return f&&window.open(f,"_blank"),f!=null},d.prototype.removeLines=function(){var h=this.$getSelectedRows();this.session.removeFullLines(h.first,h.last),this.clearSelection()},d.prototype.duplicateSelection=function(){var h=this.selection,f=this.session,b=h.getRange(),T=h.isBackwards();if(b.isEmpty()){var x=b.start.row;f.duplicateLines(x,x)}else{var R=T?b.start:b.end,I=f.insert(R,f.getTextRange(b));b.start=R,b.end=I,h.setSelectionRange(b,T)}},d.prototype.moveLinesDown=function(){this.$moveLines(1,!1)},d.prototype.moveLinesUp=function(){this.$moveLines(-1,!1)},d.prototype.moveText=function(h,f,b){return this.session.moveText(h,f,b)},d.prototype.copyLinesUp=function(){this.$moveLines(-1,!0)},d.prototype.copyLinesDown=function(){this.$moveLines(1,!0)},d.prototype.$moveLines=function(h,f){var b,T,x=this.selection;if(!x.inMultiSelectMode||this.inVirtualSelectionMode){var R=x.toOrientedRange();b=this.$getSelectedRows(R),T=this.session.$moveLines(b.first,b.last,f?0:h),f&&h==-1&&(T=0),R.moveBy(T,0),x.fromOrientedRange(R)}else{var I=x.rangeList.ranges;x.rangeList.detach(this.session),this.inVirtualSelectionMode=!0;for(var N=0,D=0,B=I.length,F=0;FU+1)break;U=K.last}for(F--,N=this.session.$moveLines(H,U,f?0:h),f&&h==-1&&(z=F+1);z<=F;)I[z].moveBy(N,0),z++;f||(N=0),D+=N}x.fromOrientedRange(x.ranges[0]),x.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},d.prototype.$getSelectedRows=function(h){return h=(h||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(h.start.row),last:this.session.getRowFoldEnd(h.end.row)}},d.prototype.onCompositionStart=function(h){this.renderer.showComposition(h)},d.prototype.onCompositionUpdate=function(h){this.renderer.setCompositionText(h)},d.prototype.onCompositionEnd=function(){this.renderer.hideComposition()},d.prototype.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},d.prototype.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},d.prototype.isRowVisible=function(h){return h>=this.getFirstVisibleRow()&&h<=this.getLastVisibleRow()},d.prototype.isRowFullyVisible=function(h){return h>=this.renderer.getFirstFullyVisibleRow()&&h<=this.renderer.getLastFullyVisibleRow()},d.prototype.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},d.prototype.$moveByPage=function(h,f){var b=this.renderer,T=this.renderer.layerConfig,x=h*Math.floor(T.height/T.lineHeight);f===!0?this.selection.$moveSelection(function(){this.moveCursorBy(x,0)}):f===!1&&(this.selection.moveCursorBy(x,0),this.selection.clearSelection());var R=b.scrollTop;b.scrollBy(0,x*T.lineHeight),f!=null&&b.scrollCursorIntoView(null,.5),b.animateScrolling(R)},d.prototype.selectPageDown=function(){this.$moveByPage(1,!0)},d.prototype.selectPageUp=function(){this.$moveByPage(-1,!0)},d.prototype.gotoPageDown=function(){this.$moveByPage(1,!1)},d.prototype.gotoPageUp=function(){this.$moveByPage(-1,!1)},d.prototype.scrollPageDown=function(){this.$moveByPage(1)},d.prototype.scrollPageUp=function(){this.$moveByPage(-1)},d.prototype.scrollToRow=function(h){this.renderer.scrollToRow(h)},d.prototype.scrollToLine=function(h,f,b,T){this.renderer.scrollToLine(h,f,b,T)},d.prototype.centerSelection=function(){var h=this.getSelectionRange(),f={row:Math.floor(h.start.row+(h.end.row-h.start.row)/2),column:Math.floor(h.start.column+(h.end.column-h.start.column)/2)};this.renderer.alignCursor(f,.5)},d.prototype.getCursorPosition=function(){return this.selection.getCursor()},d.prototype.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},d.prototype.getSelectionRange=function(){return this.selection.getRange()},d.prototype.selectAll=function(){this.selection.selectAll()},d.prototype.clearSelection=function(){this.selection.clearSelection()},d.prototype.moveCursorTo=function(h,f){this.selection.moveCursorTo(h,f)},d.prototype.moveCursorToPosition=function(h){this.selection.moveCursorToPosition(h)},d.prototype.jumpToMatching=function(h,f){var b=this.getCursorPosition(),T=new $(this.session,b.row,b.column),x=T.getCurrentToken(),R=0;x&&x.type.indexOf("tag-name")!==-1&&(x=T.stepBackward());var I=x||T.stepForward();if(I){var N,D=!1,B={},F=b.column-I.start,z,H={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(I.value.match(/[{}()\[\]]/g)){for(;F1?B[I.value]++:x.value==="=0;--R)this.$tryReplace(b[R],h)&&T++;return this.selection.setSelectionRange(x),T},d.prototype.$tryReplace=function(h,f){var b=this.session.getTextRange(h);return f=this.$search.replace(b,f),f!==null?(h.end=this.session.replace(h,f),h):null},d.prototype.getLastSearchOptions=function(){return this.$search.getOptions()},d.prototype.find=function(h,f,b){f||(f={}),typeof h=="string"||h instanceof RegExp?f.needle=h:typeof h=="object"&&w.mixin(f,h);var T=this.selection.getRange();f.needle==null&&(h=this.session.getTextRange(T)||this.$search.$options.needle,h||(T=this.session.getWordRange(T.start.row,T.start.column),h=this.session.getTextRange(T)),this.$search.set({needle:h})),this.$search.set(f),f.start||this.$search.set({start:T});var x=this.$search.find(this.session);if(f.preventScroll)return x;if(x)return this.revealRange(x,b),x;f.backwards?T.start=T.end:T.end=T.start,this.selection.setRange(T)},d.prototype.findNext=function(h,f){this.find({skipCurrent:!0,backwards:!1},h,f)},d.prototype.findPrevious=function(h,f){this.find(h,{skipCurrent:!0,backwards:!0},f)},d.prototype.revealRange=function(h,f){this.session.unfold(h),this.selection.setSelectionRange(h);var b=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(h.start,h.end,.5),f!==!1&&this.renderer.animateScrolling(b)},d.prototype.undo=function(){this.session.getUndoManager().undo(this.session),this.renderer.scrollCursorIntoView(null,.5)},d.prototype.redo=function(){this.session.getUndoManager().redo(this.session),this.renderer.scrollCursorIntoView(null,.5)},d.prototype.destroy=function(){this.$toDestroy&&(this.$toDestroy.forEach(function(h){h.destroy()}),this.$toDestroy=null),this.$mouseHandler&&this.$mouseHandler.destroy(),this.renderer.destroy(),this._signal("destroy",this),this.session&&this.session.destroy(),this._$emitInputEvent&&this._$emitInputEvent.cancel(),this.removeAllListeners()},d.prototype.setAutoScrollEditorIntoView=function(h){if(h){var f,b=this,T=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var x=this.$scrollAnchor;x.style.cssText="position:absolute",this.container.insertBefore(x,this.container.firstChild);var R=this.on("changeSelection",function(){T=!0}),I=this.renderer.on("beforeRender",function(){T&&(f=b.renderer.container.getBoundingClientRect())}),N=this.renderer.on("afterRender",function(){if(T&&f&&(b.isFocused()||b.searchBox&&b.searchBox.isFocused())){var D=b.renderer,B=D.$cursorLayer.$pixelPos,F=D.layerConfig,z=B.top-F.offset;B.top>=0&&z+f.top<0?T=!0:B.topwindow.innerHeight?T=!1:T=null,T!=null&&(x.style.top=z+"px",x.style.left=B.left+"px",x.style.height=F.lineHeight+"px",x.scrollIntoView(T)),T=f=null}});this.setAutoScrollEditorIntoView=function(D){D||(delete this.setAutoScrollEditorIntoView,this.off("changeSelection",R),this.renderer.off("afterRender",N),this.renderer.off("beforeRender",I))}}},d.prototype.$resetCursorStyle=function(){var h=this.$cursorStyle||"ace",f=this.renderer.$cursorLayer;f&&(f.setSmoothBlinking(/smooth/.test(h)),f.isBlinking=!this.$readOnly&&h!="wide",v.setCssClass(f.element,"ace_slim-cursors",/slim/.test(h)))},d.prototype.prompt=function(h,f,b){var T=this;m.loadModule("ace/ext/prompt",function(x){x.prompt(T,h,f,b)})},d}();S.$uid=0,S.prototype.curOp=null,S.prototype.prevOp={},S.prototype.$mergeableCommands=["backspace","del","insertstring"],S.prototype.$toggleWordPairs=[["first","last"],["true","false"],["yes","no"],["width","height"],["top","bottom"],["right","left"],["on","off"],["x","y"],["get","set"],["max","min"],["horizontal","vertical"],["show","hide"],["add","remove"],["up","down"],["before","after"],["even","odd"],["in","out"],["inside","outside"],["next","previous"],["increase","decrease"],["attach","detach"],["&&","||"],["==","!="]],w.implement(S.prototype,c),m.defineOptions(S.prototype,"editor",{selectionStyle:{set:function(d){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:d})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(d){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(d){this.textInput.setReadOnly(d),this.$resetCursorStyle()},initialValue:!1},copyWithEmptySelection:{set:function(d){this.textInput.setCopyWithEmptySelection(d)},initialValue:!1},cursorStyle:{set:function(d){this.$resetCursorStyle()},values:["ace","slim","smooth","wide"],initialValue:"ace"},mergeUndoDeltas:{values:[!1,!0,"always"],initialValue:!0},behavioursEnabled:{initialValue:!0},wrapBehavioursEnabled:{initialValue:!0},enableAutoIndent:{initialValue:!0},autoScrollEditorIntoView:{set:function(d){this.setAutoScrollEditorIntoView(d)}},keyboardHandler:{set:function(d){this.setKeyboardHandler(d)},get:function(){return this.$keybindingId},handlesSet:!0},value:{set:function(d){this.session.setValue(d)},get:function(){return this.getValue()},handlesSet:!0,hidden:!0},session:{set:function(d){this.setSession(d)},get:function(){return this.session},handlesSet:!0,hidden:!0},showLineNumbers:{set:function(d){this.renderer.$gutterLayer.setShowLineNumbers(d),this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER),d&&this.$relativeLineNumbers?k.attach(this):k.detach(this)},initialValue:!0},relativeLineNumbers:{set:function(d){this.$showLineNumbers&&d?k.attach(this):k.detach(this)}},placeholder:{set:function(d){this.$updatePlaceholder||(this.$updatePlaceholder=function(){var h=this.session&&(this.renderer.$composition||this.session.getLength()>1||this.session.getLine(0).length>0);if(h&&this.renderer.placeholderNode)this.renderer.off("afterRender",this.$updatePlaceholder),v.removeCssClass(this.container,"ace_hasPlaceholder"),this.renderer.placeholderNode.remove(),this.renderer.placeholderNode=null;else if(!h&&!this.renderer.placeholderNode){this.renderer.on("afterRender",this.$updatePlaceholder),v.addCssClass(this.container,"ace_hasPlaceholder");var f=v.createElement("div");f.className="ace_placeholder",f.textContent=this.$placeholder||"",this.renderer.placeholderNode=f,this.renderer.content.appendChild(this.renderer.placeholderNode)}else!h&&this.renderer.placeholderNode&&(this.renderer.placeholderNode.textContent=this.$placeholder||"")}.bind(this),this.on("input",this.$updatePlaceholder)),this.$updatePlaceholder()}},enableKeyboardAccessibility:{set:function(d){var h={name:"blurTextInput",description:"Set focus to the editor content div to allow tabbing through the page",bindKey:"Esc",exec:function(T){T.blur(),T.renderer.scroller.focus()},readOnly:!0},f=function(T){if(T.target==this.renderer.scroller&&T.keyCode===A.enter){T.preventDefault();var x=this.getCursorPosition().row;this.isRowVisible(x)||this.scrollToLine(x,!0,!0),this.focus()}},b;d?(this.renderer.enableKeyboardAccessibility=!0,this.renderer.keyboardFocusClassName="ace_keyboard-focus",this.textInput.getElement().setAttribute("tabindex",-1),this.textInput.setNumberOfExtraLines(l.isWin?3:0),this.renderer.scroller.setAttribute("tabindex",0),this.renderer.scroller.setAttribute("role","group"),this.renderer.scroller.setAttribute("aria-roledescription",g("editor.scroller.aria-roledescription","editor")),this.renderer.scroller.classList.add(this.renderer.keyboardFocusClassName),this.renderer.scroller.setAttribute("aria-label",g("editor.scroller.aria-label","Editor content, press Enter to start editing, press Escape to exit")),this.renderer.scroller.addEventListener("keyup",f.bind(this)),this.commands.addCommand(h),this.renderer.$gutter.setAttribute("tabindex",0),this.renderer.$gutter.setAttribute("aria-hidden",!1),this.renderer.$gutter.setAttribute("role","group"),this.renderer.$gutter.setAttribute("aria-roledescription",g("editor.gutter.aria-roledescription","editor")),this.renderer.$gutter.setAttribute("aria-label",g("editor.gutter.aria-label","Editor gutter, press Enter to interact with controls using arrow keys, press Escape to exit")),this.renderer.$gutter.classList.add(this.renderer.keyboardFocusClassName),this.renderer.content.setAttribute("aria-hidden",!0),b||(b=new C(this)),b.addListener(),this.textInput.setAriaOptions({setLabel:!0})):(this.renderer.enableKeyboardAccessibility=!1,this.textInput.getElement().setAttribute("tabindex",0),this.textInput.setNumberOfExtraLines(0),this.renderer.scroller.setAttribute("tabindex",-1),this.renderer.scroller.removeAttribute("role"),this.renderer.scroller.removeAttribute("aria-roledescription"),this.renderer.scroller.classList.remove(this.renderer.keyboardFocusClassName),this.renderer.scroller.removeAttribute("aria-label"),this.renderer.scroller.removeEventListener("keyup",f.bind(this)),this.commands.removeCommand(h),this.renderer.content.removeAttribute("aria-hidden"),this.renderer.$gutter.setAttribute("tabindex",-1),this.renderer.$gutter.setAttribute("aria-hidden",!0),this.renderer.$gutter.removeAttribute("role"),this.renderer.$gutter.removeAttribute("aria-roledescription"),this.renderer.$gutter.removeAttribute("aria-label"),this.renderer.$gutter.classList.remove(this.renderer.keyboardFocusClassName),b&&b.removeListener())},initialValue:!1},textInputAriaLabel:{set:function(d){this.$textInputAriaLabel=d},initialValue:""},enableMobileMenu:{set:function(d){this.$enableMobileMenu=d},initialValue:!0},customScrollbar:"renderer",hScrollBarAlwaysVisible:"renderer",vScrollBarAlwaysVisible:"renderer",highlightGutterLine:"renderer",animatedScroll:"renderer",showInvisibles:"renderer",showPrintMargin:"renderer",printMarginColumn:"renderer",printMargin:"renderer",fadeFoldWidgets:"renderer",showFoldWidgets:"renderer",displayIndentGuides:"renderer",highlightIndentGuides:"renderer",showGutter:"renderer",fontSize:"renderer",fontFamily:"renderer",maxLines:"renderer",minLines:"renderer",scrollPastEnd:"renderer",fixedWidthGutter:"renderer",theme:"renderer",hasCssTransforms:"renderer",maxPixelHeight:"renderer",useTextareaForIME:"renderer",useResizeObserver:"renderer",useSvgGutterIcons:"renderer",showFoldedAnnotations:"renderer",scrollSpeed:"$mouseHandler",dragDelay:"$mouseHandler",dragEnabled:"$mouseHandler",focusTimeout:"$mouseHandler",tooltipFollowsMouse:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",navigateWithinSoftTabs:"session",tabSize:"session",wrap:"session",indentedSoftWrap:"session",foldStyle:"session",mode:"session"});var k={getText:function(d,h){return(Math.abs(d.selection.lead.row-h)||h+1+(h<9?"\xB7":""))+""},getWidth:function(d,h,f){return Math.max(h.toString().length,(f.lastRow+1).toString().length,2)*f.characterWidth},update:function(d,h){h.renderer.$loop.schedule(h.renderer.CHANGE_GUTTER)},attach:function(d){d.renderer.$gutterLayer.$renderer=this,d.on("changeSelection",this.update),this.update(null,d)},detach:function(d){d.renderer.$gutterLayer.$renderer==this&&(d.renderer.$gutterLayer.$renderer=null),d.off("changeSelection",this.update),this.update(null,d)}};L.Editor=S}),ace.define("ace/layer/lines",["require","exports","module","ace/lib/dom"],function(_,L,E){"use strict";var y=_("../lib/dom"),w=function(){function v(s,l){this.element=s,this.canvasHeight=l||5e5,this.element.style.height=this.canvasHeight*2+"px",this.cells=[],this.cellCache=[],this.$offsetCoefficient=0}return v.prototype.moveContainer=function(s){y.translate(this.element,0,-(s.firstRowScreen*s.lineHeight%this.canvasHeight)-s.offset*this.$offsetCoefficient)},v.prototype.pageChanged=function(s,l){return Math.floor(s.firstRowScreen*s.lineHeight/this.canvasHeight)!==Math.floor(l.firstRowScreen*l.lineHeight/this.canvasHeight)},v.prototype.computeLineTop=function(s,l,i){var r=l.firstRowScreen*l.lineHeight,n=Math.floor(r/this.canvasHeight),t=i.documentToScreenRow(s,0)*l.lineHeight;return t-n*this.canvasHeight},v.prototype.computeLineHeight=function(s,l,i){return l.lineHeight*i.getRowLineCount(s)},v.prototype.getLength=function(){return this.cells.length},v.prototype.get=function(s){return this.cells[s]},v.prototype.shift=function(){this.$cacheCell(this.cells.shift())},v.prototype.pop=function(){this.$cacheCell(this.cells.pop())},v.prototype.push=function(s){if(Array.isArray(s)){this.cells.push.apply(this.cells,s);for(var l=y.createFragment(this.element),i=0;ip&&(C=u.end.row+1,u=o.getNextFoldLine(C,u),p=u?u.start.row:1/0),C>c){for(;this.$lines.getLength()>$+1;)this.$lines.pop();break}m=this.$lines.get(++$),m?m.row=C:(m=this.$lines.createCell(C,e,this.session,n),this.$lines.push(m)),this.$renderCell(m,e,u,C),C++}this._signal("afterRender"),this.$updateGutterWidth(e)},t.prototype.$updateGutterWidth=function(e){var o=this.session,a=o.gutterRenderer||this.$renderer,c=o.$firstLineNumber,u=this.$lines.last()?this.$lines.last().text:"";(this.$fixedWidth||o.$useWrapMode)&&(u=o.getLength()+c-1);var p=a?a.getWidth(o,u,e):u.toString().length*e.characterWidth,m=this.$padding||this.$computePadding();p+=m.left+m.right,p!==this.gutterWidth&&!isNaN(p)&&(this.gutterWidth=p,this.element.parentNode.style.width=this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._signal("changeGutterWidth",p))},t.prototype.$updateCursorRow=function(){if(this.$highlightGutterLine){var e=this.session.selection.getCursor();this.$cursorRow!==e.row&&(this.$cursorRow=e.row)}},t.prototype.updateLineHighlight=function(){if(this.$highlightGutterLine){var e=this.session.selection.cursor.row;if(this.$cursorRow=e,!(this.$cursorCell&&this.$cursorCell.row==e)){this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ",""));var o=this.$lines.cells;this.$cursorCell=null;for(var a=0;a=this.$cursorRow){if(c.row>this.$cursorRow){var u=this.session.getFoldLine(this.$cursorRow);if(a>0&&u&&u.start.row==o[a-1].row)c=o[a-1];else break}c.element.className="ace_gutter-active-line "+c.element.className,this.$cursorCell=c;break}}}}},t.prototype.scrollLines=function(e){var o=this.config;if(this.config=e,this.$updateCursorRow(),this.$lines.pageChanged(o,e))return this.update(e);this.$lines.moveContainer(e);var a=Math.min(e.lastRow+e.gutterOffset,this.session.getLength()-1),c=this.oldLastRow;if(this.oldLastRow=a,!o||c0;u--)this.$lines.shift();if(c>a)for(var u=this.session.getFoldedRowCount(a+1,c);u>0;u--)this.$lines.pop();e.firstRowc&&this.$lines.push(this.$renderLines(e,c+1,a)),this.updateLineHighlight(),this._signal("afterRender"),this.$updateGutterWidth(e)},t.prototype.$renderLines=function(e,o,a){for(var c=[],u=o,p=this.session.getNextFoldLine(u),m=p?p.start.row:1/0;u>m&&(u=p.end.row+1,p=this.session.getNextFoldLine(u,p),m=p?p.start.row:1/0),!(u>a);){var $=this.$lines.createCell(u,e,this.session,n);this.$renderCell($,e,p,u),c.push($),u++}return c},t.prototype.$renderCell=function(e,o,a,c){var u=e.element,p=this.session,m=u.childNodes[0],$=u.childNodes[1],C=u.childNodes[2],g=C.firstChild,M=p.$firstLineNumber,A=p.$breakpoints,S=p.$decorations,k=p.gutterRenderer||this.$renderer,d=this.$showFoldWidgets&&p.foldWidgets,h=a?a.start.row:Number.MAX_VALUE,f=o.lineHeight+"px",b=this.$useSvgGutterIcons?"ace_gutter-cell_svg-icons ":"ace_gutter-cell ",T=this.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",x=(k?k.getText(p,c):c+M).toString();if(this.$highlightGutterLine&&(c==this.$cursorRow||a&&c=h&&this.$cursorRow<=a.end.row)&&(b+="ace_gutter-active-line ",this.$cursorCell!=e&&(this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ","")),this.$cursorCell=e)),A[c]&&(b+=A[c]),S[c]&&(b+=S[c]),this.$annotations[c]&&c!==h&&(b+=this.$annotations[c].className),d){var R=d[c];R==null&&(R=d[c]=p.getFoldWidget(c))}if(R){var I="ace_fold-widget ace_"+R,N=R=="start"&&c==h&&ca.right-o.right)return"foldWidgets"},t}();r.prototype.$fixedWidth=!1,r.prototype.$highlightGutterLine=!0,r.prototype.$renderer="",r.prototype.$showLineNumbers=!0,r.prototype.$showFoldWidgets=!0,w.implement(r.prototype,s);function n(t){var e=document.createTextNode("");t.appendChild(e);var o=y.createElement("span");t.appendChild(o);var a=y.createElement("span");t.appendChild(a);var c=y.createElement("span");return a.appendChild(c),t}L.Gutter=r}),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(_,L,E){"use strict";var y=_("../range").Range,w=_("../lib/dom"),v=function(){function l(i){this.element=w.createElement("div"),this.element.className="ace_layer ace_marker-layer",i.appendChild(this.element)}return l.prototype.setPadding=function(i){this.$padding=i},l.prototype.setSession=function(i){this.session=i},l.prototype.setMarkers=function(i){this.markers=i},l.prototype.elt=function(i,r){var n=this.i!=-1&&this.element.childNodes[this.i];n?this.i++:(n=document.createElement("div"),this.element.appendChild(n),this.i=-1),n.style.cssText=r,n.className=i},l.prototype.update=function(i){if(i){this.config=i,this.i=0;var r;for(var n in this.markers){var t=this.markers[n];if(!t.range){t.update(r,this,this.session,i);continue}var e=t.range.clipRows(i.firstRow,i.lastRow);if(!e.isEmpty())if(e=e.toScreenRange(this.session),t.renderer){var o=this.$getTop(e.start.row,i),a=this.$padding+e.start.column*i.characterWidth;t.renderer(r,e,a,o,i)}else t.type=="fullLine"?this.drawFullLineMarker(r,e,t.clazz,i):t.type=="screenLine"?this.drawScreenLineMarker(r,e,t.clazz,i):e.isMultiLine()?t.type=="text"?this.drawTextMarker(r,e,t.clazz,i):this.drawMultiLineMarker(r,e,t.clazz,i):this.drawSingleLineMarker(r,e,t.clazz+" ace_start ace_br15",i)}if(this.i!=-1)for(;this.i$,u==c),t,u==c?0:1,e)},l.prototype.drawMultiLineMarker=function(i,r,n,t,e){var o=this.$padding,a=t.lineHeight,c=this.$getTop(r.start.row,t),u=o+r.start.column*t.characterWidth;if(e=e||"",this.session.$bidiHandler.isBidiRow(r.start.row)){var p=r.clone();p.end.row=p.start.row,p.end.column=this.session.getLine(p.start.row).length,this.drawBidiSingleLineMarker(i,p,n+" ace_br1 ace_start",t,null,e)}else this.elt(n+" ace_br1 ace_start","height:"+a+"px;right:"+o+"px;top:"+c+"px;left:"+u+"px;"+(e||""));if(this.session.$bidiHandler.isBidiRow(r.end.row)){var p=r.clone();p.start.row=p.end.row,p.start.column=0,this.drawBidiSingleLineMarker(i,p,n+" ace_br12",t,null,e)}else{c=this.$getTop(r.end.row,t);var m=r.end.column*t.characterWidth;this.elt(n+" ace_br12","height:"+a+"px;width:"+m+"px;top:"+c+"px;left:"+o+"px;"+(e||""))}if(a=(r.end.row-r.start.row-1)*t.lineHeight,!(a<=0)){c=this.$getTop(r.start.row+1,t);var $=(r.start.column?1:0)|(r.end.column?0:8);this.elt(n+($?" ace_br"+$:""),"height:"+a+"px;right:"+o+"px;top:"+c+"px;left:"+o+"px;"+(e||""))}},l.prototype.drawSingleLineMarker=function(i,r,n,t,e,o){if(this.session.$bidiHandler.isBidiRow(r.start.row))return this.drawBidiSingleLineMarker(i,r,n,t,e,o);var a=t.lineHeight,c=(r.end.column+(e||0)-r.start.column)*t.characterWidth,u=this.$getTop(r.start.row,t),p=this.$padding+r.start.column*t.characterWidth;this.elt(n,"height:"+a+"px;width:"+c+"px;top:"+u+"px;left:"+p+"px;"+(o||""))},l.prototype.drawBidiSingleLineMarker=function(i,r,n,t,e,o){var a=t.lineHeight,c=this.$getTop(r.start.row,t),u=this.$padding,p=this.session.$bidiHandler.getSelections(r.start.column,r.end.column);p.forEach(function(m){this.elt(n,"height:"+a+"px;width:"+(m.width+(e||0))+"px;top:"+c+"px;left:"+(u+m.left)+"px;"+(o||""))},this)},l.prototype.drawFullLineMarker=function(i,r,n,t,e){var o=this.$getTop(r.start.row,t),a=t.lineHeight;r.start.row!=r.end.row&&(a+=this.$getTop(r.end.row,t)-o),this.elt(n,"height:"+a+"px;top:"+o+"px;left:0;right:0;"+(e||""))},l.prototype.drawScreenLineMarker=function(i,r,n,t,e){var o=this.$getTop(r.start.row,t),a=t.lineHeight;this.elt(n,"height:"+a+"px;top:"+o+"px;left:0;right:0;"+(e||""))},l}();v.prototype.$padding=0;function s(l,i,r,n){return(l?1:0)|(i?2:0)|(r?4:0)|(n?8:0)}L.Marker=v}),ace.define("ace/layer/text_util",["require","exports","module"],function(_,L,E){var y=new Set(["text","rparen","lparen"]);L.isTextToken=function(w){return y.has(w)}}),ace.define("ace/layer/text",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/layer/lines","ace/lib/event_emitter","ace/config","ace/layer/text_util"],function(_,L,E){"use strict";var y=_("../lib/oop"),w=_("../lib/dom"),v=_("../lib/lang"),s=_("./lines").Lines,l=_("../lib/event_emitter").EventEmitter,i=_("../config").nls,r=_("./text_util").isTextToken,n=function(){function t(e){this.dom=w,this.element=this.dom.createElement("div"),this.element.className="ace_layer ace_text-layer",e.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this),this.$lines=new s(this.element)}return t.prototype.$updateEolChar=function(){var e=this.session.doc,o=e.getNewLineCharacter()==` +`&&e.getNewLineMode()!="windows",a=o?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=a)return this.EOL_CHAR=a,!0},t.prototype.setPadding=function(e){this.$padding=e,this.element.style.margin="0 "+e+"px"},t.prototype.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},t.prototype.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},t.prototype.$setFontMetrics=function(e){this.$fontMetrics=e,this.$fontMetrics.on("changeCharacterSize",function(o){this._signal("changeCharacterSize",o)}.bind(this)),this.$pollSizeChanges()},t.prototype.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},t.prototype.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},t.prototype.setSession=function(e){this.session=e,e&&this.$computeTabString()},t.prototype.setShowInvisibles=function(e){return this.showInvisibles==e?!1:(this.showInvisibles=e,typeof e=="string"?(this.showSpaces=/tab/i.test(e),this.showTabs=/space/i.test(e),this.showEOL=/eol/i.test(e)):this.showSpaces=this.showTabs=this.showEOL=e,this.$computeTabString(),!0)},t.prototype.setDisplayIndentGuides=function(e){return this.displayIndentGuides==e?!1:(this.displayIndentGuides=e,this.$computeTabString(),!0)},t.prototype.setHighlightIndentGuides=function(e){return this.$highlightIndentGuides===e?!1:(this.$highlightIndentGuides=e,e)},t.prototype.$computeTabString=function(){var e=this.session.getTabSize();this.tabSize=e;for(var o=this.$tabStrings=[0],a=1;aM&&(C=g.end.row+1,g=this.session.getNextFoldLine(C,g),M=g?g.start.row:1/0),!(C>u);){var A=p[m++];if(A){this.dom.removeChildren(A),this.$renderLine(A,C,C==M?g:!1),$&&(A.style.top=this.$lines.computeLineTop(C,e,this.session)+"px");var S=e.lineHeight*this.session.getRowLength(C)+"px";A.style.height!=S&&($=!0,A.style.height=S)}C++}if($)for(;m0;u--)this.$lines.shift();if(o.lastRow>e.lastRow)for(var u=this.session.getFoldedRowCount(e.lastRow+1,o.lastRow);u>0;u--)this.$lines.pop();e.firstRowo.lastRow&&this.$lines.push(this.$renderLinesFragment(e,o.lastRow+1,e.lastRow)),this.$highlightIndentGuide()},t.prototype.$renderLinesFragment=function(e,o,a){for(var c=[],u=o,p=this.session.getNextFoldLine(u),m=p?p.start.row:1/0;u>m&&(u=p.end.row+1,p=this.session.getNextFoldLine(u,p),m=p?p.start.row:1/0),!(u>a);){var $=this.$lines.createCell(u,e,this.session),C=$.element;this.dom.removeChildren(C),w.setStyle(C.style,"height",this.$lines.computeLineHeight(u,e,this.session)+"px"),w.setStyle(C.style,"top",this.$lines.computeLineTop(u,e,this.session)+"px"),this.$renderLine(C,u,u==m?p:!1),this.$useLineGroups()?C.className="ace_line_group":C.className="ace_line",c.push($),u++}return c},t.prototype.update=function(e){this.$lines.moveContainer(e),this.config=e;for(var o=e.firstRow,a=e.lastRow,c=this.$lines;c.getLength();)c.pop();c.push(this.$renderLinesFragment(e,o,a))},t.prototype.$renderToken=function(e,o,a,c){for(var u=this,p=/(\t)|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\uFEFF\uFFF9-\uFFFC\u2066\u2067\u2068\u202A\u202B\u202D\u202E\u202C\u2069\u2060\u2061\u2062\u2063\u2064\u206A\u206B\u206B\u206C\u206D\u206E\u206F]+)|(\u3000)|([\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3001-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]|[\uD800-\uDBFF][\uDC00-\uDFFF])/g,m=this.dom.createFragment(this.element),$,C=0;$=p.exec(c);){var g=$[1],M=$[2],A=$[3],S=$[4],k=$[5];if(!(!u.showSpaces&&M)){var d=C!=$.index?c.slice(C,$.index):"";if(C=$.index+$[0].length,d&&m.appendChild(this.dom.createTextNode(d,this.element)),g){var h=u.session.getScreenTabSize(o+$.index);m.appendChild(u.$tabStrings[h].cloneNode(!0)),o+=h-1}else if(M)if(u.showSpaces){var f=this.dom.createElement("span");f.className="ace_invisible ace_invisible_space",f.textContent=v.stringRepeat(u.SPACE_CHAR,M.length),m.appendChild(f)}else m.appendChild(this.dom.createTextNode(M,this.element));else if(A){var f=this.dom.createElement("span");f.className="ace_invisible ace_invisible_space ace_invalid",f.textContent=v.stringRepeat(u.SPACE_CHAR,A.length),m.appendChild(f)}else if(S){o+=1;var f=this.dom.createElement("span");f.style.width=u.config.characterWidth*2+"px",f.className=u.showSpaces?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",f.textContent=u.showSpaces?u.SPACE_CHAR:S,m.appendChild(f)}else if(k){o+=1;var f=this.dom.createElement("span");f.style.width=u.config.characterWidth*2+"px",f.className="ace_cjk",f.textContent=k,m.appendChild(f)}}}if(m.appendChild(this.dom.createTextNode(C?c.slice(C):c,this.element)),r(a.type))e.appendChild(m);else{var b="ace_"+a.type.replace(/\./g," ace_"),f=this.dom.createElement("span");a.type=="fold"&&(f.style.width=a.value.length*this.config.characterWidth+"px",f.setAttribute("title",i("inline-fold.closed.title","Unfold code"))),f.className=b,f.appendChild(m),e.appendChild(f)}return o+c.length},t.prototype.renderIndentGuide=function(e,o,a){var c=o.search(this.$indentGuideRe);if(c<=0||c>=a)return o;if(o[0]==" "){c-=c%this.tabSize;for(var u=c/this.tabSize,p=0;pp[m].start.row?this.$highlightIndentGuideMarker.dir=-1:this.$highlightIndentGuideMarker.dir=1;break}}if(!this.$highlightIndentGuideMarker.end&&e[o.row]!==""&&o.column===e[o.row].length){this.$highlightIndentGuideMarker.dir=1;for(var m=o.row+1;m0){for(var u=0;u=this.$highlightIndentGuideMarker.start+1){if(c.row>=this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(c,o)}}else for(var a=e.length-1;a>=0;a--){var c=e[a];if(this.$highlightIndentGuideMarker.end&&c.row=p;)m=this.$renderToken($,m,g,M.substring(0,p-c)),M=M.substring(p-c),c=p,$=this.$createLineElement(),e.appendChild($),$.appendChild(this.dom.createTextNode(v.stringRepeat("\xA0",a.indent),this.element)),u++,m=0,p=a[u]||Number.MAX_VALUE;M.length!=0&&(c+=M.length,m=this.$renderToken($,m,g,M))}}a[a.length-1]>this.MAX_LINE_LENGTH&&this.$renderOverflowMessage($,m,null,"",!0)},t.prototype.$renderSimpleLine=function(e,o){for(var a=0,c=0;cthis.MAX_LINE_LENGTH)return this.$renderOverflowMessage(e,a,u,p);a=this.$renderToken(e,a,u,p)}}},t.prototype.$renderOverflowMessage=function(e,o,a,c,u){a&&this.$renderToken(e,o,a,c.slice(0,this.MAX_LINE_LENGTH-o));var p=this.dom.createElement("span");p.className="ace_inline_button ace_keyword ace_toggle_wrap",p.textContent=u?"":"",e.appendChild(p)},t.prototype.$renderLine=function(e,o,a){if(!a&&a!=!1&&(a=this.session.getFoldLine(o)),a)var c=this.$getFoldLineTokens(o,a);else var c=this.session.getTokens(o);var u=e;if(c.length){var p=this.session.getRowSplitData(o);if(p&&p.length){this.$renderWrappedLine(e,c,p);var u=e.lastChild}else{var u=e;this.$useLineGroups()&&(u=this.$createLineElement(),e.appendChild(u)),this.$renderSimpleLine(u,c)}}else this.$useLineGroups()&&(u=this.$createLineElement(),e.appendChild(u));if(this.showEOL&&u){a&&(o=a.end.row);var m=this.dom.createElement("span");m.className="ace_invisible ace_invisible_eol",m.textContent=o==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,u.appendChild(m)}},t.prototype.$getFoldLineTokens=function(e,o){var a=this.session,c=[];function u(m,$,C){for(var g=0,M=0;M+m[g].value.length<$;)if(M+=m[g].value.length,g++,g==m.length)return;if(M!=$){var A=m[g].value.substring($-M);A.length>C-$&&(A=A.substring(0,C-$)),c.push({type:m[g].type,value:A}),M=$+A.length,g+=1}for(;MC?c.push({type:m[g].type,value:A.substring(0,C-M)}):c.push(m[g]),M+=A.length,g+=1}}var p=a.getTokens(e);return o.walk(function(m,$,C,g,M){m!=null?c.push({type:"fold",value:m}):(M&&(p=a.getTokens($)),p.length&&u(p,g,C))},o.end.row,this.session.getLine(o.end.row).length),c},t.prototype.$useLineGroups=function(){return this.session.getUseWrapMode()},t}();n.prototype.EOF_CHAR="\xB6",n.prototype.EOL_CHAR_LF="\xAC",n.prototype.EOL_CHAR_CRLF="\xA4",n.prototype.EOL_CHAR=n.prototype.EOL_CHAR_LF,n.prototype.TAB_CHAR="\u2014",n.prototype.SPACE_CHAR="\xB7",n.prototype.$padding=0,n.prototype.MAX_LINE_LENGTH=1e4,n.prototype.showInvisibles=!1,n.prototype.showSpaces=!1,n.prototype.showTabs=!1,n.prototype.showEOL=!1,n.prototype.displayIndentGuides=!0,n.prototype.$highlightIndentGuides=!0,n.prototype.$tabStrings=[],n.prototype.destroy={},n.prototype.onChangeTabSize=n.prototype.$computeTabString,y.implement(n.prototype,l),L.Text=n}),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(_,L,E){"use strict";var y=_("../lib/dom"),w=function(){function v(s){this.element=y.createElement("div"),this.element.className="ace_layer ace_cursor-layer",s.appendChild(this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),y.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateOpacity.bind(this)}return v.prototype.$updateOpacity=function(s){for(var l=this.cursors,i=l.length;i--;)y.setStyle(l[i].style,"opacity",s?"":"0")},v.prototype.$startCssAnimation=function(){for(var s=this.cursors,l=s.length;l--;)s[l].style.animationDuration=this.blinkInterval+"ms";this.$isAnimating=!0,setTimeout(function(){this.$isAnimating&&y.addCssClass(this.element,"ace_animate-blinking")}.bind(this))},v.prototype.$stopCssAnimation=function(){this.$isAnimating=!1,y.removeCssClass(this.element,"ace_animate-blinking")},v.prototype.setPadding=function(s){this.$padding=s},v.prototype.setSession=function(s){this.session=s},v.prototype.setBlinking=function(s){s!=this.isBlinking&&(this.isBlinking=s,this.restartTimer())},v.prototype.setBlinkInterval=function(s){s!=this.blinkInterval&&(this.blinkInterval=s,this.restartTimer())},v.prototype.setSmoothBlinking=function(s){s!=this.smoothBlinking&&(this.smoothBlinking=s,y.setCssClass(this.element,"ace_smooth-blinking",s),this.$updateCursors(!0),this.restartTimer())},v.prototype.addCursor=function(){var s=y.createElement("div");return s.className="ace_cursor",this.element.appendChild(s),this.cursors.push(s),s},v.prototype.removeCursor=function(){if(this.cursors.length>1){var s=this.cursors.pop();return s.parentNode.removeChild(s),s}},v.prototype.hideCursor=function(){this.isVisible=!1,y.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},v.prototype.showCursor=function(){this.isVisible=!0,y.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},v.prototype.restartTimer=function(){var s=this.$updateCursors;if(clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.$stopCssAnimation(),this.smoothBlinking&&(this.$isSmoothBlinking=!1,y.removeCssClass(this.element,"ace_smooth-blinking")),s(!0),!this.isBlinking||!this.blinkInterval||!this.isVisible){this.$stopCssAnimation();return}if(this.smoothBlinking&&(this.$isSmoothBlinking=!0,setTimeout(function(){this.$isSmoothBlinking&&y.addCssClass(this.element,"ace_smooth-blinking")}.bind(this))),y.HAS_CSS_ANIMATION)this.$startCssAnimation();else{var l=function(){this.timeoutId=setTimeout(function(){s(!1)},.6*this.blinkInterval)}.bind(this);this.intervalId=setInterval(function(){s(!0),l()},this.blinkInterval),l()}},v.prototype.getPixelPosition=function(s,l){if(!this.config||!this.session)return{left:0,top:0};s||(s=this.session.selection.getCursor());var i=this.session.documentToScreenPosition(s),r=this.$padding+(this.session.$bidiHandler.isBidiRow(i.row,s.row)?this.session.$bidiHandler.getPosLeft(i.column):i.column*this.config.characterWidth),n=(i.row-(l?this.config.firstRowScreen:0))*this.config.lineHeight;return{left:r,top:n}},v.prototype.isCursorInView=function(s,l){return s.top>=0&&s.tops.height+s.offset||t.top<0)&&i>1)){var e=this.cursors[r++]||this.addCursor(),o=e.style;this.drawCursor?this.drawCursor(e,t,s,l[i],this.session):this.isCursorInView(t,s)?(y.setStyle(o,"display","block"),y.translate(e,t.left,t.top),y.setStyle(o,"width",Math.round(s.characterWidth)+"px"),y.setStyle(o,"height",s.lineHeight+"px")):y.setStyle(o,"display","none")}}for(;this.cursors.length>r;)this.removeCursor();var a=this.session.getOverwrite();this.$setOverwrite(a),this.$pixelPos=t,this.restartTimer()},v.prototype.$setOverwrite=function(s){s!=this.overwrite&&(this.overwrite=s,s?y.addCssClass(this.element,"ace_overwrite-cursors"):y.removeCssClass(this.element,"ace_overwrite-cursors"))},v.prototype.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)},v}();w.prototype.$padding=0,w.prototype.drawCursor=null,L.Cursor=w}),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(_,L,E){"use strict";var y=this&&this.__extends||function(){var e=function(o,a){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,u){c.__proto__=u}||function(c,u){for(var p in u)Object.prototype.hasOwnProperty.call(u,p)&&(c[p]=u[p])},e(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");e(o,a);function c(){this.constructor=o}o.prototype=a===null?Object.create(a):(c.prototype=a.prototype,new c)}}(),w=_("./lib/oop"),v=_("./lib/dom"),s=_("./lib/event"),l=_("./lib/event_emitter").EventEmitter,i=32768,r=function(){function e(o,a){this.element=v.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+a,this.inner=v.createElement("div"),this.inner.className="ace_scrollbar-inner",this.inner.textContent="\xA0",this.element.appendChild(this.inner),o.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,s.addListener(this.element,"scroll",this.onScroll.bind(this)),s.addListener(this.element,"mousedown",s.preventDefault)}return e.prototype.setVisible=function(o){this.element.style.display=o?"":"none",this.isVisible=o,this.coeff=1},e}();w.implement(r.prototype,l);var n=function(e){y(o,e);function o(a,c){var u=e.call(this,a,"-v")||this;return u.scrollTop=0,u.scrollHeight=0,c.$scrollbarWidth=u.width=v.scrollbarWidth(a.ownerDocument),u.inner.style.width=u.element.style.width=(u.width||15)+5+"px",u.$minWidth=0,u}return o.prototype.onScroll=function(){if(!this.skipEvent){if(this.scrollTop=this.element.scrollTop,this.coeff!=1){var a=this.element.clientHeight/this.scrollHeight;this.scrollTop=this.scrollTop*(1-a)/(this.coeff-a)}this._emit("scroll",{data:this.scrollTop})}this.skipEvent=!1},o.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},o.prototype.setHeight=function(a){this.element.style.height=a+"px"},o.prototype.setScrollHeight=function(a){this.scrollHeight=a,a>i?(this.coeff=i/a,a=i):this.coeff!=1&&(this.coeff=1),this.inner.style.height=a+"px"},o.prototype.setScrollTop=function(a){this.scrollTop!=a&&(this.skipEvent=!0,this.scrollTop=a,this.element.scrollTop=a*this.coeff)},o}(r);n.prototype.setInnerHeight=n.prototype.setScrollHeight;var t=function(e){y(o,e);function o(a,c){var u=e.call(this,a,"-h")||this;return u.scrollLeft=0,u.height=c.$scrollbarWidth,u.inner.style.height=u.element.style.height=(u.height||15)+5+"px",u}return o.prototype.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},o.prototype.getHeight=function(){return this.isVisible?this.height:0},o.prototype.setWidth=function(a){this.element.style.width=a+"px"},o.prototype.setInnerWidth=function(a){this.inner.style.width=a+"px"},o.prototype.setScrollWidth=function(a){this.inner.style.width=a+"px"},o.prototype.setScrollLeft=function(a){this.scrollLeft!=a&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=a)},o}(r);L.ScrollBar=n,L.ScrollBarV=n,L.ScrollBarH=t,L.VScrollBar=n,L.HScrollBar=t}),ace.define("ace/scrollbar_custom",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(_,L,E){"use strict";var y=this&&this.__extends||function(){var t=function(e,o){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var u in c)Object.prototype.hasOwnProperty.call(c,u)&&(a[u]=c[u])},t(e,o)};return function(e,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");t(e,o);function a(){this.constructor=e}e.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}}(),w=_("./lib/oop"),v=_("./lib/dom"),s=_("./lib/event"),l=_("./lib/event_emitter").EventEmitter;v.importCssString(`.ace_editor>.ace_sb-v div, .ace_editor>.ace_sb-h div{ + position: absolute; + background: rgba(128, 128, 128, 0.6); + -moz-box-sizing: border-box; + box-sizing: border-box; + border: 1px solid #bbb; + border-radius: 2px; + z-index: 8; +} +.ace_editor>.ace_sb-v, .ace_editor>.ace_sb-h { + position: absolute; + z-index: 6; + background: none; + overflow: hidden!important; +} +.ace_editor>.ace_sb-v { + z-index: 6; + right: 0; + top: 0; + width: 12px; +} +.ace_editor>.ace_sb-v div { + z-index: 8; + right: 0; + width: 100%; +} +.ace_editor>.ace_sb-h { + bottom: 0; + left: 0; + height: 12px; +} +.ace_editor>.ace_sb-h div { + bottom: 0; + height: 100%; +} +.ace_editor>.ace_sb_grabbed { + z-index: 8; + background: #000; +}`,"ace_scrollbar.css",!1);var i=function(){function t(e,o){this.element=v.createElement("div"),this.element.className="ace_sb"+o,this.inner=v.createElement("div"),this.inner.className="",this.element.appendChild(this.inner),this.VScrollWidth=12,this.HScrollHeight=12,e.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,s.addMultiMouseDownListener(this.element,[500,300,300],this,"onMouseDown")}return t.prototype.setVisible=function(e){this.element.style.display=e?"":"none",this.isVisible=e,this.coeff=1},t}();w.implement(i.prototype,l);var r=function(t){y(e,t);function e(o,a){var c=t.call(this,o,"-v")||this;return c.scrollTop=0,c.scrollHeight=0,c.parent=o,c.width=c.VScrollWidth,c.renderer=a,c.inner.style.width=c.element.style.width=(c.width||15)+"px",c.$minWidth=0,c}return e.prototype.onMouseDown=function(o,a){if(o==="mousedown"&&!(s.getButton(a)!==0||a.detail===2)){if(a.target===this.inner){var c=this,u=a.clientY,p=function(S){u=S.clientY},m=function(){clearInterval(M)},$=a.clientY,C=this.thumbTop,g=function(){if(u!==void 0){var S=c.scrollTopFromThumbTop(C+u-$);S!==c.scrollTop&&c._emit("scroll",{data:S})}};s.capture(this.inner,p,m);var M=setInterval(g,20);return s.preventDefault(a)}var A=a.clientY-this.element.getBoundingClientRect().top-this.thumbHeight/2;return this._emit("scroll",{data:this.scrollTopFromThumbTop(A)}),s.preventDefault(a)}},e.prototype.getHeight=function(){return this.height},e.prototype.scrollTopFromThumbTop=function(o){var a=o*(this.pageHeight-this.viewHeight)/(this.slideHeight-this.thumbHeight);return a=a>>0,a<0?a=0:a>this.pageHeight-this.viewHeight&&(a=this.pageHeight-this.viewHeight),a},e.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},e.prototype.setHeight=function(o){this.height=Math.max(0,o),this.slideHeight=this.height,this.viewHeight=this.height,this.setScrollHeight(this.pageHeight,!0)},e.prototype.setScrollHeight=function(o,a){this.pageHeight===o&&!a||(this.pageHeight=o,this.thumbHeight=this.slideHeight*this.viewHeight/this.pageHeight,this.thumbHeight>this.slideHeight&&(this.thumbHeight=this.slideHeight),this.thumbHeight<15&&(this.thumbHeight=15),this.inner.style.height=this.thumbHeight+"px",this.scrollTop>this.pageHeight-this.viewHeight&&(this.scrollTop=this.pageHeight-this.viewHeight,this.scrollTop<0&&(this.scrollTop=0),this._emit("scroll",{data:this.scrollTop})))},e.prototype.setScrollTop=function(o){this.scrollTop=o,o<0&&(o=0),this.thumbTop=o*(this.slideHeight-this.thumbHeight)/(this.pageHeight-this.viewHeight),this.inner.style.top=this.thumbTop+"px"},e}(i);r.prototype.setInnerHeight=r.prototype.setScrollHeight;var n=function(t){y(e,t);function e(o,a){var c=t.call(this,o,"-h")||this;return c.scrollLeft=0,c.scrollWidth=0,c.height=c.HScrollHeight,c.inner.style.height=c.element.style.height=(c.height||12)+"px",c.renderer=a,c}return e.prototype.onMouseDown=function(o,a){if(o==="mousedown"&&!(s.getButton(a)!==0||a.detail===2)){if(a.target===this.inner){var c=this,u=a.clientX,p=function(S){u=S.clientX},m=function(){clearInterval(M)},$=a.clientX,C=this.thumbLeft,g=function(){if(u!==void 0){var S=c.scrollLeftFromThumbLeft(C+u-$);S!==c.scrollLeft&&c._emit("scroll",{data:S})}};s.capture(this.inner,p,m);var M=setInterval(g,20);return s.preventDefault(a)}var A=a.clientX-this.element.getBoundingClientRect().left-this.thumbWidth/2;return this._emit("scroll",{data:this.scrollLeftFromThumbLeft(A)}),s.preventDefault(a)}},e.prototype.getHeight=function(){return this.isVisible?this.height:0},e.prototype.scrollLeftFromThumbLeft=function(o){var a=o*(this.pageWidth-this.viewWidth)/(this.slideWidth-this.thumbWidth);return a=a>>0,a<0?a=0:a>this.pageWidth-this.viewWidth&&(a=this.pageWidth-this.viewWidth),a},e.prototype.setWidth=function(o){this.width=Math.max(0,o),this.element.style.width=this.width+"px",this.slideWidth=this.width,this.viewWidth=this.width,this.setScrollWidth(this.pageWidth,!0)},e.prototype.setScrollWidth=function(o,a){this.pageWidth===o&&!a||(this.pageWidth=o,this.thumbWidth=this.slideWidth*this.viewWidth/this.pageWidth,this.thumbWidth>this.slideWidth&&(this.thumbWidth=this.slideWidth),this.thumbWidth<15&&(this.thumbWidth=15),this.inner.style.width=this.thumbWidth+"px",this.scrollLeft>this.pageWidth-this.viewWidth&&(this.scrollLeft=this.pageWidth-this.viewWidth,this.scrollLeft<0&&(this.scrollLeft=0),this._emit("scroll",{data:this.scrollLeft})))},e.prototype.setScrollLeft=function(o){this.scrollLeft=o,o<0&&(o=0),this.thumbLeft=o*(this.slideWidth-this.thumbWidth)/(this.pageWidth-this.viewWidth),this.inner.style.left=this.thumbLeft+"px"},e}(i);n.prototype.setInnerWidth=n.prototype.setScrollWidth,L.ScrollBar=r,L.ScrollBarV=r,L.ScrollBarH=n,L.VScrollBar=r,L.HScrollBar=n}),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],function(_,L,E){"use strict";var y=_("./lib/event"),w=function(){function v(s,l){this.onRender=s,this.pending=!1,this.changes=0,this.$recursionLimit=2,this.window=l||window;var i=this;this._flush=function(r){i.pending=!1;var n=i.changes;if(n&&(y.blockIdle(100),i.changes=0,i.onRender(n)),i.changes){if(i.$recursionLimit--<0)return;i.schedule()}else i.$recursionLimit=2}}return v.prototype.schedule=function(s){this.changes=this.changes|s,this.changes&&!this.pending&&(y.nextFrame(this._flush),this.pending=!0)},v.prototype.clear=function(s){var l=this.changes;return this.changes=0,l},v}();L.RenderLoop=w}),ace.define("ace/layer/font_metrics",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/lib/useragent","ace/lib/event_emitter"],function(_,L,E){var y=_("../lib/oop"),w=_("../lib/dom"),v=_("../lib/lang"),s=_("../lib/event"),l=_("../lib/useragent"),i=_("../lib/event_emitter").EventEmitter,r=512,n=typeof ResizeObserver=="function",t=200,e=function(){function o(a){this.el=w.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=w.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=w.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),a.appendChild(this.el),this.$measureNode.textContent=v.stringRepeat("X",r),this.$characterSize={width:0,height:0},n?this.$addObserver():this.checkForSizeChanges()}return o.prototype.$setMeasureNodeStyles=function(a,c){a.width=a.height="auto",a.left=a.top="0px",a.visibility="hidden",a.position="absolute",a.whiteSpace="pre",l.isIE<8?a["font-family"]="inherit":a.font="inherit",a.overflow=c?"hidden":"visible"},o.prototype.checkForSizeChanges=function(a){if(a===void 0&&(a=this.$measureSizes()),a&&(this.$characterSize.width!==a.width||this.$characterSize.height!==a.height)){this.$measureNode.style.fontWeight="bold";var c=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=a,this.charSizes=Object.create(null),this.allowBoldFonts=c&&c.width===a.width&&c.height===a.height,this._emit("changeCharacterSize",{data:a})}},o.prototype.$addObserver=function(){var a=this;this.$observer=new window.ResizeObserver(function(c){a.checkForSizeChanges()}),this.$observer.observe(this.$measureNode)},o.prototype.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer||this.$observer)return this.$pollSizeChangesTimer;var a=this;return this.$pollSizeChangesTimer=s.onIdle(function c(){a.checkForSizeChanges(),s.onIdle(c,500)},500)},o.prototype.setPolling=function(a){a?this.$pollSizeChanges():this.$pollSizeChangesTimer&&(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)},o.prototype.$measureSizes=function(a){var c={height:(a||this.$measureNode).clientHeight,width:(a||this.$measureNode).clientWidth/r};return c.width===0||c.height===0?null:c},o.prototype.$measureCharWidth=function(a){this.$main.textContent=v.stringRepeat(a,r);var c=this.$main.getBoundingClientRect();return c.width/r},o.prototype.getCharacterWidth=function(a){var c=this.charSizes[a];return c===void 0&&(c=this.charSizes[a]=this.$measureCharWidth(a)/this.$characterSize.width),c},o.prototype.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$observer&&this.$observer.disconnect(),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)},o.prototype.$getZoom=function(a){return!a||!a.parentElement?1:(Number(window.getComputedStyle(a).zoom)||1)*this.$getZoom(a.parentElement)},o.prototype.$initTransformMeasureNodes=function(){var a=function(c,u){return["div",{style:"position: absolute;top:"+c+"px;left:"+u+"px;"}]};this.els=w.buildDom([a(0,0),a(t,0),a(0,t),a(t,t)],this.el)},o.prototype.transformCoordinates=function(a,c){if(a){var u=this.$getZoom(this.el);a=C(1/u,a)}function p(N,D,B){var F=N[1]*D[0]-N[0]*D[1];return[(-D[1]*B[0]+D[0]*B[1])/F,(+N[1]*B[0]-N[0]*B[1])/F]}function m(N,D){return[N[0]-D[0],N[1]-D[1]]}function $(N,D){return[N[0]+D[0],N[1]+D[1]]}function C(N,D){return[N*D[0],N*D[1]]}this.els||this.$initTransformMeasureNodes();function g(N){var D=N.getBoundingClientRect();return[D.left,D.top]}var M=g(this.els[0]),A=g(this.els[1]),S=g(this.els[2]),k=g(this.els[3]),d=p(m(k,A),m(k,S),m($(A,S),$(k,M))),h=C(1+d[0],m(A,M)),f=C(1+d[1],m(S,M));if(c){var b=c,T=d[0]*b[0]/t+d[1]*b[1]/t+1,x=$(C(b[0],h),C(b[1],f));return $(C(1/T/t,x),M)}var R=m(a,M),I=p(m(h,C(d[0],R)),m(f,C(d[1],R)),R);return C(t,I)},o}();e.prototype.$characterSize={width:0,height:0},y.implement(e.prototype,i),L.FontMetrics=e}),ace.define("ace/css/editor-css",["require","exports","module"],function(_,L,E){E.exports=` +.ace_br1 {border-top-left-radius : 3px;} +.ace_br2 {border-top-right-radius : 3px;} +.ace_br3 {border-top-left-radius : 3px; border-top-right-radius: 3px;} +.ace_br4 {border-bottom-right-radius: 3px;} +.ace_br5 {border-top-left-radius : 3px; border-bottom-right-radius: 3px;} +.ace_br6 {border-top-right-radius : 3px; border-bottom-right-radius: 3px;} +.ace_br7 {border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px;} +.ace_br8 {border-bottom-left-radius : 3px;} +.ace_br9 {border-top-left-radius : 3px; border-bottom-left-radius: 3px;} +.ace_br10{border-top-right-radius : 3px; border-bottom-left-radius: 3px;} +.ace_br11{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-left-radius: 3px;} +.ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;} +.ace_br13{border-top-left-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;} +.ace_br14{border-top-right-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;} +.ace_br15{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;} + + +.ace_editor { + position: relative; + overflow: hidden; + padding: 0; + font: 12px/normal 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'Source Code Pro', 'source-code-pro', monospace; + direction: ltr; + text-align: left; + -webkit-tap-highlight-color: rgba(0, 0, 0, 0); + forced-color-adjust: none; +} + +.ace_scroller { + position: absolute; + overflow: hidden; + top: 0; + bottom: 0; + background-color: inherit; + -ms-user-select: none; + -moz-user-select: none; + -webkit-user-select: none; + user-select: none; + cursor: text; +} + +.ace_content { + position: absolute; + box-sizing: border-box; + min-width: 100%; + contain: style size layout; + font-variant-ligatures: no-common-ligatures; +} + +.ace_keyboard-focus:focus { + box-shadow: inset 0 0 0 2px #5E9ED6; + outline: none; +} + +.ace_dragging .ace_scroller:before{ + position: absolute; + top: 0; + left: 0; + right: 0; + bottom: 0; + content: ''; + background: rgba(250, 250, 250, 0.01); + z-index: 1000; +} +.ace_dragging.ace_dark .ace_scroller:before{ + background: rgba(0, 0, 0, 0.01); +} + +.ace_gutter { + position: absolute; + overflow : hidden; + width: auto; + top: 0; + bottom: 0; + left: 0; + cursor: default; + z-index: 4; + -ms-user-select: none; + -moz-user-select: none; + -webkit-user-select: none; + user-select: none; + contain: style size layout; +} + +.ace_gutter-active-line { + position: absolute; + left: 0; + right: 0; +} + +.ace_scroller.ace_scroll-left:after { + content: ""; + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset; + pointer-events: none; +} + +.ace_gutter-cell, .ace_gutter-cell_svg-icons { + position: absolute; + top: 0; + left: 0; + right: 0; + padding-left: 19px; + padding-right: 6px; + background-repeat: no-repeat; +} + +.ace_gutter-cell_svg-icons .ace_gutter_annotation { + margin-left: -14px; + float: left; +} + +.ace_gutter-cell .ace_gutter_annotation { + margin-left: -19px; + float: left; +} + +.ace_gutter-cell.ace_error, .ace_icon.ace_error, .ace_icon.ace_error_fold, .ace_gutter-cell.ace_security, .ace_icon.ace_security, .ace_icon.ace_security_fold { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTtipwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/chv+399kfR+MMMDGOQAAAABJRU5ErkJggg=="); + background-repeat: no-repeat; + background-position: 2px center; +} + +.ace_gutter-cell.ace_warning, .ace_icon.ace_warning, .ace_icon.ace_warning_fold { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX///8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/zHAAAAA9Nir/tFIAAAD/tlTiuWf/tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hTf4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS++NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg=="); + background-repeat: no-repeat; + background-position: 2px center; +} + +.ace_gutter-cell.ace_info, .ace_icon.ace_info, .ace_gutter-cell.ace_hint, .ace_icon.ace_hint { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII="); + background-repeat: no-repeat; + background-position: 2px center; +} + +.ace_dark .ace_gutter-cell.ace_info, .ace_dark .ace_icon.ace_info, .ace_dark .ace_gutter-cell.ace_hint, .ace_dark .ace_icon.ace_hint { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC"); +} + +.ace_icon_svg.ace_error { + -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJyZWQiIHNoYXBlLXJlbmRlcmluZz0iZ2VvbWV0cmljUHJlY2lzaW9uIj4KPGNpcmNsZSBmaWxsPSJub25lIiBjeD0iOCIgY3k9IjgiIHI9IjciIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPGxpbmUgeDE9IjExIiB5MT0iNSIgeDI9IjUiIHkyPSIxMSIvPgo8bGluZSB4MT0iMTEiIHkxPSIxMSIgeDI9IjUiIHkyPSI1Ii8+CjwvZz4KPC9zdmc+"); + background-color: crimson; +} +.ace_icon_svg.ace_security { + -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgICA8ZyBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZT0iZGFya29yYW5nZSIgZmlsbD0ibm9uZSIgc2hhcGUtcmVuZGVyaW5nPSJnZW9tZXRyaWNQcmVjaXNpb24iPgogICAgICAgIDxwYXRoIGNsYXNzPSJzdHJva2UtbGluZWpvaW4tcm91bmQiIGQ9Ik04IDE0LjgzMDdDOCAxNC44MzA3IDIgMTIuOTA0NyAyIDguMDg5OTJWMy4yNjU0OEM1LjMxIDMuMjY1NDggNy45ODk5OSAxLjM0OTE4IDcuOTg5OTkgMS4zNDkxOEM3Ljk4OTk5IDEuMzQ5MTggMTAuNjkgMy4yNjU0OCAxNCAzLjI2NTQ4VjguMDg5OTJDMTQgMTIuOTA0NyA4IDE0LjgzMDcgOCAxNC44MzA3WiIvPgogICAgICAgIDxwYXRoIGQ9Ik0yIDguMDg5OTJWMy4yNjU0OEM1LjMxIDMuMjY1NDggNy45ODk5OSAxLjM0OTE4IDcuOTg5OTkgMS4zNDkxOCIvPgogICAgICAgIDxwYXRoIGQ9Ik0xMy45OSA4LjA4OTkyVjMuMjY1NDhDMTAuNjggMy4yNjU0OCA4IDEuMzQ5MTggOCAxLjM0OTE4Ii8+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTggNFY5Ii8+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTggMTBWMTIiLz4KICAgIDwvZz4KPC9zdmc+"); + background-color: crimson; +} +.ace_icon_svg.ace_warning { + -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJkYXJrb3JhbmdlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+Cjxwb2x5Z29uIHN0cm9rZS1saW5lam9pbj0icm91bmQiIGZpbGw9Im5vbmUiIHBvaW50cz0iOCAxIDE1IDE1IDEgMTUgOCAxIi8+CjxyZWN0IHg9IjgiIHk9IjEyIiB3aWR0aD0iMC4wMSIgaGVpZ2h0PSIwLjAxIi8+CjxsaW5lIHgxPSI4IiB5MT0iNiIgeDI9IjgiIHkyPSIxMCIvPgo8L2c+Cjwvc3ZnPg=="); + background-color: darkorange; +} +.ace_icon_svg.ace_info { + -webkit-mask-image: url("data:image/svg+xml;base64,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MyAxMi42MzE3IDEuODYxNDFMMTcuNjEzNiAxMS44MTYxQzE4LjM1MjcgMTMuMjkyOSAxNy41OTM4IDE1LjA4MDQgMTYuMDE4IDE1LjU3NDVDMTYuNDA0NCAxNC40NTA3IDE2LjMyMzEgMTMuMjE4OCAxNS43OTI0IDEyLjE1NTVMMTEuMTk5MSAyLjk1MjM4WiIgZmlsbD0iI0VDNzIxMSIvPgo8L3N2Zz4="); + background-color: darkorange; +} + +.ace_scrollbar { + contain: strict; + position: absolute; + right: 0; + bottom: 0; + z-index: 6; +} + +.ace_scrollbar-inner { + position: absolute; + cursor: text; + left: 0; + top: 0; +} + +.ace_scrollbar-v{ + overflow-x: hidden; + overflow-y: scroll; + top: 0; +} + +.ace_scrollbar-h { + overflow-x: scroll; + overflow-y: hidden; + left: 0; +} + +.ace_print-margin { + position: absolute; + height: 100%; +} + +.ace_text-input { + position: absolute; + z-index: 0; + width: 0.5em; + height: 1em; + opacity: 0; + background: transparent; + -moz-appearance: none; + appearance: none; + border: none; + resize: none; + outline: none; + overflow: hidden; + font: inherit; + padding: 0 1px; + margin: 0 -1px; + contain: strict; + -ms-user-select: text; + -moz-user-select: text; + -webkit-user-select: text; + user-select: text; + /*with \`pre-line\` chrome inserts   instead of space*/ + white-space: pre!important; +} +.ace_text-input.ace_composition { + background: transparent; + color: inherit; + z-index: 1000; + opacity: 1; +} +.ace_composition_placeholder { color: transparent } +.ace_composition_marker { + border-bottom: 1px solid; + position: absolute; + border-radius: 0; + margin-top: 1px; +} + +[ace_nocontext=true] { + transform: none!important; + filter: none!important; + clip-path: none!important; + mask : none!important; + contain: none!important; + perspective: none!important; + mix-blend-mode: initial!important; + z-index: auto; +} + +.ace_layer { + z-index: 1; + position: absolute; + overflow: hidden; + /* workaround for chrome bug https://github.com/ajaxorg/ace/issues/2312*/ + word-wrap: normal; + white-space: pre; + height: 100%; + width: 100%; + box-sizing: border-box; + /* setting pointer-events: auto; on node under the mouse, which changes + during scroll, will break mouse wheel scrolling in Safari */ + pointer-events: none; +} + +.ace_gutter-layer { + position: relative; + width: auto; + text-align: right; + pointer-events: auto; + height: 1000000px; + contain: style size layout; +} + +.ace_text-layer { + font: inherit !important; + position: absolute; + height: 1000000px; + width: 1000000px; + contain: style size layout; +} + +.ace_text-layer > .ace_line, .ace_text-layer > .ace_line_group { + contain: style size layout; + position: absolute; + top: 0; + left: 0; + right: 0; +} + +.ace_hidpi .ace_text-layer, +.ace_hidpi .ace_gutter-layer, +.ace_hidpi .ace_content, +.ace_hidpi .ace_gutter { + contain: strict; +} +.ace_hidpi .ace_text-layer > .ace_line, +.ace_hidpi .ace_text-layer > .ace_line_group { + contain: strict; +} + +.ace_cjk { + display: inline-block; + text-align: center; +} + +.ace_cursor-layer { + z-index: 4; +} + +.ace_cursor { + z-index: 4; + position: absolute; + box-sizing: border-box; + border-left: 2px solid; + /* workaround for smooth cursor repaintng whole screen in chrome */ + transform: translatez(0); +} + +.ace_multiselect .ace_cursor { + border-left-width: 1px; +} + +.ace_slim-cursors .ace_cursor { + border-left-width: 1px; +} + +.ace_overwrite-cursors .ace_cursor { + border-left-width: 0; + border-bottom: 1px solid; +} + +.ace_hidden-cursors .ace_cursor { + opacity: 0.2; +} + +.ace_hasPlaceholder .ace_hidden-cursors .ace_cursor { + opacity: 0; +} + +.ace_smooth-blinking .ace_cursor { + transition: opacity 0.18s; +} + +.ace_animate-blinking .ace_cursor { + animation-duration: 1000ms; + animation-timing-function: step-end; + animation-name: blink-ace-animate; + animation-iteration-count: infinite; +} + +.ace_animate-blinking.ace_smooth-blinking .ace_cursor { + animation-duration: 1000ms; + animation-timing-function: ease-in-out; + animation-name: blink-ace-animate-smooth; +} + +@keyframes blink-ace-animate { + from, to { opacity: 1; } + 60% { opacity: 0; } +} + +@keyframes blink-ace-animate-smooth { + from, to { opacity: 1; } + 45% { opacity: 1; } + 60% { opacity: 0; } + 85% { opacity: 0; } +} + +.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack { + position: absolute; + z-index: 3; +} + +.ace_marker-layer .ace_selection { + position: absolute; + z-index: 5; +} + +.ace_marker-layer .ace_bracket { + position: absolute; + z-index: 6; +} + +.ace_marker-layer .ace_error_bracket { + position: absolute; + border-bottom: 1px solid #DE5555; + border-radius: 0; +} + +.ace_marker-layer .ace_active-line { + position: absolute; + z-index: 2; +} + +.ace_marker-layer .ace_selected-word { + position: absolute; + z-index: 4; + box-sizing: border-box; +} + +.ace_line .ace_fold { + box-sizing: border-box; + + display: inline-block; + height: 11px; + margin-top: -2px; + vertical-align: middle; + + background-image: + url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="), + url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII="); + background-repeat: no-repeat, repeat-x; + background-position: center center, top left; + color: transparent; + + border: 1px solid black; + border-radius: 2px; + + cursor: pointer; + pointer-events: auto; +} + +.ace_dark .ace_fold { +} + +.ace_fold:hover{ + background-image: + url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="), + url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC"); +} + +.ace_tooltip { + background-color: #f5f5f5; + border: 1px solid gray; + border-radius: 1px; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3); + color: black; + max-width: 100%; + padding: 3px 4px; + position: fixed; + z-index: 999999; + box-sizing: border-box; + cursor: default; + white-space: pre-wrap; + word-wrap: break-word; + line-height: normal; + font-style: normal; + font-weight: normal; + letter-spacing: normal; + pointer-events: none; + overflow: auto; + max-width: min(60em, 66vw); + overscroll-behavior: contain; +} +.ace_tooltip pre { + white-space: pre-wrap; +} + +.ace_tooltip.ace_dark { + background-color: #636363; + color: #fff; +} + +.ace_tooltip:focus { + outline: 1px solid #5E9ED6; +} + +.ace_icon { + display: inline-block; + width: 18px; + vertical-align: top; +} + +.ace_icon_svg { + display: inline-block; + width: 12px; + vertical-align: top; + -webkit-mask-repeat: no-repeat; + -webkit-mask-size: 12px; + -webkit-mask-position: center; +} + +.ace_folding-enabled > .ace_gutter-cell, .ace_folding-enabled > .ace_gutter-cell_svg-icons { + padding-right: 13px; +} + +.ace_fold-widget { + box-sizing: border-box; + + margin: 0 -12px 0 1px; + display: none; + width: 11px; + vertical-align: top; + + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg=="); + background-repeat: no-repeat; + background-position: center; + + border-radius: 3px; + + border: 1px solid transparent; + cursor: pointer; +} + +.ace_folding-enabled .ace_fold-widget { + display: inline-block; +} + +.ace_fold-widget.ace_end { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg=="); +} + +.ace_fold-widget.ace_closed { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA=="); +} + +.ace_fold-widget:hover { + border: 1px solid rgba(0, 0, 0, 0.3); + background-color: rgba(255, 255, 255, 0.2); + box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7); +} + +.ace_fold-widget:active { + border: 1px solid rgba(0, 0, 0, 0.4); + background-color: rgba(0, 0, 0, 0.05); + box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8); +} +/** + * Dark version for fold widgets + */ +.ace_dark .ace_fold-widget { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC"); +} +.ace_dark .ace_fold-widget.ace_end { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg=="); +} +.ace_dark .ace_fold-widget.ace_closed { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg=="); +} +.ace_dark .ace_fold-widget:hover { + box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2); + background-color: rgba(255, 255, 255, 0.1); +} +.ace_dark .ace_fold-widget:active { + box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2); +} + +.ace_inline_button { + border: 1px solid lightgray; + display: inline-block; + margin: -1px 8px; + padding: 0 5px; + pointer-events: auto; + cursor: pointer; +} +.ace_inline_button:hover { + border-color: gray; + background: rgba(200,200,200,0.2); + display: inline-block; + pointer-events: auto; +} + +.ace_fold-widget.ace_invalid { + background-color: #FFB4B4; + border-color: #DE5555; +} + +.ace_fade-fold-widgets .ace_fold-widget { + transition: opacity 0.4s ease 0.05s; + opacity: 0; +} + +.ace_fade-fold-widgets:hover .ace_fold-widget { + transition: opacity 0.05s ease 0.05s; + opacity:1; +} + +.ace_underline { + text-decoration: underline; +} + +.ace_bold { + font-weight: bold; +} + +.ace_nobold .ace_bold { + font-weight: normal; +} + +.ace_italic { + font-style: italic; +} + + +.ace_error-marker { + background-color: rgba(255, 0, 0,0.2); + position: absolute; + z-index: 9; +} + +.ace_highlight-marker { + background-color: rgba(255, 255, 0,0.2); + position: absolute; + z-index: 8; +} + +.ace_mobile-menu { + position: absolute; + line-height: 1.5; + border-radius: 4px; + -ms-user-select: none; + -moz-user-select: none; + -webkit-user-select: none; + user-select: none; + background: white; + box-shadow: 1px 3px 2px grey; + border: 1px solid #dcdcdc; + color: black; +} +.ace_dark > .ace_mobile-menu { + background: #333; + color: #ccc; + box-shadow: 1px 3px 2px grey; + border: 1px solid #444; + +} +.ace_mobile-button { + padding: 2px; + cursor: pointer; + overflow: hidden; +} +.ace_mobile-button:hover { + background-color: #eee; + opacity:1; +} +.ace_mobile-button:active { + background-color: #ddd; +} + +.ace_placeholder { + position: relative; + font-family: arial; + transform: scale(0.9); + transform-origin: left; + white-space: pre; + opacity: 0.7; + margin: 0 10px; + z-index: 1; +} + +.ace_ghost_text { + opacity: 0.5; + font-style: italic; +} + +.ace_ghost_text_container > div { + white-space: pre; +} + +.ghost_text_line_wrapped::after { + content: "\u21A9"; + position: absolute; +} + +.ace_lineWidgetContainer.ace_ghost_text { + margin: 0px 4px +} + +.ace_screenreader-only { + position:absolute; + left:-10000px; + top:auto; + width:1px; + height:1px; + overflow:hidden; +} + +.ace_hidden_token { + display: none; +}`}),ace.define("ace/layer/decorators",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter"],function(_,L,E){"use strict";var y=_("../lib/dom"),w=_("../lib/oop"),v=_("../lib/event_emitter").EventEmitter,s=function(){function l(i,r){this.canvas=y.createElement("canvas"),this.renderer=r,this.pixelRatio=1,this.maxHeight=r.layerConfig.maxHeight,this.lineHeight=r.layerConfig.lineHeight,this.canvasHeight=i.parent.scrollHeight,this.heightRatio=this.canvasHeight/this.maxHeight,this.canvasWidth=i.width,this.minDecorationHeight=2*this.pixelRatio|0,this.halfMinDecorationHeight=this.minDecorationHeight/2|0,this.canvas.width=this.canvasWidth,this.canvas.height=this.canvasHeight,this.canvas.style.top="0px",this.canvas.style.right="0px",this.canvas.style.zIndex="7px",this.canvas.style.position="absolute",this.colors={},this.colors.dark={error:"rgba(255, 18, 18, 1)",warning:"rgba(18, 136, 18, 1)",info:"rgba(18, 18, 136, 1)"},this.colors.light={error:"rgb(255,51,51)",warning:"rgb(32,133,72)",info:"rgb(35,68,138)"},i.element.appendChild(this.canvas)}return l.prototype.$updateDecorators=function(i){var r=this.renderer.theme.isDark===!0?this.colors.dark:this.colors.light;if(i){this.maxHeight=i.maxHeight,this.lineHeight=i.lineHeight,this.canvasHeight=i.height;var n=(i.lastRow+1)*this.lineHeight;nd.priority?1:0}var o=this.renderer.session.$annotations;if(t.clearRect(0,0,this.canvas.width,this.canvas.height),o){var a={info:1,warning:2,error:3};o.forEach(function(k){k.priority=a[k.type]||null}),o=o.sort(e);for(var c=this.renderer.session.$foldData,u=0;uthis.canvasHeight&&(A=this.canvasHeight-this.halfMinDecorationHeight),C=Math.round(A-this.halfMinDecorationHeight),g=Math.round(A+this.halfMinDecorationHeight)}t.fillStyle=r[o[u].type]||null,t.fillRect(0,$,this.canvasWidth,g-C)}}var S=this.renderer.session.selection.getCursor();if(S){var m=this.compensateFoldRows(S.row,c),$=Math.round((S.row-m)*this.lineHeight*this.heightRatio);t.fillStyle="rgba(0, 0, 0, 0.5)",t.fillRect(0,$,this.canvasWidth,2)}},l.prototype.compensateFoldRows=function(i,r){var n=0;if(r&&r.length>0)for(var t=0;tr[t].start.row&&i=r[t].end.row&&(n+=r[t].end.row-r[t].start.row);return n},l}();w.implement(s.prototype,v),L.Decorator=s}),ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/config","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/scrollbar_custom","ace/scrollbar_custom","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter","ace/css/editor-css","ace/layer/decorators","ace/lib/useragent","ace/layer/text_util"],function(_,L,E){"use strict";var y=_("./lib/oop"),w=_("./lib/dom"),v=_("./lib/lang"),s=_("./config"),l=_("./layer/gutter").Gutter,i=_("./layer/marker").Marker,r=_("./layer/text").Text,n=_("./layer/cursor").Cursor,t=_("./scrollbar").HScrollBar,e=_("./scrollbar").VScrollBar,o=_("./scrollbar_custom").HScrollBar,a=_("./scrollbar_custom").VScrollBar,c=_("./renderloop").RenderLoop,u=_("./layer/font_metrics").FontMetrics,p=_("./lib/event_emitter").EventEmitter,m=_("./css/editor-css"),$=_("./layer/decorators").Decorator,C=_("./lib/useragent"),g=_("./layer/text_util").isTextToken;w.importCssString(m,"ace_editor.css",!1);var M=function(){function A(S,k){var d=this;this.container=S||w.createElement("div"),w.addCssClass(this.container,"ace_editor"),w.HI_DPI&&w.addCssClass(this.container,"ace_hidpi"),this.setTheme(k),s.get("useStrictCSP")==null&&s.set("useStrictCSP",!1),this.$gutter=w.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.$gutter.setAttribute("aria-hidden","true"),this.scroller=w.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=w.createElement("div"),this.content.className="ace_content",this.scroller.appendChild(this.content),this.$gutterLayer=new l(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new i(this.content);var h=this.$textLayer=new r(this.content);this.canvas=h.element,this.$markerFront=new i(this.content),this.$cursorLayer=new n(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new e(this.container,this),this.scrollBarH=new t(this.container,this),this.scrollBarV.on("scroll",function(f){d.$scrollAnimation||d.session.setScrollTop(f.data-d.scrollMargin.top)}),this.scrollBarH.on("scroll",function(f){d.$scrollAnimation||d.session.setScrollLeft(f.data-d.scrollMargin.left)}),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new u(this.container),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.on("changeCharacterSize",function(f){d.updateCharacterSize(),d.onResize(!0,d.gutterWidth,d.$size.width,d.$size.height),d._signal("changeCharacterSize",f)}),this.$size={width:0,height:0,scrollerHeight:0,scrollerWidth:0,$dirty:!0},this.layerConfig={width:1,padding:0,firstRow:0,firstRowScreen:0,lastRow:0,lineHeight:0,characterWidth:0,minHeight:1,maxHeight:1,offset:0,height:1,gutterOffset:1},this.scrollMargin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.margin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.$keepTextAreaAtCursor=!C.isIOS,this.$loop=new c(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),this.$addResizeObserver(),s.resetOptions(this),s._signal("renderer",this)}return A.prototype.updateCharacterSize=function(){this.$textLayer.allowBoldFonts!=this.$allowBoldFonts&&(this.$allowBoldFonts=this.$textLayer.allowBoldFonts,this.setStyle("ace_nobold",!this.$allowBoldFonts)),this.layerConfig.characterWidth=this.characterWidth=this.$textLayer.getCharacterWidth(),this.layerConfig.lineHeight=this.lineHeight=this.$textLayer.getLineHeight(),this.$updatePrintMargin(),w.setStyle(this.scroller.style,"line-height",this.lineHeight+"px")},A.prototype.setSession=function(S){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=S,S&&this.scrollMargin.top&&S.getScrollTop()<=0&&S.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(S),this.$markerBack.setSession(S),this.$markerFront.setSession(S),this.$gutterLayer.setSession(S),this.$textLayer.setSession(S),S&&(this.$loop.schedule(this.CHANGE_FULL),this.session.$setFontMetrics(this.$fontMetrics),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.onChangeNewLineMode=this.onChangeNewLineMode.bind(this),this.onChangeNewLineMode(),this.session.doc.on("changeNewLineMode",this.onChangeNewLineMode))},A.prototype.updateLines=function(S,k,d){if(k===void 0&&(k=1/0),this.$changedLines?(this.$changedLines.firstRow>S&&(this.$changedLines.firstRow=S),this.$changedLines.lastRowthis.layerConfig.lastRow||this.$loop.schedule(this.CHANGE_LINES)},A.prototype.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar(),this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR)},A.prototype.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},A.prototype.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},A.prototype.updateFull=function(S){S?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},A.prototype.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},A.prototype.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},A.prototype.onResize=function(S,k,d,h){if(!(this.resizing>2)){this.resizing>0?this.resizing++:this.resizing=S?1:0;var f=this.container;h||(h=f.clientHeight||f.scrollHeight),!h&&this.$maxLines&&this.lineHeight>1&&(!f.style.height||f.style.height=="0px")&&(f.style.height="1px",h=f.clientHeight||f.scrollHeight),d||(d=f.clientWidth||f.scrollWidth);var b=this.$updateCachedSize(S,k,d,h);if(this.$resizeTimer&&this.$resizeTimer.cancel(),!this.$size.scrollerHeight||!d&&!h)return this.resizing=0;S&&(this.$gutterLayer.$padding=null),S?this.$renderChanges(b|this.$changes,!0):this.$loop.schedule(b|this.$changes),this.resizing&&(this.resizing=0),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.$customScrollbar&&this.$updateCustomScrollbar(!0)}},A.prototype.$updateCachedSize=function(S,k,d,h){h-=this.$extraHeight||0;var f=0,b=this.$size,T={width:b.width,height:b.height,scrollerHeight:b.scrollerHeight,scrollerWidth:b.scrollerWidth};if(h&&(S||b.height!=h)&&(b.height=h,f|=this.CHANGE_SIZE,b.scrollerHeight=b.height,this.$horizScroll&&(b.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.setHeight(b.scrollerHeight),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",f=f|this.CHANGE_SCROLL),d&&(S||b.width!=d)){f|=this.CHANGE_SIZE,b.width=d,k==null&&(k=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=k,w.setStyle(this.scrollBarH.element.style,"left",k+"px"),w.setStyle(this.scroller.style,"left",k+this.margin.left+"px"),b.scrollerWidth=Math.max(0,d-k-this.scrollBarV.getWidth()-this.margin.h),w.setStyle(this.$gutter.style,"left",this.margin.left+"px");var x=this.scrollBarV.getWidth()+"px";w.setStyle(this.scrollBarH.element.style,"right",x),w.setStyle(this.scroller.style,"right",x),w.setStyle(this.scroller.style,"bottom",this.scrollBarH.getHeight()),this.scrollBarH.setWidth(b.scrollerWidth),(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||S)&&(f|=this.CHANGE_FULL)}return b.$dirty=!d||!h,f&&this._signal("resize",T),f},A.prototype.onGutterResize=function(S){var k=this.$showGutter?S:0;k!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,k,this.$size.width,this.$size.height)),this.session.getUseWrapMode()&&this.adjustWrapLimit()?this.$loop.schedule(this.CHANGE_FULL):this.$size.$dirty?this.$loop.schedule(this.CHANGE_FULL):this.$computeLayerConfig()},A.prototype.adjustWrapLimit=function(){var S=this.$size.scrollerWidth-this.$padding*2,k=Math.floor(S/this.characterWidth);return this.session.adjustWrapLimit(k,this.$showPrintMargin&&this.$printMarginColumn)},A.prototype.setAnimatedScroll=function(S){this.setOption("animatedScroll",S)},A.prototype.getAnimatedScroll=function(){return this.$animatedScroll},A.prototype.setShowInvisibles=function(S){this.setOption("showInvisibles",S),this.session.$bidiHandler.setShowInvisibles(S)},A.prototype.getShowInvisibles=function(){return this.getOption("showInvisibles")},A.prototype.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},A.prototype.setDisplayIndentGuides=function(S){this.setOption("displayIndentGuides",S)},A.prototype.getHighlightIndentGuides=function(){return this.getOption("highlightIndentGuides")},A.prototype.setHighlightIndentGuides=function(S){this.setOption("highlightIndentGuides",S)},A.prototype.setShowPrintMargin=function(S){this.setOption("showPrintMargin",S)},A.prototype.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},A.prototype.setPrintMarginColumn=function(S){this.setOption("printMarginColumn",S)},A.prototype.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},A.prototype.getShowGutter=function(){return this.getOption("showGutter")},A.prototype.setShowGutter=function(S){return this.setOption("showGutter",S)},A.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},A.prototype.setFadeFoldWidgets=function(S){this.setOption("fadeFoldWidgets",S)},A.prototype.setHighlightGutterLine=function(S){this.setOption("highlightGutterLine",S)},A.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},A.prototype.$updatePrintMargin=function(){if(!(!this.$showPrintMargin&&!this.$printMarginEl)){if(!this.$printMarginEl){var S=w.createElement("div");S.className="ace_layer ace_print-margin-layer",this.$printMarginEl=w.createElement("div"),this.$printMarginEl.className="ace_print-margin",S.appendChild(this.$printMarginEl),this.content.insertBefore(S,this.content.firstChild)}var k=this.$printMarginEl.style;k.left=Math.round(this.characterWidth*this.$printMarginColumn+this.$padding)+"px",k.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&this.session.$wrap==-1&&this.adjustWrapLimit()}},A.prototype.getContainerElement=function(){return this.container},A.prototype.getMouseEventTarget=function(){return this.scroller},A.prototype.getTextAreaContainer=function(){return this.container},A.prototype.$moveTextAreaToCursor=function(){if(!this.$isMousePressed){var S=this.textarea.style,k=this.$composition;if(!this.$keepTextAreaAtCursor&&!k){w.translate(this.textarea,-100,0);return}var d=this.$cursorLayer.$pixelPos;if(d){k&&k.markerRange&&(d=this.$cursorLayer.getPixelPosition(k.markerRange.start,!0));var h=this.layerConfig,f=d.top,b=d.left;f-=h.offset;var T=k&&k.useTextareaForIME||C.isMobile?this.lineHeight:1;if(f<0||f>h.height-T){w.translate(this.textarea,0,0);return}var x=1,R=this.$size.height-T;if(!k)f+=this.lineHeight;else if(k.useTextareaForIME){var I=this.textarea.value;x=this.characterWidth*this.session.$getStringScreenWidth(I)[0]}else f+=this.lineHeight+2;b-=this.scrollLeft,b>this.$size.scrollerWidth-x&&(b=this.$size.scrollerWidth-x),b+=this.gutterWidth+this.margin.left,w.setStyle(S,"height",T+"px"),w.setStyle(S,"width",x+"px"),w.translate(this.textarea,Math.min(b,this.$size.scrollerWidth-x),Math.min(f,R))}}},A.prototype.getFirstVisibleRow=function(){return this.layerConfig.firstRow},A.prototype.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(this.layerConfig.offset===0?0:1)},A.prototype.getLastFullyVisibleRow=function(){var S=this.layerConfig,k=S.lastRow,d=this.session.documentToScreenRow(k,0)*S.lineHeight;return d-this.session.getScrollTop()>S.height-S.lineHeight?k-1:k},A.prototype.getLastVisibleRow=function(){return this.layerConfig.lastRow},A.prototype.setPadding=function(S){this.$padding=S,this.$textLayer.setPadding(S),this.$cursorLayer.setPadding(S),this.$markerFront.setPadding(S),this.$markerBack.setPadding(S),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},A.prototype.setScrollMargin=function(S,k,d,h){var f=this.scrollMargin;f.top=S|0,f.bottom=k|0,f.right=h|0,f.left=d|0,f.v=f.top+f.bottom,f.h=f.left+f.right,f.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-f.top),this.updateFull()},A.prototype.setMargin=function(S,k,d,h){var f=this.margin;f.top=S|0,f.bottom=k|0,f.right=h|0,f.left=d|0,f.v=f.top+f.bottom,f.h=f.left+f.right,this.$updateCachedSize(!0,this.gutterWidth,this.$size.width,this.$size.height),this.updateFull()},A.prototype.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},A.prototype.setHScrollBarAlwaysVisible=function(S){this.setOption("hScrollBarAlwaysVisible",S)},A.prototype.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible},A.prototype.setVScrollBarAlwaysVisible=function(S){this.setOption("vScrollBarAlwaysVisible",S)},A.prototype.$updateScrollBarV=function(){var S=this.layerConfig.maxHeight,k=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(S-=(k-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>S-k&&(S=this.scrollTop+k,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(S+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},A.prototype.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},A.prototype.freeze=function(){this.$frozen=!0},A.prototype.unfreeze=function(){this.$frozen=!1},A.prototype.$renderChanges=function(S,k){if(this.$changes&&(S|=this.$changes,this.$changes=0),!this.session||!this.container.offsetWidth||this.$frozen||!S&&!k){this.$changes|=S;return}if(this.$size.$dirty)return this.$changes|=S,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender",S),this.session&&this.session.$bidiHandler&&this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);var d=this.layerConfig;if(S&this.CHANGE_FULL||S&this.CHANGE_SIZE||S&this.CHANGE_TEXT||S&this.CHANGE_LINES||S&this.CHANGE_SCROLL||S&this.CHANGE_H_SCROLL){if(S|=this.$computeLayerConfig()|this.$loop.clear(),d.firstRow!=this.layerConfig.firstRow&&d.firstRowScreen==this.layerConfig.firstRowScreen){var h=this.scrollTop+(d.firstRow-Math.max(this.layerConfig.firstRow,0))*this.lineHeight;h>0&&(this.scrollTop=h,S=S|this.CHANGE_SCROLL,S|=this.$computeLayerConfig()|this.$loop.clear())}d=this.layerConfig,this.$updateScrollBarV(),S&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),w.translate(this.content,-this.scrollLeft,-d.offset);var f=d.width+2*this.$padding+"px",b=d.minHeight+"px";w.setStyle(this.content.style,"width",f),w.setStyle(this.content.style,"height",b)}if(S&this.CHANGE_H_SCROLL&&(w.translate(this.content,-this.scrollLeft,-d.offset),this.scroller.className=this.scrollLeft<=0?"ace_scroller ":"ace_scroller ace_scroll-left ",this.enableKeyboardAccessibility&&(this.scroller.className+=this.keyboardFocusClassName)),S&this.CHANGE_FULL){this.$changedLines=null,this.$textLayer.update(d),this.$showGutter&&this.$gutterLayer.update(d),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(d),this.$markerBack.update(d),this.$markerFront.update(d),this.$cursorLayer.update(d),this.$moveTextAreaToCursor(),this._signal("afterRender",S);return}if(S&this.CHANGE_SCROLL){this.$changedLines=null,S&this.CHANGE_TEXT||S&this.CHANGE_LINES?this.$textLayer.update(d):this.$textLayer.scrollLines(d),this.$showGutter&&(S&this.CHANGE_GUTTER||S&this.CHANGE_LINES?this.$gutterLayer.update(d):this.$gutterLayer.scrollLines(d)),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(d),this.$markerBack.update(d),this.$markerFront.update(d),this.$cursorLayer.update(d),this.$moveTextAreaToCursor(),this._signal("afterRender",S);return}S&this.CHANGE_TEXT?(this.$changedLines=null,this.$textLayer.update(d),this.$showGutter&&this.$gutterLayer.update(d),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(d)):S&this.CHANGE_LINES?((this.$updateLines()||S&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(d),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(d)):S&this.CHANGE_TEXT||S&this.CHANGE_GUTTER?(this.$showGutter&&this.$gutterLayer.update(d),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(d)):S&this.CHANGE_CURSOR&&(this.$highlightGutterLine&&this.$gutterLayer.updateLineHighlight(d),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(d)),S&this.CHANGE_CURSOR&&(this.$cursorLayer.update(d),this.$moveTextAreaToCursor()),S&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(d),S&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(d),this._signal("afterRender",S)},A.prototype.$autosize=function(){var S=this.session.getScreenLength()*this.lineHeight,k=this.$maxLines*this.lineHeight,d=Math.min(k,Math.max((this.$minLines||1)*this.lineHeight,S))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(d+=this.scrollBarH.getHeight()),this.$maxPixelHeight&&d>this.$maxPixelHeight&&(d=this.$maxPixelHeight);var h=d<=2*this.lineHeight,f=!h&&S>k;if(d!=this.desiredHeight||this.$size.height!=this.desiredHeight||f!=this.$vScroll){f!=this.$vScroll&&(this.$vScroll=f,this.scrollBarV.setVisible(f));var b=this.container.clientWidth;this.container.style.height=d+"px",this.$updateCachedSize(!0,this.$gutterWidth,b,d),this.desiredHeight=d,this._signal("autosize")}},A.prototype.$computeLayerConfig=function(){var S=this.session,k=this.$size,d=k.height<=2*this.lineHeight,h=this.session.getScreenLength(),f=h*this.lineHeight,b=this.$getLongestLine(),T=!d&&(this.$hScrollBarAlwaysVisible||k.scrollerWidth-b-2*this.$padding<0),x=this.$horizScroll!==T;x&&(this.$horizScroll=T,this.scrollBarH.setVisible(T));var R=this.$vScroll;this.$maxLines&&this.lineHeight>1&&this.$autosize();var I=k.scrollerHeight+this.lineHeight,N=!this.$maxLines&&this.$scrollPastEnd?(k.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0;f+=N;var D=this.scrollMargin;this.session.setScrollTop(Math.max(-D.top,Math.min(this.scrollTop,f-k.scrollerHeight+D.bottom))),this.session.setScrollLeft(Math.max(-D.left,Math.min(this.scrollLeft,b+2*this.$padding-k.scrollerWidth+D.right)));var B=!d&&(this.$vScrollBarAlwaysVisible||k.scrollerHeight-f+N<0||this.scrollTop>D.top),F=R!==B;F&&(this.$vScroll=B,this.scrollBarV.setVisible(B));var z=this.scrollTop%this.lineHeight,H=Math.ceil(I/this.lineHeight)-1,U=Math.max(0,Math.round((this.scrollTop-z)/this.lineHeight)),K=U+H,q,ee,Y=this.lineHeight;U=S.screenToDocumentRow(U,0);var Z=S.getFoldLine(U);Z&&(U=Z.start.row),q=S.documentToScreenRow(U,0),ee=S.getRowLength(U)*Y,K=Math.min(S.screenToDocumentRow(K,0),S.getLength()-1),I=k.scrollerHeight+S.getRowLength(K)*Y+ee,z=this.scrollTop-q*Y;var X=0;return(this.layerConfig.width!=b||x)&&(X=this.CHANGE_H_SCROLL),(x||F)&&(X|=this.$updateCachedSize(!0,this.gutterWidth,k.width,k.height),this._signal("scrollbarVisibilityChanged"),F&&(b=this.$getLongestLine())),this.layerConfig={width:b,padding:this.$padding,firstRow:U,firstRowScreen:q,lastRow:K,lineHeight:Y,characterWidth:this.characterWidth,minHeight:I,maxHeight:f,offset:z,gutterOffset:Y?Math.max(0,Math.ceil((z+k.height-k.scrollerHeight)/Y)):0,height:this.$size.scrollerHeight},this.session.$bidiHandler&&this.session.$bidiHandler.setContentWidth(b-this.$padding),X},A.prototype.$updateLines=function(){if(this.$changedLines){var S=this.$changedLines.firstRow,k=this.$changedLines.lastRow;this.$changedLines=null;var d=this.layerConfig;if(!(S>d.lastRow+1)&&!(kthis.$textLayer.MAX_LINE_LENGTH&&(S=this.$textLayer.MAX_LINE_LENGTH+30),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(S*this.characterWidth))},A.prototype.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},A.prototype.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},A.prototype.addGutterDecoration=function(S,k){this.$gutterLayer.addGutterDecoration(S,k)},A.prototype.removeGutterDecoration=function(S,k){this.$gutterLayer.removeGutterDecoration(S,k)},A.prototype.updateBreakpoints=function(S){this._rows=S,this.$loop.schedule(this.CHANGE_GUTTER)},A.prototype.setAnnotations=function(S){this.$gutterLayer.setAnnotations(S),this.$loop.schedule(this.CHANGE_GUTTER)},A.prototype.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},A.prototype.hideCursor=function(){this.$cursorLayer.hideCursor()},A.prototype.showCursor=function(){this.$cursorLayer.showCursor()},A.prototype.scrollSelectionIntoView=function(S,k,d){this.scrollCursorIntoView(S,d),this.scrollCursorIntoView(k,d)},A.prototype.scrollCursorIntoView=function(S,k,d){if(this.$size.scrollerHeight!==0){var h=this.$cursorLayer.getPixelPosition(S),f=h.left,b=h.top,T=d&&d.top||0,x=d&&d.bottom||0;this.$scrollAnimation&&(this.$stopAnimation=!0);var R=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;R+T>b?(k&&R+T>b+this.lineHeight&&(b-=k*this.$size.scrollerHeight),b===0&&(b=-this.scrollMargin.top),this.session.setScrollTop(b)):R+this.$size.scrollerHeight-x=1-this.scrollMargin.top||k>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom||S<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left||S>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right)return!0},A.prototype.pixelToScreenCoordinates=function(S,k){var d;if(this.$hasCssTransforms){d={top:0,left:0};var h=this.$fontMetrics.transformCoordinates([S,k]);S=h[1]-this.gutterWidth-this.margin.left,k=h[0]}else d=this.scroller.getBoundingClientRect();var f=S+this.scrollLeft-d.left-this.$padding,b=f/this.characterWidth,T=Math.floor((k+this.scrollTop-d.top)/this.lineHeight),x=this.$blockCursor?Math.floor(b):Math.round(b);return{row:T,column:x,side:b-x>0?1:-1,offsetX:f}},A.prototype.screenToTextCoordinates=function(S,k){var d;if(this.$hasCssTransforms){d={top:0,left:0};var h=this.$fontMetrics.transformCoordinates([S,k]);S=h[1]-this.gutterWidth-this.margin.left,k=h[0]}else d=this.scroller.getBoundingClientRect();var f=S+this.scrollLeft-d.left-this.$padding,b=f/this.characterWidth,T=this.$blockCursor?Math.floor(b):Math.round(b),x=Math.floor((k+this.scrollTop-d.top)/this.lineHeight);return this.session.screenToDocumentPosition(x,Math.max(T,0),f)},A.prototype.textToScreenCoordinates=function(S,k){var d=this.scroller.getBoundingClientRect(),h=this.session.documentToScreenPosition(S,k),f=this.$padding+(this.session.$bidiHandler.isBidiRow(h.row,S)?this.session.$bidiHandler.getPosLeft(h.column):Math.round(h.column*this.characterWidth)),b=h.row*this.lineHeight;return{pageX:d.left+f-this.scrollLeft,pageY:d.top+b-this.scrollTop}},A.prototype.visualizeFocus=function(){w.addCssClass(this.container,"ace_focus")},A.prototype.visualizeBlur=function(){w.removeCssClass(this.container,"ace_focus")},A.prototype.showComposition=function(S){this.$composition=S,S.cssText||(S.cssText=this.textarea.style.cssText),S.useTextareaForIME==null&&(S.useTextareaForIME=this.$useTextareaForIME),this.$useTextareaForIME?(w.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor(),this.$cursorLayer.element.style.display="none"):S.markerId=this.session.addMarker(S.markerRange,"ace_composition_marker","text")},A.prototype.setCompositionText=function(S){var k=this.session.selection.cursor;this.addToken(S,"composition_placeholder",k.row,k.column),this.$moveTextAreaToCursor()},A.prototype.hideComposition=function(){if(this.$composition){this.$composition.markerId&&this.session.removeMarker(this.$composition.markerId),w.removeCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText=this.$composition.cssText;var S=this.session.selection.cursor;this.removeExtraToken(S.row,S.column),this.$composition=null,this.$cursorLayer.element.style.display=""}},A.prototype.setGhostText=function(S,k){var d=this.session.selection.cursor,h=k||{row:d.row,column:d.column};this.removeGhostText();var f=this.$calculateWrappedTextChunks(S,h);this.addToken(f[0].text,"ghost_text",h.row,h.column),this.$ghostText={text:S,position:{row:h.row,column:h.column}};var b=w.createElement("div");if(f.length>1){var T=this.hideTokensAfterPosition(h.row,h.column),x;f.slice(1).forEach(function(F){var z=w.createElement("div"),H=w.createElement("span");H.className="ace_ghost_text",F.wrapped&&(z.className="ghost_text_line_wrapped"),F.text.length===0&&(F.text=" "),H.appendChild(w.createTextNode(F.text)),z.appendChild(H),b.appendChild(z),x=z}),T.forEach(function(F){var z=w.createElement("span");g(F.type)||(z.className="ace_"+F.type.replace(/\./g," ace_")),z.appendChild(w.createTextNode(F.value)),x.appendChild(z)}),this.$ghostTextWidget={el:b,row:h.row,column:h.column,className:"ace_ghost_text_container"},this.session.widgetManager.addLineWidget(this.$ghostTextWidget);var R=this.$cursorLayer.getPixelPosition(h,!0),I=this.container,N=I.getBoundingClientRect().height,D=f.length*this.lineHeight,B=D0){var I=0;R.push(f[T].length);for(var N=0;N1||Math.abs(S.$size.height-h)>1?S.$resizeTimer.delay():S.$resizeTimer.cancel()}),this.$resizeObserver.observe(this.container)}},A}();M.prototype.CHANGE_CURSOR=1,M.prototype.CHANGE_MARKER=2,M.prototype.CHANGE_GUTTER=4,M.prototype.CHANGE_SCROLL=8,M.prototype.CHANGE_LINES=16,M.prototype.CHANGE_TEXT=32,M.prototype.CHANGE_SIZE=64,M.prototype.CHANGE_MARKER_BACK=128,M.prototype.CHANGE_MARKER_FRONT=256,M.prototype.CHANGE_FULL=512,M.prototype.CHANGE_H_SCROLL=1024,M.prototype.$changes=0,M.prototype.$padding=null,M.prototype.$frozen=!1,M.prototype.STEPS=8,y.implement(M.prototype,p),s.defineOptions(M.prototype,"renderer",{useResizeObserver:{set:function(A){!A&&this.$resizeObserver?(this.$resizeObserver.disconnect(),this.$resizeTimer.cancel(),this.$resizeTimer=this.$resizeObserver=null):A&&!this.$resizeObserver&&this.$addResizeObserver()}},animatedScroll:{initialValue:!1},showInvisibles:{set:function(A){this.$textLayer.setShowInvisibles(A)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!1},showPrintMargin:{set:function(){this.$updatePrintMargin()},initialValue:!0},printMarginColumn:{set:function(){this.$updatePrintMargin()},initialValue:80},printMargin:{set:function(A){typeof A=="number"&&(this.$printMarginColumn=A),this.$showPrintMargin=!!A,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(A){this.$gutter.style.display=A?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},useSvgGutterIcons:{set:function(A){this.$gutterLayer.$useSvgGutterIcons=A},initialValue:!1},showFoldedAnnotations:{set:function(A){this.$gutterLayer.$showFoldedAnnotations=A},initialValue:!1},fadeFoldWidgets:{set:function(A){w.setCssClass(this.$gutter,"ace_fade-fold-widgets",A)},initialValue:!1},showFoldWidgets:{set:function(A){this.$gutterLayer.setShowFoldWidgets(A),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(A){this.$textLayer.setDisplayIndentGuides(A)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightIndentGuides:{set:function(A){this.$textLayer.setHighlightIndentGuides(A)==!0?this.$textLayer.$highlightIndentGuide():this.$textLayer.$clearActiveIndentGuide(this.$textLayer.$lines.cells)},initialValue:!0},highlightGutterLine:{set:function(A){this.$gutterLayer.setHighlightGutterLine(A),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},hScrollBarAlwaysVisible:{set:function(A){(!this.$hScrollBarAlwaysVisible||!this.$horizScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(A){(!this.$vScrollBarAlwaysVisible||!this.$vScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(A){typeof A=="number"&&(A=A+"px"),this.container.style.fontSize=A,this.updateFontSize()},initialValue:12},fontFamily:{set:function(A){this.container.style.fontFamily=A,this.updateFontSize()}},maxLines:{set:function(A){this.updateFull()}},minLines:{set:function(A){this.$minLines<562949953421311||(this.$minLines=0),this.updateFull()}},maxPixelHeight:{set:function(A){this.updateFull()},initialValue:0},scrollPastEnd:{set:function(A){A=+A||0,this.$scrollPastEnd!=A&&(this.$scrollPastEnd=A,this.$loop.schedule(this.CHANGE_SCROLL))},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(A){this.$gutterLayer.$fixedWidth=!!A,this.$loop.schedule(this.CHANGE_GUTTER)}},customScrollbar:{set:function(A){this.$updateCustomScrollbar(A)},initialValue:!1},theme:{set:function(A){this.setTheme(A)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0},hasCssTransforms:{},useTextareaForIME:{initialValue:!C.isMobile&&!C.isIE}}),L.VirtualRenderer=M}),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],function(_,L,E){"use strict";var y=_("../lib/oop"),w=_("../lib/net"),v=_("../lib/event_emitter").EventEmitter,s=_("../config");function l(t){var e="importScripts('"+w.qualifyURL(t)+"');";try{return new Blob([e],{type:"application/javascript"})}catch(c){var o=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder,a=new o;return a.append(e),a.getBlob("application/javascript")}}function i(t){if(typeof Worker=="undefined")return{postMessage:function(){},terminate:function(){}};if(s.get("loadWorkerFromBlob")){var e=l(t),o=window.URL||window.webkitURL,a=o.createObjectURL(e);return new Worker(a)}return new Worker(t)}var r=function(t){t.postMessage||(t=this.$createWorkerFromOldConfig.apply(this,arguments)),this.$worker=t,this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this),this.changeListener=this.changeListener.bind(this),this.onMessage=this.onMessage.bind(this),this.callbackId=1,this.callbacks={},this.$worker.onmessage=this.onMessage};(function(){y.implement(this,v),this.$createWorkerFromOldConfig=function(t,e,o,a,c){if(_.nameToUrl&&!_.toUrl&&(_.toUrl=_.nameToUrl),s.get("packaged")||!_.toUrl)a=a||s.moduleUrl(e,"worker");else{var u=this.$normalizePath;a=a||u(_.toUrl("ace/worker/worker.js",null,"_"));var p={};t.forEach(function(m){p[m]=u(_.toUrl(m,null,"_").replace(/(\.js)?(\?.*)?$/,""))})}return this.$worker=i(a),c&&this.send("importScripts",c),this.$worker.postMessage({init:!0,tlns:p,module:e,classname:o}),this.$worker},this.onMessage=function(t){var e=t.data;switch(e.type){case"event":this._signal(e.name,{data:e.data});break;case"call":var o=this.callbacks[e.id];o&&(o(e.data),delete this.callbacks[e.id]);break;case"error":this.reportError(e.data);break;case"log":window.console&&console.log&&console.log.apply(console,e.data);break}},this.reportError=function(t){window.console&&console.error&&console.error(t)},this.$normalizePath=function(t){return w.qualifyURL(t)},this.terminate=function(){this._signal("terminate",{}),this.deltaQueue=null,this.$worker.terminate(),this.$worker.onerror=function(t){t.preventDefault()},this.$worker=null,this.$doc&&this.$doc.off("change",this.changeListener),this.$doc=null},this.send=function(t,e){this.$worker.postMessage({command:t,args:e})},this.call=function(t,e,o){if(o){var a=this.callbackId++;this.callbacks[a]=o,e.push(a)}this.send(t,e)},this.emit=function(t,e){try{e.data&&e.data.err&&(e.data.err={message:e.data.err.message,stack:e.data.err.stack,code:e.data.err.code}),this.$worker&&this.$worker.postMessage({event:t,data:{data:e.data}})}catch(o){console.error(o.stack)}},this.attachToDocument=function(t){this.$doc&&this.terminate(),this.$doc=t,this.call("setValue",[t.getValue()]),t.on("change",this.changeListener,!0)},this.changeListener=function(t){this.deltaQueue||(this.deltaQueue=[],setTimeout(this.$sendDeltaQueue,0)),t.action=="insert"?this.deltaQueue.push(t.start,t.lines):this.deltaQueue.push(t.start,t.end)},this.$sendDeltaQueue=function(){var t=this.deltaQueue;t&&(this.deltaQueue=null,t.length>50&&t.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:t}))}}).call(r.prototype);var n=function(t,e,o){var a=null,c=!1,u=Object.create(v),p=[],m=new r({messageBuffer:p,terminate:function(){},postMessage:function(C){p.push(C),a&&(c?setTimeout($):$())}});m.setEmitSync=function(C){c=C};var $=function(){var C=p.shift();C.command?a[C.command].apply(a,C.args):C.event&&u._signal(C.event,C.data)};return u.postMessage=function(C){m.onMessage({data:C})},u.callback=function(C,g){this.postMessage({type:"call",id:g,data:C})},u.emit=function(C,g){this.postMessage({type:"event",name:C,data:g})},s.loadModule(["worker",e],function(C){for(a=new C[o](u);p.length;)$()}),m};L.UIWorkerClient=n,L.WorkerClient=r,L.createWorker=i}),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],function(_,L,E){"use strict";var y=_("./range").Range,w=_("./lib/event_emitter").EventEmitter,v=_("./lib/oop"),s=function(){function l(i,r,n,t,e,o){var a=this;this.length=r,this.session=i,this.doc=i.getDocument(),this.mainClass=e,this.othersClass=o,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate,!0),this.$others=t,this.$onCursorChange=function(){setTimeout(function(){a.onCursorChange()})},this.$pos=n;var c=i.getUndoManager().$undoStack||i.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=c.length,this.setup(),i.selection.on("changeCursor",this.$onCursorChange)}return l.prototype.setup=function(){var i=this,r=this.doc,n=this.session;this.selectionBefore=n.selection.toJSON(),n.selection.inMultiSelectMode&&n.selection.toSingleRange(),this.pos=r.createAnchor(this.$pos.row,this.$pos.column);var t=this.pos;t.$insertRight=!0,t.detach(),t.markerId=n.addMarker(new y(t.row,t.column,t.row,t.column+this.length),this.mainClass,null,!1),this.others=[],this.$others.forEach(function(e){var o=r.createAnchor(e.row,e.column);o.$insertRight=!0,o.detach(),i.others.push(o)}),n.setUndoSelect(!1)},l.prototype.showOtherMarkers=function(){if(!this.othersActive){var i=this.session,r=this;this.othersActive=!0,this.others.forEach(function(n){n.markerId=i.addMarker(new y(n.row,n.column,n.row,n.column+r.length),r.othersClass,null,!1)})}},l.prototype.hideOtherMarkers=function(){if(this.othersActive){this.othersActive=!1;for(var i=0;i=this.pos.column&&r.start.column<=this.pos.column+this.length+1,e=r.start.column-this.pos.column;if(this.updateAnchors(i),t&&(this.length+=n),t&&!this.session.$fromUndo){if(i.action==="insert")for(var o=this.others.length-1;o>=0;o--){var a=this.others[o],c={row:a.row,column:a.column+e};this.doc.insertMergedLines(c,i.lines)}else if(i.action==="remove")for(var o=this.others.length-1;o>=0;o--){var a=this.others[o],c={row:a.row,column:a.column+e};this.doc.remove(new y(c.row,c.column,c.row,c.column-n))}}this.$updating=!1,this.updateMarkers()}},l.prototype.updateAnchors=function(i){this.pos.onChange(i);for(var r=this.others.length;r--;)this.others[r].onChange(i);this.updateMarkers()},l.prototype.updateMarkers=function(){if(!this.$updating){var i=this,r=this.session,n=function(e,o){r.removeMarker(e.markerId),e.markerId=r.addMarker(new y(e.row,e.column,e.row,e.column+i.length),o,null,!1)};n(this.pos,this.mainClass);for(var t=this.others.length;t--;)n(this.others[t],this.othersClass)}},l.prototype.onCursorChange=function(i){if(!(this.$updating||!this.session)){var r=this.session.selection.getCursor();r.row===this.pos.row&&r.column>=this.pos.column&&r.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",i)):(this.hideOtherMarkers(),this._emit("cursorLeave",i))}},l.prototype.detach=function(){this.session.removeMarker(this.pos&&this.pos.markerId),this.hideOtherMarkers(),this.doc.off("change",this.$onUpdate),this.session.selection.off("changeCursor",this.$onCursorChange),this.session.setUndoSelect(!0),this.session=null},l.prototype.cancel=function(){if(this.$undoStackDepth!==-1){for(var i=this.session.getUndoManager(),r=(i.$undoStack||i.$undostack).length-this.$undoStackDepth,n=0;n1?w.multiSelect.joinSelections():w.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readOnly:!0},{name:"splitSelectionIntoLines",description:"Split into lines",exec:function(w){w.multiSelect.splitIntoLines()},readOnly:!0},{name:"alignCursors",description:"Align cursors",exec:function(w){w.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",description:"Find all",exec:function(w){w.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readOnly:!0}],L.multiSelectCommands=[{name:"singleSelection",description:"Single selection",bindKey:"esc",exec:function(w){w.exitMultiSelectMode()},scrollIntoView:"cursor",readOnly:!0,isAvailable:function(w){return w&&w.inMultiSelectMode}}];var y=_("../keyboard/hash_handler").HashHandler;L.keyboardHandler=new y(L.multiSelectCommands)}),ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"],function(_,L,E){var y=_("./range_list").RangeList,w=_("./range").Range,v=_("./selection").Selection,s=_("./mouse/multi_select_handler").onMouseDown,l=_("./lib/event"),i=_("./lib/lang"),r=_("./commands/multi_select_commands");L.commands=r.defaultCommands.concat(r.multiSelectCommands);var n=_("./search").Search,t=new n;function e(m,$,C){return t.$options.wrap=!0,t.$options.needle=$,t.$options.backwards=C==-1,t.find(m)}var o=_("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(o.prototype),function(){this.ranges=null,this.rangeList=null,this.addRange=function(m,$){if(m){if(!this.inMultiSelectMode&&this.rangeCount===0){var C=this.toOrientedRange();if(this.rangeList.add(C),this.rangeList.add(m),this.rangeList.ranges.length!=2)return this.rangeList.removeAll(),$||this.fromOrientedRange(m);this.rangeList.removeAll(),this.rangeList.add(C),this.$onAddRange(C)}m.cursor||(m.cursor=m.end);var g=this.rangeList.add(m);return this.$onAddRange(m),g.length&&this.$onRemoveRange(g),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),$||this.fromOrientedRange(m)}},this.toSingleRange=function(m){m=m||this.ranges[0];var $=this.rangeList.removeAll();$.length&&this.$onRemoveRange($),m&&this.fromOrientedRange(m)},this.substractPoint=function(m){var $=this.rangeList.substractPoint(m);if($)return this.$onRemoveRange($),$[0]},this.mergeOverlappingRanges=function(){var m=this.rangeList.merge();m.length&&this.$onRemoveRange(m)},this.$onAddRange=function(m){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(m),this._signal("addRange",{range:m})},this.$onRemoveRange=function(m){if(this.rangeCount=this.rangeList.ranges.length,this.rangeCount==1&&this.inMultiSelectMode){var $=this.rangeList.ranges.pop();m.push($),this.rangeCount=0}for(var C=m.length;C--;){var g=this.ranges.indexOf(m[C]);this.ranges.splice(g,1)}this._signal("removeRange",{ranges:m}),this.rangeCount===0&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),$=$||this.ranges[0],$&&!$.isEqual(this.getRange())&&this.fromOrientedRange($)},this.$initRangeList=function(){this.rangeList||(this.rangeList=new y,this.ranges=[],this.rangeCount=0)},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){for(var m=this.ranges.length?this.ranges:[this.getRange()],$=[],C=0;C1){var m=this.rangeList.ranges,$=m[m.length-1],C=w.fromPoints(m[0].start,$.end);this.toSingleRange(),this.setSelectionRange(C,$.cursor==$.start)}else{var g=this.session.documentToScreenPosition(this.cursor),M=this.session.documentToScreenPosition(this.anchor),A=this.rectangularRangeBlock(g,M);A.forEach(this.addRange,this)}},this.rectangularRangeBlock=function(m,$,C){var g=[],M=m.column<$.column;if(M)var A=m.column,S=$.column,k=m.offsetX,d=$.offsetX;else var A=$.column,S=m.column,k=$.offsetX,d=m.offsetX;var h=m.row<$.row;if(h)var f=m.row,b=$.row;else var f=$.row,b=m.row;A<0&&(A=0),f<0&&(f=0),f==b&&(C=!0);for(var T,x=f;x<=b;x++){var R=w.fromPoints(this.session.screenToDocumentPosition(x,A,k),this.session.screenToDocumentPosition(x,S,d));if(R.isEmpty()){if(T&&c(R.end,T))break;T=R.end}R.cursor=M?R.start:R.end,g.push(R)}if(h&&g.reverse(),!C){for(var I=g.length-1;g[I].isEmpty()&&I>0;)I--;if(I>0)for(var N=0;g[N].isEmpty();)N++;for(var D=I;D>=N;D--)g[D].isEmpty()&&g.splice(D,1)}return g}}.call(v.prototype);var a=_("./editor").Editor;(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(m){m.cursor||(m.cursor=m.end);var $=this.getSelectionStyle();return m.marker=this.session.addMarker(m,"ace_selection",$),this.session.$selectionMarkers.push(m),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,m},this.removeSelectionMarker=function(m){if(m.marker){this.session.removeMarker(m.marker);var $=this.session.$selectionMarkers.indexOf(m);$!=-1&&this.session.$selectionMarkers.splice($,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length}},this.removeSelectionMarkers=function(m){for(var $=this.session.$selectionMarkers,C=m.length;C--;){var g=m[C];if(g.marker){this.session.removeMarker(g.marker);var M=$.indexOf(g);M!=-1&&$.splice(M,1)}}this.session.selectionMarkerCount=$.length},this.$onAddRange=function(m){this.addSelectionMarker(m.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(m){this.removeSelectionMarkers(m.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(m){this.inMultiSelectMode||(this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(r.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers())},this.$onSingleSelect=function(m){this.session.multiSelect.inVirtualMode||(this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(r.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection"))},this.$onMultiSelectExec=function(m){var $=m.command,C=m.editor;if(C.multiSelect){if($.multiSelectAction)$.multiSelectAction=="forEach"?g=C.forEachSelection($,m.args):$.multiSelectAction=="forEachLine"?g=C.forEachSelection($,m.args,!0):$.multiSelectAction=="single"?(C.exitMultiSelectMode(),g=$.exec(C,m.args||{})):g=$.multiSelectAction(C,m.args||{});else{var g=$.exec(C,m.args||{});C.multiSelect.addRange(C.multiSelect.toOrientedRange()),C.multiSelect.mergeOverlappingRanges()}return g}},this.forEachSelection=function(m,$,C){if(!this.inVirtualSelectionMode){var g=C&&C.keepOrder,M=C==!0||C&&C.$byLines,A=this.session,S=this.selection,k=S.rangeList,d=(g?S:k).ranges,h;if(!d.length)return m.exec?m.exec(this,$||{}):m(this,$||{});var f=S._eventRegistry;S._eventRegistry={};var b=new v(A);this.inVirtualSelectionMode=!0;for(var T=d.length;T--;){if(M)for(;T>0&&d[T].start.row==d[T-1].end.row;)T--;b.fromOrientedRange(d[T]),b.index=T,this.selection=A.selection=b;var x=m.exec?m.exec(this,$||{}):m(this,$||{});!h&&x!==void 0&&(h=x),b.toOrientedRange(d[T])}b.detach(),this.selection=A.selection=S,this.inVirtualSelectionMode=!1,S._eventRegistry=f,S.mergeOverlappingRanges(),S.ranges[0]&&S.fromOrientedRange(S.ranges[0]);var R=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),R&&R.from==R.to&&this.renderer.animateScrolling(R.from),h}},this.exitMultiSelectMode=function(){!this.inMultiSelectMode||this.inVirtualSelectionMode||this.multiSelect.toSingleRange()},this.getSelectedText=function(){var m="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){for(var $=this.multiSelect.rangeList.ranges,C=[],g=0;g<$.length;g++)C.push(this.session.getTextRange($[g]));var M=this.session.getDocument().getNewLineCharacter();m=C.join(M),m.length==(C.length-1)*M.length&&(m="")}else this.selection.isEmpty()||(m=this.session.getTextRange(this.getSelectionRange()));return m},this.$checkMultiselectChange=function(m,$){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var C=this.multiSelect.ranges[0];if(this.multiSelect.isEmpty()&&$==this.multiSelect.anchor)return;var g=$==this.multiSelect.anchor?C.cursor==C.start?C.end:C.start:C.cursor;g.row!=$.row||this.session.$clipPositionToDocument(g.row,g.column).column!=$.column?this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange()):this.multiSelect.mergeOverlappingRanges()}},this.findAll=function(m,$,C){if($=$||{},$.needle=m||$.needle,$.needle==null){var g=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();$.needle=this.session.getTextRange(g)}this.$search.set($);var M=this.$search.findAll(this.session);if(!M.length)return 0;var A=this.multiSelect;C||A.toSingleRange(M[0]);for(var S=M.length;S--;)A.addRange(M[S],!0);return g&&A.rangeList.rangeAtPoint(g.start)&&A.addRange(g,!0),M.length},this.selectMoreLines=function(m,$){var C=this.selection.toOrientedRange(),g=C.cursor==C.end,M=this.session.documentToScreenPosition(C.cursor);this.selection.$desiredColumn&&(M.column=this.selection.$desiredColumn);var A=this.session.screenToDocumentPosition(M.row+m,M.column);if(C.isEmpty())var k=A;else var S=this.session.documentToScreenPosition(g?C.end:C.start),k=this.session.screenToDocumentPosition(S.row+m,S.column);if(g){var d=w.fromPoints(A,k);d.cursor=d.start}else{var d=w.fromPoints(k,A);d.cursor=d.end}if(d.desiredColumn=M.column,!this.selection.inMultiSelectMode)this.selection.addRange(C);else if($)var h=C.cursor;this.selection.addRange(d),h&&this.selection.substractPoint(h)},this.transposeSelections=function(m){for(var $=this.session,C=$.multiSelect,g=C.ranges,M=g.length;M--;){var A=g[M];if(A.isEmpty()){var S=$.getWordRange(A.start.row,A.start.column);A.start.row=S.start.row,A.start.column=S.start.column,A.end.row=S.end.row,A.end.column=S.end.column}}C.mergeOverlappingRanges();for(var k=[],M=g.length;M--;){var A=g[M];k.unshift($.getTextRange(A))}m<0?k.unshift(k.pop()):k.push(k.shift());for(var M=g.length;M--;){var A=g[M],d=A.clone();$.replace(A,k[M]),A.start.row=d.start.row,A.start.column=d.start.column}C.fromOrientedRange(C.ranges[0])},this.selectMore=function(m,$,C){var g=this.session,M=g.multiSelect,A=M.toOrientedRange();if(!(A.isEmpty()&&(A=g.getWordRange(A.start.row,A.start.column),A.cursor=m==-1?A.start:A.end,this.multiSelect.addRange(A),C))){var S=g.getTextRange(A),k=e(g,S,m);k&&(k.cursor=m==-1?k.start:k.end,this.session.unfold(k),this.multiSelect.addRange(k),this.renderer.scrollCursorIntoView(null,.5)),$&&this.multiSelect.substractPoint(A.cursor)}},this.alignCursors=function(){var m=this.session,$=m.multiSelect,C=$.ranges,g=-1,M=C.filter(function(I){if(I.cursor.row==g)return!0;g=I.cursor.row});if(!C.length||M.length==C.length-1){var A=this.selection.getRange(),S=A.start.row,k=A.end.row,d=S==k;if(d){var h=this.session.getLength(),f;do f=this.session.getLine(k);while(/[=:]/.test(f)&&++k0);S<0&&(S=0),k>=h&&(k=h-1)}var b=this.session.removeFullLines(S,k);b=this.$reAlignText(b,d),this.session.insert({row:S,column:0},b.join(` +`)+` +`),d||(A.start.column=0,A.end.column=b[b.length-1].length),this.selection.setRange(A)}else{M.forEach(function(I){$.substractPoint(I.cursor)});var T=0,x=1/0,R=C.map(function(I){var N=I.cursor,D=m.getLine(N.row),B=D.substr(N.column).search(/\S/g);return B==-1&&(B=0),N.column>T&&(T=N.column),BF?m.insert(D,i.stringRepeat(" ",B-F)):m.remove(new w(D.row,D.column,D.row,D.column-B+F)),I.start.column=I.end.column=T,I.start.row=I.end.row=D.row,I.cursor=I.end}),$.fromOrientedRange(C[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}},this.$reAlignText=function(m,$){var C=!0,g=!0,M,A,S;return m.map(function(b){var T=b.match(/(\s*)(.*?)(\s*)([=:].*)/);return T?M==null?(M=T[1].length,A=T[2].length,S=T[3].length,T):(M+A+S!=T[1].length+T[2].length+T[3].length&&(g=!1),M!=T[1].length&&(C=!1),M>T[1].length&&(M=T[1].length),AT[3].length&&(S=T[3].length),T):[b]}).map($?d:C?g?h:d:f);function k(b){return i.stringRepeat(" ",b)}function d(b){return b[2]?k(M)+b[2]+k(A-b[2].length+S)+b[4].replace(/^([=:])\s+/,"$1 "):b[0]}function h(b){return b[2]?k(M+A-b[2].length)+b[2]+k(S)+b[4].replace(/^([=:])\s+/,"$1 "):b[0]}function f(b){return b[2]?k(M)+b[2]+k(S)+b[4].replace(/^([=:])\s+/,"$1 "):b[0]}}}).call(a.prototype);function c(m,$){return m.row==$.row&&m.column==$.column}L.onSessionChange=function(m){var $=m.session;$&&!$.multiSelect&&($.$selectionMarkers=[],$.selection.$initRangeList(),$.multiSelect=$.selection),this.multiSelect=$&&$.multiSelect;var C=m.oldSession;C&&(C.multiSelect.off("addRange",this.$onAddRange),C.multiSelect.off("removeRange",this.$onRemoveRange),C.multiSelect.off("multiSelect",this.$onMultiSelect),C.multiSelect.off("singleSelect",this.$onSingleSelect),C.multiSelect.lead.off("change",this.$checkMultiselectChange),C.multiSelect.anchor.off("change",this.$checkMultiselectChange)),$&&($.multiSelect.on("addRange",this.$onAddRange),$.multiSelect.on("removeRange",this.$onRemoveRange),$.multiSelect.on("multiSelect",this.$onMultiSelect),$.multiSelect.on("singleSelect",this.$onSingleSelect),$.multiSelect.lead.on("change",this.$checkMultiselectChange),$.multiSelect.anchor.on("change",this.$checkMultiselectChange)),$&&this.inMultiSelectMode!=$.selection.inMultiSelectMode&&($.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())};function u(m){m.$multiselectOnSessionChange||(m.$onAddRange=m.$onAddRange.bind(m),m.$onRemoveRange=m.$onRemoveRange.bind(m),m.$onMultiSelect=m.$onMultiSelect.bind(m),m.$onSingleSelect=m.$onSingleSelect.bind(m),m.$multiselectOnSessionChange=L.onSessionChange.bind(m),m.$checkMultiselectChange=m.$checkMultiselectChange.bind(m),m.$multiselectOnSessionChange(m),m.on("changeSession",m.$multiselectOnSessionChange),m.on("mousedown",s),m.commands.addCommands(r.defaultCommands),p(m))}function p(m){if(!m.textInput)return;var $=m.textInput.getElement(),C=!1;l.addListener($,"keydown",function(M){var A=M.keyCode==18&&!(M.ctrlKey||M.shiftKey||M.metaKey);m.$blockSelectEnabled&&A?C||(m.renderer.setMouseCursor("crosshair"),C=!0):C&&g()},m),l.addListener($,"keyup",g,m),l.addListener($,"blur",g,m);function g(M){C&&(m.renderer.setMouseCursor(""),C=!1)}}L.MultiSelect=u,_("./config").defineOptions(a.prototype,"editor",{enableMultiselect:{set:function(m){u(this),m?this.on("mousedown",s):this.off("mousedown",s)},value:!0},enableBlockSelect:{set:function(m){this.$blockSelectEnabled=m},value:!0}})}),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(_,L,E){"use strict";var y=_("../../range").Range,w=L.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(v,s,l){var i=v.getLine(l);return this.foldingStartMarker.test(i)?"start":s=="markbeginend"&&this.foldingStopMarker&&this.foldingStopMarker.test(i)?"end":""},this.getFoldWidgetRange=function(v,s,l){return null},this.indentationBlock=function(v,s,l){var i=/\S/,r=v.getLine(s),n=r.search(i);if(n!=-1){for(var t=l||r.length,e=v.getLength(),o=s,a=s;++so){var p=v.getLine(a).length;return new y(o,t,a,p)}}},this.openingBracketBlock=function(v,s,l,i,r){var n={row:l,column:i+1},t=v.$findClosingBracket(s,n,r);if(t){var e=v.foldWidgets[t.row];return e==null&&(e=v.getFoldWidget(t.row)),e=="start"&&t.row>n.row&&(t.row--,t.column=v.getLine(t.row).length),y.fromPoints(n,t)}},this.closingBracketBlock=function(v,s,l,i,r){var n={row:l,column:i},t=v.$findOpeningBracket(s,n);if(t)return t.column++,n.column--,y.fromPoints(t,n)}}).call(w.prototype)}),ace.define("ace/ext/error_marker",["require","exports","module","ace/lib/dom","ace/range","ace/config"],function(_,L,E){"use strict";var y=_("../lib/dom"),w=_("../range").Range,v=_("../config").nls;function s(i,r,n){for(var t=0,e=i.length-1;t<=e;){var o=t+e>>1,a=n(r,i[o]);if(a>0)t=o+1;else if(a<0)e=o-1;else return o}return-(t+1)}function l(i,r,n){var t=i.getAnnotations().sort(w.comparePoints);if(t.length){var e=s(t,{row:r,column:-1},w.comparePoints);e<0&&(e=-e-1),e>=t.length?e=n>0?0:t.length-1:e===0&&n<0&&(e=t.length-1);var o=t[e];if(!(!o||!n)){if(o.row===r){do o=t[e+=n];while(o&&o.row===r);if(!o)return t.slice()}var a=[];r=o.row;do a[n<0?"unshift":"push"](o),o=t[e+=n];while(o&&o.row==r);return a.length&&a}}}L.showErrorMarker=function(i,r){var n=i.session,t=i.getCursorPosition(),e=t.row,o=n.widgetManager.getWidgetsAtRow(e).filter(function(M){return M.type=="errorMarker"})[0];o?o.destroy():e-=r;var a=l(n,e,r),c;if(a){var u=a[0];t.column=(u.pos&&typeof u.column!="number"?u.pos.sc:u.column)||0,t.row=u.row,c=i.renderer.$gutterLayer.$annotations[t.row]}else{if(o)return;c={displayText:[v("error-marker.good-state","Looks good!")],className:"ace_ok"}}i.session.unfold(t.row),i.selection.moveToPosition(t);var p={row:t.row,fixedWidth:!0,coverGutter:!0,el:y.createElement("div"),type:"errorMarker"},m=p.el.appendChild(y.createElement("div")),$=p.el.appendChild(y.createElement("div"));$.className="error_widget_arrow "+c.className;var C=i.renderer.$cursorLayer.getPixelPosition(t).left;$.style.left=C+i.renderer.gutterWidth-5+"px",p.el.className="error_widget_wrapper",m.className="error_widget "+c.className,c.displayText.forEach(function(M,A){m.appendChild(y.createTextNode(M)),A{pe=J.nmd(pe),ace.define("ace/split",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/editor","ace/virtual_renderer","ace/edit_session"],function(_,L,E){"use strict";var y=_("./lib/oop"),w=_("./lib/lang"),v=_("./lib/event_emitter").EventEmitter,s=_("./editor").Editor,l=_("./virtual_renderer").VirtualRenderer,i=_("./edit_session").EditSession,r;r=function(n,t,e){this.BELOW=1,this.BESIDE=0,this.$container=n,this.$theme=t,this.$splits=0,this.$editorCSS="",this.$editors=[],this.$orientation=this.BESIDE,this.setSplits(e||1),this.$cEditor=this.$editors[0],this.on("focus",function(o){this.$cEditor=o}.bind(this))},function(){y.implement(this,v),this.$createEditor=function(){var n=document.createElement("div");n.className=this.$editorCSS,n.style.cssText="position: absolute; top:0px; bottom:0px",this.$container.appendChild(n);var t=new s(new l(n,this.$theme));return t.on("focus",function(){this._emit("focus",t)}.bind(this)),this.$editors.push(t),t.setFontSize(this.$fontSize),t},this.setSplits=function(n){var t;if(n<1)throw"The number of splits have to be > 0!";if(n!=this.$splits){if(n>this.$splits){for(;this.$splitsn;)t=this.$editors[this.$splits-1],this.$container.removeChild(t.container),this.$splits--;this.resize()}},this.getSplits=function(){return this.$splits},this.getEditor=function(n){return this.$editors[n]},this.getCurrentEditor=function(){return this.$cEditor},this.focus=function(){this.$cEditor.focus()},this.blur=function(){this.$cEditor.blur()},this.setTheme=function(n){this.$editors.forEach(function(t){t.setTheme(n)})},this.setKeyboardHandler=function(n){this.$editors.forEach(function(t){t.setKeyboardHandler(n)})},this.forEach=function(n,t){this.$editors.forEach(n,t)},this.$fontSize="",this.setFontSize=function(n){this.$fontSize=n,this.forEach(function(t){t.setFontSize(n)})},this.$cloneSession=function(n){var t=new i(n.getDocument(),n.getMode()),e=n.getUndoManager();return t.setUndoManager(e),t.setTabSize(n.getTabSize()),t.setUseSoftTabs(n.getUseSoftTabs()),t.setOverwrite(n.getOverwrite()),t.setBreakpoints(n.getBreakpoints()),t.setUseWrapMode(n.getUseWrapMode()),t.setUseWorker(n.getUseWorker()),t.setWrapLimitRange(n.$wrapLimitRange.min,n.$wrapLimitRange.max),t.$foldData=n.$cloneFoldData(),t},this.setSession=function(n,t){var e;t==null?e=this.$cEditor:e=this.$editors[t];var o=this.$editors.some(function(a){return a.session===n});return o&&(n=this.$cloneSession(n)),e.setSession(n),n},this.getOrientation=function(){return this.$orientation},this.setOrientation=function(n){this.$orientation!=n&&(this.$orientation=n,this.resize())},this.resize=function(){var n=this.$container.clientWidth,t=this.$container.clientHeight,e;if(this.$orientation==this.BESIDE)for(var o=n/this.$splits,a=0;a{var j=function(){this.Diff_Timeout=1,this.Diff_EditCost=4,this.Match_Threshold=.5,this.Match_Distance=1e3,this.Patch_DeleteThreshold=.5,this.Patch_Margin=4,this.Match_MaxBits=32},J=-1,_=1,L=0;j.Diff=function(E,y){return[E,y]},j.prototype.diff_main=function(E,y,w,v){typeof v=="undefined"&&(this.Diff_Timeout<=0?v=Number.MAX_VALUE:v=new Date().getTime()+this.Diff_Timeout*1e3);var s=v;if(E==null||y==null)throw new Error("Null input. (diff_main)");if(E==y)return E?[new j.Diff(L,E)]:[];typeof w=="undefined"&&(w=!0);var l=w,i=this.diff_commonPrefix(E,y),r=E.substring(0,i);E=E.substring(i),y=y.substring(i),i=this.diff_commonSuffix(E,y);var n=E.substring(E.length-i);E=E.substring(0,E.length-i),y=y.substring(0,y.length-i);var t=this.diff_compute_(E,y,l,s);return r&&t.unshift(new j.Diff(L,r)),n&&t.push(new j.Diff(L,n)),this.diff_cleanupMerge(t),t},j.prototype.diff_compute_=function(E,y,w,v){var s;if(!E)return[new j.Diff(_,y)];if(!y)return[new j.Diff(J,E)];var l=E.length>y.length?E:y,i=E.length>y.length?y:E,r=l.indexOf(i);if(r!=-1)return s=[new j.Diff(_,l.substring(0,r)),new j.Diff(L,i),new j.Diff(_,l.substring(r+i.length))],E.length>y.length&&(s[0][0]=s[2][0]=J),s;if(i.length==1)return[new j.Diff(J,E),new j.Diff(_,y)];var n=this.diff_halfMatch_(E,y);if(n){var t=n[0],e=n[1],o=n[2],a=n[3],c=n[4],u=this.diff_main(t,o,w,v),p=this.diff_main(e,a,w,v);return u.concat([new j.Diff(L,c)],p)}return w&&E.length>100&&y.length>100?this.diff_lineMode_(E,y,v):this.diff_bisect_(E,y,v)},j.prototype.diff_lineMode_=function(E,y,w){var v=this.diff_linesToChars_(E,y);E=v.chars1,y=v.chars2;var s=v.lineArray,l=this.diff_main(E,y,!1,w);this.diff_charsToLines_(l,s),this.diff_cleanupSemantic(l),l.push(new j.Diff(L,""));for(var i=0,r=0,n=0,t="",e="";i=1&&n>=1){l.splice(i-r-n,r+n),i=i-r-n;for(var o=this.diff_main(t,e,!1,w),a=o.length-1;a>=0;a--)l.splice(i,0,o[a]);i=i+o.length}n=0,r=0,t="",e="";break}i++}return l.pop(),l},j.prototype.diff_bisect_=function(E,y,w){for(var v=E.length,s=y.length,l=Math.ceil((v+s)/2),i=l,r=2*l,n=new Array(r),t=new Array(r),e=0;ew);$++){for(var C=-$+c;C<=$-u;C+=2){var g=i+C,M;C==-$||C!=$&&n[g-1]v)u+=2;else if(A>s)c+=2;else if(a){var S=i+o-C;if(S>=0&&S=k)return this.diff_bisectSplit_(E,y,M,A,w)}}}for(var d=-$+p;d<=$-m;d+=2){var S=i+d,k;d==-$||d!=$&&t[S-1]v)m+=2;else if(h>s)p+=2;else if(!a){var g=i+o-d;if(g>=0&&g=k)return this.diff_bisectSplit_(E,y,M,A,w)}}}}return[new j.Diff(J,E),new j.Diff(_,y)]},j.prototype.diff_bisectSplit_=function(E,y,w,v,s){var l=E.substring(0,w),i=y.substring(0,v),r=E.substring(w),n=y.substring(v),t=this.diff_main(l,i,!1,s),e=this.diff_main(r,n,!1,s);return t.concat(e)},j.prototype.diff_linesToChars_=function(E,y){var w=[],v={};w[0]="";function s(n){for(var t="",e=0,o=-1,a=w.length;ov?E=E.substring(w-v):wy.length?E:y,v=E.length>y.length?y:E;if(w.length<4||v.length*2=u.length?[M,A,S,k,g]:null}var i=l(w,v,Math.ceil(w.length/4)),r=l(w,v,Math.ceil(w.length/2)),n;if(!i&&!r)return null;r?i?n=i[4].length>r[4].length?i:r:n=r:n=i;var t,e,o,a;E.length>y.length?(t=n[0],e=n[1],o=n[2],a=n[3]):(o=n[0],a=n[1],t=n[2],e=n[3]);var c=n[4];return[t,e,o,a,c]},j.prototype.diff_cleanupSemantic=function(E){for(var y=!1,w=[],v=0,s=null,l=0,i=0,r=0,n=0,t=0;l0?w[v-1]:-1,i=0,r=0,n=0,t=0,s=null,y=!0)),l++;for(y&&this.diff_cleanupMerge(E),this.diff_cleanupSemanticLossless(E),l=1;l=c?(a>=e.length/2||a>=o.length/2)&&(E.splice(l,0,new j.Diff(L,o.substring(0,a))),E[l-1][1]=e.substring(0,e.length-a),E[l+1][1]=o.substring(a),l++):(c>=e.length/2||c>=o.length/2)&&(E.splice(l,0,new j.Diff(L,e.substring(0,c))),E[l-1][0]=_,E[l-1][1]=o.substring(0,o.length-c),E[l+1][0]=J,E[l+1][1]=e.substring(c),l++),l++}l++}},j.prototype.diff_cleanupSemanticLossless=function(E){function y(c,u){if(!c||!u)return 6;var p=c.charAt(c.length-1),m=u.charAt(0),$=p.match(j.nonAlphaNumericRegex_),C=m.match(j.nonAlphaNumericRegex_),g=$&&p.match(j.whitespaceRegex_),M=C&&m.match(j.whitespaceRegex_),A=g&&p.match(j.linebreakRegex_),S=M&&m.match(j.linebreakRegex_),k=A&&c.match(j.blanklineEndRegex_),d=S&&u.match(j.blanklineStartRegex_);return k||d?5:A||S?4:$&&!g&&M?3:g||M?2:$||C?1:0}for(var w=1;w=o&&(o=a,n=v,t=s,e=l)}E[w-1][1]!=n&&(n?E[w-1][1]=n:(E.splice(w-1,1),w--),E[w][1]=t,e?E[w+1][1]=e:(E.splice(w+1,1),w--))}w++}},j.nonAlphaNumericRegex_=/[^a-zA-Z0-9]/,j.whitespaceRegex_=/\s/,j.linebreakRegex_=/[\r\n]/,j.blanklineEndRegex_=/\n\r?\n$/,j.blanklineStartRegex_=/^\r?\n\r?\n/,j.prototype.diff_cleanupEfficiency=function(E){for(var y=!1,w=[],v=0,s=null,l=0,i=!1,r=!1,n=!1,t=!1;l0?w[v-1]:-1,n=t=!1),y=!0)),l++;y&&this.diff_cleanupMerge(E)},j.prototype.diff_cleanupMerge=function(E){E.push(new j.Diff(L,""));for(var y=0,w=0,v=0,s="",l="",i;y1?(w!==0&&v!==0&&(i=this.diff_commonPrefix(l,s),i!==0&&(y-w-v>0&&E[y-w-v-1][0]==L?E[y-w-v-1][1]+=l.substring(0,i):(E.splice(0,0,new j.Diff(L,l.substring(0,i))),y++),l=l.substring(i),s=s.substring(i)),i=this.diff_commonSuffix(l,s),i!==0&&(E[y][1]=l.substring(l.length-i)+E[y][1],l=l.substring(0,l.length-i),s=s.substring(0,s.length-i))),y-=w+v,E.splice(y,w+v),s.length&&(E.splice(y,0,new j.Diff(J,s)),y++),l.length&&(E.splice(y,0,new j.Diff(_,l)),y++),y++):y!==0&&E[y-1][0]==L?(E[y-1][1]+=E[y][1],E.splice(y,1)):y++,v=0,w=0,s="",l="";break}E[E.length-1][1]===""&&E.pop();var r=!1;for(y=1;yy));i++)s=w,l=v;return E.length!=i&&E[i][0]===J?l:l+(y-s)},j.prototype.diff_prettyHtml=function(E){for(var y=[],w=/&/g,v=//g,l=/\n/g,i=0;i");switch(r){case _:y[i]=''+t+"";break;case J:y[i]=''+t+"";break;case L:y[i]=""+t+"";break}}return y.join("")},j.prototype.diff_text1=function(E){for(var y=[],w=0;wthis.Match_MaxBits)throw new Error("Pattern too long for this browser.");var v=this.match_alphabet_(y),s=this;function l(M,A){var S=M/y.length,k=Math.abs(w-A);return s.Match_Distance?S+k/s.Match_Distance:k?1:S}var i=this.Match_Threshold,r=E.indexOf(y,w);r!=-1&&(i=Math.min(l(0,r),i),r=E.lastIndexOf(y,w+y.length),r!=-1&&(i=Math.min(l(0,r),i)));var n=1<=u;$--){var C=v[E.charAt($-1)];if(c===0?m[$]=(m[$+1]<<1|1)&C:m[$]=(m[$+1]<<1|1)&C|((a[$+1]|a[$])<<1|1)|a[$+1],m[$]&n){var g=l(c,$-1);if(g<=i)if(i=g,r=$-1,r>w)u=Math.max(1,2*w-r);else break}}if(l(c+1,w)>i)break;a=m}return r},j.prototype.match_alphabet_=function(E){for(var y={},w=0;w2&&(this.diff_cleanupSemantic(s),this.diff_cleanupEfficiency(s));else if(E&&typeof E=="object"&&typeof y=="undefined"&&typeof w=="undefined")s=E,v=this.diff_text1(s);else if(typeof E=="string"&&y&&typeof y=="object"&&typeof w=="undefined")v=E,s=y;else if(typeof E=="string"&&typeof y=="string"&&w&&typeof w=="object")v=E,s=w;else throw new Error("Unknown call format to patch_make.");if(s.length===0)return[];for(var l=[],i=new j.patch_obj,r=0,n=0,t=0,e=v,o=v,a=0;a=2*this.Patch_Margin&&r&&(this.patch_addContext_(i,e),l.push(i),i=new j.patch_obj,r=0,e=o,n=t);break}c!==_&&(n+=u.length),c!==J&&(t+=u.length)}return r&&(this.patch_addContext_(i,e),l.push(i)),l},j.prototype.patch_deepCopy=function(E){for(var y=[],w=0;wthis.Match_MaxBits?(n=this.match_main(y,r.substring(0,this.Match_MaxBits),i),n!=-1&&(t=this.match_main(y,r.substring(r.length-this.Match_MaxBits),i+r.length-this.Match_MaxBits),(t==-1||n>=t)&&(n=-1))):n=this.match_main(y,r,i),n==-1)s[l]=!1,v-=E[l].length2-E[l].length1;else{s[l]=!0,v=n-i;var e;if(t==-1?e=y.substring(n,n+r.length):e=y.substring(n,t+this.Match_MaxBits),r==e)y=y.substring(0,n)+this.diff_text2(E[l].diffs)+y.substring(n+r.length);else{var o=this.diff_main(r,e,!1);if(r.length>this.Match_MaxBits&&this.diff_levenshtein(o)/r.length>this.Patch_DeleteThreshold)s[l]=!1;else{this.diff_cleanupSemanticLossless(o);for(var a=0,c,u=0;ul[0][1].length){var i=y-l[0][1].length;l[0][1]=w.substring(l[0][1].length)+l[0][1],s.start1-=i,s.start2-=i,s.length1+=i,s.length2+=i}if(s=E[E.length-1],l=s.diffs,l.length==0||l[l.length-1][0]!=L)l.push(new j.Diff(L,w)),s.length1+=y,s.length2+=y;else if(y>l[l.length-1][1].length){var i=y-l[l.length-1][1].length;l[l.length-1][1]+=w.substring(0,i),s.length1+=i,s.length2+=i}return w},j.prototype.patch_splitMax=function(E){for(var y=this.Match_MaxBits,w=0;w2*y?(r.length1+=e.length,s+=e.length,n=!1,r.diffs.push(new j.Diff(t,e)),v.diffs.shift()):(e=e.substring(0,y-r.length1-this.Patch_Margin),r.length1+=e.length,s+=e.length,t===L?(r.length2+=e.length,l+=e.length):n=!1,r.diffs.push(new j.Diff(t,e)),e==v.diffs[0][1]?v.diffs.shift():v.diffs[0][1]=v.diffs[0][1].substring(e.length))}i=this.diff_text2(r.diffs),i=i.substring(i.length-this.Patch_Margin);var o=this.diff_text1(v.diffs).substring(0,this.Patch_Margin);o!==""&&(r.length1+=o.length,r.length2+=o.length,r.diffs.length!==0&&r.diffs[r.diffs.length-1][0]===L?r.diffs[r.diffs.length-1][1]+=o:r.diffs.push(new j.Diff(L,o))),n||E.splice(++w,0,r)}}},j.prototype.patch_toText=function(E){for(var y=[],w=0;w{var _="Expected a function",L="__lodash_hash_undefined__",E=1/0,y="[object Function]",w="[object GeneratorFunction]",v="[object Symbol]",s=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,l=/^\w*$/,i=/^\./,r=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/[\\^$.*+?()[\]{}|]/g,t=/\\(\\)?/g,e=/^\[object .+?Constructor\]$/,o=typeof J.g=="object"&&J.g&&J.g.Object===Object&&J.g,a=typeof self=="object"&&self&&self.Object===Object&&self,c=o||a||Function("return this")();function u(P,Q){return P==null?void 0:P[Q]}function p(P){var Q=!1;if(P!=null&&typeof P.toString!="function")try{Q=!!(P+"")}catch(re){}return Q}var m=Array.prototype,$=Function.prototype,C=Object.prototype,g=c["__core-js_shared__"],M=function(){var P=/[^.]+$/.exec(g&&g.keys&&g.keys.IE_PROTO||"");return P?"Symbol(src)_1."+P:""}(),A=$.toString,S=C.hasOwnProperty,k=C.toString,d=RegExp("^"+A.call(S).replace(n,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),h=c.Symbol,f=m.splice,b=Ie(c,"Map"),T=Ie(Object,"create"),x=h?h.prototype:void 0,R=x?x.toString:void 0;function I(P){var Q=-1,re=P?P.length:0;for(this.clear();++Q-1}function Y(P,Q){var re=this.__data__,me=fe(re,P);return me<0?re.push([P,Q]):re[me][1]=Q,this}H.prototype.clear=U,H.prototype.delete=K,H.prototype.get=q,H.prototype.has=ee,H.prototype.set=Y;function Z(P){var Q=-1,re=P?P.length:0;for(this.clear();++Q{pe=J.nmd(pe);var _=200,L="__lodash_hash_undefined__",E=1,y=2,w=9007199254740991,v="[object Arguments]",s="[object Array]",l="[object AsyncFunction]",i="[object Boolean]",r="[object Date]",n="[object Error]",t="[object Function]",e="[object GeneratorFunction]",o="[object Map]",a="[object Number]",c="[object Null]",u="[object Object]",p="[object Promise]",m="[object Proxy]",$="[object RegExp]",C="[object Set]",g="[object String]",M="[object Symbol]",A="[object Undefined]",S="[object WeakMap]",k="[object ArrayBuffer]",d="[object DataView]",h="[object Float32Array]",f="[object Float64Array]",b="[object Int8Array]",T="[object Int16Array]",x="[object Int32Array]",R="[object Uint8Array]",I="[object Uint8ClampedArray]",N="[object Uint16Array]",D="[object Uint32Array]",B=/[\\^$.*+?()[\]{}|]/g,F=/^\[object .+?Constructor\]$/,z=/^(?:0|[1-9]\d*)$/,H={};H[h]=H[f]=H[b]=H[T]=H[x]=H[R]=H[I]=H[N]=H[D]=!0,H[v]=H[s]=H[k]=H[i]=H[d]=H[r]=H[n]=H[t]=H[o]=H[a]=H[u]=H[$]=H[C]=H[g]=H[S]=!1;var U=typeof J.g=="object"&&J.g&&J.g.Object===Object&&J.g,K=typeof self=="object"&&self&&self.Object===Object&&self,q=U||K||Function("return this")(),ee=j&&!j.nodeType&&j,Y=ee&&!0&&pe&&!pe.nodeType&&pe,Z=Y&&Y.exports===ee,X=Z&&U.process,ae=function(){try{return X&&X.binding&&X.binding("util")}catch(O){}}(),ce=ae&&ae.isTypedArray;function de(O,W){for(var V=-1,ne=O==null?0:O.length,$e=0,le=[];++V-1}function Wt(O,W){var V=this.__data__,ne=rt(V,O);return ne<0?(++this.size,V.push([O,W])):V[ne][1]=W,this}Pe.prototype.clear=Dt,Pe.prototype.delete=Ot,Pe.prototype.get=Nt,Pe.prototype.has=Ft,Pe.prototype.set=Wt;function Ke(O){var W=-1,V=O==null?0:O.length;for(this.clear();++WLe))return!1;var Se=le.get(O);if(Se&&le.get(W))return Se==W;var xe=-1,We=!0,Ee=V&y?new it:void 0;for(le.set(O,W),le.set(W,O);++xe-1&&O%1==0&&O-1&&O%1==0&&O<=w}function $t(O){var W=typeof O;return O!=null&&(W=="object"||W=="function")}function nt(O){return O!=null&&typeof O=="object"}var St=ce?Re(ce):tn;function vn(O){return gn(O)?Xt(O):nn(O)}function mn(){return[]}function yn(){return!1}pe.exports=pn}}]); + +//# sourceMappingURL=vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js.3a2375c7.chunk.js.map \ No newline at end of file diff --git a/admin/custom/static/js/vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js.3a2375c7.chunk.js.map b/admin/custom/static/js/vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js.3a2375c7.chunk.js.map new file mode 100644 index 0000000..4477c6e --- /dev/null +++ b/admin/custom/static/js/vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js.3a2375c7.chunk.js.map @@ -0,0 +1 @@ +{"version":3,"file":"static/js/vendors-node_modules_iobroker_json-config_node_modules_react-ace_lib_index_js.3a2375c7.chunk.js","mappings":"6/BAAA,cAEA,UACA,UACMA,EAAU,EAAQ,IAAgB,EACxC,UAMMC,KAAM,kBAAc,EAkE1B,cAAsC,OA2FpC,WAAYC,EAAwB,CAClC,QAAK,UAACA,CAAK,GAAC,KACZ,sBAAa,QAAQ,SAAAC,EAAM,CACzB,EAAKA,CAAM,EAAI,EAAKA,CAAM,EAAE,KAAK,CAAI,CACvC,CAAC,EACD,EAAK,SAAW,W,CAClB,CACO,8BAAP,SAAkBC,EAAiB,CAEjC,QADIC,EAASD,GAAQA,EAAK,WACnBC,GAAQ,CACb,GAAIA,EAAO,SAAS,IAAM,sBACxB,MAAO,GAETA,EAASA,EAAO,UAClB,CACA,MAAO,EACT,EACO,8BAAP,sBACQ,EAqBF,KAAK,MApBPC,EAAS,YACTC,EAAY,eACZC,EAAU,aACVC,EAAI,OACJC,EAAK,QACLC,EAAK,QACLC,EAAQ,WACRC,EAAU,aACVC,EAAK,QACLC,EAAY,eACZC,EAAU,aACVC,EAAW,cACXC,EAAe,kBACf,iBAAAC,EAAe,IAAH,OAAG,CAAC,EAAG,EAAG,EAAG,CAAC,EAAC,EAC3BC,EAAe,kBACfC,EAAM,SACNC,EAAQ,WACRC,EAAW,cACXC,EAAO,UACPC,EAAW,cAGb,KAAK,OAASxB,EAAI,KAAK,KAAK,SAAS,EAEjCM,GACFA,EAAaN,CAAG,EAIlB,QADMyB,EAAc,OAAO,K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,CAAK,GAAK00D,GAAe,KAAK10D,EAAO,QAAQ,GAC/D,CAACs7D,GAAqB,KAAKt7D,EAAO,QAAQ,CAC9C,EAyBIs3D,GAAU,MAAM,QA2BpB,SAAS2J,GAAYjhE,EAAO,CAC1B,OAAOA,GAAS,MAAQq/D,GAASr/D,EAAM,MAAM,GAAK,CAACk3D,GAAWl3D,CAAK,CACrE,CAmBA,IAAIq9D,GAAW5B,IAAkByF,GA8BjC,SAAShiE,GAAQc,EAAOwrC,EAAO,CAC7B,OAAOwyB,GAAYh+D,EAAOwrC,CAAK,CACjC,CAmBA,SAAS0rB,GAAWl3D,EAAO,CACzB,GAAI,CAACg3D,GAASh3D,CAAK,EACjB,MAAO,GAIT,IAAImL,EAAM0yD,GAAW79D,CAAK,EAC1B,OAAOmL,GAAOioD,GAAWjoD,GAAOkoD,GAAUloD,GAAOitD,GAAYjtD,GAAO0tD,CACtE,CA4BA,SAASwG,GAASr/D,EAAO,CACvB,OAAO,OAAOA,GAAS,UACrBA,EAAQ,IAAMA,EAAQ,GAAK,GAAKA,GAASi4D,CAC7C,CA2BA,SAASjB,GAASh3D,EAAO,CACvB,IAAIoC,EAAO,OAAOpC,EAClB,OAAOA,GAAS,OAASoC,GAAQ,UAAYA,GAAQ,WACvD,CA0BA,SAASy1D,GAAa73D,EAAO,CAC3B,OAAOA,GAAS,MAAQ,OAAOA,GAAS,QAC1C,CAmBA,IAAIu9D,GAAelD,GAAmBO,GAAUP,EAAgB,EAAI+E,GA8BpE,SAASpsD,GAAKihD,EAAQ,CACpB,OAAOgN,GAAYhN,CAAM,EAAI8I,GAAc9I,CAAM,EAAIqL,GAASrL,CAAM,CACtE,CAoBA,SAAS6M,IAAY,CACnB,MAAO,CAAC,CACV,CAeA,SAASI,IAAY,CACnB,MAAO,EACT,CAEAr7D,GAAO,QAAU3G,E","sources":["../node_modules/@iobroker/json-config/node_modules/react-ace/src/ace.tsx","../node_modules/@iobroker/json-config/node_modules/react-ace/src/diff.tsx","../node_modules/@iobroker/json-config/node_modules/react-ace/src/editorOptions.ts","../node_modules/@iobroker/json-config/node_modules/react-ace/src/index.ts","../node_modules/@iobroker/json-config/node_modules/react-ace/src/split.tsx","../node_modules/ace-builds/src-noconflict/ace.js","../node_modules/ace-builds/src-noconflict/ext-split.js","../node_modules/diff-match-patch/index.js","../node_modules/lodash.get/index.js","../node_modules/lodash.isequal/index.js"],"sourcesContent":["import { Ace, Range } from \"ace-builds\";\nimport * as AceBuilds from \"ace-builds\";\nimport * as PropTypes from \"prop-types\";\nimport * as React from \"react\";\nconst isEqual = require(\"lodash.isequal\");\nimport {\n debounce,\n editorEvents,\n editorOptions,\n getAceInstance\n} from \"./editorOptions\";\nconst ace = getAceInstance();\n\nimport {\n IAceEditor,\n IAceOptions,\n ICommand,\n IEditorProps,\n IMarker\n} from \"./types\";\n/**\n * See https://github.com/ajaxorg/ace/wiki/Configuring-Ace\n */\n\nexport interface IAceEditorProps {\n name?: string;\n style?: React.CSSProperties;\n /** For available modes see https://github.com/thlorenz/brace/tree/master/mode */\n mode?: string | object;\n /** For available themes see https://github.com/thlorenz/brace/tree/master/theme */\n theme?: string;\n height?: string;\n width?: string;\n className?: string;\n fontSize?: number | string;\n lineHeight?: number | string;\n showGutter?: boolean;\n showPrintMargin?: boolean;\n highlightActiveLine?: boolean;\n focus?: boolean;\n cursorStart?: number;\n wrapEnabled?: boolean;\n readOnly?: boolean;\n minLines?: number;\n maxLines?: number;\n navigateToFileEnd?: boolean;\n debounceChangePeriod?: number;\n enableBasicAutocompletion?: boolean | string[];\n enableLiveAutocompletion?: boolean | string[];\n enableMobileMenu?: boolean;\n tabSize?: number;\n value?: string;\n placeholder?: string;\n defaultValue?: string;\n scrollMargin?: number[];\n enableSnippets?: boolean;\n onSelectionChange?: (value: any, event?: any) => void;\n onCursorChange?: (value: any, event?: any) => void;\n onInput?: (event?: any) => void;\n onLoad?: (editor: Ace.Editor) => void;\n onValidate?: (annotations: Ace.Annotation[]) => void;\n onBeforeLoad?: (ace: typeof AceBuilds) => void;\n onChange?: (value: string, event?: any) => void;\n onSelection?: (selectedText: string, event?: any) => void;\n onCopy?: (value: string) => void;\n onPaste?: (value: string) => void;\n onFocus?: (event: any, editor?: Ace.Editor) => void;\n onBlur?: (event: any, editor?: Ace.Editor) => void;\n onScroll?: (editor: IEditorProps) => void;\n editorProps?: IEditorProps;\n setOptions?: IAceOptions;\n keyboardHandler?: string;\n commands?: ICommand[];\n annotations?: Ace.Annotation[];\n markers?: IMarker[];\n}\n\nexport default class ReactAce extends React.Component {\n public static propTypes: PropTypes.ValidationMap = {\n mode: PropTypes.oneOfType([PropTypes.string, PropTypes.object]),\n focus: PropTypes.bool,\n theme: PropTypes.string,\n name: PropTypes.string,\n className: PropTypes.string,\n height: PropTypes.string,\n width: PropTypes.string,\n fontSize: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),\n lineHeight: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),\n showGutter: PropTypes.bool,\n onChange: PropTypes.func,\n onCopy: PropTypes.func,\n onPaste: PropTypes.func,\n onFocus: PropTypes.func,\n onInput: PropTypes.func,\n onBlur: PropTypes.func,\n onScroll: PropTypes.func,\n value: PropTypes.string,\n defaultValue: PropTypes.string,\n onLoad: PropTypes.func,\n onSelectionChange: PropTypes.func,\n onCursorChange: PropTypes.func,\n onBeforeLoad: PropTypes.func,\n onValidate: PropTypes.func,\n minLines: PropTypes.number,\n maxLines: PropTypes.number,\n readOnly: PropTypes.bool,\n highlightActiveLine: PropTypes.bool,\n tabSize: PropTypes.number,\n showPrintMargin: PropTypes.bool,\n cursorStart: PropTypes.number,\n debounceChangePeriod: PropTypes.number,\n editorProps: PropTypes.object,\n setOptions: PropTypes.object,\n style: PropTypes.object,\n scrollMargin: PropTypes.array,\n annotations: PropTypes.array,\n markers: PropTypes.array,\n keyboardHandler: PropTypes.string,\n wrapEnabled: PropTypes.bool,\n enableSnippets: PropTypes.bool,\n enableBasicAutocompletion: PropTypes.oneOfType([\n PropTypes.bool,\n PropTypes.array\n ]),\n enableLiveAutocompletion: PropTypes.oneOfType([\n PropTypes.bool,\n PropTypes.array\n ]),\n navigateToFileEnd: PropTypes.bool,\n commands: PropTypes.array,\n placeholder: PropTypes.string\n };\n public static defaultProps: Partial = {\n name: \"ace-editor\",\n focus: false,\n mode: \"\",\n theme: \"\",\n height: \"500px\",\n width: \"500px\",\n fontSize: 12,\n enableSnippets: false,\n showGutter: true,\n onChange: null,\n onPaste: null,\n onLoad: null,\n onScroll: null,\n minLines: null,\n maxLines: null,\n readOnly: false,\n highlightActiveLine: true,\n showPrintMargin: true,\n tabSize: 4,\n cursorStart: 1,\n editorProps: {},\n style: {},\n scrollMargin: [0, 0, 0, 0],\n setOptions: {},\n wrapEnabled: false,\n enableBasicAutocompletion: false,\n enableLiveAutocompletion: false,\n placeholder: null,\n navigateToFileEnd: true\n };\n public editor: IAceEditor;\n public refEditor: HTMLElement;\n public debounce: (fn: any, delay: number) => (...args: any) => void;\n // [index: string]: any;\n public silent: boolean;\n constructor(props: IAceEditorProps) {\n super(props);\n editorEvents.forEach(method => {\n this[method] = this[method].bind(this);\n });\n this.debounce = debounce;\n }\n public isInShadow(node: HTMLElement): boolean {\n let parent = node && node.parentNode;\n while (parent) {\n if (parent.toString() === \"[object ShadowRoot]\") {\n return true;\n }\n parent = parent.parentNode;\n }\n return false;\n }\n public componentDidMount() {\n const {\n className,\n onBeforeLoad,\n onValidate,\n mode,\n focus,\n theme,\n fontSize,\n lineHeight,\n value,\n defaultValue,\n showGutter,\n wrapEnabled,\n showPrintMargin,\n scrollMargin = [0, 0, 0, 0],\n keyboardHandler,\n onLoad,\n commands,\n annotations,\n markers,\n placeholder\n } = this.props;\n\n this.editor = ace.edit(this.refEditor) as IAceEditor;\n\n if (onBeforeLoad) {\n onBeforeLoad(ace);\n }\n\n const editorProps = Object.keys(this.props.editorProps);\n for (let i = 0; i < editorProps.length; i++) {\n this.editor[editorProps[i]] = this.props.editorProps[editorProps[i]];\n }\n if (this.props.debounceChangePeriod) {\n this.onChange = this.debounce(\n this.onChange,\n this.props.debounceChangePeriod\n );\n }\n this.editor.renderer.setScrollMargin(\n scrollMargin[0],\n scrollMargin[1],\n scrollMargin[2],\n scrollMargin[3]\n );\n if (this.isInShadow(this.refEditor)) {\n this.editor.renderer.attachToShadowRoot();\n }\n this.editor\n .getSession()\n .setMode(\n typeof mode === \"string\" ? `ace/mode/${mode}` : (mode as Ace.SyntaxMode)\n );\n if (theme && theme !== \"\") this.editor.setTheme(`ace/theme/${theme}`);\n this.editor.setFontSize(\n typeof fontSize === \"number\" ? `${fontSize}px` : fontSize\n );\n if (lineHeight) {\n this.editor.container.style.lineHeight =\n typeof lineHeight === \"number\" ? `${lineHeight}px` : `${lineHeight}`;\n this.editor.renderer.updateFontSize();\n }\n this.editor\n .getSession()\n .setValue(!defaultValue ? value || \"\" : defaultValue);\n\n if (this.props.navigateToFileEnd) {\n this.editor.navigateFileEnd();\n }\n this.editor.renderer.setShowGutter(showGutter);\n this.editor.getSession().setUseWrapMode(wrapEnabled);\n this.editor.setShowPrintMargin(showPrintMargin);\n this.editor.on(\"focus\", this.onFocus);\n this.editor.on(\"blur\", this.onBlur);\n this.editor.on(\"copy\", this.onCopy);\n this.editor.on(\"paste\", this.onPaste);\n this.editor.on(\"change\", this.onChange);\n this.editor.on(\"input\", this.onInput);\n if (placeholder) {\n this.updatePlaceholder();\n }\n this.editor\n .getSession()\n .selection.on(\"changeSelection\", this.onSelectionChange);\n this.editor.getSession().selection.on(\"changeCursor\", this.onCursorChange);\n if (onValidate) {\n // @ts-ignore types don't include\n this.editor.getSession().on(\"changeAnnotation\", () => {\n // tslint:disable-next-line:no-shadowed-variable\n const annotations = this.editor.getSession().getAnnotations();\n this.props.onValidate(annotations);\n });\n }\n this.editor.session.on(\"changeScrollTop\", this.onScroll);\n this.editor.getSession().setAnnotations(annotations || []);\n if (markers && markers.length > 0) {\n this.handleMarkers(markers);\n }\n\n // get a list of possible options to avoid 'misspelled option errors'\n const availableOptions = this.editor.$options;\n editorOptions.forEach(option => {\n if (availableOptions.hasOwnProperty(option)) {\n // @ts-ignore\n this.editor.setOption(option, this.props[option]);\n } else if (this.props[option]) {\n console.warn(\n `ReactAce: editor option ${option} was activated but not found. Did you need to import a related tool or did you possibly mispell the option?`\n );\n }\n });\n\n this.handleOptions(this.props);\n\n if (Array.isArray(commands)) {\n commands.forEach(command => {\n if (typeof command.exec === \"string\") {\n (this.editor.commands as any).bindKey(command.bindKey, command.exec);\n } else {\n (this.editor.commands as any).addCommand(command);\n }\n });\n }\n\n if (keyboardHandler) {\n this.editor.setKeyboardHandler(\"ace/keyboard/\" + keyboardHandler);\n }\n\n if (className) {\n this.refEditor.className += \" \" + className;\n }\n\n if (onLoad) {\n onLoad(this.editor);\n }\n\n this.editor.resize();\n\n if (focus) {\n this.editor.focus();\n }\n }\n\n public componentDidUpdate(prevProps: IAceEditorProps) {\n const oldProps = prevProps;\n const nextProps = this.props;\n\n for (let i = 0; i < editorOptions.length; i++) {\n const option = editorOptions[i];\n if (nextProps[option] !== oldProps[option]) {\n // @ts-ignore\n this.editor.setOption(option, nextProps[option]);\n }\n }\n\n if (nextProps.className !== oldProps.className) {\n const appliedClasses = this.refEditor.className;\n const appliedClassesArray = appliedClasses.trim().split(\" \");\n const oldClassesArray = oldProps.className.trim().split(\" \");\n oldClassesArray.forEach(oldClass => {\n const index = appliedClassesArray.indexOf(oldClass);\n appliedClassesArray.splice(index, 1);\n });\n this.refEditor.className =\n \" \" + nextProps.className + \" \" + appliedClassesArray.join(\" \");\n }\n\n // First process editor value, as it may create a new session (see issue #300)\n const valueChanged =\n this.editor &&\n nextProps.value != null &&\n this.editor.getValue() !== nextProps.value;\n\n if (valueChanged) {\n // editor.setValue is a synchronous function call, change event is emitted before setValue return.\n this.silent = true;\n const pos = this.editor.session.selection.toJSON();\n this.editor.setValue(nextProps.value, nextProps.cursorStart);\n this.editor.session.selection.fromJSON(pos);\n this.silent = false;\n }\n\n if (nextProps.placeholder !== oldProps.placeholder) {\n this.updatePlaceholder();\n }\n if (nextProps.mode !== oldProps.mode) {\n this.editor\n .getSession()\n .setMode(\n typeof nextProps.mode === \"string\"\n ? `ace/mode/${nextProps.mode}`\n : (nextProps.mode as Ace.SyntaxMode)\n );\n }\n if (nextProps.theme !== oldProps.theme) {\n this.editor.setTheme(\"ace/theme/\" + nextProps.theme);\n }\n if (nextProps.keyboardHandler !== oldProps.keyboardHandler) {\n if (nextProps.keyboardHandler) {\n this.editor.setKeyboardHandler(\n \"ace/keyboard/\" + nextProps.keyboardHandler\n );\n } else {\n this.editor.setKeyboardHandler(null);\n }\n }\n if (nextProps.fontSize !== oldProps.fontSize) {\n this.editor.setFontSize(\n typeof nextProps.fontSize === \"number\"\n ? `${nextProps.fontSize}px`\n : nextProps.fontSize\n );\n }\n if (nextProps.lineHeight !== oldProps.lineHeight) {\n this.editor.container.style.lineHeight =\n typeof nextProps.lineHeight === \"number\"\n ? `${nextProps.lineHeight}px`\n : nextProps.lineHeight;\n this.editor.renderer.updateFontSize();\n }\n if (nextProps.wrapEnabled !== oldProps.wrapEnabled) {\n this.editor.getSession().setUseWrapMode(nextProps.wrapEnabled);\n }\n if (nextProps.showPrintMargin !== oldProps.showPrintMargin) {\n this.editor.setShowPrintMargin(nextProps.showPrintMargin);\n }\n if (nextProps.showGutter !== oldProps.showGutter) {\n this.editor.renderer.setShowGutter(nextProps.showGutter);\n }\n if (!isEqual(nextProps.setOptions, oldProps.setOptions)) {\n this.handleOptions(nextProps);\n }\n // if the value or annotations changed, set the annotations\n // changing the value may create create a new session which will require annotations to be re-set\n if (valueChanged || !isEqual(nextProps.annotations, oldProps.annotations)) {\n this.editor.getSession().setAnnotations(nextProps.annotations || []);\n }\n if (\n !isEqual(nextProps.markers, oldProps.markers) &&\n Array.isArray(nextProps.markers)\n ) {\n this.handleMarkers(nextProps.markers);\n }\n\n // this doesn't look like it works at all....\n if (!isEqual(nextProps.scrollMargin, oldProps.scrollMargin)) {\n this.handleScrollMargins(nextProps.scrollMargin);\n }\n\n if (\n prevProps.height !== this.props.height ||\n prevProps.width !== this.props.width\n ) {\n this.editor.resize();\n }\n if (this.props.focus && !prevProps.focus) {\n this.editor.focus();\n }\n }\n\n public handleScrollMargins(margins = [0, 0, 0, 0]) {\n this.editor.renderer.setScrollMargin(\n margins[0],\n margins[1],\n margins[2],\n margins[3]\n );\n }\n\n public componentWillUnmount() {\n if (this.editor) {\n this.editor.destroy();\n this.editor = null;\n }\n }\n\n public onChange(event: any) {\n if (this.editor && this.props.onChange && !this.silent) {\n const value = this.editor.getValue();\n this.props.onChange(value, event);\n }\n }\n\n public onSelectionChange(event: any) {\n if (this.props.onSelectionChange) {\n const value = this.editor.getSelection();\n this.props.onSelectionChange(value, event);\n }\n }\n public onCursorChange(event: any) {\n if (this.props.onCursorChange) {\n const value = this.editor.getSelection();\n this.props.onCursorChange(value, event);\n }\n }\n public onInput(event?: any) {\n if (this.props.onInput) {\n this.props.onInput(event);\n }\n if (this.props.placeholder) {\n this.updatePlaceholder();\n }\n }\n public onFocus(event: any) {\n if (this.props.onFocus) {\n this.props.onFocus(event, this.editor);\n }\n }\n\n public onBlur(event: any) {\n if (this.props.onBlur) {\n this.props.onBlur(event, this.editor);\n }\n }\n\n public onCopy({ text }: { text: string }) {\n if (this.props.onCopy) {\n this.props.onCopy(text);\n }\n }\n\n public onPaste({ text }: { text: string }) {\n if (this.props.onPaste) {\n this.props.onPaste(text);\n }\n }\n\n public onScroll() {\n if (this.props.onScroll) {\n this.props.onScroll(this.editor);\n }\n }\n\n public handleOptions(props: IAceEditorProps) {\n const setOptions = Object.keys(props.setOptions);\n for (let y = 0; y < setOptions.length; y++) {\n // @ts-ignore\n this.editor.setOption(setOptions[y], props.setOptions[setOptions[y]]);\n }\n }\n\n public handleMarkers(markers: IMarker[]) {\n // remove foreground markers\n let currentMarkers = this.editor.getSession().getMarkers(true);\n for (const i in currentMarkers) {\n if (currentMarkers.hasOwnProperty(i)) {\n this.editor.getSession().removeMarker(currentMarkers[i].id);\n }\n }\n // remove background markers except active line marker and selected word marker\n currentMarkers = this.editor.getSession().getMarkers(false);\n for (const i in currentMarkers) {\n if (\n currentMarkers.hasOwnProperty(i) &&\n currentMarkers[i].clazz !== \"ace_active-line\" &&\n currentMarkers[i].clazz !== \"ace_selected-word\"\n ) {\n this.editor.getSession().removeMarker(currentMarkers[i].id);\n }\n }\n // add new markers\n markers.forEach(\n ({\n startRow,\n startCol,\n endRow,\n endCol,\n className,\n type,\n inFront = false\n }) => {\n const range = new Range(startRow, startCol, endRow, endCol);\n this.editor.getSession().addMarker(range, className, type, inFront);\n }\n );\n }\n\n public updatePlaceholder() {\n // Adapted from https://stackoverflow.com/questions/26695708/how-can-i-add-placeholder-text-when-the-editor-is-empty\n\n const editor = this.editor;\n const { placeholder } = this.props;\n\n const showPlaceholder = !editor.session.getValue().length;\n let node = editor.renderer.placeholderNode;\n\n if (!showPlaceholder && node) {\n editor.renderer.scroller.removeChild(editor.renderer.placeholderNode);\n editor.renderer.placeholderNode = null;\n } else if (showPlaceholder && !node) {\n node = editor.renderer.placeholderNode = document.createElement(\"div\");\n node.textContent = placeholder || \"\";\n node.className = \"ace_comment ace_placeholder\";\n node.style.padding = \"0 9px\";\n node.style.position = \"absolute\";\n node.style.zIndex = \"3\";\n editor.renderer.scroller.appendChild(node);\n } else if (showPlaceholder && node) {\n node.textContent = placeholder;\n }\n }\n\n public updateRef(item: HTMLElement) {\n this.refEditor = item;\n }\n\n public render() {\n const { name, width, height, style } = this.props;\n const divStyle = { width, height, ...style };\n return
;\n }\n}\n","import * as PropTypes from \"prop-types\";\nimport * as React from \"react\";\nimport SplitEditor from \"./split\";\nconst DiffMatchPatch = require(\"diff-match-patch\");\nimport { IEditorProps } from \"./types\";\n\nexport interface IDiffEditorProps {\n cursorStart?: number;\n editorProps?: object;\n enableBasicAutocompletion?: boolean | string[];\n enableLiveAutocompletion?: boolean | string[];\n focus?: boolean;\n fontSize?: number;\n height?: string;\n highlightActiveLine?: boolean;\n maxLines?: number;\n minLines?: number;\n mode?: string;\n name?: string;\n className?: string;\n onLoad?: (editor: IEditorProps) => void;\n onChange?: (value: string[], event?: any) => void;\n onPaste?: (value: string) => void;\n onScroll?: (editor: IEditorProps) => void;\n orientation?: string;\n readOnly?: boolean;\n scrollMargin?: number[];\n setOptions?: object;\n showGutter?: boolean;\n showPrintMargin?: boolean;\n splits?: number;\n style?: object;\n tabSize?: number;\n theme?: string;\n value?: string[];\n width?: string;\n wrapEnabled?: boolean;\n}\n\nexport interface IDiffEditorState {\n value: string[];\n}\n\nexport default class DiffComponent extends React.Component<\n IDiffEditorProps,\n IDiffEditorState\n> {\n public static propTypes: PropTypes.ValidationMap = {\n cursorStart: PropTypes.number,\n editorProps: PropTypes.object,\n enableBasicAutocompletion: PropTypes.bool,\n enableLiveAutocompletion: PropTypes.bool,\n focus: PropTypes.bool,\n fontSize: PropTypes.number,\n height: PropTypes.string,\n highlightActiveLine: PropTypes.bool,\n maxLines: PropTypes.number,\n minLines: PropTypes.number,\n mode: PropTypes.string,\n name: PropTypes.string,\n className: PropTypes.string,\n onLoad: PropTypes.func,\n onPaste: PropTypes.func,\n onScroll: PropTypes.func,\n onChange: PropTypes.func,\n orientation: PropTypes.string,\n readOnly: PropTypes.bool,\n scrollMargin: PropTypes.array,\n setOptions: PropTypes.object,\n showGutter: PropTypes.bool,\n showPrintMargin: PropTypes.bool,\n splits: PropTypes.number,\n style: PropTypes.object,\n tabSize: PropTypes.number,\n theme: PropTypes.string,\n value: PropTypes.array,\n width: PropTypes.string,\n wrapEnabled: PropTypes.bool\n };\n\n public static defaultProps: Partial = {\n cursorStart: 1,\n editorProps: {},\n enableBasicAutocompletion: false,\n enableLiveAutocompletion: false,\n focus: false,\n fontSize: 12,\n height: \"500px\",\n highlightActiveLine: true,\n maxLines: null,\n minLines: null,\n mode: \"\",\n name: \"ace-editor\",\n onLoad: null,\n onScroll: null,\n onPaste: null,\n onChange: null,\n orientation: \"beside\",\n readOnly: false,\n scrollMargin: [0, 0, 0, 0],\n setOptions: {},\n showGutter: true,\n showPrintMargin: true,\n splits: 2,\n style: {},\n tabSize: 4,\n theme: \"github\",\n value: [\"\", \"\"],\n width: \"500px\",\n wrapEnabled: true\n };\n constructor(props: IDiffEditorProps) {\n super(props);\n this.state = {\n value: this.props.value\n };\n this.onChange = this.onChange.bind(this);\n this.diff = this.diff.bind(this);\n }\n\n public componentDidUpdate() {\n const { value } = this.props;\n\n if (value !== this.state.value) {\n this.setState({ value });\n }\n }\n\n public onChange(value: any) {\n this.setState({\n value\n });\n if (this.props.onChange) {\n this.props.onChange(value);\n }\n }\n\n public diff() {\n const dmp = new DiffMatchPatch();\n const lhString = this.state.value[0];\n const rhString = this.state.value[1];\n\n if (lhString.length === 0 && rhString.length === 0) {\n return [];\n }\n\n const diff = dmp.diff_main(lhString, rhString);\n dmp.diff_cleanupSemantic(diff);\n\n const diffedLines = this.generateDiffedLines(diff);\n const codeEditorSettings = this.setCodeMarkers(diffedLines);\n return codeEditorSettings;\n }\n\n public generateDiffedLines(diff: any) {\n const C = {\n DIFF_EQUAL: 0,\n DIFF_DELETE: -1,\n DIFF_INSERT: 1\n };\n\n const diffedLines = {\n left: [] as any[],\n right: [] as any[]\n };\n\n const cursor = {\n left: 1,\n right: 1\n };\n\n diff.forEach((chunk: any) => {\n const chunkType = chunk[0];\n const text = chunk[1];\n let lines = text.split(\"\\n\").length - 1;\n\n // diff-match-patch sometimes returns empty strings at random\n if (text.length === 0) {\n return;\n }\n\n const firstChar = text[0];\n const lastChar = text[text.length - 1];\n let linesToHighlight = 0;\n\n switch (chunkType) {\n case C.DIFF_EQUAL:\n cursor.left += lines;\n cursor.right += lines;\n\n break;\n case C.DIFF_DELETE:\n // If the deletion starts with a newline, push the cursor down to that line\n if (firstChar === \"\\n\") {\n cursor.left++;\n lines--;\n }\n\n linesToHighlight = lines;\n\n // If the deletion does not include a newline, highlight the same line on the right\n if (linesToHighlight === 0) {\n diffedLines.right.push({\n startLine: cursor.right,\n endLine: cursor.right\n });\n }\n\n // If the last character is a newline, we don't want to highlight that line\n if (lastChar === \"\\n\") {\n linesToHighlight -= 1;\n }\n\n diffedLines.left.push({\n startLine: cursor.left,\n endLine: cursor.left + linesToHighlight\n });\n\n cursor.left += lines;\n break;\n case C.DIFF_INSERT:\n // If the insertion starts with a newline, push the cursor down to that line\n if (firstChar === \"\\n\") {\n cursor.right++;\n lines--;\n }\n\n linesToHighlight = lines;\n\n // If the insertion does not include a newline, highlight the same line on the left\n if (linesToHighlight === 0) {\n diffedLines.left.push({\n startLine: cursor.left,\n endLine: cursor.left\n });\n }\n\n // If the last character is a newline, we don't want to highlight that line\n if (lastChar === \"\\n\") {\n linesToHighlight -= 1;\n }\n\n diffedLines.right.push({\n startLine: cursor.right,\n endLine: cursor.right + linesToHighlight\n });\n\n cursor.right += lines;\n break;\n default:\n throw new Error(\"Diff type was not defined.\");\n }\n });\n return diffedLines;\n }\n\n // Receives a collection of line numbers and iterates through them to highlight appropriately\n // Returns an object that tells the render() method how to display the code editors\n public setCodeMarkers(diffedLines: any = { left: [], right: [] }) {\n const codeEditorSettings = [];\n\n const newMarkerSet = {\n left: [] as any[],\n right: [] as any[]\n };\n\n for (let i = 0; i < diffedLines.left.length; i++) {\n const markerObj = {\n startRow: diffedLines.left[i].startLine - 1,\n endRow: diffedLines.left[i].endLine,\n type: \"text\",\n className: \"codeMarker\"\n };\n newMarkerSet.left.push(markerObj);\n }\n\n for (let i = 0; i < diffedLines.right.length; i++) {\n const markerObj = {\n startRow: diffedLines.right[i].startLine - 1,\n endRow: diffedLines.right[i].endLine,\n type: \"text\",\n className: \"codeMarker\"\n };\n newMarkerSet.right.push(markerObj);\n }\n\n codeEditorSettings[0] = newMarkerSet.left;\n codeEditorSettings[1] = newMarkerSet.right;\n\n return codeEditorSettings;\n }\n\n public render() {\n const markers = this.diff();\n return (\n \n );\n }\n}\n","import * as AceBuilds from \"ace-builds\";\n\ntype EditorOption =\n | \"minLines\"\n | \"maxLines\"\n | \"readOnly\"\n | \"highlightActiveLine\"\n | \"tabSize\"\n | \"enableBasicAutocompletion\"\n | \"enableLiveAutocompletion\"\n | \"enableSnippets\";\n\nconst editorOptions: EditorOption[] = [\n \"minLines\",\n \"maxLines\",\n \"readOnly\",\n \"highlightActiveLine\",\n \"tabSize\",\n \"enableBasicAutocompletion\",\n \"enableLiveAutocompletion\",\n \"enableSnippets\"\n];\n\ntype EditorEvent =\n | \"onChange\"\n | \"onFocus\"\n | \"onInput\"\n | \"onBlur\"\n | \"onCopy\"\n | \"onPaste\"\n | \"onSelectionChange\"\n | \"onCursorChange\"\n | \"onScroll\"\n | \"handleOptions\"\n | \"updateRef\";\n\nconst editorEvents: EditorEvent[] = [\n \"onChange\",\n \"onFocus\",\n \"onInput\",\n \"onBlur\",\n \"onCopy\",\n \"onPaste\",\n \"onSelectionChange\",\n \"onCursorChange\",\n \"onScroll\",\n \"handleOptions\",\n \"updateRef\"\n];\n\n// Typescript globals definition to allow us to create a window object during SSR.\ndeclare global {\n namespace NodeJS {\n // tslint:disable-next-line\n interface Global {\n window: any;\n }\n }\n}\nconst getAceInstance = (): typeof AceBuilds => {\n let ace;\n if (typeof window === \"undefined\") {\n // ace-builds just needs some window object to attach ace to.\n // During SSR even just an empty object will work.\n global.window = {} as any;\n ace = require(\"ace-builds\");\n // And it can be discarded immediately afterward to avoid confusing\n // other libraries that might detect SSR the same way we did.\n delete global.window;\n } else if ((window as any).ace) {\n // Fallback for ace.require when vanilla ACE is hosted over a CDN\n ace = (window as any).ace;\n ace.acequire = (window as any).ace.require || (window as any).ace.acequire;\n } else {\n ace = require(\"ace-builds\");\n }\n return ace;\n};\n\nconst debounce = (fn: (...args: any[]) => void, delay: number) => {\n let timer: any = null;\n // tslint:disable-next-line\n return function () {\n const context = this;\n const args = arguments;\n clearTimeout(timer);\n timer = setTimeout(() => {\n fn.apply(context, args);\n }, delay);\n };\n};\nexport { editorOptions, editorEvents, debounce, getAceInstance };\n","import ace, { IAceEditorProps } from \"./ace\";\nimport diff, { IDiffEditorProps, IDiffEditorState } from \"./diff\";\nimport split, { ISplitEditorProps } from \"./split\";\nimport {\n IAceOptions,\n IAnnotation,\n ICommand,\n ICommandBindKey,\n ICommandManager,\n IEditorProps,\n IMarker\n} from \"./types\";\nexport {\n split,\n diff,\n IAceOptions,\n IAceEditorProps,\n IAnnotation,\n ICommand,\n ICommandBindKey,\n ICommandManager,\n IDiffEditorProps,\n IDiffEditorState,\n IEditorProps,\n IMarker,\n ISplitEditorProps\n};\nexport default ace;\n","import {\n debounce,\n editorEvents,\n editorOptions,\n getAceInstance\n} from \"./editorOptions\";\nconst ace = getAceInstance();\nimport { Ace, Range } from \"ace-builds\";\nimport { Split } from \"ace-builds/src-noconflict/ext-split\";\nimport * as PropTypes from \"prop-types\";\nimport * as React from \"react\";\nconst isEqual = require(\"lodash.isequal\");\nconst get = require(\"lodash.get\");\nimport {\n IAceEditor,\n IAceOptions,\n IAnnotation,\n ICommand,\n IEditorProps,\n IMarker\n} from \"./types\";\n\ninterface IAceEditorClass extends IAceEditor {\n [index: string]: any;\n $options?: any;\n}\n\nexport interface ISplitEditorProps {\n [index: string]: any;\n name?: string;\n style?: object;\n /** For available modes see https://github.com/thlorenz/brace/tree/master/mode */\n mode?: string;\n /** For available themes see https://github.com/thlorenz/brace/tree/master/theme */\n theme?: string;\n height?: string;\n width?: string;\n className?: string;\n fontSize?: number | string;\n showGutter?: boolean;\n showPrintMargin?: boolean;\n highlightActiveLine?: boolean;\n focus?: boolean;\n splits: number;\n debounceChangePeriod?: number;\n cursorStart?: number;\n wrapEnabled?: boolean;\n readOnly?: boolean;\n minLines?: number;\n maxLines?: number;\n enableBasicAutocompletion?: boolean | string[];\n enableLiveAutocompletion?: boolean | string[];\n tabSize?: number;\n value?: string[];\n defaultValue?: string[];\n scrollMargin?: number[];\n orientation?: string;\n onSelectionChange?: (value: any, event?: any) => void;\n onCursorChange?: (value: any, event?: any) => void;\n onInput?: (event?: any) => void;\n onLoad?: (editor: IEditorProps) => void;\n onBeforeLoad?: (ace: any) => void;\n onChange?: (value: string[], event?: any) => void;\n onSelection?: (selectedText: string, event?: any) => void;\n onCopy?: (value: string) => void;\n onPaste?: (value: string) => void;\n onFocus?: (value: Event) => void;\n onBlur?: (value: Event) => void;\n onScroll?: (editor: IEditorProps) => void;\n editorProps?: IEditorProps;\n setOptions?: IAceOptions;\n keyboardHandler?: string;\n commands?: ICommand[];\n annotations?: IAnnotation[][];\n markers?: IMarker[][];\n}\n\nexport default class SplitComponent extends React.Component {\n [index: string]: any;\n\n public static propTypes: PropTypes.ValidationMap = {\n className: PropTypes.string,\n debounceChangePeriod: PropTypes.number,\n defaultValue: PropTypes.arrayOf(PropTypes.string),\n focus: PropTypes.bool,\n fontSize: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),\n height: PropTypes.string,\n mode: PropTypes.string,\n name: PropTypes.string,\n onBlur: PropTypes.func,\n onChange: PropTypes.func,\n onCopy: PropTypes.func,\n onFocus: PropTypes.func,\n onInput: PropTypes.func,\n onLoad: PropTypes.func,\n onPaste: PropTypes.func,\n onScroll: PropTypes.func,\n orientation: PropTypes.string,\n showGutter: PropTypes.bool,\n splits: PropTypes.number,\n theme: PropTypes.string,\n value: PropTypes.arrayOf(PropTypes.string),\n width: PropTypes.string,\n onSelectionChange: PropTypes.func,\n onCursorChange: PropTypes.func,\n onBeforeLoad: PropTypes.func,\n minLines: PropTypes.number,\n maxLines: PropTypes.number,\n readOnly: PropTypes.bool,\n highlightActiveLine: PropTypes.bool,\n tabSize: PropTypes.number,\n showPrintMargin: PropTypes.bool,\n cursorStart: PropTypes.number,\n editorProps: PropTypes.object,\n setOptions: PropTypes.object,\n style: PropTypes.object,\n scrollMargin: PropTypes.array,\n annotations: PropTypes.array,\n markers: PropTypes.array,\n keyboardHandler: PropTypes.string,\n wrapEnabled: PropTypes.bool,\n enableBasicAutocompletion: PropTypes.oneOfType([\n PropTypes.bool,\n PropTypes.array\n ]),\n enableLiveAutocompletion: PropTypes.oneOfType([\n PropTypes.bool,\n PropTypes.array\n ]),\n commands: PropTypes.array\n };\n public static defaultProps: Partial = {\n name: \"ace-editor\",\n focus: false,\n orientation: \"beside\",\n splits: 2,\n mode: \"\",\n theme: \"\",\n height: \"500px\",\n width: \"500px\",\n value: [],\n fontSize: 12,\n showGutter: true,\n onChange: null,\n onPaste: null,\n onLoad: null,\n onScroll: null,\n minLines: null,\n maxLines: null,\n readOnly: false,\n highlightActiveLine: true,\n showPrintMargin: true,\n tabSize: 4,\n cursorStart: 1,\n editorProps: {},\n style: {},\n scrollMargin: [0, 0, 0, 0],\n setOptions: {},\n wrapEnabled: false,\n enableBasicAutocompletion: false,\n enableLiveAutocompletion: false\n };\n public editor: IAceEditorClass;\n public refEditor: HTMLElement;\n public silent: boolean;\n public split: IAceEditorClass;\n public splitEditor: IAceEditorClass;\n public debounce: (fn: any, delay: number) => (...args: any) => void;\n constructor(props: ISplitEditorProps) {\n super(props);\n editorEvents.forEach(method => {\n this[method] = this[method].bind(this);\n });\n this.debounce = debounce;\n }\n public isInShadow(node: HTMLElement): boolean {\n let parent = node && node.parentNode;\n while (parent) {\n if (parent.toString() === \"[object ShadowRoot]\") {\n return true;\n }\n parent = parent.parentNode;\n }\n return false;\n }\n public componentDidMount() {\n const {\n className,\n onBeforeLoad,\n mode,\n focus,\n theme,\n fontSize,\n value,\n defaultValue,\n cursorStart,\n showGutter,\n wrapEnabled,\n showPrintMargin,\n scrollMargin = [0, 0, 0, 0],\n keyboardHandler,\n onLoad,\n commands,\n annotations,\n markers,\n splits\n } = this.props;\n\n this.editor = ace.edit(this.refEditor) as IAceEditor;\n if (this.isInShadow(this.refEditor)) {\n this.editor.renderer.attachToShadowRoot();\n }\n this.editor.setTheme(`ace/theme/${theme}`);\n\n if (onBeforeLoad) {\n onBeforeLoad(ace);\n }\n\n const editorProps = Object.keys(this.props.editorProps);\n\n const split = new Split(\n this.editor.container,\n `ace/theme/${theme}`,\n splits\n );\n this.editor.env.split = split;\n\n this.splitEditor = split.getEditor(0);\n this.split = split;\n // in a split scenario we don't want a print margin for the entire application\n this.editor.setShowPrintMargin(false);\n this.editor.renderer.setShowGutter(false);\n // get a list of possible options to avoid 'misspelled option errors'\n const availableOptions = this.splitEditor.$options;\n if (this.props.debounceChangePeriod) {\n this.onChange = this.debounce(\n this.onChange,\n this.props.debounceChangePeriod\n );\n }\n split.forEach((editor: IAceEditorClass, index: number) => {\n for (let i = 0; i < editorProps.length; i++) {\n editor[editorProps[i]] = this.props.editorProps[editorProps[i]];\n }\n const defaultValueForEditor = get(defaultValue, index);\n const valueForEditor = get(value, index, \"\");\n editor.session.setUndoManager(new ace.UndoManager());\n editor.setTheme(`ace/theme/${theme}`);\n editor.renderer.setScrollMargin(\n scrollMargin[0],\n scrollMargin[1],\n scrollMargin[2],\n scrollMargin[3]\n );\n editor.getSession().setMode(`ace/mode/${mode}`);\n editor.setFontSize(fontSize as any);\n editor.renderer.setShowGutter(showGutter);\n editor.getSession().setUseWrapMode(wrapEnabled);\n editor.setShowPrintMargin(showPrintMargin);\n editor.on(\"focus\", this.onFocus);\n editor.on(\"blur\", this.onBlur);\n editor.on(\"input\" as any, this.onInput);\n editor.on(\"copy\", this.onCopy as any);\n editor.on(\"paste\", this.onPaste as any);\n editor.on(\"change\", this.onChange);\n editor\n .getSession()\n .selection.on(\"changeSelection\", this.onSelectionChange);\n editor.getSession().selection.on(\"changeCursor\", this.onCursorChange);\n editor.session.on(\"changeScrollTop\", this.onScroll);\n editor.setValue(\n defaultValueForEditor === undefined\n ? valueForEditor\n : defaultValueForEditor,\n cursorStart\n );\n const newAnnotations = get(annotations, index, []);\n const newMarkers = get(markers, index, []);\n editor.getSession().setAnnotations(newAnnotations);\n if (newMarkers && newMarkers.length > 0) {\n this.handleMarkers(newMarkers, editor);\n }\n\n for (let i = 0; i < editorOptions.length; i++) {\n const option = editorOptions[i];\n if (availableOptions.hasOwnProperty(option)) {\n editor.setOption(option as any, this.props[option]);\n } else if (this.props[option]) {\n console.warn(\n `ReaceAce: editor option ${option} was activated but not found. Did you need to import a related tool or did you possibly mispell the option?`\n );\n }\n }\n this.handleOptions(this.props, editor);\n\n if (Array.isArray(commands)) {\n commands.forEach(command => {\n if (typeof command.exec === \"string\") {\n (editor.commands as any).bindKey(command.bindKey, command.exec);\n } else {\n (editor.commands as any).addCommand(command);\n }\n });\n }\n\n if (keyboardHandler) {\n editor.setKeyboardHandler(\"ace/keyboard/\" + keyboardHandler);\n }\n });\n\n if (className) {\n this.refEditor.className += \" \" + className;\n }\n\n if (focus) {\n this.splitEditor.focus();\n }\n\n const sp = this.editor.env.split;\n sp.setOrientation(\n this.props.orientation === \"below\" ? sp.BELOW : sp.BESIDE\n );\n sp.resize(true);\n if (onLoad) {\n onLoad(sp);\n }\n }\n\n public componentDidUpdate(prevProps: ISplitEditorProps) {\n const oldProps = prevProps;\n const nextProps = this.props;\n\n const split = this.editor.env.split;\n\n if (nextProps.splits !== oldProps.splits) {\n split.setSplits(nextProps.splits);\n }\n\n if (nextProps.orientation !== oldProps.orientation) {\n split.setOrientation(\n nextProps.orientation === \"below\" ? split.BELOW : split.BESIDE\n );\n }\n\n split.forEach((editor: IAceEditorClass, index: number) => {\n if (nextProps.mode !== oldProps.mode) {\n editor.getSession().setMode(\"ace/mode/\" + nextProps.mode);\n }\n if (nextProps.keyboardHandler !== oldProps.keyboardHandler) {\n if (nextProps.keyboardHandler) {\n editor.setKeyboardHandler(\n \"ace/keyboard/\" + nextProps.keyboardHandler\n );\n } else {\n editor.setKeyboardHandler(null);\n }\n }\n if (nextProps.fontSize !== oldProps.fontSize) {\n editor.setFontSize(nextProps.fontSize as any);\n }\n if (nextProps.wrapEnabled !== oldProps.wrapEnabled) {\n editor.getSession().setUseWrapMode(nextProps.wrapEnabled);\n }\n if (nextProps.showPrintMargin !== oldProps.showPrintMargin) {\n editor.setShowPrintMargin(nextProps.showPrintMargin);\n }\n if (nextProps.showGutter !== oldProps.showGutter) {\n editor.renderer.setShowGutter(nextProps.showGutter);\n }\n\n for (let i = 0; i < editorOptions.length; i++) {\n const option = editorOptions[i];\n if (nextProps[option] !== oldProps[option]) {\n editor.setOption(option as any, nextProps[option]);\n }\n }\n if (!isEqual(nextProps.setOptions, oldProps.setOptions)) {\n this.handleOptions(nextProps, editor);\n }\n const nextValue = get(nextProps.value, index, \"\");\n if (editor.getValue() !== nextValue) {\n // editor.setValue is a synchronous function call, change event is emitted before setValue return.\n this.silent = true;\n const pos = (editor.session.selection as any).toJSON();\n editor.setValue(nextValue, nextProps.cursorStart);\n (editor.session.selection as any).fromJSON(pos);\n this.silent = false;\n }\n const newAnnotations = get(nextProps.annotations, index, []);\n const oldAnnotations = get(oldProps.annotations, index, []);\n if (!isEqual(newAnnotations, oldAnnotations)) {\n editor.getSession().setAnnotations(newAnnotations);\n }\n\n const newMarkers = get(nextProps.markers, index, []);\n const oldMarkers = get(oldProps.markers, index, []);\n if (!isEqual(newMarkers, oldMarkers) && Array.isArray(newMarkers)) {\n this.handleMarkers(newMarkers, editor);\n }\n });\n\n if (nextProps.className !== oldProps.className) {\n const appliedClasses = this.refEditor.className;\n const appliedClassesArray = appliedClasses.trim().split(\" \");\n const oldClassesArray = oldProps.className.trim().split(\" \");\n oldClassesArray.forEach(oldClass => {\n const index = appliedClassesArray.indexOf(oldClass);\n appliedClassesArray.splice(index, 1);\n });\n this.refEditor.className =\n \" \" + nextProps.className + \" \" + appliedClassesArray.join(\" \");\n }\n\n if (nextProps.theme !== oldProps.theme) {\n split.setTheme(\"ace/theme/\" + nextProps.theme);\n }\n\n if (nextProps.focus && !oldProps.focus) {\n this.splitEditor.focus();\n }\n if (\n nextProps.height !== this.props.height ||\n nextProps.width !== this.props.width\n ) {\n this.editor.resize();\n }\n }\n\n public componentWillUnmount() {\n this.editor.destroy();\n this.editor = null;\n }\n\n public onChange(event: any) {\n if (this.props.onChange && !this.silent) {\n const value: any = [];\n this.editor.env.split.forEach((editor: IAceEditorClass) => {\n value.push(editor.getValue());\n });\n this.props.onChange(value, event);\n }\n }\n\n public onSelectionChange(event: any) {\n if (this.props.onSelectionChange) {\n const value: any = [];\n this.editor.env.split.forEach((editor: IAceEditorClass) => {\n value.push(editor.getSelection());\n });\n this.props.onSelectionChange(value, event);\n }\n }\n public onCursorChange(event: any) {\n if (this.props.onCursorChange) {\n const value: any = [];\n this.editor.env.split.forEach((editor: IAceEditorClass) => {\n value.push(editor.getSelection());\n });\n this.props.onCursorChange(value, event);\n }\n }\n public onFocus(event: any) {\n if (this.props.onFocus) {\n this.props.onFocus(event);\n }\n }\n\n public onInput(event: any) {\n if (this.props.onInput) {\n this.props.onInput(event);\n }\n }\n\n public onBlur(event: any) {\n if (this.props.onBlur) {\n this.props.onBlur(event);\n }\n }\n\n public onCopy(text: string) {\n if (this.props.onCopy) {\n this.props.onCopy(text);\n }\n }\n\n public onPaste(text: string) {\n if (this.props.onPaste) {\n this.props.onPaste(text);\n }\n }\n\n public onScroll() {\n if (this.props.onScroll) {\n this.props.onScroll(this.editor);\n }\n }\n\n public handleOptions(props: ISplitEditorProps, editor: IAceEditorClass) {\n const setOptions = Object.keys(props.setOptions);\n for (let y = 0; y < setOptions.length; y++) {\n editor.setOption(setOptions[y] as any, props.setOptions[setOptions[y]]);\n }\n }\n\n public handleMarkers(markers: IMarker[], editor: IAceEditorClass) {\n // remove foreground markers\n let currentMarkers = editor.getSession().getMarkers(true);\n for (const i in currentMarkers) {\n if (currentMarkers.hasOwnProperty(i)) {\n editor.getSession().removeMarker(currentMarkers[i].id);\n }\n }\n // remove background markers\n currentMarkers = editor.getSession().getMarkers(false);\n for (const i in currentMarkers) {\n if (currentMarkers.hasOwnProperty(i)) {\n editor.getSession().removeMarker(currentMarkers[i].id);\n }\n }\n // add new markers\n markers.forEach(\n ({\n startRow,\n startCol,\n endRow,\n endCol,\n className,\n type,\n inFront = false\n }) => {\n const range = new Range(startRow, startCol, endRow, endCol);\n editor\n .getSession()\n .addMarker(range as any, className, type as any, inFront);\n }\n );\n }\n\n public updateRef(item: HTMLElement) {\n this.refEditor = item;\n }\n\n public render() {\n const { name, width, height, style } = this.props;\n const divStyle = { width, height, ...style };\n return
;\n }\n}\n","/* ***** BEGIN LICENSE BLOCK *****\n * Distributed under the BSD license:\n *\n * Copyright (c) 2010, Ajax.org B.V.\n * All rights reserved.\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions are met:\n * * Redistributions of source code must retain the above copyright\n * notice, this list of conditions and the following disclaimer.\n * * Redistributions in binary form must reproduce the above copyright\n * notice, this list of conditions and the following disclaimer in the\n * documentation and/or other materials provided with the distribution.\n * * Neither the name of Ajax.org B.V. nor the\n * names of its contributors may be used to endorse or promote products\n * derived from this software without specific prior written permission.\n *\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND\n * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\n * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\n * DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY\n * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES\n * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;\n * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND\n * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS\n * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n *\n * ***** END LICENSE BLOCK ***** */\n\n/**\n * Define a module along with a payload\n * @param module a name for the payload\n * @param payload a function to call with (require, exports, module) params\n */\n\n(function() {\n\nvar ACE_NAMESPACE = \"ace\";\n\nvar global = (function() { return this; })();\nif (!global && typeof window != \"undefined\") global = window; // strict mode\n\n\nif (!ACE_NAMESPACE && typeof requirejs !== \"undefined\")\n return;\n\n\nvar define = function(module, deps, payload) {\n if (typeof module !== \"string\") {\n if (define.original)\n define.original.apply(this, arguments);\n else {\n console.error(\"dropping module because define wasn\\'t a string.\");\n console.trace();\n }\n return;\n }\n if (arguments.length == 2)\n payload = deps;\n if (!define.modules[module]) {\n define.payloads[module] = payload;\n define.modules[module] = null;\n }\n};\n\ndefine.modules = {};\ndefine.payloads = {};\n\n/**\n * Get at functionality define()ed using the function above\n */\nvar _require = function(parentId, module, callback) {\n if (typeof module === \"string\") {\n var payload = lookup(parentId, module);\n if (payload != undefined) {\n callback && callback();\n return payload;\n }\n } else if (Object.prototype.toString.call(module) === \"[object Array]\") {\n var params = [];\n for (var i = 0, l = module.length; i < l; ++i) {\n var dep = lookup(parentId, module[i]);\n if (dep == undefined && require.original)\n return;\n params.push(dep);\n }\n return callback && callback.apply(null, params) || true;\n }\n};\n\nvar require = function(module, callback) {\n var packagedModule = _require(\"\", module, callback);\n if (packagedModule == undefined && require.original)\n return require.original.apply(this, arguments);\n return packagedModule;\n};\n\nvar normalizeModule = function(parentId, moduleName) {\n // normalize plugin requires\n if (moduleName.indexOf(\"!\") !== -1) {\n var chunks = moduleName.split(\"!\");\n return normalizeModule(parentId, chunks[0]) + \"!\" + normalizeModule(parentId, chunks[1]);\n }\n // normalize relative requires\n if (moduleName.charAt(0) == \".\") {\n var base = parentId.split(\"/\").slice(0, -1).join(\"/\");\n moduleName = base + \"/\" + moduleName;\n\n while(moduleName.indexOf(\".\") !== -1 && previous != moduleName) {\n var previous = moduleName;\n moduleName = moduleName.replace(/\\/\\.\\//, \"/\").replace(/[^\\/]+\\/\\.\\.\\//, \"\");\n }\n }\n return moduleName;\n};\n\n/**\n * Internal function to lookup moduleNames and resolve them by calling the\n * definition function if needed.\n */\nvar lookup = function(parentId, moduleName) {\n moduleName = normalizeModule(parentId, moduleName);\n\n var module = define.modules[moduleName];\n if (!module) {\n module = define.payloads[moduleName];\n if (typeof module === 'function') {\n var exports = {};\n var mod = {\n id: moduleName,\n uri: '',\n exports: exports,\n packaged: true\n };\n\n var req = function(module, callback) {\n return _require(moduleName, module, callback);\n };\n\n var returnValue = module(req, exports, mod);\n exports = returnValue || mod.exports;\n define.modules[moduleName] = exports;\n delete define.payloads[moduleName];\n }\n module = define.modules[moduleName] = exports || module;\n }\n return module;\n};\n\nfunction exportAce(ns) {\n var root = global;\n if (ns) {\n if (!global[ns])\n global[ns] = {};\n root = global[ns];\n }\n\n if (!root.define || !root.define.packaged) {\n define.original = root.define;\n root.define = define;\n root.define.packaged = true;\n }\n\n if (!root.require || !root.require.packaged) {\n require.original = root.require;\n root.require = require;\n root.require.packaged = true;\n }\n}\n\nexportAce(ACE_NAMESPACE);\n\n})();\n\nace.define(\"ace/lib/es6-shim\",[\"require\",\"exports\",\"module\"], function(require, exports, module){function defineProp(obj, name, val) {\n Object.defineProperty(obj, name, {\n value: val,\n enumerable: false,\n writable: true,\n configurable: true\n });\n}\nif (!String.prototype.startsWith) {\n defineProp(String.prototype, \"startsWith\", function (searchString, position) {\n position = position || 0;\n return this.lastIndexOf(searchString, position) === position;\n });\n}\nif (!String.prototype.endsWith) {\n defineProp(String.prototype, \"endsWith\", function (searchString, position) {\n var subjectString = this;\n if (position === undefined || position > subjectString.length) {\n position = subjectString.length;\n }\n position -= searchString.length;\n var lastIndex = subjectString.indexOf(searchString, position);\n return lastIndex !== -1 && lastIndex === position;\n });\n}\nif (!String.prototype.repeat) {\n defineProp(String.prototype, \"repeat\", function (count) {\n var result = \"\";\n var string = this;\n while (count > 0) {\n if (count & 1)\n result += string;\n if ((count >>= 1))\n string += string;\n }\n return result;\n });\n}\nif (!String.prototype.includes) {\n defineProp(String.prototype, \"includes\", function (str, position) {\n return this.indexOf(str, position) != -1;\n });\n}\nif (!Object.assign) {\n Object.assign = function (target) {\n if (target === undefined || target === null) {\n throw new TypeError(\"Cannot convert undefined or null to object\");\n }\n var output = Object(target);\n for (var index = 1; index < arguments.length; index++) {\n var source = arguments[index];\n if (source !== undefined && source !== null) {\n Object.keys(source).forEach(function (key) {\n output[key] = source[key];\n });\n }\n }\n return output;\n };\n}\nif (!Object.values) {\n Object.values = function (o) {\n return Object.keys(o).map(function (k) {\n return o[k];\n });\n };\n}\nif (!Array.prototype.find) {\n defineProp(Array.prototype, \"find\", function (predicate) {\n var len = this.length;\n var thisArg = arguments[1];\n for (var k = 0; k < len; k++) {\n var kValue = this[k];\n if (predicate.call(thisArg, kValue, k, this)) {\n return kValue;\n }\n }\n });\n}\nif (!Array.prototype.findIndex) {\n defineProp(Array.prototype, \"findIndex\", function (predicate) {\n var len = this.length;\n var thisArg = arguments[1];\n for (var k = 0; k < len; k++) {\n var kValue = this[k];\n if (predicate.call(thisArg, kValue, k, this)) {\n return k;\n }\n }\n });\n}\nif (!Array.prototype.includes) {\n defineProp(Array.prototype, \"includes\", function (item, position) {\n return this.indexOf(item, position) != -1;\n });\n}\nif (!Array.prototype.fill) {\n defineProp(Array.prototype, \"fill\", function (value) {\n var O = this;\n var len = O.length >>> 0;\n var start = arguments[1];\n var relativeStart = start >> 0;\n var k = relativeStart < 0\n ? Math.max(len + relativeStart, 0)\n : Math.min(relativeStart, len);\n var end = arguments[2];\n var relativeEnd = end === undefined ? len : end >> 0;\n var final = relativeEnd < 0\n ? Math.max(len + relativeEnd, 0)\n : Math.min(relativeEnd, len);\n while (k < final) {\n O[k] = value;\n k++;\n }\n return O;\n });\n}\nif (!Array.of) {\n defineProp(Array, \"of\", function () {\n return Array.prototype.slice.call(arguments);\n });\n}\n\n});\n\nace.define(\"ace/lib/fixoldbrowsers\",[\"require\",\"exports\",\"module\",\"ace/lib/es6-shim\"], function(require, exports, module){// vim:set ts=4 sts=4 sw=4 st:\n\"use strict\";\nrequire(\"./es6-shim\");\n\n});\n\nace.define(\"ace/lib/deep_copy\",[\"require\",\"exports\",\"module\"], function(require, exports, module){exports.deepCopy = function deepCopy(obj) {\n if (typeof obj !== \"object\" || !obj)\n return obj;\n var copy;\n if (Array.isArray(obj)) {\n copy = [];\n for (var key = 0; key < obj.length; key++) {\n copy[key] = deepCopy(obj[key]);\n }\n return copy;\n }\n if (Object.prototype.toString.call(obj) !== \"[object Object]\")\n return obj;\n copy = {};\n for (var key in obj)\n copy[key] = deepCopy(obj[key]);\n return copy;\n};\n\n});\n\nace.define(\"ace/lib/lang\",[\"require\",\"exports\",\"module\",\"ace/lib/deep_copy\"], function(require, exports, module){\"use strict\";\nexports.last = function (a) {\n return a[a.length - 1];\n};\nexports.stringReverse = function (string) {\n return string.split(\"\").reverse().join(\"\");\n};\nexports.stringRepeat = function (string, count) {\n var result = '';\n while (count > 0) {\n if (count & 1)\n result += string;\n if (count >>= 1)\n string += string;\n }\n return result;\n};\nvar trimBeginRegexp = /^\\s\\s*/;\nvar trimEndRegexp = /\\s\\s*$/;\nexports.stringTrimLeft = function (string) {\n return string.replace(trimBeginRegexp, '');\n};\nexports.stringTrimRight = function (string) {\n return string.replace(trimEndRegexp, '');\n};\nexports.copyObject = function (obj) {\n var copy = {};\n for (var key in obj) {\n copy[key] = obj[key];\n }\n return copy;\n};\nexports.copyArray = function (array) {\n var copy = [];\n for (var i = 0, l = array.length; i < l; i++) {\n if (array[i] && typeof array[i] == \"object\")\n copy[i] = this.copyObject(array[i]);\n else\n copy[i] = array[i];\n }\n return copy;\n};\nexports.deepCopy = require(\"./deep_copy\").deepCopy;\nexports.arrayToMap = function (arr) {\n var map = {};\n for (var i = 0; i < arr.length; i++) {\n map[arr[i]] = 1;\n }\n return map;\n};\nexports.createMap = function (props) {\n var map = Object.create(null);\n for (var i in props) {\n map[i] = props[i];\n }\n return map;\n};\nexports.arrayRemove = function (array, value) {\n for (var i = 0; i <= array.length; i++) {\n if (value === array[i]) {\n array.splice(i, 1);\n }\n }\n};\nexports.escapeRegExp = function (str) {\n return str.replace(/([.*+?^${}()|[\\]\\/\\\\])/g, '\\\\$1');\n};\nexports.escapeHTML = function (str) {\n return (\"\" + str).replace(/&/g, \"&\").replace(/\"/g, \""\").replace(/'/g, \"'\").replace(/ 0xffff ? 2 : 1;\n};\n\n});\n\nace.define(\"ace/lib/useragent\",[\"require\",\"exports\",\"module\"], function(require, exports, module){\"use strict\";\nexports.OS = {\n LINUX: \"LINUX\",\n MAC: \"MAC\",\n WINDOWS: \"WINDOWS\"\n};\nexports.getOS = function () {\n if (exports.isMac) {\n return exports.OS.MAC;\n }\n else if (exports.isLinux) {\n return exports.OS.LINUX;\n }\n else {\n return exports.OS.WINDOWS;\n }\n};\nvar _navigator = typeof navigator == \"object\" ? navigator : {};\nvar os = (/mac|win|linux/i.exec(_navigator.platform) || [\"other\"])[0].toLowerCase();\nvar ua = _navigator.userAgent || \"\";\nvar appName = _navigator.appName || \"\";\nexports.isWin = (os == \"win\");\nexports.isMac = (os == \"mac\");\nexports.isLinux = (os == \"linux\");\nexports.isIE =\n (appName == \"Microsoft Internet Explorer\" || appName.indexOf(\"MSAppHost\") >= 0)\n ? parseFloat((ua.match(/(?:MSIE |Trident\\/[0-9]+[\\.0-9]+;.*rv:)([0-9]+[\\.0-9]+)/) || [])[1])\n : parseFloat((ua.match(/(?:Trident\\/[0-9]+[\\.0-9]+;.*rv:)([0-9]+[\\.0-9]+)/) || [])[1]); // for ie\nexports.isOldIE = exports.isIE && exports.isIE < 9;\nexports.isGecko = exports.isMozilla = ua.match(/ Gecko\\/\\d+/);\nexports.isOpera = typeof opera == \"object\" && Object.prototype.toString.call(window[\"opera\"]) == \"[object Opera]\";\nexports.isWebKit = parseFloat(ua.split(\"WebKit/\")[1]) || undefined;\nexports.isChrome = parseFloat(ua.split(\" Chrome/\")[1]) || undefined;\nexports.isSafari = parseFloat(ua.split(\" Safari/\")[1]) && !exports.isChrome || undefined;\nexports.isEdge = parseFloat(ua.split(\" Edge/\")[1]) || undefined;\nexports.isAIR = ua.indexOf(\"AdobeAIR\") >= 0;\nexports.isAndroid = ua.indexOf(\"Android\") >= 0;\nexports.isChromeOS = ua.indexOf(\" CrOS \") >= 0;\nexports.isIOS = /iPad|iPhone|iPod/.test(ua) && !window[\"MSStream\"];\nif (exports.isIOS)\n exports.isMac = true;\nexports.isMobile = exports.isIOS || exports.isAndroid;\n\n});\n\nace.define(\"ace/lib/dom\",[\"require\",\"exports\",\"module\",\"ace/lib/useragent\"], function(require, exports, module){\"use strict\";\nvar useragent = require(\"./useragent\");\nvar XHTML_NS = \"http://www.w3.org/1999/xhtml\";\nexports.buildDom = function buildDom(arr, parent, refs) {\n if (typeof arr == \"string\" && arr) {\n var txt = document.createTextNode(arr);\n if (parent)\n parent.appendChild(txt);\n return txt;\n }\n if (!Array.isArray(arr)) {\n if (arr && arr.appendChild && parent)\n parent.appendChild(arr);\n return arr;\n }\n if (typeof arr[0] != \"string\" || !arr[0]) {\n var els = [];\n for (var i = 0; i < arr.length; i++) {\n var ch = buildDom(arr[i], parent, refs);\n ch && els.push(ch);\n }\n return els;\n }\n var el = document.createElement(arr[0]);\n var options = arr[1];\n var childIndex = 1;\n if (options && typeof options == \"object\" && !Array.isArray(options))\n childIndex = 2;\n for (var i = childIndex; i < arr.length; i++)\n buildDom(arr[i], el, refs);\n if (childIndex == 2) {\n Object.keys(options).forEach(function (n) {\n var val = options[n];\n if (n === \"class\") {\n el.className = Array.isArray(val) ? val.join(\" \") : val;\n }\n else if (typeof val == \"function\" || n == \"value\" || n[0] == \"$\") {\n el[n] = val;\n }\n else if (n === \"ref\") {\n if (refs)\n refs[val] = el;\n }\n else if (n === \"style\") {\n if (typeof val == \"string\")\n el.style.cssText = val;\n }\n else if (val != null) {\n el.setAttribute(n, val);\n }\n });\n }\n if (parent)\n parent.appendChild(el);\n return el;\n};\nexports.getDocumentHead = function (doc) {\n if (!doc)\n doc = document;\n return doc.head || doc.getElementsByTagName(\"head\")[0] || doc.documentElement;\n};\nexports.createElement = function (tag, ns) {\n return document.createElementNS ?\n document.createElementNS(ns || XHTML_NS, tag) :\n document.createElement(tag);\n};\nexports.removeChildren = function (element) {\n element.innerHTML = \"\";\n};\nexports.createTextNode = function (textContent, element) {\n var doc = element ? element.ownerDocument : document;\n return doc.createTextNode(textContent);\n};\nexports.createFragment = function (element) {\n var doc = element ? element.ownerDocument : document;\n return doc.createDocumentFragment();\n};\nexports.hasCssClass = function (el, name) {\n var classes = (el.className + \"\").split(/\\s+/g);\n return classes.indexOf(name) !== -1;\n};\nexports.addCssClass = function (el, name) {\n if (!exports.hasCssClass(el, name)) {\n el.className += \" \" + name;\n }\n};\nexports.removeCssClass = function (el, name) {\n var classes = el.className.split(/\\s+/g);\n while (true) {\n var index = classes.indexOf(name);\n if (index == -1) {\n break;\n }\n classes.splice(index, 1);\n }\n el.className = classes.join(\" \");\n};\nexports.toggleCssClass = function (el, name) {\n var classes = el.className.split(/\\s+/g), add = true;\n while (true) {\n var index = classes.indexOf(name);\n if (index == -1) {\n break;\n }\n add = false;\n classes.splice(index, 1);\n }\n if (add)\n classes.push(name);\n el.className = classes.join(\" \");\n return add;\n};\nexports.setCssClass = function (node, className, include) {\n if (include) {\n exports.addCssClass(node, className);\n }\n else {\n exports.removeCssClass(node, className);\n }\n};\nexports.hasCssString = function (id, doc) {\n var index = 0, sheets;\n doc = doc || document;\n if ((sheets = doc.querySelectorAll(\"style\"))) {\n while (index < sheets.length) {\n if (sheets[index++].id === id) {\n return true;\n }\n }\n }\n};\nexports.removeElementById = function (id, doc) {\n doc = doc || document;\n if (doc.getElementById(id)) {\n doc.getElementById(id).remove();\n }\n};\nvar strictCSP;\nvar cssCache = [];\nexports.useStrictCSP = function (value) {\n strictCSP = value;\n if (value == false)\n insertPendingStyles();\n else if (!cssCache)\n cssCache = [];\n};\nfunction insertPendingStyles() {\n var cache = cssCache;\n cssCache = null;\n cache && cache.forEach(function (item) {\n importCssString(item[0], item[1]);\n });\n}\nfunction importCssString(cssText, id, target) {\n if (typeof document == \"undefined\")\n return;\n if (cssCache) {\n if (target) {\n insertPendingStyles();\n }\n else if (target === false) {\n return cssCache.push([cssText, id]);\n }\n }\n if (strictCSP)\n return;\n var container = target;\n if (!target || !target.getRootNode) {\n container = document;\n }\n else {\n container = target.getRootNode();\n if (!container || container == target)\n container = document;\n }\n var doc = container.ownerDocument || container;\n if (id && exports.hasCssString(id, container))\n return null;\n if (id)\n cssText += \"\\n/*# sourceURL=ace/css/\" + id + \" */\";\n var style = exports.createElement(\"style\");\n style.appendChild(doc.createTextNode(cssText));\n if (id)\n style.id = id;\n if (container == doc)\n container = exports.getDocumentHead(doc);\n container.insertBefore(style, container.firstChild);\n}\nexports.importCssString = importCssString;\nexports.importCssStylsheet = function (uri, doc) {\n exports.buildDom([\"link\", { rel: \"stylesheet\", href: uri }], exports.getDocumentHead(doc));\n};\nexports.scrollbarWidth = function (doc) {\n var inner = exports.createElement(\"ace_inner\");\n inner.style.width = \"100%\";\n inner.style.minWidth = \"0px\";\n inner.style.height = \"200px\";\n inner.style.display = \"block\";\n var outer = exports.createElement(\"ace_outer\");\n var style = outer.style;\n style.position = \"absolute\";\n style.left = \"-10000px\";\n style.overflow = \"hidden\";\n style.width = \"200px\";\n style.minWidth = \"0px\";\n style.height = \"150px\";\n style.display = \"block\";\n outer.appendChild(inner);\n var body = (doc && doc.documentElement) || (document && document.documentElement);\n if (!body)\n return 0;\n body.appendChild(outer);\n var noScrollbar = inner.offsetWidth;\n style.overflow = \"scroll\";\n var withScrollbar = inner.offsetWidth;\n if (noScrollbar === withScrollbar) {\n withScrollbar = outer.clientWidth;\n }\n body.removeChild(outer);\n return noScrollbar - withScrollbar;\n};\nexports.computedStyle = function (element, style) {\n return window.getComputedStyle(element, \"\") || {};\n};\nexports.setStyle = function (styles, property, value) {\n if (styles[property] !== value) {\n styles[property] = value;\n }\n};\nexports.HAS_CSS_ANIMATION = false;\nexports.HAS_CSS_TRANSFORMS = false;\nexports.HI_DPI = useragent.isWin\n ? typeof window !== \"undefined\" && window.devicePixelRatio >= 1.5\n : true;\nif (useragent.isChromeOS)\n exports.HI_DPI = false;\nif (typeof document !== \"undefined\") {\n var div = document.createElement(\"div\");\n if (exports.HI_DPI && div.style.transform !== undefined)\n exports.HAS_CSS_TRANSFORMS = true;\n if (!useragent.isEdge && typeof div.style.animationName !== \"undefined\")\n exports.HAS_CSS_ANIMATION = true;\n div = null;\n}\nif (exports.HAS_CSS_TRANSFORMS) {\n exports.translate = function (element, tx, ty) {\n element.style.transform = \"translate(\" + Math.round(tx) + \"px, \" + Math.round(ty) + \"px)\";\n };\n}\nelse {\n exports.translate = function (element, tx, ty) {\n element.style.top = Math.round(ty) + \"px\";\n element.style.left = Math.round(tx) + \"px\";\n };\n}\n\n});\n\nace.define(\"ace/lib/net\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\"], function(require, exports, module){/*\n * based on code from:\n *\n * @license RequireJS text 0.25.0 Copyright (c) 2010-2011, The Dojo Foundation All Rights Reserved.\n * Available via the MIT or new BSD license.\n * see: http://github.com/jrburke/requirejs for details\n */\n\"use strict\";\nvar dom = require(\"./dom\");\nexports.get = function (url, callback) {\n var xhr = new XMLHttpRequest();\n xhr.open('GET', url, true);\n xhr.onreadystatechange = function () {\n if (xhr.readyState === 4) {\n callback(xhr.responseText);\n }\n };\n xhr.send(null);\n};\nexports.loadScript = function (path, callback) {\n var head = dom.getDocumentHead();\n var s = document.createElement('script');\n s.src = path;\n head.appendChild(s);\n s.onload = s.onreadystatechange = function (_, isAbort) {\n if (isAbort || !s.readyState || s.readyState == \"loaded\" || s.readyState == \"complete\") {\n s = s.onload = s.onreadystatechange = null;\n if (!isAbort)\n callback();\n }\n };\n};\nexports.qualifyURL = function (url) {\n var a = document.createElement('a');\n a.href = url;\n return a.href;\n};\n\n});\n\nace.define(\"ace/lib/oop\",[\"require\",\"exports\",\"module\"], function(require, exports, module){\"use strict\";\nexports.inherits = function (ctor, superCtor) {\n ctor.super_ = superCtor;\n ctor.prototype = Object.create(superCtor.prototype, {\n constructor: {\n value: ctor,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n};\nexports.mixin = function (obj, mixin) {\n for (var key in mixin) {\n obj[key] = mixin[key];\n }\n return obj;\n};\nexports.implement = function (proto, mixin) {\n exports.mixin(proto, mixin);\n};\n\n});\n\nace.define(\"ace/lib/event_emitter\",[\"require\",\"exports\",\"module\"], function(require, exports, module){\"use strict\";\nvar EventEmitter = {};\nvar stopPropagation = function () { this.propagationStopped = true; };\nvar preventDefault = function () { this.defaultPrevented = true; };\nEventEmitter._emit =\n EventEmitter._dispatchEvent = function (eventName, e) {\n this._eventRegistry || (this._eventRegistry = {});\n this._defaultHandlers || (this._defaultHandlers = {});\n var listeners = this._eventRegistry[eventName] || [];\n var defaultHandler = this._defaultHandlers[eventName];\n if (!listeners.length && !defaultHandler)\n return;\n if (typeof e != \"object\" || !e)\n e = {};\n if (!e.type)\n e.type = eventName;\n if (!e.stopPropagation)\n e.stopPropagation = stopPropagation;\n if (!e.preventDefault)\n e.preventDefault = preventDefault;\n listeners = listeners.slice();\n for (var i = 0; i < listeners.length; i++) {\n listeners[i](e, this);\n if (e.propagationStopped)\n break;\n }\n if (defaultHandler && !e.defaultPrevented)\n return defaultHandler(e, this);\n };\nEventEmitter._signal = function (eventName, e) {\n var listeners = (this._eventRegistry || {})[eventName];\n if (!listeners)\n return;\n listeners = listeners.slice();\n for (var i = 0; i < listeners.length; i++)\n listeners[i](e, this);\n};\nEventEmitter.once = function (eventName, callback) {\n var _self = this;\n this.on(eventName, function newCallback() {\n _self.off(eventName, newCallback);\n callback.apply(null, arguments);\n });\n if (!callback) {\n return new Promise(function (resolve) {\n callback = resolve;\n });\n }\n};\nEventEmitter.setDefaultHandler = function (eventName, callback) {\n var handlers = this._defaultHandlers;\n if (!handlers)\n handlers = this._defaultHandlers = { _disabled_: {} };\n if (handlers[eventName]) {\n var old = handlers[eventName];\n var disabled = handlers._disabled_[eventName];\n if (!disabled)\n handlers._disabled_[eventName] = disabled = [];\n disabled.push(old);\n var i = disabled.indexOf(callback);\n if (i != -1)\n disabled.splice(i, 1);\n }\n handlers[eventName] = callback;\n};\nEventEmitter.removeDefaultHandler = function (eventName, callback) {\n var handlers = this._defaultHandlers;\n if (!handlers)\n return;\n var disabled = handlers._disabled_[eventName];\n if (handlers[eventName] == callback) {\n if (disabled)\n this.setDefaultHandler(eventName, disabled.pop());\n }\n else if (disabled) {\n var i = disabled.indexOf(callback);\n if (i != -1)\n disabled.splice(i, 1);\n }\n};\nEventEmitter.on =\n EventEmitter.addEventListener = function (eventName, callback, capturing) {\n this._eventRegistry = this._eventRegistry || {};\n var listeners = this._eventRegistry[eventName];\n if (!listeners)\n listeners = this._eventRegistry[eventName] = [];\n if (listeners.indexOf(callback) == -1)\n listeners[capturing ? \"unshift\" : \"push\"](callback);\n return callback;\n };\nEventEmitter.off =\n EventEmitter.removeListener =\n EventEmitter.removeEventListener = function (eventName, callback) {\n this._eventRegistry = this._eventRegistry || {};\n var listeners = this._eventRegistry[eventName];\n if (!listeners)\n return;\n var index = listeners.indexOf(callback);\n if (index !== -1)\n listeners.splice(index, 1);\n };\nEventEmitter.removeAllListeners = function (eventName) {\n if (!eventName)\n this._eventRegistry = this._defaultHandlers = undefined;\n if (this._eventRegistry)\n this._eventRegistry[eventName] = undefined;\n if (this._defaultHandlers)\n this._defaultHandlers[eventName] = undefined;\n};\nexports.EventEmitter = EventEmitter;\n\n});\n\nace.define(\"ace/lib/report_error\",[\"require\",\"exports\",\"module\"], function(require, exports, module){exports.reportError = function reportError(msg, data) {\n var e = new Error(msg);\n e[\"data\"] = data;\n if (typeof console == \"object\" && console.error)\n console.error(e);\n setTimeout(function () { throw e; });\n};\n\n});\n\nace.define(\"ace/lib/default_english_messages\",[\"require\",\"exports\",\"module\"], function(require, exports, module){var defaultEnglishMessages = {\n \"autocomplete.popup.aria-roledescription\": \"Autocomplete suggestions\",\n \"autocomplete.popup.aria-label\": \"Autocomplete suggestions\",\n \"autocomplete.popup.item.aria-roledescription\": \"item\",\n \"autocomplete.loading\": \"Loading...\",\n \"editor.scroller.aria-roledescription\": \"editor\",\n \"editor.scroller.aria-label\": \"Editor content, press Enter to start editing, press Escape to exit\",\n \"editor.gutter.aria-roledescription\": \"editor\",\n \"editor.gutter.aria-label\": \"Editor gutter, press Enter to interact with controls using arrow keys, press Escape to exit\",\n \"error-marker.good-state\": \"Looks good!\",\n \"prompt.recently-used\": \"Recently used\",\n \"prompt.other-commands\": \"Other commands\",\n \"prompt.no-matching-commands\": \"No matching commands\",\n \"search-box.find.placeholder\": \"Search for\",\n \"search-box.find-all.text\": \"All\",\n \"search-box.replace.placeholder\": \"Replace with\",\n \"search-box.replace-next.text\": \"Replace\",\n \"search-box.replace-all.text\": \"All\",\n \"search-box.toggle-replace.title\": \"Toggle Replace mode\",\n \"search-box.toggle-regexp.title\": \"RegExp Search\",\n \"search-box.toggle-case.title\": \"CaseSensitive Search\",\n \"search-box.toggle-whole-word.title\": \"Whole Word Search\",\n \"search-box.toggle-in-selection.title\": \"Search In Selection\",\n \"search-box.search-counter\": \"$0 of $1\",\n \"text-input.aria-roledescription\": \"editor\",\n \"text-input.aria-label\": \"Cursor at row $0\",\n \"gutter.code-folding.range.aria-label\": \"Toggle code folding, rows $0 through $1\",\n \"gutter.code-folding.closed.aria-label\": \"Toggle code folding, rows $0 through $1\",\n \"gutter.code-folding.open.aria-label\": \"Toggle code folding, row $0\",\n \"gutter.code-folding.closed.title\": \"Unfold code\",\n \"gutter.code-folding.open.title\": \"Fold code\",\n \"gutter.annotation.aria-label.error\": \"Error, read annotations row $0\",\n \"gutter.annotation.aria-label.warning\": \"Warning, read annotations row $0\",\n \"gutter.annotation.aria-label.info\": \"Info, read annotations row $0\",\n \"inline-fold.closed.title\": \"Unfold code\",\n \"gutter-tooltip.aria-label.error.singular\": \"error\",\n \"gutter-tooltip.aria-label.error.plural\": \"errors\",\n \"gutter-tooltip.aria-label.warning.singular\": \"warning\",\n \"gutter-tooltip.aria-label.warning.plural\": \"warnings\",\n \"gutter-tooltip.aria-label.info.singular\": \"information message\",\n \"gutter-tooltip.aria-label.info.plural\": \"information messages\",\n \"gutter.annotation.aria-label.security\": \"Security finding, read annotations row $0\",\n \"gutter.annotation.aria-label.hint\": \"Suggestion, read annotations row $0\",\n \"gutter-tooltip.aria-label.security.singular\": \"security finding\",\n \"gutter-tooltip.aria-label.security.plural\": \"security findings\",\n \"gutter-tooltip.aria-label.hint.singular\": \"suggestion\",\n \"gutter-tooltip.aria-label.hint.plural\": \"suggestions\"\n};\nexports.defaultEnglishMessages = defaultEnglishMessages;\n\n});\n\nace.define(\"ace/lib/app_config\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/event_emitter\",\"ace/lib/report_error\",\"ace/lib/default_english_messages\"], function(require, exports, module){\"no use strict\";\nvar oop = require(\"./oop\");\nvar EventEmitter = require(\"./event_emitter\").EventEmitter;\nvar reportError = require(\"./report_error\").reportError;\nvar defaultEnglishMessages = require(\"./default_english_messages\").defaultEnglishMessages;\nvar optionsProvider = {\n setOptions: function (optList) {\n Object.keys(optList).forEach(function (key) {\n this.setOption(key, optList[key]);\n }, this);\n },\n getOptions: function (optionNames) {\n var result = {};\n if (!optionNames) {\n var options = this.$options;\n optionNames = Object.keys(options).filter(function (key) {\n return !options[key].hidden;\n });\n }\n else if (!Array.isArray(optionNames)) {\n result = optionNames;\n optionNames = Object.keys(result);\n }\n optionNames.forEach(function (key) {\n result[key] = this.getOption(key);\n }, this);\n return result;\n },\n setOption: function (name, value) {\n if (this[\"$\" + name] === value)\n return;\n var opt = this.$options[name];\n if (!opt) {\n return warn('misspelled option \"' + name + '\"');\n }\n if (opt.forwardTo)\n return this[opt.forwardTo] && this[opt.forwardTo].setOption(name, value);\n if (!opt.handlesSet)\n this[\"$\" + name] = value;\n if (opt && opt.set)\n opt.set.call(this, value);\n },\n getOption: function (name) {\n var opt = this.$options[name];\n if (!opt) {\n return warn('misspelled option \"' + name + '\"');\n }\n if (opt.forwardTo)\n return this[opt.forwardTo] && this[opt.forwardTo].getOption(name);\n return opt && opt.get ? opt.get.call(this) : this[\"$\" + name];\n }\n};\nfunction warn(message) {\n if (typeof console != \"undefined\" && console.warn)\n console.warn.apply(console, arguments);\n}\nvar messages;\nvar nlsPlaceholders;\nvar AppConfig = /** @class */ (function () {\n function AppConfig() {\n this.$defaultOptions = {};\n messages = defaultEnglishMessages;\n nlsPlaceholders = \"dollarSigns\";\n }\n AppConfig.prototype.defineOptions = function (obj, path, options) {\n if (!obj.$options)\n this.$defaultOptions[path] = obj.$options = {};\n Object.keys(options).forEach(function (key) {\n var opt = options[key];\n if (typeof opt == \"string\")\n opt = { forwardTo: opt };\n opt.name || (opt.name = key);\n obj.$options[opt.name] = opt;\n if (\"initialValue\" in opt)\n obj[\"$\" + opt.name] = opt.initialValue;\n });\n oop.implement(obj, optionsProvider);\n return this;\n };\n AppConfig.prototype.resetOptions = function (obj) {\n Object.keys(obj.$options).forEach(function (key) {\n var opt = obj.$options[key];\n if (\"value\" in opt)\n obj.setOption(key, opt.value);\n });\n };\n AppConfig.prototype.setDefaultValue = function (path, name, value) {\n if (!path) {\n for (path in this.$defaultOptions)\n if (this.$defaultOptions[path][name])\n break;\n if (!this.$defaultOptions[path][name])\n return false;\n }\n var opts = this.$defaultOptions[path] || (this.$defaultOptions[path] = {});\n if (opts[name]) {\n if (opts.forwardTo)\n this.setDefaultValue(opts.forwardTo, name, value);\n else\n opts[name].value = value;\n }\n };\n AppConfig.prototype.setDefaultValues = function (path, optionHash) {\n Object.keys(optionHash).forEach(function (key) {\n this.setDefaultValue(path, key, optionHash[key]);\n }, this);\n };\n AppConfig.prototype.setMessages = function (value, options) {\n messages = value;\n if (options && options.placeholders) {\n nlsPlaceholders = options.placeholders;\n }\n };\n AppConfig.prototype.nls = function (key, defaultString, params) {\n if (!messages[key]) {\n warn(\"No message found for the key '\" + key + \"' in the provided messages, trying to find a translation for the default string '\" + defaultString + \"'.\");\n if (!messages[defaultString]) {\n warn(\"No message found for the default string '\" + defaultString + \"' in the provided messages. Falling back to the default English message.\");\n }\n }\n var translated = messages[key] || messages[defaultString] || defaultString;\n if (params) {\n if (nlsPlaceholders === \"dollarSigns\") {\n translated = translated.replace(/\\$(\\$|[\\d]+)/g, function (_, dollarMatch) {\n if (dollarMatch == \"$\")\n return \"$\";\n return params[dollarMatch];\n });\n }\n if (nlsPlaceholders === \"curlyBrackets\") {\n translated = translated.replace(/\\{([^\\}]+)\\}/g, function (_, curlyBracketMatch) {\n return params[curlyBracketMatch];\n });\n }\n }\n return translated;\n };\n return AppConfig;\n}());\nAppConfig.prototype.warn = warn;\nAppConfig.prototype.reportError = reportError;\noop.implement(AppConfig.prototype, EventEmitter);\nexports.AppConfig = AppConfig;\n\n});\n\nace.define(\"ace/theme/textmate-css\",[\"require\",\"exports\",\"module\"], function(require, exports, module){module.exports = \".ace-tm .ace_gutter {\\n background: #f0f0f0;\\n color: #333;\\n}\\n\\n.ace-tm .ace_print-margin {\\n width: 1px;\\n background: #e8e8e8;\\n}\\n\\n.ace-tm .ace_fold {\\n background-color: #6B72E6;\\n}\\n\\n.ace-tm {\\n background-color: #FFFFFF;\\n color: black;\\n}\\n\\n.ace-tm .ace_cursor {\\n color: black;\\n}\\n \\n.ace-tm .ace_invisible {\\n color: rgb(191, 191, 191);\\n}\\n\\n.ace-tm .ace_storage,\\n.ace-tm .ace_keyword {\\n color: blue;\\n}\\n\\n.ace-tm .ace_constant {\\n color: rgb(197, 6, 11);\\n}\\n\\n.ace-tm .ace_constant.ace_buildin {\\n color: rgb(88, 72, 246);\\n}\\n\\n.ace-tm .ace_constant.ace_language {\\n color: rgb(88, 92, 246);\\n}\\n\\n.ace-tm .ace_constant.ace_library {\\n color: rgb(6, 150, 14);\\n}\\n\\n.ace-tm .ace_invalid {\\n background-color: rgba(255, 0, 0, 0.1);\\n color: red;\\n}\\n\\n.ace-tm .ace_support.ace_function {\\n color: rgb(60, 76, 114);\\n}\\n\\n.ace-tm .ace_support.ace_constant {\\n color: rgb(6, 150, 14);\\n}\\n\\n.ace-tm .ace_support.ace_type,\\n.ace-tm .ace_support.ace_class {\\n color: rgb(109, 121, 222);\\n}\\n\\n.ace-tm .ace_keyword.ace_operator {\\n color: rgb(104, 118, 135);\\n}\\n\\n.ace-tm .ace_string {\\n color: rgb(3, 106, 7);\\n}\\n\\n.ace-tm .ace_comment {\\n color: rgb(76, 136, 107);\\n}\\n\\n.ace-tm .ace_comment.ace_doc {\\n color: rgb(0, 102, 255);\\n}\\n\\n.ace-tm .ace_comment.ace_doc.ace_tag {\\n color: rgb(128, 159, 191);\\n}\\n\\n.ace-tm .ace_constant.ace_numeric {\\n color: rgb(0, 0, 205);\\n}\\n\\n.ace-tm .ace_variable {\\n color: rgb(49, 132, 149);\\n}\\n\\n.ace-tm .ace_xml-pe {\\n color: rgb(104, 104, 91);\\n}\\n\\n.ace-tm .ace_entity.ace_name.ace_function {\\n color: #0000A2;\\n}\\n\\n\\n.ace-tm .ace_heading {\\n color: rgb(12, 7, 255);\\n}\\n\\n.ace-tm .ace_list {\\n color:rgb(185, 6, 144);\\n}\\n\\n.ace-tm .ace_meta.ace_tag {\\n color:rgb(0, 22, 142);\\n}\\n\\n.ace-tm .ace_string.ace_regex {\\n color: rgb(255, 0, 0)\\n}\\n\\n.ace-tm .ace_marker-layer .ace_selection {\\n background: rgb(181, 213, 255);\\n}\\n.ace-tm.ace_multiselect .ace_selection.ace_start {\\n box-shadow: 0 0 3px 0px white;\\n}\\n.ace-tm .ace_marker-layer .ace_step {\\n background: rgb(252, 255, 0);\\n}\\n\\n.ace-tm .ace_marker-layer .ace_stack {\\n background: rgb(164, 229, 101);\\n}\\n\\n.ace-tm .ace_marker-layer .ace_bracket {\\n margin: -1px 0 0 -1px;\\n border: 1px solid rgb(192, 192, 192);\\n}\\n\\n.ace-tm .ace_marker-layer .ace_active-line {\\n background: rgba(0, 0, 0, 0.07);\\n}\\n\\n.ace-tm .ace_gutter-active-line {\\n background-color : #dcdcdc;\\n}\\n\\n.ace-tm .ace_marker-layer .ace_selected-word {\\n background: rgb(250, 250, 255);\\n border: 1px solid rgb(200, 200, 250);\\n}\\n\\n.ace-tm .ace_indent-guide {\\n background: url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\\\") right repeat-y;\\n}\\n\\n.ace-tm .ace_indent-guide-active {\\n background: url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAAZSURBVHjaYvj///9/hivKyv8BAAAA//8DACLqBhbvk+/eAAAAAElFTkSuQmCC\\\") right repeat-y;\\n}\\n\";\n\n});\n\nace.define(\"ace/theme/textmate\",[\"require\",\"exports\",\"module\",\"ace/theme/textmate-css\",\"ace/lib/dom\"], function(require, exports, module){\"use strict\";\nexports.isDark = false;\nexports.cssClass = \"ace-tm\";\nexports.cssText = require(\"./textmate-css\");\nexports.$id = \"ace/theme/textmate\";\nvar dom = require(\"../lib/dom\");\ndom.importCssString(exports.cssText, exports.cssClass, false);\n\n});\n\nace.define(\"ace/config\",[\"require\",\"exports\",\"module\",\"ace/lib/lang\",\"ace/lib/net\",\"ace/lib/dom\",\"ace/lib/app_config\",\"ace/theme/textmate\"], function(require, exports, module){\"no use strict\";\nvar lang = require(\"./lib/lang\");\nvar net = require(\"./lib/net\");\nvar dom = require(\"./lib/dom\");\nvar AppConfig = require(\"./lib/app_config\").AppConfig;\nmodule.exports = exports = new AppConfig();\nvar options = {\n packaged: false,\n workerPath: null,\n modePath: null,\n themePath: null,\n basePath: \"\",\n suffix: \".js\",\n $moduleUrls: {},\n loadWorkerFromBlob: true,\n sharedPopups: false,\n useStrictCSP: null\n};\nexports.get = function (key) {\n if (!options.hasOwnProperty(key))\n throw new Error(\"Unknown config key: \" + key);\n return options[key];\n};\nexports.set = function (key, value) {\n if (options.hasOwnProperty(key))\n options[key] = value;\n else if (this.setDefaultValue(\"\", key, value) == false)\n throw new Error(\"Unknown config key: \" + key);\n if (key == \"useStrictCSP\")\n dom.useStrictCSP(value);\n};\nexports.all = function () {\n return lang.copyObject(options);\n};\nexports.$modes = {};\nexports.moduleUrl = function (name, component) {\n if (options.$moduleUrls[name])\n return options.$moduleUrls[name];\n var parts = name.split(\"/\");\n component = component || parts[parts.length - 2] || \"\";\n var sep = component == \"snippets\" ? \"/\" : \"-\";\n var base = parts[parts.length - 1];\n if (component == \"worker\" && sep == \"-\") {\n var re = new RegExp(\"^\" + component + \"[\\\\-_]|[\\\\-_]\" + component + \"$\", \"g\");\n base = base.replace(re, \"\");\n }\n if ((!base || base == component) && parts.length > 1)\n base = parts[parts.length - 2];\n var path = options[component + \"Path\"];\n if (path == null) {\n path = options.basePath;\n }\n else if (sep == \"/\") {\n component = sep = \"\";\n }\n if (path && path.slice(-1) != \"/\")\n path += \"/\";\n return path + component + sep + base + this.get(\"suffix\");\n};\nexports.setModuleUrl = function (name, subst) {\n return options.$moduleUrls[name] = subst;\n};\nvar loader = function (moduleName, cb) {\n if (moduleName === \"ace/theme/textmate\" || moduleName === \"./theme/textmate\")\n return cb(null, require(\"./theme/textmate\"));\n if (customLoader)\n return customLoader(moduleName, cb);\n console.error(\"loader is not configured\");\n};\nvar customLoader;\nexports.setLoader = function (cb) {\n customLoader = cb;\n};\nexports.dynamicModules = Object.create(null);\nexports.$loading = {};\nexports.$loaded = {};\nexports.loadModule = function (moduleId, onLoad) {\n var loadedModule;\n if (Array.isArray(moduleId)) {\n var moduleType = moduleId[0];\n var moduleName = moduleId[1];\n }\n else if (typeof moduleId == \"string\") {\n var moduleName = moduleId;\n }\n var load = function (module) {\n if (module && !exports.$loading[moduleName])\n return onLoad && onLoad(module);\n if (!exports.$loading[moduleName])\n exports.$loading[moduleName] = [];\n exports.$loading[moduleName].push(onLoad);\n if (exports.$loading[moduleName].length > 1)\n return;\n var afterLoad = function () {\n loader(moduleName, function (err, module) {\n if (module)\n exports.$loaded[moduleName] = module;\n exports._emit(\"load.module\", { name: moduleName, module: module });\n var listeners = exports.$loading[moduleName];\n exports.$loading[moduleName] = null;\n listeners.forEach(function (onLoad) {\n onLoad && onLoad(module);\n });\n });\n };\n if (!exports.get(\"packaged\"))\n return afterLoad();\n net.loadScript(exports.moduleUrl(moduleName, moduleType), afterLoad);\n reportErrorIfPathIsNotConfigured();\n };\n if (exports.dynamicModules[moduleName]) {\n exports.dynamicModules[moduleName]().then(function (module) {\n if (module.default) {\n load(module.default);\n }\n else {\n load(module);\n }\n });\n }\n else {\n try {\n loadedModule = this.$require(moduleName);\n }\n catch (e) { }\n load(loadedModule || exports.$loaded[moduleName]);\n }\n};\nexports.$require = function (moduleName) {\n if (typeof module[\"require\"] == \"function\") {\n var req = \"require\";\n return module[req](moduleName);\n }\n};\nexports.setModuleLoader = function (moduleName, onLoad) {\n exports.dynamicModules[moduleName] = onLoad;\n};\nvar reportErrorIfPathIsNotConfigured = function () {\n if (!options.basePath && !options.workerPath\n && !options.modePath && !options.themePath\n && !Object.keys(options.$moduleUrls).length) {\n console.error(\"Unable to infer path to ace from script src,\", \"use ace.config.set('basePath', 'path') to enable dynamic loading of modes and themes\", \"or with webpack use ace/webpack-resolver\");\n reportErrorIfPathIsNotConfigured = function () { };\n }\n};\nexports.version = \"1.36.5\";\n\n});\n\nace.define(\"ace/loader_build\",[\"require\",\"exports\",\"module\",\"ace/lib/fixoldbrowsers\",\"ace/config\"], function(require, exports, module) {\n\"use strict\";\n\nrequire(\"./lib/fixoldbrowsers\");\nvar config = require(\"./config\");\nconfig.setLoader(function(moduleName, cb) {\n require([moduleName], function(module) {\n cb(null, module);\n });\n});\n\nvar global = (function() {\n return this || typeof window != \"undefined\" && window;\n})();\n\nmodule.exports = function(ace) {\n config.init = init;\n config.$require = require;\n ace.require = require;\n\n if (typeof define === \"function\")\n ace.define = define;\n};\ninit(true);function init(packaged) {\n\n if (!global || !global.document)\n return;\n \n config.set(\"packaged\", packaged || require.packaged || module.packaged || (global.define && define.packaged));\n\n var scriptOptions = {};\n var scriptUrl = \"\";\n var currentScript = (document.currentScript || document._currentScript ); // native or polyfill\n var currentDocument = currentScript && currentScript.ownerDocument || document;\n \n if (currentScript && currentScript.src) {\n scriptUrl = currentScript.src.split(/[?#]/)[0].split(\"/\").slice(0, -1).join(\"/\") || \"\";\n }\n \n var scripts = currentDocument.getElementsByTagName(\"script\");\n for (var i=0; i [\" + this.end.row + \"/\" + this.end.column + \"]\");\n };\n Range.prototype.contains = function (row, column) {\n return this.compare(row, column) == 0;\n };\n Range.prototype.compareRange = function (range) {\n var cmp, end = range.end, start = range.start;\n cmp = this.compare(end.row, end.column);\n if (cmp == 1) {\n cmp = this.compare(start.row, start.column);\n if (cmp == 1) {\n return 2;\n }\n else if (cmp == 0) {\n return 1;\n }\n else {\n return 0;\n }\n }\n else if (cmp == -1) {\n return -2;\n }\n else {\n cmp = this.compare(start.row, start.column);\n if (cmp == -1) {\n return -1;\n }\n else if (cmp == 1) {\n return 42;\n }\n else {\n return 0;\n }\n }\n };\n Range.prototype.comparePoint = function (p) {\n return this.compare(p.row, p.column);\n };\n Range.prototype.containsRange = function (range) {\n return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;\n };\n Range.prototype.intersects = function (range) {\n var cmp = this.compareRange(range);\n return (cmp == -1 || cmp == 0 || cmp == 1);\n };\n Range.prototype.isEnd = function (row, column) {\n return this.end.row == row && this.end.column == column;\n };\n Range.prototype.isStart = function (row, column) {\n return this.start.row == row && this.start.column == column;\n };\n Range.prototype.setStart = function (row, column) {\n if (typeof row == \"object\") {\n this.start.column = row.column;\n this.start.row = row.row;\n }\n else {\n this.start.row = row;\n this.start.column = column;\n }\n };\n Range.prototype.setEnd = function (row, column) {\n if (typeof row == \"object\") {\n this.end.column = row.column;\n this.end.row = row.row;\n }\n else {\n this.end.row = row;\n this.end.column = column;\n }\n };\n Range.prototype.inside = function (row, column) {\n if (this.compare(row, column) == 0) {\n if (this.isEnd(row, column) || this.isStart(row, column)) {\n return false;\n }\n else {\n return true;\n }\n }\n return false;\n };\n Range.prototype.insideStart = function (row, column) {\n if (this.compare(row, column) == 0) {\n if (this.isEnd(row, column)) {\n return false;\n }\n else {\n return true;\n }\n }\n return false;\n };\n Range.prototype.insideEnd = function (row, column) {\n if (this.compare(row, column) == 0) {\n if (this.isStart(row, column)) {\n return false;\n }\n else {\n return true;\n }\n }\n return false;\n };\n Range.prototype.compare = function (row, column) {\n if (!this.isMultiLine()) {\n if (row === this.start.row) {\n return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);\n }\n }\n if (row < this.start.row)\n return -1;\n if (row > this.end.row)\n return 1;\n if (this.start.row === row)\n return column >= this.start.column ? 0 : -1;\n if (this.end.row === row)\n return column <= this.end.column ? 0 : 1;\n return 0;\n };\n Range.prototype.compareStart = function (row, column) {\n if (this.start.row == row && this.start.column == column) {\n return -1;\n }\n else {\n return this.compare(row, column);\n }\n };\n Range.prototype.compareEnd = function (row, column) {\n if (this.end.row == row && this.end.column == column) {\n return 1;\n }\n else {\n return this.compare(row, column);\n }\n };\n Range.prototype.compareInside = function (row, column) {\n if (this.end.row == row && this.end.column == column) {\n return 1;\n }\n else if (this.start.row == row && this.start.column == column) {\n return -1;\n }\n else {\n return this.compare(row, column);\n }\n };\n Range.prototype.clipRows = function (firstRow, lastRow) {\n if (this.end.row > lastRow)\n var end = { row: lastRow + 1, column: 0 };\n else if (this.end.row < firstRow)\n var end = { row: firstRow, column: 0 };\n if (this.start.row > lastRow)\n var start = { row: lastRow + 1, column: 0 };\n else if (this.start.row < firstRow)\n var start = { row: firstRow, column: 0 };\n return Range.fromPoints(start || this.start, end || this.end);\n };\n Range.prototype.extend = function (row, column) {\n var cmp = this.compare(row, column);\n if (cmp == 0)\n return this;\n else if (cmp == -1)\n var start = { row: row, column: column };\n else\n var end = { row: row, column: column };\n return Range.fromPoints(start || this.start, end || this.end);\n };\n Range.prototype.isEmpty = function () {\n return (this.start.row === this.end.row && this.start.column === this.end.column);\n };\n Range.prototype.isMultiLine = function () {\n return (this.start.row !== this.end.row);\n };\n Range.prototype.clone = function () {\n return Range.fromPoints(this.start, this.end);\n };\n Range.prototype.collapseRows = function () {\n if (this.end.column == 0)\n return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row - 1), 0);\n else\n return new Range(this.start.row, 0, this.end.row, 0);\n };\n Range.prototype.toScreenRange = function (session) {\n var screenPosStart = session.documentToScreenPosition(this.start);\n var screenPosEnd = session.documentToScreenPosition(this.end);\n return new Range(screenPosStart.row, screenPosStart.column, screenPosEnd.row, screenPosEnd.column);\n };\n Range.prototype.moveBy = function (row, column) {\n this.start.row += row;\n this.start.column += column;\n this.end.row += row;\n this.end.column += column;\n };\n return Range;\n}());\nRange.fromPoints = function (start, end) {\n return new Range(start.row, start.column, end.row, end.column);\n};\nRange.comparePoints = function (p1, p2) {\n return p1.row - p2.row || p1.column - p2.column;\n};\nexports.Range = Range;\n\n});\n\nace.define(\"ace/lib/keys\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\"], function(require, exports, module){\"use strict\";\nvar oop = require(\"./oop\");\nvar Keys = {\n MODIFIER_KEYS: {\n 16: 'Shift', 17: 'Ctrl', 18: 'Alt', 224: 'Meta',\n 91: 'MetaLeft', 92: 'MetaRight', 93: 'ContextMenu'\n },\n KEY_MODS: {\n \"ctrl\": 1, \"alt\": 2, \"option\": 2, \"shift\": 4,\n \"super\": 8, \"meta\": 8, \"command\": 8, \"cmd\": 8,\n \"control\": 1\n },\n FUNCTION_KEYS: {\n 8: \"Backspace\",\n 9: \"Tab\",\n 13: \"Return\",\n 19: \"Pause\",\n 27: \"Esc\",\n 32: \"Space\",\n 33: \"PageUp\",\n 34: \"PageDown\",\n 35: \"End\",\n 36: \"Home\",\n 37: \"Left\",\n 38: \"Up\",\n 39: \"Right\",\n 40: \"Down\",\n 44: \"Print\",\n 45: \"Insert\",\n 46: \"Delete\",\n '-13': \"NumpadEnter\",\n 144: \"Numlock\",\n 145: \"Scrolllock\"\n },\n PRINTABLE_KEYS: {\n 32: ' ', 59: ';', 61: '=', 107: '+', 109: '-', 110: '.',\n 186: ';', 187: '=', 188: ',', 189: '-', 190: '.', 191: '/', 192: '`',\n 219: '[', 220: '\\\\', 221: ']', 222: \"'\", 111: '/', 106: '*'\n }\n};\nvar codeToKeyCode = {\n Command: 224,\n Backspace: 8,\n Tab: 9,\n Return: 13,\n Enter: 13,\n Pause: 19,\n Escape: 27,\n PageUp: 33,\n PageDown: 34,\n End: 35,\n Home: 36,\n Insert: 45,\n Delete: 46,\n ArrowLeft: 37,\n ArrowUp: 38,\n ArrowRight: 39,\n ArrowDown: 40,\n Backquote: 192,\n Minus: 189,\n Equal: 187,\n BracketLeft: 219,\n Backslash: 220,\n BracketRight: 221,\n Semicolon: 186,\n Quote: 222,\n Comma: 188,\n Period: 190,\n Slash: 191,\n Space: 32,\n NumpadAdd: 107,\n NumpadDecimal: 110,\n NumpadSubtract: 109,\n NumpadDivide: 111,\n NumpadMultiply: 106\n};\nfor (var i = 0; i < 10; i++) {\n codeToKeyCode[\"Digit\" + i] = 48 + i;\n codeToKeyCode[\"Numpad\" + i] = 96 + i;\n Keys.PRINTABLE_KEYS[48 + i] = \"\" + i;\n Keys.FUNCTION_KEYS[96 + i] = \"Numpad\" + i;\n}\nfor (var i = 65; i < 91; i++) {\n var chr = String.fromCharCode(i + 32);\n codeToKeyCode[\"Key\" + chr.toUpperCase()] = i;\n Keys.PRINTABLE_KEYS[i] = chr;\n}\nfor (var i = 1; i < 13; i++) {\n codeToKeyCode[\"F\" + i] = 111 + i;\n Keys.FUNCTION_KEYS[111 + i] = \"F\" + i;\n}\nvar modifiers = {\n Shift: 16,\n Control: 17,\n Alt: 18,\n Meta: 224\n};\nfor (var mod in modifiers) {\n codeToKeyCode[mod] = codeToKeyCode[mod + \"Left\"]\n = codeToKeyCode[mod + \"Right\"] = modifiers[mod];\n}\nexports.$codeToKeyCode = codeToKeyCode;\nKeys.PRINTABLE_KEYS[173] = '-';\nfor (var j in Keys.FUNCTION_KEYS) {\n var name = Keys.FUNCTION_KEYS[j].toLowerCase();\n Keys[name] = parseInt(j, 10);\n}\nfor (var j in Keys.PRINTABLE_KEYS) {\n var name = Keys.PRINTABLE_KEYS[j].toLowerCase();\n Keys[name] = parseInt(j, 10);\n}\noop.mixin(Keys, Keys.MODIFIER_KEYS);\noop.mixin(Keys, Keys.PRINTABLE_KEYS);\noop.mixin(Keys, Keys.FUNCTION_KEYS);\nKeys.enter = Keys[\"return\"];\nKeys.escape = Keys.esc;\nKeys.del = Keys[\"delete\"];\n(function () {\n var mods = [\"cmd\", \"ctrl\", \"alt\", \"shift\"];\n for (var i = Math.pow(2, mods.length); i--;) {\n Keys.KEY_MODS[i] = mods.filter(function (x) {\n return i & Keys.KEY_MODS[x];\n }).join(\"-\") + \"-\";\n }\n})();\nKeys.KEY_MODS[0] = \"\";\nKeys.KEY_MODS[-1] = \"input-\";\noop.mixin(exports, Keys);\nexports.default = exports;\nexports.keyCodeToString = function (keyCode) {\n var keyString = Keys[keyCode];\n if (typeof keyString != \"string\")\n keyString = String.fromCharCode(keyCode);\n return keyString.toLowerCase();\n};\n\n});\n\nace.define(\"ace/lib/event\",[\"require\",\"exports\",\"module\",\"ace/lib/keys\",\"ace/lib/useragent\"], function(require, exports, module){\"use strict\"; var keys = require(\"./keys\");\nvar useragent = require(\"./useragent\");\nvar pressedKeys = null;\nvar ts = 0;\nvar activeListenerOptions;\nfunction detectListenerOptionsSupport() {\n activeListenerOptions = false;\n try {\n document.createComment(\"\").addEventListener(\"test\", function () { }, {\n get passive() {\n activeListenerOptions = { passive: false };\n return true;\n }\n });\n }\n catch (e) { }\n}\nfunction getListenerOptions() {\n if (activeListenerOptions == undefined)\n detectListenerOptionsSupport();\n return activeListenerOptions;\n}\nfunction EventListener(elem, type, callback) {\n this.elem = elem;\n this.type = type;\n this.callback = callback;\n}\nEventListener.prototype.destroy = function () {\n removeListener(this.elem, this.type, this.callback);\n this.elem = this.type = this.callback = undefined;\n};\nvar addListener = exports.addListener = function (elem, type, callback, /**@type{any?}*/ destroyer) {\n elem.addEventListener(type, callback, getListenerOptions());\n if (destroyer)\n destroyer.$toDestroy.push(new EventListener(elem, type, callback));\n};\nvar removeListener = exports.removeListener = function (elem, type, callback) {\n elem.removeEventListener(type, callback, getListenerOptions());\n};\nexports.stopEvent = function (e) {\n exports.stopPropagation(e);\n exports.preventDefault(e);\n return false;\n};\nexports.stopPropagation = function (e) {\n if (e.stopPropagation)\n e.stopPropagation();\n};\nexports.preventDefault = function (e) {\n if (e.preventDefault)\n e.preventDefault();\n};\nexports.getButton = function (e) {\n if (e.type == \"dblclick\")\n return 0;\n if (e.type == \"contextmenu\" || (useragent.isMac && (e.ctrlKey && !e.altKey && !e.shiftKey)))\n return 2;\n return e.button;\n};\nexports.capture = function (el, eventHandler, releaseCaptureHandler) {\n var ownerDocument = el && el.ownerDocument || document;\n function onMouseUp(e) {\n eventHandler && eventHandler(e);\n releaseCaptureHandler && releaseCaptureHandler(e);\n removeListener(ownerDocument, \"mousemove\", eventHandler);\n removeListener(ownerDocument, \"mouseup\", onMouseUp);\n removeListener(ownerDocument, \"dragstart\", onMouseUp);\n }\n addListener(ownerDocument, \"mousemove\", eventHandler);\n addListener(ownerDocument, \"mouseup\", onMouseUp);\n addListener(ownerDocument, \"dragstart\", onMouseUp);\n return onMouseUp;\n};\nexports.addMouseWheelListener = function (el, callback, destroyer) {\n addListener(el, \"wheel\", function (e) {\n var factor = 0.15;\n var deltaX = e.deltaX || 0;\n var deltaY = e.deltaY || 0;\n switch (e.deltaMode) {\n case e.DOM_DELTA_PIXEL:\n e.wheelX = deltaX * factor;\n e.wheelY = deltaY * factor;\n break;\n case e.DOM_DELTA_LINE:\n var linePixels = 15;\n e.wheelX = deltaX * linePixels;\n e.wheelY = deltaY * linePixels;\n break;\n case e.DOM_DELTA_PAGE:\n var pagePixels = 150;\n e.wheelX = deltaX * pagePixels;\n e.wheelY = deltaY * pagePixels;\n break;\n }\n callback(e);\n }, destroyer);\n};\nexports.addMultiMouseDownListener = function (elements, timeouts, eventHandler, callbackName, destroyer) {\n var clicks = 0;\n var startX, startY, timer;\n var eventNames = {\n 2: \"dblclick\",\n 3: \"tripleclick\",\n 4: \"quadclick\"\n };\n function onMousedown(e) {\n if (exports.getButton(e) !== 0) {\n clicks = 0;\n }\n else if (e.detail > 1) {\n clicks++;\n if (clicks > 4)\n clicks = 1;\n }\n else {\n clicks = 1;\n }\n if (useragent.isIE) {\n var isNewClick = Math.abs(e.clientX - startX) > 5 || Math.abs(e.clientY - startY) > 5;\n if (!timer || isNewClick)\n clicks = 1;\n if (timer)\n clearTimeout(timer);\n timer = setTimeout(function () { timer = null; }, timeouts[clicks - 1] || 600);\n if (clicks == 1) {\n startX = e.clientX;\n startY = e.clientY;\n }\n }\n e._clicks = clicks;\n eventHandler[callbackName](\"mousedown\", e);\n if (clicks > 4)\n clicks = 0;\n else if (clicks > 1)\n return eventHandler[callbackName](eventNames[clicks], e);\n }\n if (!Array.isArray(elements))\n elements = [elements];\n elements.forEach(function (el) {\n addListener(el, \"mousedown\", onMousedown, destroyer);\n });\n};\nfunction getModifierHash(e) {\n return 0 | (e.ctrlKey ? 1 : 0) | (e.altKey ? 2 : 0) | (e.shiftKey ? 4 : 0) | (e.metaKey ? 8 : 0);\n}\nexports.getModifierString = function (e) {\n return keys.KEY_MODS[getModifierHash(e)];\n};\nfunction normalizeCommandKeys(callback, e, keyCode) {\n var hashId = getModifierHash(e);\n if (!keyCode && e.code) {\n keyCode = keys.$codeToKeyCode[e.code] || keyCode;\n }\n if (!useragent.isMac && pressedKeys) {\n if (e.getModifierState && (e.getModifierState(\"OS\") || e.getModifierState(\"Win\")))\n hashId |= 8;\n if (pressedKeys.altGr) {\n if ((3 & hashId) != 3)\n pressedKeys.altGr = 0;\n else\n return;\n }\n if (keyCode === 18 || keyCode === 17) {\n var location = e.location;\n if (keyCode === 17 && location === 1) {\n if (pressedKeys[keyCode] == 1)\n ts = e.timeStamp;\n }\n else if (keyCode === 18 && hashId === 3 && location === 2) {\n var dt = e.timeStamp - ts;\n if (dt < 50)\n pressedKeys.altGr = true;\n }\n }\n }\n if (keyCode in keys.MODIFIER_KEYS) {\n keyCode = -1;\n }\n if (!hashId && keyCode === 13) {\n if (e.location === 3) {\n callback(e, hashId, -keyCode);\n if (e.defaultPrevented)\n return;\n }\n }\n if (useragent.isChromeOS && hashId & 8) {\n callback(e, hashId, keyCode);\n if (e.defaultPrevented)\n return;\n else\n hashId &= ~8;\n }\n if (!hashId && !(keyCode in keys.FUNCTION_KEYS) && !(keyCode in keys.PRINTABLE_KEYS)) {\n return false;\n }\n return callback(e, hashId, keyCode);\n}\nexports.addCommandKeyListener = function (el, callback, destroyer) {\n var lastDefaultPrevented = null;\n addListener(el, \"keydown\", function (e) {\n pressedKeys[e.keyCode] = (pressedKeys[e.keyCode] || 0) + 1;\n var result = normalizeCommandKeys(callback, e, e.keyCode);\n lastDefaultPrevented = e.defaultPrevented;\n return result;\n }, destroyer);\n addListener(el, \"keypress\", function (e) {\n if (lastDefaultPrevented && (e.ctrlKey || e.altKey || e.shiftKey || e.metaKey)) {\n exports.stopEvent(e);\n lastDefaultPrevented = null;\n }\n }, destroyer);\n addListener(el, \"keyup\", function (e) {\n pressedKeys[e.keyCode] = null;\n }, destroyer);\n if (!pressedKeys) {\n resetPressedKeys();\n addListener(window, \"focus\", resetPressedKeys);\n }\n};\nfunction resetPressedKeys() {\n pressedKeys = Object.create(null);\n}\nif (typeof window == \"object\" && window.postMessage && !useragent.isOldIE) {\n var postMessageId = 1;\n exports.nextTick = function (callback, win) {\n win = win || window;\n var messageName = \"zero-timeout-message-\" + (postMessageId++);\n var listener = function (e) {\n if (e.data == messageName) {\n exports.stopPropagation(e);\n removeListener(win, \"message\", listener);\n callback();\n }\n };\n addListener(win, \"message\", listener);\n win.postMessage(messageName, \"*\");\n };\n}\nexports.$idleBlocked = false;\nexports.onIdle = function (cb, timeout) {\n return setTimeout(function handler() {\n if (!exports.$idleBlocked) {\n cb();\n }\n else {\n setTimeout(handler, 100);\n }\n }, timeout);\n};\nexports.$idleBlockId = null;\nexports.blockIdle = function (delay) {\n if (exports.$idleBlockId)\n clearTimeout(exports.$idleBlockId);\n exports.$idleBlocked = true;\n exports.$idleBlockId = setTimeout(function () {\n exports.$idleBlocked = false;\n }, delay || 100);\n};\nexports.nextFrame = typeof window == \"object\" && (window.requestAnimationFrame\n || window[\"mozRequestAnimationFrame\"]\n || window[\"webkitRequestAnimationFrame\"]\n || window[\"msRequestAnimationFrame\"]\n || window[\"oRequestAnimationFrame\"]);\nif (exports.nextFrame)\n exports.nextFrame = exports.nextFrame.bind(window);\nelse\n exports.nextFrame = function (callback) {\n setTimeout(callback, 17);\n };\n\n});\n\nace.define(\"ace/clipboard\",[\"require\",\"exports\",\"module\"], function(require, exports, module){\"use strict\";\nvar $cancelT;\nmodule.exports = {\n lineMode: false,\n pasteCancelled: function () {\n if ($cancelT && $cancelT > Date.now() - 50)\n return true;\n return $cancelT = false;\n },\n cancel: function () {\n $cancelT = Date.now();\n }\n};\n\n});\n\nace.define(\"ace/keyboard/textinput\",[\"require\",\"exports\",\"module\",\"ace/lib/event\",\"ace/config\",\"ace/lib/useragent\",\"ace/lib/dom\",\"ace/lib/lang\",\"ace/clipboard\",\"ace/lib/keys\"], function(require, exports, module){\"use strict\";\nvar event = require(\"../lib/event\");\nvar nls = require(\"../config\").nls;\nvar useragent = require(\"../lib/useragent\");\nvar dom = require(\"../lib/dom\");\nvar lang = require(\"../lib/lang\");\nvar clipboard = require(\"../clipboard\");\nvar BROKEN_SETDATA = useragent.isChrome < 18;\nvar USE_IE_MIME_TYPE = useragent.isIE;\nvar HAS_FOCUS_ARGS = useragent.isChrome > 63;\nvar MAX_LINE_LENGTH = 400;\nvar KEYS = require(\"../lib/keys\");\nvar MODS = KEYS.KEY_MODS;\nvar isIOS = useragent.isIOS;\nvar valueResetRegex = isIOS ? /\\s/ : /\\n/;\nvar isMobile = useragent.isMobile;\nvar TextInput;\nTextInput = function (parentNode, host) {\n var text = dom.createElement(\"textarea\");\n text.className = \"ace_text-input\";\n text.setAttribute(\"wrap\", \"off\");\n text.setAttribute(\"autocorrect\", \"off\");\n text.setAttribute(\"autocapitalize\", \"off\");\n text.setAttribute(\"spellcheck\", \"false\");\n text.style.opacity = \"0\";\n parentNode.insertBefore(text, parentNode.firstChild);\n var copied = false;\n var pasted = false;\n var inComposition = false;\n var sendingText = false;\n var tempStyle = '';\n if (!isMobile)\n text.style.fontSize = \"1px\";\n var commandMode = false;\n var ignoreFocusEvents = false;\n var lastValue = \"\";\n var lastSelectionStart = 0;\n var lastSelectionEnd = 0;\n var lastRestoreEnd = 0;\n var rowStart = Number.MAX_SAFE_INTEGER;\n var rowEnd = Number.MIN_SAFE_INTEGER;\n var numberOfExtraLines = 0;\n try {\n var isFocused = document.activeElement === text;\n }\n catch (e) { }\n this.setNumberOfExtraLines = function (number) {\n rowStart = Number.MAX_SAFE_INTEGER;\n rowEnd = Number.MIN_SAFE_INTEGER;\n if (number < 0) {\n numberOfExtraLines = 0;\n return;\n }\n numberOfExtraLines = number;\n };\n this.setAriaLabel = function () {\n var ariaLabel = \"\";\n if (host.$textInputAriaLabel) {\n ariaLabel += \"\".concat(host.$textInputAriaLabel, \", \");\n }\n if (host.session) {\n var row = host.session.selection.cursor.row;\n ariaLabel += nls(\"text-input.aria-label\", \"Cursor at row $0\", [row + 1]);\n }\n text.setAttribute(\"aria-label\", ariaLabel);\n };\n this.setAriaOptions = function (options) {\n if (options.activeDescendant) {\n text.setAttribute(\"aria-haspopup\", \"true\");\n text.setAttribute(\"aria-autocomplete\", options.inline ? \"both\" : \"list\");\n text.setAttribute(\"aria-activedescendant\", options.activeDescendant);\n }\n else {\n text.setAttribute(\"aria-haspopup\", \"false\");\n text.setAttribute(\"aria-autocomplete\", \"both\");\n text.removeAttribute(\"aria-activedescendant\");\n }\n if (options.role) {\n text.setAttribute(\"role\", options.role);\n }\n if (options.setLabel) {\n text.setAttribute(\"aria-roledescription\", nls(\"text-input.aria-roledescription\", \"editor\"));\n this.setAriaLabel();\n }\n };\n this.setAriaOptions({ role: \"textbox\" });\n event.addListener(text, \"blur\", function (e) {\n if (ignoreFocusEvents)\n return;\n host.onBlur(e);\n isFocused = false;\n }, host);\n event.addListener(text, \"focus\", function (e) {\n if (ignoreFocusEvents)\n return;\n isFocused = true;\n if (useragent.isEdge) {\n try {\n if (!document.hasFocus())\n return;\n }\n catch (e) { }\n }\n host.onFocus(e);\n if (useragent.isEdge)\n setTimeout(resetSelection);\n else\n resetSelection();\n }, host);\n this.$focusScroll = false;\n this.focus = function () {\n this.setAriaOptions({\n setLabel: host.renderer.enableKeyboardAccessibility\n });\n if (tempStyle || HAS_FOCUS_ARGS || this.$focusScroll == \"browser\")\n return text.focus({ preventScroll: true });\n var top = text.style.top;\n text.style.position = \"fixed\";\n text.style.top = \"0px\";\n try {\n var isTransformed = text.getBoundingClientRect().top != 0;\n }\n catch (e) {\n return;\n }\n var ancestors = [];\n if (isTransformed) {\n var t = text.parentElement;\n while (t && t.nodeType == 1) {\n ancestors.push(t);\n t.setAttribute(\"ace_nocontext\", \"true\");\n if (!t.parentElement && t.getRootNode)\n t = t.getRootNode()[\"host\"];\n else\n t = t.parentElement;\n }\n }\n text.focus({ preventScroll: true });\n if (isTransformed) {\n ancestors.forEach(function (p) {\n p.removeAttribute(\"ace_nocontext\");\n });\n }\n setTimeout(function () {\n text.style.position = \"\";\n if (text.style.top == \"0px\")\n text.style.top = top;\n }, 0);\n };\n this.blur = function () {\n text.blur();\n };\n this.isFocused = function () {\n return isFocused;\n };\n host.on(\"beforeEndOperation\", function () {\n var curOp = host.curOp;\n var commandName = curOp && curOp.command && curOp.command.name;\n if (commandName == \"insertstring\")\n return;\n var isUserAction = commandName && (curOp.docChanged || curOp.selectionChanged);\n if (inComposition && isUserAction) {\n lastValue = text.value = \"\";\n onCompositionEnd();\n }\n resetSelection();\n });\n host.on(\"changeSelection\", this.setAriaLabel);\n var positionToSelection = function (row, column) {\n var selection = column;\n for (var i = 1; i <= row - rowStart && i < 2 * numberOfExtraLines + 1; i++) {\n selection += host.session.getLine(row - i).length + 1;\n }\n return selection;\n };\n var resetSelection = isIOS\n ? function (value) {\n if (!isFocused || (copied && !value) || sendingText)\n return;\n if (!value)\n value = \"\";\n var newValue = \"\\n ab\" + value + \"cde fg\\n\";\n if (newValue != text.value)\n text.value = lastValue = newValue;\n var selectionStart = 4;\n var selectionEnd = 4 + (value.length || (host.selection.isEmpty() ? 0 : 1));\n if (lastSelectionStart != selectionStart || lastSelectionEnd != selectionEnd) {\n text.setSelectionRange(selectionStart, selectionEnd);\n }\n lastSelectionStart = selectionStart;\n lastSelectionEnd = selectionEnd;\n }\n : function () {\n if (inComposition || sendingText)\n return;\n if (!isFocused && !afterContextMenu)\n return;\n inComposition = true;\n var selectionStart = 0;\n var selectionEnd = 0;\n var line = \"\";\n if (host.session) {\n var selection = host.selection;\n var range = selection.getRange();\n var row = selection.cursor.row;\n if (row === rowEnd + 1) {\n rowStart = rowEnd + 1;\n rowEnd = rowStart + 2 * numberOfExtraLines;\n }\n else if (row === rowStart - 1) {\n rowEnd = rowStart - 1;\n rowStart = rowEnd - 2 * numberOfExtraLines;\n }\n else if (row < rowStart - 1 || row > rowEnd + 1) {\n rowStart = row > numberOfExtraLines ? row - numberOfExtraLines : 0;\n rowEnd = row > numberOfExtraLines ? row + numberOfExtraLines : 2 * numberOfExtraLines;\n }\n var lines = [];\n for (var i = rowStart; i <= rowEnd; i++) {\n lines.push(host.session.getLine(i));\n }\n line = lines.join('\\n');\n selectionStart = positionToSelection(range.start.row, range.start.column);\n selectionEnd = positionToSelection(range.end.row, range.end.column);\n if (range.start.row < rowStart) {\n var prevLine = host.session.getLine(rowStart - 1);\n selectionStart = range.start.row < rowStart - 1 ? 0 : selectionStart;\n selectionEnd += prevLine.length + 1;\n line = prevLine + \"\\n\" + line;\n }\n else if (range.end.row > rowEnd) {\n var nextLine = host.session.getLine(rowEnd + 1);\n selectionEnd = range.end.row > rowEnd + 1 ? nextLine.length : range.end.column;\n selectionEnd += line.length + 1;\n line = line + \"\\n\" + nextLine;\n }\n else if (isMobile && row > 0) {\n line = \"\\n\" + line;\n selectionEnd += 1;\n selectionStart += 1;\n }\n if (line.length > MAX_LINE_LENGTH) {\n if (selectionStart < MAX_LINE_LENGTH && selectionEnd < MAX_LINE_LENGTH) {\n line = line.slice(0, MAX_LINE_LENGTH);\n }\n else {\n line = \"\\n\";\n if (selectionStart == selectionEnd) {\n selectionStart = selectionEnd = 0;\n }\n else {\n selectionStart = 0;\n selectionEnd = 1;\n }\n }\n }\n var newValue = line + \"\\n\\n\";\n if (newValue != lastValue) {\n text.value = lastValue = newValue;\n lastSelectionStart = lastSelectionEnd = newValue.length;\n }\n }\n if (afterContextMenu) {\n lastSelectionStart = text.selectionStart;\n lastSelectionEnd = text.selectionEnd;\n }\n if (lastSelectionEnd != selectionEnd\n || lastSelectionStart != selectionStart\n || text.selectionEnd != lastSelectionEnd // on ie edge selectionEnd changes silently after the initialization\n ) {\n try {\n text.setSelectionRange(selectionStart, selectionEnd);\n lastSelectionStart = selectionStart;\n lastSelectionEnd = selectionEnd;\n }\n catch (e) { }\n }\n inComposition = false;\n };\n this.resetSelection = resetSelection;\n if (isFocused)\n host.onFocus();\n var isAllSelected = function (text) {\n return text.selectionStart === 0 && text.selectionEnd >= lastValue.length\n && text.value === lastValue && lastValue\n && text.selectionEnd !== lastSelectionEnd;\n };\n var onSelect = function (e) {\n if (inComposition)\n return;\n if (copied) {\n copied = false;\n }\n else if (isAllSelected(text)) {\n host.selectAll();\n resetSelection();\n }\n else if (isMobile && text.selectionStart != lastSelectionStart) {\n resetSelection();\n }\n };\n var inputHandler = null;\n this.setInputHandler = function (cb) { inputHandler = cb; };\n this.getInputHandler = function () { return inputHandler; };\n var afterContextMenu = false;\n var sendText = function (value, fromInput) {\n if (afterContextMenu)\n afterContextMenu = false;\n if (pasted) {\n resetSelection();\n if (value)\n host.onPaste(value);\n pasted = false;\n return \"\";\n }\n else {\n var selectionStart = text.selectionStart;\n var selectionEnd = text.selectionEnd;\n var extendLeft = lastSelectionStart;\n var extendRight = lastValue.length - lastSelectionEnd;\n var inserted = value;\n var restoreStart = value.length - selectionStart;\n var restoreEnd = value.length - selectionEnd;\n var i = 0;\n while (extendLeft > 0 && lastValue[i] == value[i]) {\n i++;\n extendLeft--;\n }\n inserted = inserted.slice(i);\n i = 1;\n while (extendRight > 0 && lastValue.length - i > lastSelectionStart - 1 && lastValue[lastValue.length - i] == value[value.length - i]) {\n i++;\n extendRight--;\n }\n restoreStart -= i - 1;\n restoreEnd -= i - 1;\n var endIndex = inserted.length - i + 1;\n if (endIndex < 0) {\n extendLeft = -endIndex;\n endIndex = 0;\n }\n inserted = inserted.slice(0, endIndex);\n if (!fromInput && !inserted && !restoreStart && !extendLeft && !extendRight && !restoreEnd)\n return \"\";\n sendingText = true;\n var shouldReset = false;\n if (useragent.isAndroid && inserted == \". \") {\n inserted = \" \";\n shouldReset = true;\n }\n if (inserted && !extendLeft && !extendRight && !restoreStart && !restoreEnd || commandMode) {\n host.onTextInput(inserted);\n }\n else {\n host.onTextInput(inserted, {\n extendLeft: extendLeft,\n extendRight: extendRight,\n restoreStart: restoreStart,\n restoreEnd: restoreEnd\n });\n }\n sendingText = false;\n lastValue = value;\n lastSelectionStart = selectionStart;\n lastSelectionEnd = selectionEnd;\n lastRestoreEnd = restoreEnd;\n return shouldReset ? \"\\n\" : inserted;\n }\n };\n var onInput = function (e) {\n if (inComposition)\n return onCompositionUpdate();\n if (e && e.inputType) {\n if (e.inputType == \"historyUndo\")\n return host.execCommand(\"undo\");\n if (e.inputType == \"historyRedo\")\n return host.execCommand(\"redo\");\n }\n var data = text.value;\n var inserted = sendText(data, true);\n if (data.length > MAX_LINE_LENGTH + 100\n || valueResetRegex.test(inserted)\n || isMobile && lastSelectionStart < 1 && lastSelectionStart == lastSelectionEnd) {\n resetSelection();\n }\n };\n var handleClipboardData = function (e, data, forceIEMime) {\n var clipboardData = e.clipboardData || window[\"clipboardData\"];\n if (!clipboardData || BROKEN_SETDATA)\n return;\n var mime = USE_IE_MIME_TYPE || forceIEMime ? \"Text\" : \"text/plain\";\n try {\n if (data) {\n return clipboardData.setData(mime, data) !== false;\n }\n else {\n return clipboardData.getData(mime);\n }\n }\n catch (e) {\n if (!forceIEMime)\n return handleClipboardData(e, data, true);\n }\n };\n var doCopy = function (e, isCut) {\n var data = host.getCopyText();\n if (!data)\n return event.preventDefault(e);\n if (handleClipboardData(e, data)) {\n if (isIOS) {\n resetSelection(data);\n copied = data;\n setTimeout(function () {\n copied = false;\n }, 10);\n }\n isCut ? host.onCut() : host.onCopy();\n event.preventDefault(e);\n }\n else {\n copied = true;\n text.value = data;\n text.select();\n setTimeout(function () {\n copied = false;\n resetSelection();\n isCut ? host.onCut() : host.onCopy();\n });\n }\n };\n var onCut = function (e) {\n doCopy(e, true);\n };\n var onCopy = function (e) {\n doCopy(e, false);\n };\n var onPaste = function (e) {\n var data = handleClipboardData(e);\n if (clipboard.pasteCancelled())\n return;\n if (typeof data == \"string\") {\n if (data)\n host.onPaste(data, e);\n if (useragent.isIE)\n setTimeout(resetSelection);\n event.preventDefault(e);\n }\n else {\n text.value = \"\";\n pasted = true;\n }\n };\n event.addCommandKeyListener(text, function (e, hashId, keyCode) {\n if (inComposition)\n return;\n return host.onCommandKey(e, hashId, keyCode);\n }, host);\n event.addListener(text, \"select\", onSelect, host);\n event.addListener(text, \"input\", onInput, host);\n event.addListener(text, \"cut\", onCut, host);\n event.addListener(text, \"copy\", onCopy, host);\n event.addListener(text, \"paste\", onPaste, host);\n if (!('oncut' in text) || !('oncopy' in text) || !('onpaste' in text)) {\n event.addListener(parentNode, \"keydown\", function (e) {\n if ((useragent.isMac && !e.metaKey) || !e.ctrlKey)\n return;\n switch (e.keyCode) {\n case 67:\n onCopy(e);\n break;\n case 86:\n onPaste(e);\n break;\n case 88:\n onCut(e);\n break;\n }\n }, host);\n }\n var onCompositionStart = function (e) {\n if (inComposition || !host.onCompositionStart || host.$readOnly)\n return;\n inComposition = {};\n if (commandMode)\n return;\n if (e.data)\n inComposition.useTextareaForIME = false;\n setTimeout(onCompositionUpdate, 0);\n host._signal(\"compositionStart\");\n host.on(\"mousedown\", cancelComposition);\n var range = host.getSelectionRange();\n range.end.row = range.start.row;\n range.end.column = range.start.column;\n inComposition.markerRange = range;\n inComposition.selectionStart = lastSelectionStart;\n host.onCompositionStart(inComposition);\n if (inComposition.useTextareaForIME) {\n lastValue = text.value = \"\";\n lastSelectionStart = 0;\n lastSelectionEnd = 0;\n }\n else {\n if (text.msGetInputContext)\n inComposition.context = text.msGetInputContext();\n if (text.getInputContext)\n inComposition.context = text.getInputContext();\n }\n };\n var onCompositionUpdate = function () {\n if (!inComposition || !host.onCompositionUpdate || host.$readOnly)\n return;\n if (commandMode)\n return cancelComposition();\n if (inComposition.useTextareaForIME) {\n host.onCompositionUpdate(text.value);\n }\n else {\n var data = text.value;\n sendText(data);\n if (inComposition.markerRange) {\n if (inComposition.context) {\n inComposition.markerRange.start.column = inComposition.selectionStart\n = inComposition.context.compositionStartOffset;\n }\n inComposition.markerRange.end.column = inComposition.markerRange.start.column\n + lastSelectionEnd - inComposition.selectionStart + lastRestoreEnd;\n }\n }\n };\n var onCompositionEnd = function (e) {\n if (!host.onCompositionEnd || host.$readOnly)\n return;\n inComposition = false;\n host.onCompositionEnd();\n host.off(\"mousedown\", cancelComposition);\n if (e)\n onInput();\n };\n function cancelComposition() {\n ignoreFocusEvents = true;\n text.blur();\n text.focus();\n ignoreFocusEvents = false;\n }\n var syncComposition = lang.delayedCall(onCompositionUpdate, 50).schedule.bind(null, null);\n function onKeyup(e) {\n if (e.keyCode == 27 && text.value.length < text.selectionStart) {\n if (!inComposition)\n lastValue = text.value;\n lastSelectionStart = lastSelectionEnd = -1;\n resetSelection();\n }\n syncComposition();\n }\n event.addListener(text, \"compositionstart\", onCompositionStart, host);\n event.addListener(text, \"compositionupdate\", onCompositionUpdate, host);\n event.addListener(text, \"keyup\", onKeyup, host);\n event.addListener(text, \"keydown\", syncComposition, host);\n event.addListener(text, \"compositionend\", onCompositionEnd, host);\n this.getElement = function () {\n return text;\n };\n this.setCommandMode = function (value) {\n commandMode = value;\n text.readOnly = false;\n };\n this.setReadOnly = function (readOnly) {\n if (!commandMode)\n text.readOnly = readOnly;\n };\n this.setCopyWithEmptySelection = function (value) {\n };\n this.onContextMenu = function (e) {\n afterContextMenu = true;\n resetSelection();\n host._emit(\"nativecontextmenu\", { target: host, domEvent: e });\n this.moveToMouse(e, true);\n };\n this.moveToMouse = function (e, bringToFront) {\n if (!tempStyle)\n tempStyle = text.style.cssText;\n text.style.cssText = (bringToFront ? \"z-index:100000;\" : \"\")\n + (useragent.isIE ? \"opacity:0.1;\" : \"\")\n + \"text-indent: -\" + (lastSelectionStart + lastSelectionEnd) * host.renderer.characterWidth * 0.5 + \"px;\";\n var rect = host.container.getBoundingClientRect();\n var style = dom.computedStyle(host.container);\n var top = rect.top + (parseInt(style.borderTopWidth) || 0);\n var left = rect.left + (parseInt(rect.borderLeftWidth) || 0);\n var maxTop = rect.bottom - top - text.clientHeight - 2;\n var move = function (e) {\n dom.translate(text, e.clientX - left - 2, Math.min(e.clientY - top - 2, maxTop));\n };\n move(e);\n if (e.type != \"mousedown\")\n return;\n host.renderer.$isMousePressed = true;\n clearTimeout(closeTimeout);\n if (useragent.isWin)\n event.capture(host.container, move, onContextMenuClose);\n };\n this.onContextMenuClose = onContextMenuClose;\n var closeTimeout;\n function onContextMenuClose() {\n clearTimeout(closeTimeout);\n closeTimeout = setTimeout(function () {\n if (tempStyle) {\n text.style.cssText = tempStyle;\n tempStyle = '';\n }\n host.renderer.$isMousePressed = false;\n if (host.renderer.$keepTextAreaAtCursor)\n host.renderer.$moveTextAreaToCursor();\n }, 0);\n }\n var onContextMenu = function (e) {\n host.textInput.onContextMenu(e);\n onContextMenuClose();\n };\n event.addListener(text, \"mouseup\", onContextMenu, host);\n event.addListener(text, \"mousedown\", function (e) {\n e.preventDefault();\n onContextMenuClose();\n }, host);\n event.addListener(host.renderer.scroller, \"contextmenu\", onContextMenu, host);\n event.addListener(text, \"contextmenu\", onContextMenu, host);\n if (isIOS)\n addIosSelectionHandler(parentNode, host, text);\n function addIosSelectionHandler(parentNode, host, text) {\n var typingResetTimeout = null;\n var typing = false;\n text.addEventListener(\"keydown\", function (e) {\n if (typingResetTimeout)\n clearTimeout(typingResetTimeout);\n typing = true;\n }, true);\n text.addEventListener(\"keyup\", function (e) {\n typingResetTimeout = setTimeout(function () {\n typing = false;\n }, 100);\n }, true);\n var detectArrowKeys = function (e) {\n if (document.activeElement !== text)\n return;\n if (typing || inComposition || host.$mouseHandler.isMousePressed)\n return;\n if (copied) {\n return;\n }\n var selectionStart = text.selectionStart;\n var selectionEnd = text.selectionEnd;\n var key = null;\n var modifier = 0;\n if (selectionStart == 0) {\n key = KEYS.up;\n }\n else if (selectionStart == 1) {\n key = KEYS.home;\n }\n else if (selectionEnd > lastSelectionEnd && lastValue[selectionEnd] == \"\\n\") {\n key = KEYS.end;\n }\n else if (selectionStart < lastSelectionStart && lastValue[selectionStart - 1] == \" \") {\n key = KEYS.left;\n modifier = MODS.option;\n }\n else if (selectionStart < lastSelectionStart\n || (selectionStart == lastSelectionStart\n && lastSelectionEnd != lastSelectionStart\n && selectionStart == selectionEnd)) {\n key = KEYS.left;\n }\n else if (selectionEnd > lastSelectionEnd && lastValue.slice(0, selectionEnd).split(\"\\n\").length > 2) {\n key = KEYS.down;\n }\n else if (selectionEnd > lastSelectionEnd && lastValue[selectionEnd - 1] == \" \") {\n key = KEYS.right;\n modifier = MODS.option;\n }\n else if (selectionEnd > lastSelectionEnd\n || (selectionEnd == lastSelectionEnd\n && lastSelectionEnd != lastSelectionStart\n && selectionStart == selectionEnd)) {\n key = KEYS.right;\n }\n if (selectionStart !== selectionEnd)\n modifier |= MODS.shift;\n if (key) {\n var result = host.onCommandKey({}, modifier, key);\n if (!result && host.commands) {\n key = KEYS.keyCodeToString(key);\n var command = host.commands.findKeyCommand(modifier, key);\n if (command)\n host.execCommand(command);\n }\n lastSelectionStart = selectionStart;\n lastSelectionEnd = selectionEnd;\n resetSelection(\"\");\n }\n };\n document.addEventListener(\"selectionchange\", detectArrowKeys);\n host.on(\"destroy\", function () {\n document.removeEventListener(\"selectionchange\", detectArrowKeys);\n });\n }\n this.destroy = function () {\n if (text.parentElement)\n text.parentElement.removeChild(text);\n };\n};\nexports.TextInput = TextInput;\nexports.$setUserAgentForTests = function (_isMobile, _isIOS) {\n isMobile = _isMobile;\n isIOS = _isIOS;\n};\n\n});\n\nace.define(\"ace/mouse/default_handlers\",[\"require\",\"exports\",\"module\",\"ace/lib/useragent\"], function(require, exports, module){\"use strict\";\nvar useragent = require(\"../lib/useragent\");\nvar DRAG_OFFSET = 0; // pixels\nvar SCROLL_COOLDOWN_T = 550; // milliseconds\nvar DefaultHandlers = /** @class */ (function () {\n function DefaultHandlers(mouseHandler) {\n mouseHandler.$clickSelection = null;\n var editor = mouseHandler.editor;\n editor.setDefaultHandler(\"mousedown\", this.onMouseDown.bind(mouseHandler));\n editor.setDefaultHandler(\"dblclick\", this.onDoubleClick.bind(mouseHandler));\n editor.setDefaultHandler(\"tripleclick\", this.onTripleClick.bind(mouseHandler));\n editor.setDefaultHandler(\"quadclick\", this.onQuadClick.bind(mouseHandler));\n editor.setDefaultHandler(\"mousewheel\", this.onMouseWheel.bind(mouseHandler));\n var exports = [\"select\", \"startSelect\", \"selectEnd\", \"selectAllEnd\", \"selectByWordsEnd\",\n \"selectByLinesEnd\", \"dragWait\", \"dragWaitEnd\", \"focusWait\"];\n exports.forEach(function (x) {\n mouseHandler[x] = this[x];\n }, this);\n mouseHandler[\"selectByLines\"] = this.extendSelectionBy.bind(mouseHandler, \"getLineRange\");\n mouseHandler[\"selectByWords\"] = this.extendSelectionBy.bind(mouseHandler, \"getWordRange\");\n }\n DefaultHandlers.prototype.onMouseDown = function (ev) {\n var inSelection = ev.inSelection();\n var pos = ev.getDocumentPosition();\n this.mousedownEvent = ev;\n var editor = this.editor;\n var button = ev.getButton();\n if (button !== 0) {\n var selectionRange = editor.getSelectionRange();\n var selectionEmpty = selectionRange.isEmpty();\n if (selectionEmpty || button == 1)\n editor.selection.moveToPosition(pos);\n if (button == 2) {\n editor.textInput.onContextMenu(ev.domEvent);\n if (!useragent.isMozilla)\n ev.preventDefault();\n }\n return;\n }\n this.mousedownEvent.time = Date.now();\n if (inSelection && !editor.isFocused()) {\n editor.focus();\n if (this.$focusTimeout && !this.$clickSelection && !editor.inMultiSelectMode) {\n this.setState(\"focusWait\");\n this.captureMouse(ev);\n return;\n }\n }\n this.captureMouse(ev);\n this.startSelect(pos, ev.domEvent._clicks > 1);\n return ev.preventDefault();\n };\n DefaultHandlers.prototype.startSelect = function (pos, waitForClickSelection) {\n pos = pos || this.editor.renderer.screenToTextCoordinates(this.x, this.y);\n var editor = this.editor;\n if (!this.mousedownEvent)\n return;\n if (this.mousedownEvent.getShiftKey())\n editor.selection.selectToPosition(pos);\n else if (!waitForClickSelection)\n editor.selection.moveToPosition(pos);\n if (!waitForClickSelection)\n this.select();\n editor.setStyle(\"ace_selecting\");\n this.setState(\"select\");\n };\n DefaultHandlers.prototype.select = function () {\n var anchor, editor = this.editor;\n var cursor = editor.renderer.screenToTextCoordinates(this.x, this.y);\n if (this.$clickSelection) {\n var cmp = this.$clickSelection.comparePoint(cursor);\n if (cmp == -1) {\n anchor = this.$clickSelection.end;\n }\n else if (cmp == 1) {\n anchor = this.$clickSelection.start;\n }\n else {\n var orientedRange = calcRangeOrientation(this.$clickSelection, cursor);\n cursor = orientedRange.cursor;\n anchor = orientedRange.anchor;\n }\n editor.selection.setSelectionAnchor(anchor.row, anchor.column);\n }\n editor.selection.selectToPosition(cursor);\n editor.renderer.scrollCursorIntoView();\n };\n DefaultHandlers.prototype.extendSelectionBy = function (unitName) {\n var anchor, editor = this.editor;\n var cursor = editor.renderer.screenToTextCoordinates(this.x, this.y);\n var range = editor.selection[unitName](cursor.row, cursor.column);\n if (this.$clickSelection) {\n var cmpStart = this.$clickSelection.comparePoint(range.start);\n var cmpEnd = this.$clickSelection.comparePoint(range.end);\n if (cmpStart == -1 && cmpEnd <= 0) {\n anchor = this.$clickSelection.end;\n if (range.end.row != cursor.row || range.end.column != cursor.column)\n cursor = range.start;\n }\n else if (cmpEnd == 1 && cmpStart >= 0) {\n anchor = this.$clickSelection.start;\n if (range.start.row != cursor.row || range.start.column != cursor.column)\n cursor = range.end;\n }\n else if (cmpStart == -1 && cmpEnd == 1) {\n cursor = range.end;\n anchor = range.start;\n }\n else {\n var orientedRange = calcRangeOrientation(this.$clickSelection, cursor);\n cursor = orientedRange.cursor;\n anchor = orientedRange.anchor;\n }\n editor.selection.setSelectionAnchor(anchor.row, anchor.column);\n }\n editor.selection.selectToPosition(cursor);\n editor.renderer.scrollCursorIntoView();\n };\n DefaultHandlers.prototype.selectByLinesEnd = function () {\n this.$clickSelection = null;\n this.editor.unsetStyle(\"ace_selecting\");\n };\n DefaultHandlers.prototype.focusWait = function () {\n var distance = calcDistance(this.mousedownEvent.x, this.mousedownEvent.y, this.x, this.y);\n var time = Date.now();\n if (distance > DRAG_OFFSET || time - this.mousedownEvent.time > this.$focusTimeout)\n this.startSelect(this.mousedownEvent.getDocumentPosition());\n };\n DefaultHandlers.prototype.onDoubleClick = function (ev) {\n var pos = ev.getDocumentPosition();\n var editor = this.editor;\n var session = editor.session;\n var range = session.getBracketRange(pos);\n if (range) {\n if (range.isEmpty()) {\n range.start.column--;\n range.end.column++;\n }\n this.setState(\"select\");\n }\n else {\n range = editor.selection.getWordRange(pos.row, pos.column);\n this.setState(\"selectByWords\");\n }\n this.$clickSelection = range;\n this.select();\n };\n DefaultHandlers.prototype.onTripleClick = function (ev) {\n var pos = ev.getDocumentPosition();\n var editor = this.editor;\n this.setState(\"selectByLines\");\n var range = editor.getSelectionRange();\n if (range.isMultiLine() && range.contains(pos.row, pos.column)) {\n this.$clickSelection = editor.selection.getLineRange(range.start.row);\n this.$clickSelection.end = editor.selection.getLineRange(range.end.row).end;\n }\n else {\n this.$clickSelection = editor.selection.getLineRange(pos.row);\n }\n this.select();\n };\n DefaultHandlers.prototype.onQuadClick = function (ev) {\n var editor = this.editor;\n editor.selectAll();\n this.$clickSelection = editor.getSelectionRange();\n this.setState(\"selectAll\");\n };\n DefaultHandlers.prototype.onMouseWheel = function (ev) {\n if (ev.getAccelKey())\n return;\n if (ev.getShiftKey() && ev.wheelY && !ev.wheelX) {\n ev.wheelX = ev.wheelY;\n ev.wheelY = 0;\n }\n var editor = this.editor;\n if (!this.$lastScroll)\n this.$lastScroll = { t: 0, vx: 0, vy: 0, allowed: 0 };\n var prevScroll = this.$lastScroll;\n var t = ev.domEvent.timeStamp;\n var dt = t - prevScroll.t;\n var vx = dt ? ev.wheelX / dt : prevScroll.vx;\n var vy = dt ? ev.wheelY / dt : prevScroll.vy;\n if (dt < SCROLL_COOLDOWN_T) {\n vx = (vx + prevScroll.vx) / 2;\n vy = (vy + prevScroll.vy) / 2;\n }\n var direction = Math.abs(vx / vy);\n var canScroll = false;\n if (direction >= 1 && editor.renderer.isScrollableBy(ev.wheelX * ev.speed, 0))\n canScroll = true;\n if (direction <= 1 && editor.renderer.isScrollableBy(0, ev.wheelY * ev.speed))\n canScroll = true;\n if (canScroll) {\n prevScroll.allowed = t;\n }\n else if (t - prevScroll.allowed < SCROLL_COOLDOWN_T) {\n var isSlower = Math.abs(vx) <= 1.5 * Math.abs(prevScroll.vx)\n && Math.abs(vy) <= 1.5 * Math.abs(prevScroll.vy);\n if (isSlower) {\n canScroll = true;\n prevScroll.allowed = t;\n }\n else {\n prevScroll.allowed = 0;\n }\n }\n prevScroll.t = t;\n prevScroll.vx = vx;\n prevScroll.vy = vy;\n if (canScroll) {\n editor.renderer.scrollBy(ev.wheelX * ev.speed, ev.wheelY * ev.speed);\n return ev.stop();\n }\n };\n return DefaultHandlers;\n}());\nDefaultHandlers.prototype.selectEnd = DefaultHandlers.prototype.selectByLinesEnd;\nDefaultHandlers.prototype.selectAllEnd = DefaultHandlers.prototype.selectByLinesEnd;\nDefaultHandlers.prototype.selectByWordsEnd = DefaultHandlers.prototype.selectByLinesEnd;\nexports.DefaultHandlers = DefaultHandlers;\nfunction calcDistance(ax, ay, bx, by) {\n return Math.sqrt(Math.pow(bx - ax, 2) + Math.pow(by - ay, 2));\n}\nfunction calcRangeOrientation(range, cursor) {\n if (range.start.row == range.end.row)\n var cmp = 2 * cursor.column - range.start.column - range.end.column;\n else if (range.start.row == range.end.row - 1 && !range.start.column && !range.end.column)\n var cmp = cursor.column - 4;\n else\n var cmp = 2 * cursor.row - range.start.row - range.end.row;\n if (cmp < 0)\n return { cursor: range.start, anchor: range.end };\n else\n return { cursor: range.end, anchor: range.start };\n}\n\n});\n\nace.define(\"ace/lib/scroll\",[\"require\",\"exports\",\"module\"], function(require, exports, module){exports.preventParentScroll = function preventParentScroll(event) {\n event.stopPropagation();\n var target = event.currentTarget;\n var contentOverflows = target.scrollHeight > target.clientHeight;\n if (!contentOverflows) {\n event.preventDefault();\n }\n};\n\n});\n\nace.define(\"ace/tooltip\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\",\"ace/lib/event\",\"ace/range\",\"ace/lib/scroll\"], function(require, exports, module){\"use strict\";\nvar __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __values = (this && this.__values) || function(o) {\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\n if (m) return m.call(o);\n if (o && typeof o.length === \"number\") return {\n next: function () {\n if (o && i >= o.length) o = void 0;\n return { value: o && o[i++], done: !o };\n }\n };\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\n};\nvar dom = require(\"./lib/dom\");\nvar event = require(\"./lib/event\");\nvar Range = require(\"./range\").Range;\nvar preventParentScroll = require(\"./lib/scroll\").preventParentScroll;\nvar CLASSNAME = \"ace_tooltip\";\nvar Tooltip = /** @class */ (function () {\n function Tooltip(parentNode) {\n this.isOpen = false;\n this.$element = null;\n this.$parentNode = parentNode;\n }\n Tooltip.prototype.$init = function () {\n this.$element = dom.createElement(\"div\");\n this.$element.className = CLASSNAME;\n this.$element.style.display = \"none\";\n this.$parentNode.appendChild(this.$element);\n return this.$element;\n };\n Tooltip.prototype.getElement = function () {\n return this.$element || this.$init();\n };\n Tooltip.prototype.setText = function (text) {\n this.getElement().textContent = text;\n };\n Tooltip.prototype.setHtml = function (html) {\n this.getElement().innerHTML = html;\n };\n Tooltip.prototype.setPosition = function (x, y) {\n this.getElement().style.left = x + \"px\";\n this.getElement().style.top = y + \"px\";\n };\n Tooltip.prototype.setClassName = function (className) {\n dom.addCssClass(this.getElement(), className);\n };\n Tooltip.prototype.setTheme = function (theme) {\n this.$element.className = CLASSNAME + \" \" +\n (theme.isDark ? \"ace_dark \" : \"\") + (theme.cssClass || \"\");\n };\n Tooltip.prototype.show = function (text, x, y) {\n if (text != null)\n this.setText(text);\n if (x != null && y != null)\n this.setPosition(x, y);\n if (!this.isOpen) {\n this.getElement().style.display = \"block\";\n this.isOpen = true;\n }\n };\n Tooltip.prototype.hide = function (e) {\n if (this.isOpen) {\n this.getElement().style.display = \"none\";\n this.getElement().className = CLASSNAME;\n this.isOpen = false;\n }\n };\n Tooltip.prototype.getHeight = function () {\n return this.getElement().offsetHeight;\n };\n Tooltip.prototype.getWidth = function () {\n return this.getElement().offsetWidth;\n };\n Tooltip.prototype.destroy = function () {\n this.isOpen = false;\n if (this.$element && this.$element.parentNode) {\n this.$element.parentNode.removeChild(this.$element);\n }\n };\n return Tooltip;\n}());\nvar PopupManager = /** @class */ (function () {\n function PopupManager() {\n this.popups = [];\n }\n PopupManager.prototype.addPopup = function (popup) {\n this.popups.push(popup);\n this.updatePopups();\n };\n PopupManager.prototype.removePopup = function (popup) {\n var index = this.popups.indexOf(popup);\n if (index !== -1) {\n this.popups.splice(index, 1);\n this.updatePopups();\n }\n };\n PopupManager.prototype.updatePopups = function () {\n var e_1, _a, e_2, _b;\n this.popups.sort(function (a, b) { return b.priority - a.priority; });\n var visiblepopups = [];\n try {\n for (var _c = __values(this.popups), _d = _c.next(); !_d.done; _d = _c.next()) {\n var popup = _d.value;\n var shouldDisplay = true;\n try {\n for (var visiblepopups_1 = (e_2 = void 0, __values(visiblepopups)), visiblepopups_1_1 = visiblepopups_1.next(); !visiblepopups_1_1.done; visiblepopups_1_1 = visiblepopups_1.next()) {\n var visiblePopup = visiblepopups_1_1.value;\n if (this.doPopupsOverlap(visiblePopup, popup)) {\n shouldDisplay = false;\n break;\n }\n }\n }\n catch (e_2_1) { e_2 = { error: e_2_1 }; }\n finally {\n try {\n if (visiblepopups_1_1 && !visiblepopups_1_1.done && (_b = visiblepopups_1.return)) _b.call(visiblepopups_1);\n }\n finally { if (e_2) throw e_2.error; }\n }\n if (shouldDisplay) {\n visiblepopups.push(popup);\n }\n else {\n popup.hide();\n }\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (_d && !_d.done && (_a = _c.return)) _a.call(_c);\n }\n finally { if (e_1) throw e_1.error; }\n }\n };\n PopupManager.prototype.doPopupsOverlap = function (popupA, popupB) {\n var rectA = popupA.getElement().getBoundingClientRect();\n var rectB = popupB.getElement().getBoundingClientRect();\n return (rectA.left < rectB.right && rectA.right > rectB.left && rectA.top < rectB.bottom && rectA.bottom\n > rectB.top);\n };\n return PopupManager;\n}());\nvar popupManager = new PopupManager();\nexports.popupManager = popupManager;\nexports.Tooltip = Tooltip;\nvar HoverTooltip = /** @class */ (function (_super) {\n __extends(HoverTooltip, _super);\n function HoverTooltip(parentNode) {\n if (parentNode === void 0) { parentNode = document.body; }\n var _this = _super.call(this, parentNode) || this;\n _this.timeout = undefined;\n _this.lastT = 0;\n _this.idleTime = 350;\n _this.lastEvent = undefined;\n _this.onMouseOut = _this.onMouseOut.bind(_this);\n _this.onMouseMove = _this.onMouseMove.bind(_this);\n _this.waitForHover = _this.waitForHover.bind(_this);\n _this.hide = _this.hide.bind(_this);\n var el = _this.getElement();\n el.style.whiteSpace = \"pre-wrap\";\n el.style.pointerEvents = \"auto\";\n el.addEventListener(\"mouseout\", _this.onMouseOut);\n el.tabIndex = -1;\n el.addEventListener(\"blur\", function () {\n if (!el.contains(document.activeElement))\n this.hide();\n }.bind(_this));\n el.addEventListener(\"wheel\", preventParentScroll);\n return _this;\n }\n HoverTooltip.prototype.addToEditor = function (editor) {\n editor.on(\"mousemove\", this.onMouseMove);\n editor.on(\"mousedown\", this.hide);\n editor.renderer.getMouseEventTarget().addEventListener(\"mouseout\", this.onMouseOut, true);\n };\n HoverTooltip.prototype.removeFromEditor = function (editor) {\n editor.off(\"mousemove\", this.onMouseMove);\n editor.off(\"mousedown\", this.hide);\n editor.renderer.getMouseEventTarget().removeEventListener(\"mouseout\", this.onMouseOut, true);\n if (this.timeout) {\n clearTimeout(this.timeout);\n this.timeout = null;\n }\n };\n HoverTooltip.prototype.onMouseMove = function (e, editor) {\n this.lastEvent = e;\n this.lastT = Date.now();\n var isMousePressed = editor.$mouseHandler.isMousePressed;\n if (this.isOpen) {\n var pos = this.lastEvent && this.lastEvent.getDocumentPosition();\n if (!this.range\n || !this.range.contains(pos.row, pos.column)\n || isMousePressed\n || this.isOutsideOfText(this.lastEvent)) {\n this.hide();\n }\n }\n if (this.timeout || isMousePressed)\n return;\n this.lastEvent = e;\n this.timeout = setTimeout(this.waitForHover, this.idleTime);\n };\n HoverTooltip.prototype.waitForHover = function () {\n if (this.timeout)\n clearTimeout(this.timeout);\n var dt = Date.now() - this.lastT;\n if (this.idleTime - dt > 10) {\n this.timeout = setTimeout(this.waitForHover, this.idleTime - dt);\n return;\n }\n this.timeout = null;\n if (this.lastEvent && !this.isOutsideOfText(this.lastEvent)) {\n this.$gatherData(this.lastEvent, this.lastEvent.editor);\n }\n };\n HoverTooltip.prototype.isOutsideOfText = function (e) {\n var editor = e.editor;\n var docPos = e.getDocumentPosition();\n var line = editor.session.getLine(docPos.row);\n if (docPos.column == line.length) {\n var screenPos = editor.renderer.pixelToScreenCoordinates(e.clientX, e.clientY);\n var clippedPos = editor.session.documentToScreenPosition(docPos.row, docPos.column);\n if (clippedPos.column != screenPos.column\n || clippedPos.row != screenPos.row) {\n return true;\n }\n }\n return false;\n };\n HoverTooltip.prototype.setDataProvider = function (value) {\n this.$gatherData = value;\n };\n HoverTooltip.prototype.showForRange = function (editor, range, domNode, startingEvent) {\n var MARGIN = 10;\n if (startingEvent && startingEvent != this.lastEvent)\n return;\n if (this.isOpen && document.activeElement == this.getElement())\n return;\n var renderer = editor.renderer;\n if (!this.isOpen) {\n popupManager.addPopup(this);\n this.$registerCloseEvents();\n this.setTheme(renderer.theme);\n }\n this.isOpen = true;\n this.addMarker(range, editor.session);\n this.range = Range.fromPoints(range.start, range.end);\n var position = renderer.textToScreenCoordinates(range.start.row, range.start.column);\n var rect = renderer.scroller.getBoundingClientRect();\n if (position.pageX < rect.left)\n position.pageX = rect.left;\n var element = this.getElement();\n element.innerHTML = \"\";\n element.appendChild(domNode);\n element.style.maxHeight = \"\";\n element.style.display = \"block\";\n var labelHeight = element.clientHeight;\n var labelWidth = element.clientWidth;\n var spaceBelow = window.innerHeight - position.pageY - renderer.lineHeight;\n var isAbove = true;\n if (position.pageY - labelHeight < 0 && position.pageY < spaceBelow) {\n isAbove = false;\n }\n element.style.maxHeight = (isAbove ? position.pageY : spaceBelow) - MARGIN + \"px\";\n element.style.top = isAbove ? \"\" : position.pageY + renderer.lineHeight + \"px\";\n element.style.bottom = isAbove ? window.innerHeight - position.pageY + \"px\" : \"\";\n element.style.left = Math.min(position.pageX, window.innerWidth - labelWidth - MARGIN) + \"px\";\n };\n HoverTooltip.prototype.addMarker = function (range, session) {\n if (this.marker) {\n this.$markerSession.removeMarker(this.marker);\n }\n this.$markerSession = session;\n this.marker = session && session.addMarker(range, \"ace_highlight-marker\", \"text\");\n };\n HoverTooltip.prototype.hide = function (e) {\n if (!e && document.activeElement == this.getElement())\n return;\n if (e && e.target && (e.type != \"keydown\" || e.ctrlKey || e.metaKey) && this.$element.contains(e.target))\n return;\n this.lastEvent = null;\n if (this.timeout)\n clearTimeout(this.timeout);\n this.timeout = null;\n this.addMarker(null);\n if (this.isOpen) {\n this.$removeCloseEvents();\n this.getElement().style.display = \"none\";\n this.isOpen = false;\n popupManager.removePopup(this);\n }\n };\n HoverTooltip.prototype.$registerCloseEvents = function () {\n window.addEventListener(\"keydown\", this.hide, true);\n window.addEventListener(\"wheel\", this.hide, true);\n window.addEventListener(\"mousedown\", this.hide, true);\n };\n HoverTooltip.prototype.$removeCloseEvents = function () {\n window.removeEventListener(\"keydown\", this.hide, true);\n window.removeEventListener(\"wheel\", this.hide, true);\n window.removeEventListener(\"mousedown\", this.hide, true);\n };\n HoverTooltip.prototype.onMouseOut = function (e) {\n if (this.timeout) {\n clearTimeout(this.timeout);\n this.timeout = null;\n }\n this.lastEvent = null;\n if (!this.isOpen)\n return;\n if (!e.relatedTarget || this.getElement().contains(e.relatedTarget))\n return;\n if (e && e.currentTarget.contains(e.relatedTarget))\n return;\n if (!e.relatedTarget.classList.contains(\"ace_content\"))\n this.hide();\n };\n return HoverTooltip;\n}(Tooltip));\nexports.HoverTooltip = HoverTooltip;\n\n});\n\nace.define(\"ace/mouse/default_gutter_handler\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\",\"ace/lib/event\",\"ace/tooltip\",\"ace/config\",\"ace/lib/lang\"], function(require, exports, module){\"use strict\";\nvar __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __values = (this && this.__values) || function(o) {\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\n if (m) return m.call(o);\n if (o && typeof o.length === \"number\") return {\n next: function () {\n if (o && i >= o.length) o = void 0;\n return { value: o && o[i++], done: !o };\n }\n };\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\n};\nvar dom = require(\"../lib/dom\");\nvar event = require(\"../lib/event\");\nvar Tooltip = require(\"../tooltip\").Tooltip;\nvar nls = require(\"../config\").nls;\nvar lang = require(\"../lib/lang\");\nfunction GutterHandler(mouseHandler) {\n var editor = mouseHandler.editor;\n var gutter = editor.renderer.$gutterLayer;\n var tooltip = new GutterTooltip(editor);\n mouseHandler.editor.setDefaultHandler(\"guttermousedown\", function (e) {\n if (!editor.isFocused() || e.getButton() != 0)\n return;\n var gutterRegion = gutter.getRegion(e);\n if (gutterRegion == \"foldWidgets\")\n return;\n var row = e.getDocumentPosition().row;\n var selection = editor.session.selection;\n if (e.getShiftKey())\n selection.selectTo(row, 0);\n else {\n if (e.domEvent.detail == 2) {\n editor.selectAll();\n return e.preventDefault();\n }\n mouseHandler.$clickSelection = editor.selection.getLineRange(row);\n }\n mouseHandler.setState(\"selectByLines\");\n mouseHandler.captureMouse(e);\n return e.preventDefault();\n });\n var tooltipTimeout, mouseEvent;\n function showTooltip() {\n var row = mouseEvent.getDocumentPosition().row;\n var maxRow = editor.session.getLength();\n if (row == maxRow) {\n var screenRow = editor.renderer.pixelToScreenCoordinates(0, mouseEvent.y).row;\n var pos = mouseEvent.$pos;\n if (screenRow > editor.session.documentToScreenRow(pos.row, pos.column))\n return hideTooltip();\n }\n tooltip.showTooltip(row);\n if (!tooltip.isOpen)\n return;\n editor.on(\"mousewheel\", hideTooltip);\n if (mouseHandler.$tooltipFollowsMouse) {\n moveTooltip(mouseEvent);\n }\n else {\n var gutterRow = mouseEvent.getGutterRow();\n var gutterCell = gutter.$lines.get(gutterRow);\n if (gutterCell) {\n var gutterElement = gutterCell.element.querySelector(\".ace_gutter_annotation\");\n var rect = gutterElement.getBoundingClientRect();\n var style = tooltip.getElement().style;\n style.left = rect.right + \"px\";\n style.top = rect.bottom + \"px\";\n }\n else {\n moveTooltip(mouseEvent);\n }\n }\n }\n function hideTooltip() {\n if (tooltipTimeout)\n tooltipTimeout = clearTimeout(tooltipTimeout);\n if (tooltip.isOpen) {\n tooltip.hideTooltip();\n editor.off(\"mousewheel\", hideTooltip);\n }\n }\n function moveTooltip(e) {\n tooltip.setPosition(e.x, e.y);\n }\n mouseHandler.editor.setDefaultHandler(\"guttermousemove\", function (e) {\n var target = e.domEvent.target || e.domEvent.srcElement;\n if (dom.hasCssClass(target, \"ace_fold-widget\"))\n return hideTooltip();\n if (tooltip.isOpen && mouseHandler.$tooltipFollowsMouse)\n moveTooltip(e);\n mouseEvent = e;\n if (tooltipTimeout)\n return;\n tooltipTimeout = setTimeout(function () {\n tooltipTimeout = null;\n if (mouseEvent && !mouseHandler.isMousePressed)\n showTooltip();\n else\n hideTooltip();\n }, 50);\n });\n event.addListener(editor.renderer.$gutter, \"mouseout\", function (e) {\n mouseEvent = null;\n if (!tooltip.isOpen || tooltipTimeout)\n return;\n tooltipTimeout = setTimeout(function () {\n tooltipTimeout = null;\n hideTooltip();\n }, 50);\n }, editor);\n editor.on(\"changeSession\", hideTooltip);\n editor.on(\"input\", hideTooltip);\n}\nexports.GutterHandler = GutterHandler;\nvar GutterTooltip = /** @class */ (function (_super) {\n __extends(GutterTooltip, _super);\n function GutterTooltip(editor) {\n var _this = _super.call(this, editor.container) || this;\n _this.editor = editor;\n return _this;\n }\n GutterTooltip.prototype.setPosition = function (x, y) {\n var windowWidth = window.innerWidth || document.documentElement.clientWidth;\n var windowHeight = window.innerHeight || document.documentElement.clientHeight;\n var width = this.getWidth();\n var height = this.getHeight();\n x += 15;\n y += 15;\n if (x + width > windowWidth) {\n x -= (x + width) - windowWidth;\n }\n if (y + height > windowHeight) {\n y -= 20 + height;\n }\n Tooltip.prototype.setPosition.call(this, x, y);\n };\n Object.defineProperty(GutterTooltip, \"annotationLabels\", {\n get: function () {\n return {\n error: {\n singular: nls(\"gutter-tooltip.aria-label.error.singular\", \"error\"),\n plural: nls(\"gutter-tooltip.aria-label.error.plural\", \"errors\")\n },\n security: {\n singular: nls(\"gutter-tooltip.aria-label.security.singular\", \"security finding\"),\n plural: nls(\"gutter-tooltip.aria-label.security.plural\", \"security findings\")\n },\n warning: {\n singular: nls(\"gutter-tooltip.aria-label.warning.singular\", \"warning\"),\n plural: nls(\"gutter-tooltip.aria-label.warning.plural\", \"warnings\")\n },\n info: {\n singular: nls(\"gutter-tooltip.aria-label.info.singular\", \"information message\"),\n plural: nls(\"gutter-tooltip.aria-label.info.plural\", \"information messages\")\n },\n hint: {\n singular: nls(\"gutter-tooltip.aria-label.hint.singular\", \"suggestion\"),\n plural: nls(\"gutter-tooltip.aria-label.hint.plural\", \"suggestions\")\n }\n };\n },\n enumerable: false,\n configurable: true\n });\n GutterTooltip.prototype.showTooltip = function (row) {\n var _a;\n var gutter = this.editor.renderer.$gutterLayer;\n var annotationsInRow = gutter.$annotations[row];\n var annotation;\n if (annotationsInRow)\n annotation = {\n displayText: Array.from(annotationsInRow.displayText),\n type: Array.from(annotationsInRow.type)\n };\n else\n annotation = { displayText: [], type: [] };\n var fold = gutter.session.getFoldLine(row);\n if (fold && gutter.$showFoldedAnnotations) {\n var annotationsInFold = { error: [], security: [], warning: [], info: [], hint: [] };\n var severityRank = { error: 1, security: 2, warning: 3, info: 4, hint: 5 };\n var mostSevereAnnotationTypeInFold;\n for (var i = row + 1; i <= fold.end.row; i++) {\n if (!gutter.$annotations[i])\n continue;\n for (var j = 0; j < gutter.$annotations[i].text.length; j++) {\n var annotationType = gutter.$annotations[i].type[j];\n annotationsInFold[annotationType].push(gutter.$annotations[i].text[j]);\n if (!mostSevereAnnotationTypeInFold ||\n severityRank[annotationType] < severityRank[mostSevereAnnotationTypeInFold]) {\n mostSevereAnnotationTypeInFold = annotationType;\n }\n }\n }\n if ([\"error\", \"security\", \"warning\"].includes(mostSevereAnnotationTypeInFold)) {\n var summaryFoldedAnnotations = \"\".concat(GutterTooltip.annotationsToSummaryString(annotationsInFold), \" in folded code.\");\n annotation.displayText.push(summaryFoldedAnnotations);\n annotation.type.push(mostSevereAnnotationTypeInFold + \"_fold\");\n }\n }\n if (annotation.displayText.length === 0)\n return this.hide();\n var annotationMessages = { error: [], security: [], warning: [], info: [], hint: [] };\n var iconClassName = gutter.$useSvgGutterIcons ? \"ace_icon_svg\" : \"ace_icon\";\n for (var i = 0; i < annotation.displayText.length; i++) {\n var lineElement = dom.createElement(\"span\");\n var iconElement = dom.createElement(\"span\");\n (_a = iconElement.classList).add.apply(_a, [\"ace_\".concat(annotation.type[i]), iconClassName]);\n iconElement.setAttribute(\"aria-label\", \"\".concat(GutterTooltip.annotationLabels[annotation.type[i].replace(\"_fold\", \"\")].singular));\n iconElement.setAttribute(\"role\", \"img\");\n iconElement.appendChild(dom.createTextNode(\" \"));\n lineElement.appendChild(iconElement);\n lineElement.appendChild(dom.createTextNode(annotation.displayText[i]));\n lineElement.appendChild(dom.createElement(\"br\"));\n annotationMessages[annotation.type[i].replace(\"_fold\", \"\")].push(lineElement);\n }\n var tooltipElement = this.getElement();\n dom.removeChildren(tooltipElement);\n annotationMessages.error.forEach(function (el) { return tooltipElement.appendChild(el); });\n annotationMessages.security.forEach(function (el) { return tooltipElement.appendChild(el); });\n annotationMessages.warning.forEach(function (el) { return tooltipElement.appendChild(el); });\n annotationMessages.info.forEach(function (el) { return tooltipElement.appendChild(el); });\n annotationMessages.hint.forEach(function (el) { return tooltipElement.appendChild(el); });\n tooltipElement.setAttribute(\"aria-live\", \"polite\");\n if (!this.isOpen) {\n this.setTheme(this.editor.renderer.theme);\n this.setClassName(\"ace_gutter-tooltip\");\n }\n this.show();\n this.editor._signal(\"showGutterTooltip\", this);\n };\n GutterTooltip.prototype.hideTooltip = function () {\n this.$element.removeAttribute(\"aria-live\");\n this.hide();\n this.editor._signal(\"hideGutterTooltip\", this);\n };\n GutterTooltip.annotationsToSummaryString = function (annotations) {\n var e_1, _a;\n var summary = [];\n var annotationTypes = [\"error\", \"security\", \"warning\", \"info\", \"hint\"];\n try {\n for (var annotationTypes_1 = __values(annotationTypes), annotationTypes_1_1 = annotationTypes_1.next(); !annotationTypes_1_1.done; annotationTypes_1_1 = annotationTypes_1.next()) {\n var annotationType = annotationTypes_1_1.value;\n if (!annotations[annotationType].length)\n continue;\n var label = annotations[annotationType].length === 1 ? GutterTooltip.annotationLabels[annotationType].singular : GutterTooltip.annotationLabels[annotationType].plural;\n summary.push(\"\".concat(annotations[annotationType].length, \" \").concat(label));\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (annotationTypes_1_1 && !annotationTypes_1_1.done && (_a = annotationTypes_1.return)) _a.call(annotationTypes_1);\n }\n finally { if (e_1) throw e_1.error; }\n }\n return summary.join(\", \");\n };\n return GutterTooltip;\n}(Tooltip));\nexports.GutterTooltip = GutterTooltip;\n\n});\n\nace.define(\"ace/mouse/mouse_event\",[\"require\",\"exports\",\"module\",\"ace/lib/event\",\"ace/lib/useragent\"], function(require, exports, module){\"use strict\";\nvar event = require(\"../lib/event\");\nvar useragent = require(\"../lib/useragent\");\nvar MouseEvent = /** @class */ (function () {\n function MouseEvent(domEvent, editor) { this.speed; this.wheelX; this.wheelY;\n this.domEvent = domEvent;\n this.editor = editor;\n this.x = this.clientX = domEvent.clientX;\n this.y = this.clientY = domEvent.clientY;\n this.$pos = null;\n this.$inSelection = null;\n this.propagationStopped = false;\n this.defaultPrevented = false;\n }\n MouseEvent.prototype.stopPropagation = function () {\n event.stopPropagation(this.domEvent);\n this.propagationStopped = true;\n };\n MouseEvent.prototype.preventDefault = function () {\n event.preventDefault(this.domEvent);\n this.defaultPrevented = true;\n };\n MouseEvent.prototype.stop = function () {\n this.stopPropagation();\n this.preventDefault();\n };\n MouseEvent.prototype.getDocumentPosition = function () {\n if (this.$pos)\n return this.$pos;\n this.$pos = this.editor.renderer.screenToTextCoordinates(this.clientX, this.clientY);\n return this.$pos;\n };\n MouseEvent.prototype.getGutterRow = function () {\n var documentRow = this.getDocumentPosition().row;\n var screenRow = this.editor.session.documentToScreenRow(documentRow, 0);\n var screenTopRow = this.editor.session.documentToScreenRow(this.editor.renderer.$gutterLayer.$lines.get(0).row, 0);\n return screenRow - screenTopRow;\n };\n MouseEvent.prototype.inSelection = function () {\n if (this.$inSelection !== null)\n return this.$inSelection;\n var editor = this.editor;\n var selectionRange = editor.getSelectionRange();\n if (selectionRange.isEmpty())\n this.$inSelection = false;\n else {\n var pos = this.getDocumentPosition();\n this.$inSelection = selectionRange.contains(pos.row, pos.column);\n }\n return this.$inSelection;\n };\n MouseEvent.prototype.getButton = function () {\n return event.getButton(this.domEvent);\n };\n MouseEvent.prototype.getShiftKey = function () {\n return this.domEvent.shiftKey;\n };\n MouseEvent.prototype.getAccelKey = function () {\n return useragent.isMac ? this.domEvent.metaKey : this.domEvent.ctrlKey;\n };\n return MouseEvent;\n}());\nexports.MouseEvent = MouseEvent;\n\n});\n\nace.define(\"ace/mouse/dragdrop_handler\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\",\"ace/lib/event\",\"ace/lib/useragent\"], function(require, exports, module){\"use strict\";\nvar dom = require(\"../lib/dom\");\nvar event = require(\"../lib/event\");\nvar useragent = require(\"../lib/useragent\");\nvar AUTOSCROLL_DELAY = 200;\nvar SCROLL_CURSOR_DELAY = 200;\nvar SCROLL_CURSOR_HYSTERESIS = 5;\nfunction DragdropHandler(mouseHandler) {\n var editor = mouseHandler.editor;\n var dragImage = dom.createElement(\"div\");\n dragImage.style.cssText = \"top:-100px;position:absolute;z-index:2147483647;opacity:0.5\";\n dragImage.textContent = \"\\xa0\";\n var exports = [\"dragWait\", \"dragWaitEnd\", \"startDrag\", \"dragReadyEnd\", \"onMouseDrag\"];\n exports.forEach(function (x) {\n mouseHandler[x] = this[x];\n }, this);\n editor.on(\"mousedown\", this.onMouseDown.bind(mouseHandler));\n var mouseTarget = editor.container;\n var dragSelectionMarker, x, y;\n var timerId, range;\n var dragCursor, counter = 0;\n var dragOperation;\n var isInternal;\n var autoScrollStartTime;\n var cursorMovedTime;\n var cursorPointOnCaretMoved;\n this.onDragStart = function (e) {\n if (this.cancelDrag || !mouseTarget.draggable) {\n var self = this;\n setTimeout(function () {\n self.startSelect();\n self.captureMouse(e);\n }, 0);\n return e.preventDefault();\n }\n range = editor.getSelectionRange();\n var dataTransfer = e.dataTransfer;\n dataTransfer.effectAllowed = editor.getReadOnly() ? \"copy\" : \"copyMove\";\n editor.container.appendChild(dragImage);\n dataTransfer.setDragImage && dataTransfer.setDragImage(dragImage, 0, 0);\n setTimeout(function () {\n editor.container.removeChild(dragImage);\n });\n dataTransfer.clearData();\n dataTransfer.setData(\"Text\", editor.session.getTextRange());\n isInternal = true;\n this.setState(\"drag\");\n };\n this.onDragEnd = function (e) {\n mouseTarget.draggable = false;\n isInternal = false;\n this.setState(null);\n if (!editor.getReadOnly()) {\n var dropEffect = e.dataTransfer.dropEffect;\n if (!dragOperation && dropEffect == \"move\")\n editor.session.remove(editor.getSelectionRange());\n editor.$resetCursorStyle();\n }\n this.editor.unsetStyle(\"ace_dragging\");\n this.editor.renderer.setCursorStyle(\"\");\n };\n this.onDragEnter = function (e) {\n if (editor.getReadOnly() || !canAccept(e.dataTransfer))\n return;\n x = e.clientX;\n y = e.clientY;\n if (!dragSelectionMarker)\n addDragMarker();\n counter++;\n e.dataTransfer.dropEffect = dragOperation = getDropEffect(e);\n return event.preventDefault(e);\n };\n this.onDragOver = function (e) {\n if (editor.getReadOnly() || !canAccept(e.dataTransfer))\n return;\n x = e.clientX;\n y = e.clientY;\n if (!dragSelectionMarker) {\n addDragMarker();\n counter++;\n }\n if (onMouseMoveTimer !== null)\n onMouseMoveTimer = null;\n e.dataTransfer.dropEffect = dragOperation = getDropEffect(e);\n return event.preventDefault(e);\n };\n this.onDragLeave = function (e) {\n counter--;\n if (counter <= 0 && dragSelectionMarker) {\n clearDragMarker();\n dragOperation = null;\n return event.preventDefault(e);\n }\n };\n this.onDrop = function (e) {\n if (!dragCursor)\n return;\n var dataTransfer = e.dataTransfer;\n if (isInternal) {\n switch (dragOperation) {\n case \"move\":\n if (range.contains(dragCursor.row, dragCursor.column)) {\n range = {\n start: dragCursor,\n end: dragCursor\n };\n }\n else {\n range = editor.moveText(range, dragCursor);\n }\n break;\n case \"copy\":\n range = editor.moveText(range, dragCursor, true);\n break;\n }\n }\n else {\n var dropData = dataTransfer.getData('Text');\n range = {\n start: dragCursor,\n end: editor.session.insert(dragCursor, dropData)\n };\n editor.focus();\n dragOperation = null;\n }\n clearDragMarker();\n return event.preventDefault(e);\n };\n event.addListener(mouseTarget, \"dragstart\", this.onDragStart.bind(mouseHandler), editor);\n event.addListener(mouseTarget, \"dragend\", this.onDragEnd.bind(mouseHandler), editor);\n event.addListener(mouseTarget, \"dragenter\", this.onDragEnter.bind(mouseHandler), editor);\n event.addListener(mouseTarget, \"dragover\", this.onDragOver.bind(mouseHandler), editor);\n event.addListener(mouseTarget, \"dragleave\", this.onDragLeave.bind(mouseHandler), editor);\n event.addListener(mouseTarget, \"drop\", this.onDrop.bind(mouseHandler), editor);\n function scrollCursorIntoView(cursor, prevCursor) {\n var now = Date.now();\n var vMovement = !prevCursor || cursor.row != prevCursor.row;\n var hMovement = !prevCursor || cursor.column != prevCursor.column;\n if (!cursorMovedTime || vMovement || hMovement) {\n editor.moveCursorToPosition(cursor);\n cursorMovedTime = now;\n cursorPointOnCaretMoved = { x: x, y: y };\n }\n else {\n var distance = calcDistance(cursorPointOnCaretMoved.x, cursorPointOnCaretMoved.y, x, y);\n if (distance > SCROLL_CURSOR_HYSTERESIS) {\n cursorMovedTime = null;\n }\n else if (now - cursorMovedTime >= SCROLL_CURSOR_DELAY) {\n editor.renderer.scrollCursorIntoView();\n cursorMovedTime = null;\n }\n }\n }\n function autoScroll(cursor, prevCursor) {\n var now = Date.now();\n var lineHeight = editor.renderer.layerConfig.lineHeight;\n var characterWidth = editor.renderer.layerConfig.characterWidth;\n var editorRect = editor.renderer.scroller.getBoundingClientRect();\n var offsets = {\n x: {\n left: x - editorRect.left,\n right: editorRect.right - x\n },\n y: {\n top: y - editorRect.top,\n bottom: editorRect.bottom - y\n }\n };\n var nearestXOffset = Math.min(offsets.x.left, offsets.x.right);\n var nearestYOffset = Math.min(offsets.y.top, offsets.y.bottom);\n var scrollCursor = { row: cursor.row, column: cursor.column };\n if (nearestXOffset / characterWidth <= 2) {\n scrollCursor.column += (offsets.x.left < offsets.x.right ? -3 : +2);\n }\n if (nearestYOffset / lineHeight <= 1) {\n scrollCursor.row += (offsets.y.top < offsets.y.bottom ? -1 : +1);\n }\n var vScroll = cursor.row != scrollCursor.row;\n var hScroll = cursor.column != scrollCursor.column;\n var vMovement = !prevCursor || cursor.row != prevCursor.row;\n if (vScroll || (hScroll && !vMovement)) {\n if (!autoScrollStartTime)\n autoScrollStartTime = now;\n else if (now - autoScrollStartTime >= AUTOSCROLL_DELAY)\n editor.renderer.scrollCursorIntoView(scrollCursor);\n }\n else {\n autoScrollStartTime = null;\n }\n }\n function onDragInterval() {\n var prevCursor = dragCursor;\n dragCursor = editor.renderer.screenToTextCoordinates(x, y);\n scrollCursorIntoView(dragCursor, prevCursor);\n autoScroll(dragCursor, prevCursor);\n }\n function addDragMarker() {\n range = editor.selection.toOrientedRange();\n dragSelectionMarker = editor.session.addMarker(range, \"ace_selection\", editor.getSelectionStyle());\n editor.clearSelection();\n if (editor.isFocused())\n editor.renderer.$cursorLayer.setBlinking(false);\n clearInterval(timerId);\n onDragInterval();\n timerId = setInterval(onDragInterval, 20);\n counter = 0;\n event.addListener(document, \"mousemove\", onMouseMove);\n }\n function clearDragMarker() {\n clearInterval(timerId);\n editor.session.removeMarker(dragSelectionMarker);\n dragSelectionMarker = null;\n editor.selection.fromOrientedRange(range);\n if (editor.isFocused() && !isInternal)\n editor.$resetCursorStyle();\n range = null;\n dragCursor = null;\n counter = 0;\n autoScrollStartTime = null;\n cursorMovedTime = null;\n event.removeListener(document, \"mousemove\", onMouseMove);\n }\n var onMouseMoveTimer = null;\n function onMouseMove() {\n if (onMouseMoveTimer == null) {\n onMouseMoveTimer = setTimeout(function () {\n if (onMouseMoveTimer != null && dragSelectionMarker)\n clearDragMarker();\n }, 20);\n }\n }\n function canAccept(dataTransfer) {\n var types = dataTransfer.types;\n return !types || Array.prototype.some.call(types, function (type) {\n return type == 'text/plain' || type == 'Text';\n });\n }\n function getDropEffect(e) {\n var copyAllowed = ['copy', 'copymove', 'all', 'uninitialized'];\n var moveAllowed = ['move', 'copymove', 'linkmove', 'all', 'uninitialized'];\n var copyModifierState = useragent.isMac ? e.altKey : e.ctrlKey;\n var effectAllowed = \"uninitialized\";\n try {\n effectAllowed = e.dataTransfer.effectAllowed.toLowerCase();\n }\n catch (e) { }\n var dropEffect = \"none\";\n if (copyModifierState && copyAllowed.indexOf(effectAllowed) >= 0)\n dropEffect = \"copy\";\n else if (moveAllowed.indexOf(effectAllowed) >= 0)\n dropEffect = \"move\";\n else if (copyAllowed.indexOf(effectAllowed) >= 0)\n dropEffect = \"copy\";\n return dropEffect;\n }\n}\n(function () {\n this.dragWait = function () {\n var interval = Date.now() - this.mousedownEvent.time;\n if (interval > this.editor.getDragDelay())\n this.startDrag();\n };\n this.dragWaitEnd = function () {\n var target = this.editor.container;\n target.draggable = false;\n this.startSelect(this.mousedownEvent.getDocumentPosition());\n this.selectEnd();\n };\n this.dragReadyEnd = function (e) {\n this.editor.$resetCursorStyle();\n this.editor.unsetStyle(\"ace_dragging\");\n this.editor.renderer.setCursorStyle(\"\");\n this.dragWaitEnd();\n };\n this.startDrag = function () {\n this.cancelDrag = false;\n var editor = this.editor;\n var target = editor.container;\n target.draggable = true;\n editor.renderer.$cursorLayer.setBlinking(false);\n editor.setStyle(\"ace_dragging\");\n var cursorStyle = useragent.isWin ? \"default\" : \"move\";\n editor.renderer.setCursorStyle(cursorStyle);\n this.setState(\"dragReady\");\n };\n this.onMouseDrag = function (e) {\n var target = this.editor.container;\n if (useragent.isIE && this.state == \"dragReady\") {\n var distance = calcDistance(this.mousedownEvent.x, this.mousedownEvent.y, this.x, this.y);\n if (distance > 3)\n target.dragDrop();\n }\n if (this.state === \"dragWait\") {\n var distance = calcDistance(this.mousedownEvent.x, this.mousedownEvent.y, this.x, this.y);\n if (distance > 0) {\n target.draggable = false;\n this.startSelect(this.mousedownEvent.getDocumentPosition());\n }\n }\n };\n this.onMouseDown = function (e) {\n if (!this.$dragEnabled)\n return;\n this.mousedownEvent = e;\n var editor = this.editor;\n var inSelection = e.inSelection();\n var button = e.getButton();\n var clickCount = e.domEvent.detail || 1;\n if (clickCount === 1 && button === 0 && inSelection) {\n if (e.editor.inMultiSelectMode && (e.getAccelKey() || e.getShiftKey()))\n return;\n this.mousedownEvent.time = Date.now();\n var eventTarget = e.domEvent.target || e.domEvent.srcElement;\n if (\"unselectable\" in eventTarget)\n eventTarget.unselectable = \"on\";\n if (editor.getDragDelay()) {\n if (useragent.isWebKit) {\n this.cancelDrag = true;\n var mouseTarget = editor.container;\n mouseTarget.draggable = true;\n }\n this.setState(\"dragWait\");\n }\n else {\n this.startDrag();\n }\n this.captureMouse(e, this.onMouseDrag.bind(this));\n e.defaultPrevented = true;\n }\n };\n}).call(DragdropHandler.prototype);\nfunction calcDistance(ax, ay, bx, by) {\n return Math.sqrt(Math.pow(bx - ax, 2) + Math.pow(by - ay, 2));\n}\nexports.DragdropHandler = DragdropHandler;\n\n});\n\nace.define(\"ace/mouse/touch_handler\",[\"require\",\"exports\",\"module\",\"ace/mouse/mouse_event\",\"ace/lib/event\",\"ace/lib/dom\"], function(require, exports, module){\"use strict\";\nvar MouseEvent = require(\"./mouse_event\").MouseEvent;\nvar event = require(\"../lib/event\");\nvar dom = require(\"../lib/dom\");\nexports.addTouchListeners = function (el, editor) {\n var mode = \"scroll\";\n var startX;\n var startY;\n var touchStartT;\n var lastT;\n var longTouchTimer;\n var animationTimer;\n var animationSteps = 0;\n var pos;\n var clickCount = 0;\n var vX = 0;\n var vY = 0;\n var pressed;\n var contextMenu;\n function createContextMenu() {\n var clipboard = window.navigator && window.navigator.clipboard;\n var isOpen = false;\n var updateMenu = function () {\n var selected = editor.getCopyText();\n var hasUndo = editor.session.getUndoManager().hasUndo();\n contextMenu.replaceChild(dom.buildDom(isOpen ? [\"span\",\n !selected && canExecuteCommand(\"selectall\") && [\"span\", { class: \"ace_mobile-button\", action: \"selectall\" }, \"Select All\"],\n selected && canExecuteCommand(\"copy\") && [\"span\", { class: \"ace_mobile-button\", action: \"copy\" }, \"Copy\"],\n selected && canExecuteCommand(\"cut\") && [\"span\", { class: \"ace_mobile-button\", action: \"cut\" }, \"Cut\"],\n clipboard && canExecuteCommand(\"paste\") && [\"span\", { class: \"ace_mobile-button\", action: \"paste\" }, \"Paste\"],\n hasUndo && canExecuteCommand(\"undo\") && [\"span\", { class: \"ace_mobile-button\", action: \"undo\" }, \"Undo\"],\n canExecuteCommand(\"find\") && [\"span\", { class: \"ace_mobile-button\", action: \"find\" }, \"Find\"],\n canExecuteCommand(\"openCommandPalette\") && [\"span\", { class: \"ace_mobile-button\", action: \"openCommandPalette\" }, \"Palette\"]\n ] : [\"span\"]), contextMenu.firstChild);\n };\n var canExecuteCommand = function (/** @type {string} */ cmd) {\n return editor.commands.canExecute(cmd, editor);\n };\n var handleClick = function (e) {\n var action = e.target.getAttribute(\"action\");\n if (action == \"more\" || !isOpen) {\n isOpen = !isOpen;\n return updateMenu();\n }\n if (action == \"paste\") {\n clipboard.readText().then(function (text) {\n editor.execCommand(action, text);\n });\n }\n else if (action) {\n if (action == \"cut\" || action == \"copy\") {\n if (clipboard)\n clipboard.writeText(editor.getCopyText());\n else\n document.execCommand(\"copy\");\n }\n editor.execCommand(action);\n }\n contextMenu.firstChild.style.display = \"none\";\n isOpen = false;\n if (action != \"openCommandPalette\")\n editor.focus();\n };\n contextMenu = dom.buildDom([\"div\",\n {\n class: \"ace_mobile-menu\",\n ontouchstart: function (e) {\n mode = \"menu\";\n e.stopPropagation();\n e.preventDefault();\n editor.textInput.focus();\n },\n ontouchend: function (e) {\n e.stopPropagation();\n e.preventDefault();\n handleClick(e);\n },\n onclick: handleClick\n },\n [\"span\"],\n [\"span\", { class: \"ace_mobile-button\", action: \"more\" }, \"...\"]\n ], editor.container);\n }\n function showContextMenu() {\n if (!editor.getOption(\"enableMobileMenu\")) {\n if (contextMenu) {\n hideContextMenu();\n }\n return;\n }\n if (!contextMenu)\n createContextMenu();\n var cursor = editor.selection.cursor;\n var pagePos = editor.renderer.textToScreenCoordinates(cursor.row, cursor.column);\n var leftOffset = editor.renderer.textToScreenCoordinates(0, 0).pageX;\n var scrollLeft = editor.renderer.scrollLeft;\n var rect = editor.container.getBoundingClientRect();\n contextMenu.style.top = pagePos.pageY - rect.top - 3 + \"px\";\n if (pagePos.pageX - rect.left < rect.width - 70) {\n contextMenu.style.left = \"\";\n contextMenu.style.right = \"10px\";\n }\n else {\n contextMenu.style.right = \"\";\n contextMenu.style.left = leftOffset + scrollLeft - rect.left + \"px\";\n }\n contextMenu.style.display = \"\";\n contextMenu.firstChild.style.display = \"none\";\n editor.on(\"input\", hideContextMenu);\n }\n function hideContextMenu(e) {\n if (contextMenu)\n contextMenu.style.display = \"none\";\n editor.off(\"input\", hideContextMenu);\n }\n function handleLongTap() {\n longTouchTimer = null;\n clearTimeout(longTouchTimer);\n var range = editor.selection.getRange();\n var inSelection = range.contains(pos.row, pos.column);\n if (range.isEmpty() || !inSelection) {\n editor.selection.moveToPosition(pos);\n editor.selection.selectWord();\n }\n mode = \"wait\";\n showContextMenu();\n }\n function switchToSelectionMode() {\n longTouchTimer = null;\n clearTimeout(longTouchTimer);\n editor.selection.moveToPosition(pos);\n var range = clickCount >= 2\n ? editor.selection.getLineRange(pos.row)\n : editor.session.getBracketRange(pos);\n if (range && !range.isEmpty()) {\n editor.selection.setRange(range);\n }\n else {\n editor.selection.selectWord();\n }\n mode = \"wait\";\n }\n event.addListener(el, \"contextmenu\", function (e) {\n if (!pressed)\n return;\n var textarea = editor.textInput.getElement();\n textarea.focus();\n }, editor);\n event.addListener(el, \"touchstart\", function (e) {\n var touches = e.touches;\n if (longTouchTimer || touches.length > 1) {\n clearTimeout(longTouchTimer);\n longTouchTimer = null;\n touchStartT = -1;\n mode = \"zoom\";\n return;\n }\n pressed = editor.$mouseHandler.isMousePressed = true;\n var h = editor.renderer.layerConfig.lineHeight;\n var w = editor.renderer.layerConfig.lineHeight;\n var t = e.timeStamp;\n lastT = t;\n var touchObj = touches[0];\n var x = touchObj.clientX;\n var y = touchObj.clientY;\n if (Math.abs(startX - x) + Math.abs(startY - y) > h)\n touchStartT = -1;\n startX = e.clientX = x;\n startY = e.clientY = y;\n vX = vY = 0;\n var ev = new MouseEvent(e, editor);\n pos = ev.getDocumentPosition();\n if (t - touchStartT < 500 && touches.length == 1 && !animationSteps) {\n clickCount++;\n e.preventDefault();\n e.button = 0;\n switchToSelectionMode();\n }\n else {\n clickCount = 0;\n var cursor = editor.selection.cursor;\n var anchor = editor.selection.isEmpty() ? cursor : editor.selection.anchor;\n var cursorPos = editor.renderer.$cursorLayer.getPixelPosition(cursor, true);\n var anchorPos = editor.renderer.$cursorLayer.getPixelPosition(anchor, true);\n var rect = editor.renderer.scroller.getBoundingClientRect();\n var offsetTop = editor.renderer.layerConfig.offset;\n var offsetLeft = editor.renderer.scrollLeft;\n var weightedDistance = function (x, y) {\n x = x / w;\n y = y / h - 0.75;\n return x * x + y * y;\n };\n if (e.clientX < rect.left) {\n mode = \"zoom\";\n return;\n }\n var diff1 = weightedDistance(e.clientX - rect.left - cursorPos.left + offsetLeft, e.clientY - rect.top - cursorPos.top + offsetTop);\n var diff2 = weightedDistance(e.clientX - rect.left - anchorPos.left + offsetLeft, e.clientY - rect.top - anchorPos.top + offsetTop);\n if (diff1 < 3.5 && diff2 < 3.5)\n mode = diff1 > diff2 ? \"cursor\" : \"anchor\";\n if (diff2 < 3.5)\n mode = \"anchor\";\n else if (diff1 < 3.5)\n mode = \"cursor\";\n else\n mode = \"scroll\";\n longTouchTimer = setTimeout(handleLongTap, 450);\n }\n touchStartT = t;\n }, editor);\n event.addListener(el, \"touchend\", function (e) {\n pressed = editor.$mouseHandler.isMousePressed = false;\n if (animationTimer)\n clearInterval(animationTimer);\n if (mode == \"zoom\") {\n mode = \"\";\n animationSteps = 0;\n }\n else if (longTouchTimer) {\n editor.selection.moveToPosition(pos);\n animationSteps = 0;\n showContextMenu();\n }\n else if (mode == \"scroll\") {\n animate();\n hideContextMenu();\n }\n else {\n showContextMenu();\n }\n clearTimeout(longTouchTimer);\n longTouchTimer = null;\n }, editor);\n event.addListener(el, \"touchmove\", function (e) {\n if (longTouchTimer) {\n clearTimeout(longTouchTimer);\n longTouchTimer = null;\n }\n var touches = e.touches;\n if (touches.length > 1 || mode == \"zoom\")\n return;\n var touchObj = touches[0];\n var wheelX = startX - touchObj.clientX;\n var wheelY = startY - touchObj.clientY;\n if (mode == \"wait\") {\n if (wheelX * wheelX + wheelY * wheelY > 4)\n mode = \"cursor\";\n else\n return e.preventDefault();\n }\n startX = touchObj.clientX;\n startY = touchObj.clientY;\n e.clientX = touchObj.clientX;\n e.clientY = touchObj.clientY;\n var t = e.timeStamp;\n var dt = t - lastT;\n lastT = t;\n if (mode == \"scroll\") {\n var mouseEvent = new MouseEvent(e, editor);\n mouseEvent.speed = 1;\n mouseEvent.wheelX = wheelX;\n mouseEvent.wheelY = wheelY;\n if (10 * Math.abs(wheelX) < Math.abs(wheelY))\n wheelX = 0;\n if (10 * Math.abs(wheelY) < Math.abs(wheelX))\n wheelY = 0;\n if (dt != 0) {\n vX = wheelX / dt;\n vY = wheelY / dt;\n }\n editor._emit(\"mousewheel\", mouseEvent);\n if (!mouseEvent.propagationStopped) {\n vX = vY = 0;\n }\n }\n else {\n var ev = new MouseEvent(e, editor);\n var pos = ev.getDocumentPosition();\n if (mode == \"cursor\")\n editor.selection.moveCursorToPosition(pos);\n else if (mode == \"anchor\")\n editor.selection.setSelectionAnchor(pos.row, pos.column);\n editor.renderer.scrollCursorIntoView(pos);\n e.preventDefault();\n }\n }, editor);\n function animate() {\n animationSteps += 60;\n animationTimer = setInterval(function () {\n if (animationSteps-- <= 0) {\n clearInterval(animationTimer);\n animationTimer = null;\n }\n if (Math.abs(vX) < 0.01)\n vX = 0;\n if (Math.abs(vY) < 0.01)\n vY = 0;\n if (animationSteps < 20)\n vX = 0.9 * vX;\n if (animationSteps < 20)\n vY = 0.9 * vY;\n var oldScrollTop = editor.session.getScrollTop();\n editor.renderer.scrollBy(10 * vX, 10 * vY);\n if (oldScrollTop == editor.session.getScrollTop())\n animationSteps = 0;\n }, 10);\n }\n};\n\n});\n\nace.define(\"ace/mouse/mouse_handler\",[\"require\",\"exports\",\"module\",\"ace/lib/event\",\"ace/lib/useragent\",\"ace/mouse/default_handlers\",\"ace/mouse/default_gutter_handler\",\"ace/mouse/mouse_event\",\"ace/mouse/dragdrop_handler\",\"ace/mouse/touch_handler\",\"ace/config\"], function(require, exports, module){\"use strict\";\nvar event = require(\"../lib/event\");\nvar useragent = require(\"../lib/useragent\");\nvar DefaultHandlers = require(\"./default_handlers\").DefaultHandlers;\nvar DefaultGutterHandler = require(\"./default_gutter_handler\").GutterHandler;\nvar MouseEvent = require(\"./mouse_event\").MouseEvent;\nvar DragdropHandler = require(\"./dragdrop_handler\").DragdropHandler;\nvar addTouchListeners = require(\"./touch_handler\").addTouchListeners;\nvar config = require(\"../config\");\nvar MouseHandler = /** @class */ (function () {\n function MouseHandler(editor) { this.$dragDelay; this.$dragEnabled; this.$mouseMoved; this.mouseEvent; this.$focusTimeout;\n var _self = this;\n this.editor = editor;\n new DefaultHandlers(this);\n new DefaultGutterHandler(this);\n new DragdropHandler(this);\n var focusEditor = function (e) {\n var windowBlurred = !document.hasFocus || !document.hasFocus()\n || !editor.isFocused() && document.activeElement == (editor.textInput && editor.textInput.getElement());\n if (windowBlurred)\n window.focus();\n editor.focus();\n setTimeout(function () {\n if (!editor.isFocused())\n editor.focus();\n });\n };\n var mouseTarget = editor.renderer.getMouseEventTarget();\n event.addListener(mouseTarget, \"click\", this.onMouseEvent.bind(this, \"click\"), editor);\n event.addListener(mouseTarget, \"mousemove\", this.onMouseMove.bind(this, \"mousemove\"), editor);\n event.addMultiMouseDownListener([\n mouseTarget,\n editor.renderer.scrollBarV && editor.renderer.scrollBarV.inner,\n editor.renderer.scrollBarH && editor.renderer.scrollBarH.inner,\n editor.textInput && editor.textInput.getElement()\n ].filter(Boolean), [400, 300, 250], this, \"onMouseEvent\", editor);\n event.addMouseWheelListener(editor.container, this.onMouseWheel.bind(this, \"mousewheel\"), editor);\n addTouchListeners(editor.container, editor);\n var gutterEl = editor.renderer.$gutter;\n event.addListener(gutterEl, \"mousedown\", this.onMouseEvent.bind(this, \"guttermousedown\"), editor);\n event.addListener(gutterEl, \"click\", this.onMouseEvent.bind(this, \"gutterclick\"), editor);\n event.addListener(gutterEl, \"dblclick\", this.onMouseEvent.bind(this, \"gutterdblclick\"), editor);\n event.addListener(gutterEl, \"mousemove\", this.onMouseEvent.bind(this, \"guttermousemove\"), editor);\n event.addListener(mouseTarget, \"mousedown\", focusEditor, editor);\n event.addListener(gutterEl, \"mousedown\", focusEditor, editor);\n if (useragent.isIE && editor.renderer.scrollBarV) {\n event.addListener(editor.renderer.scrollBarV.element, \"mousedown\", focusEditor, editor);\n event.addListener(editor.renderer.scrollBarH.element, \"mousedown\", focusEditor, editor);\n }\n editor.on(\"mousemove\", function (e) {\n if (_self.state || _self.$dragDelay || !_self.$dragEnabled)\n return;\n var character = editor.renderer.screenToTextCoordinates(e.x, e.y);\n var range = editor.session.selection.getRange();\n var renderer = editor.renderer;\n if (!range.isEmpty() && range.insideStart(character.row, character.column)) {\n renderer.setCursorStyle(\"default\");\n }\n else {\n renderer.setCursorStyle(\"\");\n }\n }, //@ts-expect-error TODO: seems mistyping - should be boolean\n editor);\n }\n MouseHandler.prototype.onMouseEvent = function (name, e) {\n if (!this.editor.session)\n return;\n this.editor._emit(name, new MouseEvent(e, this.editor));\n };\n MouseHandler.prototype.onMouseMove = function (name, e) {\n var listeners = this.editor._eventRegistry && this.editor._eventRegistry.mousemove;\n if (!listeners || !listeners.length)\n return;\n this.editor._emit(name, new MouseEvent(e, this.editor));\n };\n MouseHandler.prototype.onMouseWheel = function (name, e) {\n var mouseEvent = new MouseEvent(e, this.editor);\n mouseEvent.speed = this.$scrollSpeed * 2;\n mouseEvent.wheelX = e.wheelX;\n mouseEvent.wheelY = e.wheelY;\n this.editor._emit(name, mouseEvent);\n };\n MouseHandler.prototype.setState = function (state) {\n this.state = state;\n };\n MouseHandler.prototype.captureMouse = function (ev, mouseMoveHandler) {\n this.x = ev.x;\n this.y = ev.y;\n this.isMousePressed = true;\n var editor = this.editor;\n var renderer = this.editor.renderer;\n renderer.$isMousePressed = true;\n var self = this;\n var onMouseMove = function (e) {\n if (!e)\n return;\n if (useragent.isWebKit && !e.which && self.releaseMouse)\n return self.releaseMouse();\n self.x = e.clientX;\n self.y = e.clientY;\n mouseMoveHandler && mouseMoveHandler(e);\n self.mouseEvent = new MouseEvent(e, self.editor);\n self.$mouseMoved = true;\n };\n var onCaptureEnd = function (e) {\n editor.off(\"beforeEndOperation\", onOperationEnd);\n clearInterval(timerId);\n if (editor.session)\n onCaptureInterval();\n self[self.state + \"End\"] && self[self.state + \"End\"](e);\n self.state = \"\";\n self.isMousePressed = renderer.$isMousePressed = false;\n if (renderer.$keepTextAreaAtCursor)\n renderer.$moveTextAreaToCursor();\n self.$onCaptureMouseMove = self.releaseMouse = null;\n e && self.onMouseEvent(\"mouseup\", e);\n editor.endOperation();\n };\n var onCaptureInterval = function () {\n self[self.state] && self[self.state]();\n self.$mouseMoved = false;\n };\n if (useragent.isOldIE && ev.domEvent.type == \"dblclick\") {\n return setTimeout(function () { onCaptureEnd(ev); });\n }\n var onOperationEnd = function (e) {\n if (!self.releaseMouse)\n return;\n if (editor.curOp.command.name && editor.curOp.selectionChanged) {\n self[self.state + \"End\"] && self[self.state + \"End\"]();\n self.state = \"\";\n self.releaseMouse();\n }\n };\n editor.on(\"beforeEndOperation\", onOperationEnd);\n editor.startOperation({ command: { name: \"mouse\" } });\n self.$onCaptureMouseMove = onMouseMove;\n self.releaseMouse = event.capture(this.editor.container, onMouseMove, onCaptureEnd);\n var timerId = setInterval(onCaptureInterval, 20);\n };\n MouseHandler.prototype.cancelContextMenu = function () {\n var stop = function (e) {\n if (e && e.domEvent && e.domEvent.type != \"contextmenu\")\n return;\n this.editor.off(\"nativecontextmenu\", stop);\n if (e && e.domEvent)\n event.stopEvent(e.domEvent);\n }.bind(this);\n setTimeout(stop, 10);\n this.editor.on(\"nativecontextmenu\", stop);\n };\n MouseHandler.prototype.destroy = function () {\n if (this.releaseMouse)\n this.releaseMouse();\n };\n return MouseHandler;\n}());\nMouseHandler.prototype.releaseMouse = null;\nconfig.defineOptions(MouseHandler.prototype, \"mouseHandler\", {\n scrollSpeed: { initialValue: 2 },\n dragDelay: { initialValue: (useragent.isMac ? 150 : 0) },\n dragEnabled: { initialValue: true },\n focusTimeout: { initialValue: 0 },\n tooltipFollowsMouse: { initialValue: true }\n});\nexports.MouseHandler = MouseHandler;\n\n});\n\nace.define(\"ace/mouse/fold_handler\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\"], function(require, exports, module){\"use strict\";\nvar dom = require(\"../lib/dom\");\nvar FoldHandler = /** @class */ (function () {\n function FoldHandler(editor) {\n editor.on(\"click\", function (e) {\n var position = e.getDocumentPosition();\n var session = editor.session;\n var fold = session.getFoldAt(position.row, position.column, 1);\n if (fold) {\n if (e.getAccelKey())\n session.removeFold(fold);\n else\n session.expandFold(fold);\n e.stop();\n }\n var target = e.domEvent && e.domEvent.target;\n if (target && dom.hasCssClass(target, \"ace_inline_button\")) {\n if (dom.hasCssClass(target, \"ace_toggle_wrap\")) {\n session.setOption(\"wrap\", !session.getUseWrapMode());\n editor.renderer.scrollCursorIntoView();\n }\n }\n });\n editor.on(\"gutterclick\", function (e) {\n var gutterRegion = editor.renderer.$gutterLayer.getRegion(e);\n if (gutterRegion == \"foldWidgets\") {\n var row = e.getDocumentPosition().row;\n var session = editor.session;\n if (session.foldWidgets && session.foldWidgets[row])\n editor.session.onFoldWidgetClick(row, e);\n if (!editor.isFocused())\n editor.focus();\n e.stop();\n }\n });\n editor.on(\"gutterdblclick\", function (e) {\n var gutterRegion = editor.renderer.$gutterLayer.getRegion(e);\n if (gutterRegion == \"foldWidgets\") {\n var row = e.getDocumentPosition().row;\n var session = editor.session;\n var data = session.getParentFoldRangeData(row, true);\n var range = data.range || data.firstRange;\n if (range) {\n row = range.start.row;\n var fold = session.getFoldAt(row, session.getLine(row).length, 1);\n if (fold) {\n session.removeFold(fold);\n }\n else {\n session.addFold(\"...\", range);\n editor.renderer.scrollCursorIntoView({ row: range.start.row, column: 0 });\n }\n }\n e.stop();\n }\n });\n }\n return FoldHandler;\n}());\nexports.FoldHandler = FoldHandler;\n\n});\n\nace.define(\"ace/keyboard/keybinding\",[\"require\",\"exports\",\"module\",\"ace/lib/keys\",\"ace/lib/event\"], function(require, exports, module){\"use strict\";\nvar keyUtil = require(\"../lib/keys\");\nvar event = require(\"../lib/event\");\nvar KeyBinding = /** @class */ (function () {\n function KeyBinding(editor) {\n this.$editor = editor;\n this.$data = { editor: editor };\n this.$handlers = [];\n this.setDefaultHandler(editor.commands);\n }\n KeyBinding.prototype.setDefaultHandler = function (kb) {\n this.removeKeyboardHandler(this.$defaultHandler);\n this.$defaultHandler = kb;\n this.addKeyboardHandler(kb, 0);\n };\n KeyBinding.prototype.setKeyboardHandler = function (kb) {\n var h = this.$handlers;\n if (h[h.length - 1] == kb)\n return;\n while (h[h.length - 1] && h[h.length - 1] != this.$defaultHandler)\n this.removeKeyboardHandler(h[h.length - 1]);\n this.addKeyboardHandler(kb, 1);\n };\n KeyBinding.prototype.addKeyboardHandler = function (kb, pos) {\n if (!kb)\n return;\n if (typeof kb == \"function\" && !kb.handleKeyboard)\n kb.handleKeyboard = kb;\n var i = this.$handlers.indexOf(kb);\n if (i != -1)\n this.$handlers.splice(i, 1);\n if (pos == undefined)\n this.$handlers.push(kb);\n else\n this.$handlers.splice(pos, 0, kb);\n if (i == -1 && kb.attach)\n kb.attach(this.$editor);\n };\n KeyBinding.prototype.removeKeyboardHandler = function (kb) {\n var i = this.$handlers.indexOf(kb);\n if (i == -1)\n return false;\n this.$handlers.splice(i, 1);\n kb.detach && kb.detach(this.$editor);\n return true;\n };\n KeyBinding.prototype.getKeyboardHandler = function () {\n return this.$handlers[this.$handlers.length - 1];\n };\n KeyBinding.prototype.getStatusText = function () {\n var data = this.$data;\n var editor = data.editor;\n return this.$handlers.map(function (h) {\n return h.getStatusText && h.getStatusText(editor, data) || \"\";\n }).filter(Boolean).join(\" \");\n };\n KeyBinding.prototype.$callKeyboardHandlers = function (hashId, keyString, keyCode, e) {\n var toExecute;\n var success = false;\n var commands = this.$editor.commands;\n for (var i = this.$handlers.length; i--;) {\n toExecute = this.$handlers[i].handleKeyboard(\n this.$data, hashId, keyString, keyCode, e);\n if (!toExecute || !toExecute.command)\n continue;\n if (toExecute.command == \"null\") {\n success = true;\n }\n else {\n success = commands.exec(toExecute.command, this.$editor, toExecute.args, e);\n }\n if (success && e && hashId != -1 &&\n toExecute[\"passEvent\"] != true && toExecute.command[\"passEvent\"] != true) {\n event.stopEvent(e);\n }\n if (success)\n break;\n }\n if (!success && hashId == -1) {\n toExecute = { command: \"insertstring\" };\n success = commands.exec(\"insertstring\", this.$editor, keyString);\n }\n if (success && this.$editor._signal)\n this.$editor._signal(\"keyboardActivity\", toExecute);\n return success;\n };\n KeyBinding.prototype.onCommandKey = function (e, hashId, keyCode) {\n var keyString = keyUtil.keyCodeToString(keyCode);\n return this.$callKeyboardHandlers(hashId, keyString, keyCode, e);\n };\n KeyBinding.prototype.onTextInput = function (text) {\n return this.$callKeyboardHandlers(-1, text);\n };\n return KeyBinding;\n}());\nexports.KeyBinding = KeyBinding;\n\n});\n\nace.define(\"ace/lib/bidiutil\",[\"require\",\"exports\",\"module\"], function(require, exports, module){\"use strict\";\nvar ArabicAlefBetIntervalsBegine = ['\\u0621', '\\u0641'];\nvar ArabicAlefBetIntervalsEnd = ['\\u063A', '\\u064a'];\nvar dir = 0, hiLevel = 0;\nvar lastArabic = false, hasUBAT_AL = false, hasUBAT_B = false, hasUBAT_S = false, hasBlockSep = false, hasSegSep = false;\nvar impTab_LTR = [ [0, 3, 0, 1, 0, 0, 0], [0, 3, 0, 1, 2, 2, 0], [0, 3, 0, 0x11, 2, 0, 1], [0, 3, 5, 5, 4, 1, 0], [0, 3, 0x15, 0x15, 4, 0, 1], [0, 3, 5, 5, 4, 2, 0]\n];\nvar impTab_RTL = [ [2, 0, 1, 1, 0, 1, 0], [2, 0, 1, 1, 0, 2, 0], [2, 0, 2, 1, 3, 2, 0], [2, 0, 2, 0x21, 3, 1, 1]\n];\nvar LTR = 0, RTL = 1;\nvar L = 0;\nvar R = 1;\nvar EN = 2;\nvar AN = 3;\nvar ON = 4;\nvar B = 5;\nvar S = 6;\nvar AL = 7;\nvar WS = 8;\nvar CS = 9;\nvar ES = 10;\nvar ET = 11;\nvar NSM = 12;\nvar LRE = 13;\nvar RLE = 14;\nvar PDF = 15;\nvar LRO = 16;\nvar RLO = 17;\nvar BN = 18;\nvar UnicodeTBL00 = [\n BN, BN, BN, BN, BN, BN, BN, BN, BN, S, B, S, WS, B, BN, BN,\n BN, BN, BN, BN, BN, BN, BN, BN, BN, BN, BN, BN, B, B, B, S,\n WS, ON, ON, ET, ET, ET, ON, ON, ON, ON, ON, ES, CS, ES, CS, CS,\n EN, EN, EN, EN, EN, EN, EN, EN, EN, EN, CS, ON, ON, ON, ON, ON,\n ON, L, L, L, L, L, L, L, L, L, L, L, L, L, L, L,\n L, L, L, L, L, L, L, L, L, L, L, ON, ON, ON, ON, ON,\n ON, L, L, L, L, L, L, L, L, L, L, L, L, L, L, L,\n L, L, L, L, L, L, L, L, L, L, L, ON, ON, ON, ON, BN,\n BN, BN, BN, BN, BN, B, BN, BN, BN, BN, BN, BN, BN, BN, BN, BN,\n BN, BN, BN, BN, BN, BN, BN, BN, BN, BN, BN, BN, BN, BN, BN, BN,\n CS, ON, ET, ET, ET, ET, ON, ON, ON, ON, L, ON, ON, BN, ON, ON,\n ET, ET, EN, EN, ON, L, ON, ON, ON, EN, L, ON, ON, ON, ON, ON\n];\nvar UnicodeTBL20 = [\n WS, WS, WS, WS, WS, WS, WS, WS, WS, WS, WS, BN, BN, BN, L, R,\n ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON,\n ON, ON, ON, ON, ON, ON, ON, ON, WS, B, LRE, RLE, PDF, LRO, RLO, CS,\n ET, ET, ET, ET, ET, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON,\n ON, ON, ON, ON, CS, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON,\n ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, ON, WS\n];\nfunction _computeLevels(chars, levels, len, charTypes) {\n var impTab = dir ? impTab_RTL : impTab_LTR, prevState = null, newClass = null, newLevel = null, newState = 0, action = null, cond = null, condPos = -1, i = null, ix = null, classes = [];\n if (!charTypes) {\n for (i = 0, charTypes = []; i < len; i++) {\n charTypes[i] = _getCharacterType(chars[i]);\n }\n }\n hiLevel = dir;\n lastArabic = false;\n hasUBAT_AL = false;\n hasUBAT_B = false;\n hasUBAT_S = false;\n for (ix = 0; ix < len; ix++) {\n prevState = newState;\n classes[ix] = newClass = _getCharClass(chars, charTypes, classes, ix);\n newState = impTab[prevState][newClass];\n action = newState & 0xF0;\n newState &= 0x0F;\n levels[ix] = newLevel = impTab[newState][5];\n if (action > 0) {\n if (action == 0x10) {\n for (i = condPos; i < ix; i++) {\n levels[i] = 1;\n }\n condPos = -1;\n }\n else {\n condPos = -1;\n }\n }\n cond = impTab[newState][6];\n if (cond) {\n if (condPos == -1) {\n condPos = ix;\n }\n }\n else {\n if (condPos > -1) {\n for (i = condPos; i < ix; i++) {\n levels[i] = newLevel;\n }\n condPos = -1;\n }\n }\n if (charTypes[ix] == B) {\n levels[ix] = 0;\n }\n hiLevel |= newLevel;\n }\n if (hasUBAT_S) {\n for (i = 0; i < len; i++) {\n if (charTypes[i] == S) {\n levels[i] = dir;\n for (var j = i - 1; j >= 0; j--) {\n if (charTypes[j] == WS) {\n levels[j] = dir;\n }\n else {\n break;\n }\n }\n }\n }\n }\n}\nfunction _invertLevel(lev, levels, _array) {\n if (hiLevel < lev) {\n return;\n }\n if (lev == 1 && dir == RTL && !hasUBAT_B) {\n _array.reverse();\n return;\n }\n var len = _array.length, start = 0, end, lo, hi, tmp;\n while (start < len) {\n if (levels[start] >= lev) {\n end = start + 1;\n while (end < len && levels[end] >= lev) {\n end++;\n }\n for (lo = start, hi = end - 1; lo < hi; lo++, hi--) {\n tmp = _array[lo];\n _array[lo] = _array[hi];\n _array[hi] = tmp;\n }\n start = end;\n }\n start++;\n }\n}\nfunction _getCharClass(chars, types, classes, ix) {\n var cType = types[ix], wType, nType, len, i;\n switch (cType) {\n case L:\n case R:\n lastArabic = false;\n case ON:\n case AN:\n return cType;\n case EN:\n return lastArabic ? AN : EN;\n case AL:\n lastArabic = true;\n hasUBAT_AL = true;\n return R;\n case WS:\n return ON;\n case CS:\n if (ix < 1 || (ix + 1) >= types.length ||\n ((wType = classes[ix - 1]) != EN && wType != AN) ||\n ((nType = types[ix + 1]) != EN && nType != AN)) {\n return ON;\n }\n if (lastArabic) {\n nType = AN;\n }\n return nType == wType ? nType : ON;\n case ES:\n wType = ix > 0 ? classes[ix - 1] : B;\n if (wType == EN && (ix + 1) < types.length && types[ix + 1] == EN) {\n return EN;\n }\n return ON;\n case ET:\n if (ix > 0 && classes[ix - 1] == EN) {\n return EN;\n }\n if (lastArabic) {\n return ON;\n }\n i = ix + 1;\n len = types.length;\n while (i < len && types[i] == ET) {\n i++;\n }\n if (i < len && types[i] == EN) {\n return EN;\n }\n return ON;\n case NSM:\n len = types.length;\n i = ix + 1;\n while (i < len && types[i] == NSM) {\n i++;\n }\n if (i < len) {\n var c = chars[ix], rtlCandidate = (c >= 0x0591 && c <= 0x08FF) || c == 0xFB1E;\n wType = types[i];\n if (rtlCandidate && (wType == R || wType == AL)) {\n return R;\n }\n }\n if (ix < 1 || (wType = types[ix - 1]) == B) {\n return ON;\n }\n return classes[ix - 1];\n case B:\n lastArabic = false;\n hasUBAT_B = true;\n return dir;\n case S:\n hasUBAT_S = true;\n return ON;\n case LRE:\n case RLE:\n case LRO:\n case RLO:\n case PDF:\n lastArabic = false;\n case BN:\n return ON;\n }\n}\nfunction _getCharacterType(ch) {\n var uc = ch.charCodeAt(0), hi = uc >> 8;\n if (hi == 0) {\n return ((uc > 0x00BF) ? L : UnicodeTBL00[uc]);\n }\n else if (hi == 5) {\n return (/[\\u0591-\\u05f4]/.test(ch) ? R : L);\n }\n else if (hi == 6) {\n if (/[\\u0610-\\u061a\\u064b-\\u065f\\u06d6-\\u06e4\\u06e7-\\u06ed]/.test(ch))\n return NSM;\n else if (/[\\u0660-\\u0669\\u066b-\\u066c]/.test(ch))\n return AN;\n else if (uc == 0x066A)\n return ET;\n else if (/[\\u06f0-\\u06f9]/.test(ch))\n return EN;\n else\n return AL;\n }\n else if (hi == 0x20 && uc <= 0x205F) {\n return UnicodeTBL20[uc & 0xFF];\n }\n else if (hi == 0xFE) {\n return (uc >= 0xFE70 ? AL : ON);\n }\n return ON;\n}\nfunction _isArabicDiacritics(ch) {\n return (ch >= '\\u064b' && ch <= '\\u0655');\n}\nexports.L = L;\nexports.R = R;\nexports.EN = EN;\nexports.ON_R = 3;\nexports.AN = 4;\nexports.R_H = 5;\nexports.B = 6;\nexports.RLE = 7;\nexports.DOT = \"\\xB7\";\nexports.doBidiReorder = function (text, textCharTypes, isRtl) {\n if (text.length < 2)\n return {};\n var chars = text.split(\"\"), logicalFromVisual = new Array(chars.length), bidiLevels = new Array(chars.length), levels = [];\n dir = isRtl ? RTL : LTR;\n _computeLevels(chars, levels, chars.length, textCharTypes);\n for (var i = 0; i < logicalFromVisual.length; logicalFromVisual[i] = i, i++)\n ;\n _invertLevel(2, levels, logicalFromVisual);\n _invertLevel(1, levels, logicalFromVisual);\n for (var i = 0; i < logicalFromVisual.length - 1; i++) { //fix levels to reflect character width\n if (textCharTypes[i] === AN) {\n levels[i] = exports.AN;\n }\n else if (levels[i] === R && ((textCharTypes[i] > AL && textCharTypes[i] < LRE)\n || textCharTypes[i] === ON || textCharTypes[i] === BN)) {\n levels[i] = exports.ON_R;\n }\n else if ((i > 0 && chars[i - 1] === '\\u0644') && /\\u0622|\\u0623|\\u0625|\\u0627/.test(chars[i])) {\n levels[i - 1] = levels[i] = exports.R_H;\n i++;\n }\n }\n if (chars[chars.length - 1] === exports.DOT)\n levels[chars.length - 1] = exports.B;\n if (chars[0] === '\\u202B')\n levels[0] = exports.RLE;\n for (var i = 0; i < logicalFromVisual.length; i++) {\n bidiLevels[i] = levels[logicalFromVisual[i]];\n }\n return { 'logicalFromVisual': logicalFromVisual, 'bidiLevels': bidiLevels };\n};\nexports.hasBidiCharacters = function (text, textCharTypes) {\n var ret = false;\n for (var i = 0; i < text.length; i++) {\n textCharTypes[i] = _getCharacterType(text.charAt(i));\n if (!ret && (textCharTypes[i] == R || textCharTypes[i] == AL || textCharTypes[i] == AN))\n ret = true;\n }\n return ret;\n};\nexports.getVisualFromLogicalIdx = function (logIdx, rowMap) {\n for (var i = 0; i < rowMap.logicalFromVisual.length; i++) {\n if (rowMap.logicalFromVisual[i] == logIdx)\n return i;\n }\n return 0;\n};\n\n});\n\nace.define(\"ace/bidihandler\",[\"require\",\"exports\",\"module\",\"ace/lib/bidiutil\",\"ace/lib/lang\"], function(require, exports, module){\"use strict\";\nvar bidiUtil = require(\"./lib/bidiutil\");\nvar lang = require(\"./lib/lang\");\nvar bidiRE = /[\\u0590-\\u05f4\\u0600-\\u06ff\\u0700-\\u08ac\\u202B]/;\nvar BidiHandler = /** @class */ (function () {\n function BidiHandler(session) {\n this.session = session;\n this.bidiMap = {};\n this.currentRow = null;\n this.bidiUtil = bidiUtil;\n this.charWidths = [];\n this.EOL = \"\\xAC\";\n this.showInvisibles = true;\n this.isRtlDir = false;\n this.$isRtl = false;\n this.line = \"\";\n this.wrapIndent = 0;\n this.EOF = \"\\xB6\";\n this.RLE = \"\\u202B\";\n this.contentWidth = 0;\n this.fontMetrics = null;\n this.rtlLineOffset = 0;\n this.wrapOffset = 0;\n this.isMoveLeftOperation = false;\n this.seenBidi = bidiRE.test(session.getValue());\n }\n BidiHandler.prototype.isBidiRow = function (screenRow, docRow, splitIndex) {\n if (!this.seenBidi)\n return false;\n if (screenRow !== this.currentRow) {\n this.currentRow = screenRow;\n this.updateRowLine(docRow, splitIndex);\n this.updateBidiMap();\n }\n return this.bidiMap.bidiLevels;\n };\n BidiHandler.prototype.onChange = function (delta) {\n if (!this.seenBidi) {\n if (delta.action == \"insert\" && bidiRE.test(delta.lines.join(\"\\n\"))) {\n this.seenBidi = true;\n this.currentRow = null;\n }\n }\n else {\n this.currentRow = null;\n }\n };\n BidiHandler.prototype.getDocumentRow = function () {\n var docRow = 0;\n var rowCache = this.session.$screenRowCache;\n if (rowCache.length) {\n var index = this.session.$getRowCacheIndex(rowCache, this.currentRow);\n if (index >= 0)\n docRow = this.session.$docRowCache[index];\n }\n return docRow;\n };\n BidiHandler.prototype.getSplitIndex = function () {\n var splitIndex = 0;\n var rowCache = this.session.$screenRowCache;\n if (rowCache.length) {\n var currentIndex, prevIndex = this.session.$getRowCacheIndex(rowCache, this.currentRow);\n while (this.currentRow - splitIndex > 0) {\n currentIndex = this.session.$getRowCacheIndex(rowCache, this.currentRow - splitIndex - 1);\n if (currentIndex !== prevIndex)\n break;\n prevIndex = currentIndex;\n splitIndex++;\n }\n }\n else {\n splitIndex = this.currentRow;\n }\n return splitIndex;\n };\n BidiHandler.prototype.updateRowLine = function (docRow, splitIndex) {\n if (docRow === undefined)\n docRow = this.getDocumentRow();\n var isLastRow = (docRow === this.session.getLength() - 1), endOfLine = isLastRow ? this.EOF : this.EOL;\n this.wrapIndent = 0;\n this.line = this.session.getLine(docRow);\n this.isRtlDir = this.$isRtl || this.line.charAt(0) === this.RLE;\n if (this.session.$useWrapMode) {\n var splits = this.session.$wrapData[docRow];\n if (splits) {\n if (splitIndex === undefined)\n splitIndex = this.getSplitIndex();\n if (splitIndex > 0 && splits.length) {\n this.wrapIndent = splits.indent;\n this.wrapOffset = this.wrapIndent * this.charWidths[bidiUtil.L];\n this.line = (splitIndex < splits.length) ?\n this.line.substring(splits[splitIndex - 1], splits[splitIndex]) :\n this.line.substring(splits[splits.length - 1]);\n }\n else {\n this.line = this.line.substring(0, splits[splitIndex]);\n }\n if (splitIndex == splits.length) {\n this.line += (this.showInvisibles) ? endOfLine : bidiUtil.DOT;\n }\n }\n }\n else {\n this.line += this.showInvisibles ? endOfLine : bidiUtil.DOT;\n }\n var session = this.session, shift = 0, size;\n this.line = this.line.replace(/\\t|[\\u1100-\\u2029, \\u202F-\\uFFE6]/g, function (ch, i) {\n if (ch === '\\t' || session.isFullWidth(ch.charCodeAt(0))) {\n size = (ch === '\\t') ? session.getScreenTabSize(i + shift) : 2;\n shift += size - 1;\n return lang.stringRepeat(bidiUtil.DOT, size);\n }\n return ch;\n });\n if (this.isRtlDir) {\n this.fontMetrics.$main.textContent = (this.line.charAt(this.line.length - 1) == bidiUtil.DOT) ? this.line.substr(0, this.line.length - 1) : this.line;\n this.rtlLineOffset = this.contentWidth - this.fontMetrics.$main.getBoundingClientRect().width;\n }\n };\n BidiHandler.prototype.updateBidiMap = function () {\n var textCharTypes = [];\n if (bidiUtil.hasBidiCharacters(this.line, textCharTypes) || this.isRtlDir) {\n this.bidiMap = bidiUtil.doBidiReorder(this.line, textCharTypes, this.isRtlDir);\n }\n else {\n this.bidiMap = {};\n }\n };\n BidiHandler.prototype.markAsDirty = function () {\n this.currentRow = null;\n };\n BidiHandler.prototype.updateCharacterWidths = function (fontMetrics) {\n if (this.characterWidth === fontMetrics.$characterSize.width)\n return;\n this.fontMetrics = fontMetrics;\n var characterWidth = this.characterWidth = fontMetrics.$characterSize.width;\n var bidiCharWidth = fontMetrics.$measureCharWidth(\"\\u05d4\");\n this.charWidths[bidiUtil.L] = this.charWidths[bidiUtil.EN] = this.charWidths[bidiUtil.ON_R] = characterWidth;\n this.charWidths[bidiUtil.R] = this.charWidths[bidiUtil.AN] = bidiCharWidth;\n this.charWidths[bidiUtil.R_H] = bidiCharWidth * 0.45;\n this.charWidths[bidiUtil.B] = this.charWidths[bidiUtil.RLE] = 0;\n this.currentRow = null;\n };\n BidiHandler.prototype.setShowInvisibles = function (showInvisibles) {\n this.showInvisibles = showInvisibles;\n this.currentRow = null;\n };\n BidiHandler.prototype.setEolChar = function (eolChar) {\n this.EOL = eolChar;\n };\n BidiHandler.prototype.setContentWidth = function (width) {\n this.contentWidth = width;\n };\n BidiHandler.prototype.isRtlLine = function (row) {\n if (this.$isRtl)\n return true;\n if (row != undefined)\n return (this.session.getLine(row).charAt(0) == this.RLE);\n else\n return this.isRtlDir;\n };\n BidiHandler.prototype.setRtlDirection = function (editor, isRtlDir) {\n var cursor = editor.getCursorPosition();\n for (var row = editor.selection.getSelectionAnchor().row; row <= cursor.row; row++) {\n if (!isRtlDir && editor.session.getLine(row).charAt(0) === editor.session.$bidiHandler.RLE)\n editor.session.doc.removeInLine(row, 0, 1);\n else if (isRtlDir && editor.session.getLine(row).charAt(0) !== editor.session.$bidiHandler.RLE)\n editor.session.doc.insert({ column: 0, row: row }, editor.session.$bidiHandler.RLE);\n }\n };\n BidiHandler.prototype.getPosLeft = function (col) {\n col -= this.wrapIndent;\n var leftBoundary = (this.line.charAt(0) === this.RLE) ? 1 : 0;\n var logicalIdx = (col > leftBoundary) ? (this.session.getOverwrite() ? col : col - 1) : leftBoundary;\n var visualIdx = bidiUtil.getVisualFromLogicalIdx(logicalIdx, this.bidiMap), levels = this.bidiMap.bidiLevels, left = 0;\n if (!this.session.getOverwrite() && col <= leftBoundary && levels[visualIdx] % 2 !== 0)\n visualIdx++;\n for (var i = 0; i < visualIdx; i++) {\n left += this.charWidths[levels[i]];\n }\n if (!this.session.getOverwrite() && (col > leftBoundary) && (levels[visualIdx] % 2 === 0))\n left += this.charWidths[levels[visualIdx]];\n if (this.wrapIndent)\n left += this.isRtlDir ? (-1 * this.wrapOffset) : this.wrapOffset;\n if (this.isRtlDir)\n left += this.rtlLineOffset;\n return left;\n };\n BidiHandler.prototype.getSelections = function (startCol, endCol) {\n var map = this.bidiMap, levels = map.bidiLevels, level, selections = [], offset = 0, selColMin = Math.min(startCol, endCol) - this.wrapIndent, selColMax = Math.max(startCol, endCol) - this.wrapIndent, isSelected = false, isSelectedPrev = false, selectionStart = 0;\n if (this.wrapIndent)\n offset += this.isRtlDir ? (-1 * this.wrapOffset) : this.wrapOffset;\n for (var logIdx, visIdx = 0; visIdx < levels.length; visIdx++) {\n logIdx = map.logicalFromVisual[visIdx];\n level = levels[visIdx];\n isSelected = (logIdx >= selColMin) && (logIdx < selColMax);\n if (isSelected && !isSelectedPrev) {\n selectionStart = offset;\n }\n else if (!isSelected && isSelectedPrev) {\n selections.push({ left: selectionStart, width: offset - selectionStart });\n }\n offset += this.charWidths[level];\n isSelectedPrev = isSelected;\n }\n if (isSelected && (visIdx === levels.length)) {\n selections.push({ left: selectionStart, width: offset - selectionStart });\n }\n if (this.isRtlDir) {\n for (var i = 0; i < selections.length; i++) {\n selections[i].left += this.rtlLineOffset;\n }\n }\n return selections;\n };\n BidiHandler.prototype.offsetToCol = function (posX) {\n if (this.isRtlDir)\n posX -= this.rtlLineOffset;\n var logicalIdx = 0, posX = Math.max(posX, 0), offset = 0, visualIdx = 0, levels = this.bidiMap.bidiLevels, charWidth = this.charWidths[levels[visualIdx]];\n if (this.wrapIndent)\n posX -= this.isRtlDir ? (-1 * this.wrapOffset) : this.wrapOffset;\n while (posX > offset + charWidth / 2) {\n offset += charWidth;\n if (visualIdx === levels.length - 1) {\n charWidth = 0;\n break;\n }\n charWidth = this.charWidths[levels[++visualIdx]];\n }\n if (visualIdx > 0 && (levels[visualIdx - 1] % 2 !== 0) && (levels[visualIdx] % 2 === 0)) {\n if (posX < offset)\n visualIdx--;\n logicalIdx = this.bidiMap.logicalFromVisual[visualIdx];\n }\n else if (visualIdx > 0 && (levels[visualIdx - 1] % 2 === 0) && (levels[visualIdx] % 2 !== 0)) {\n logicalIdx = 1 + ((posX > offset) ? this.bidiMap.logicalFromVisual[visualIdx]\n : this.bidiMap.logicalFromVisual[visualIdx - 1]);\n }\n else if ((this.isRtlDir && visualIdx === levels.length - 1 && charWidth === 0 && (levels[visualIdx - 1] % 2 === 0))\n || (!this.isRtlDir && visualIdx === 0 && (levels[visualIdx] % 2 !== 0))) {\n logicalIdx = 1 + this.bidiMap.logicalFromVisual[visualIdx];\n }\n else {\n if (visualIdx > 0 && (levels[visualIdx - 1] % 2 !== 0) && charWidth !== 0)\n visualIdx--;\n logicalIdx = this.bidiMap.logicalFromVisual[visualIdx];\n }\n if (logicalIdx === 0 && this.isRtlDir)\n logicalIdx++;\n return (logicalIdx + this.wrapIndent);\n };\n return BidiHandler;\n}());\nexports.BidiHandler = BidiHandler;\n\n});\n\nace.define(\"ace/selection\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/lang\",\"ace/lib/event_emitter\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar oop = require(\"./lib/oop\");\nvar lang = require(\"./lib/lang\");\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar Range = require(\"./range\").Range;\nvar Selection = /** @class */ (function () {\n function Selection(session) {\n this.session = session;\n this.doc = session.getDocument();\n this.clearSelection();\n this.cursor = this.lead = this.doc.createAnchor(0, 0);\n this.anchor = this.doc.createAnchor(0, 0);\n this.$silent = false;\n var self = this;\n this.cursor.on(\"change\", function (e) {\n self.$cursorChanged = true;\n if (!self.$silent)\n self._emit(\"changeCursor\");\n if (!self.$isEmpty && !self.$silent)\n self._emit(\"changeSelection\");\n if (!self.$keepDesiredColumnOnChange && e.old.column != e.value.column)\n self.$desiredColumn = null;\n });\n this.anchor.on(\"change\", function () {\n self.$anchorChanged = true;\n if (!self.$isEmpty && !self.$silent)\n self._emit(\"changeSelection\");\n });\n }\n Selection.prototype.isEmpty = function () {\n return this.$isEmpty || (this.anchor.row == this.lead.row &&\n this.anchor.column == this.lead.column);\n };\n Selection.prototype.isMultiLine = function () {\n return !this.$isEmpty && this.anchor.row != this.cursor.row;\n };\n Selection.prototype.getCursor = function () {\n return this.lead.getPosition();\n };\n Selection.prototype.setAnchor = function (row, column) {\n this.$isEmpty = false;\n this.anchor.setPosition(row, column);\n };\n Selection.prototype.getAnchor = function () {\n if (this.$isEmpty)\n return this.getSelectionLead();\n return this.anchor.getPosition();\n };\n Selection.prototype.getSelectionLead = function () {\n return this.lead.getPosition();\n };\n Selection.prototype.isBackwards = function () {\n var anchor = this.anchor;\n var lead = this.lead;\n return (anchor.row > lead.row || (anchor.row == lead.row && anchor.column > lead.column));\n };\n Selection.prototype.getRange = function () {\n var anchor = this.anchor;\n var lead = this.lead;\n if (this.$isEmpty)\n return Range.fromPoints(lead, lead);\n return this.isBackwards()\n ? Range.fromPoints(lead, anchor)\n : Range.fromPoints(anchor, lead);\n };\n Selection.prototype.clearSelection = function () {\n if (!this.$isEmpty) {\n this.$isEmpty = true;\n this._emit(\"changeSelection\");\n }\n };\n Selection.prototype.selectAll = function () {\n this.$setSelection(0, 0, Number.MAX_VALUE, Number.MAX_VALUE);\n };\n Selection.prototype.setRange = function (range, reverse) {\n var start = reverse ? range.end : range.start;\n var end = reverse ? range.start : range.end;\n this.$setSelection(start.row, start.column, end.row, end.column);\n };\n Selection.prototype.$setSelection = function (anchorRow, anchorColumn, cursorRow, cursorColumn) {\n if (this.$silent)\n return;\n var wasEmpty = this.$isEmpty;\n var wasMultiselect = this.inMultiSelectMode;\n this.$silent = true;\n this.$cursorChanged = this.$anchorChanged = false;\n this.anchor.setPosition(anchorRow, anchorColumn);\n this.cursor.setPosition(cursorRow, cursorColumn);\n this.$isEmpty = !Range.comparePoints(this.anchor, this.cursor);\n this.$silent = false;\n if (this.$cursorChanged)\n this._emit(\"changeCursor\");\n if (this.$cursorChanged || this.$anchorChanged || wasEmpty != this.$isEmpty || wasMultiselect)\n this._emit(\"changeSelection\");\n };\n Selection.prototype.$moveSelection = function (mover) {\n var lead = this.lead;\n if (this.$isEmpty)\n this.setSelectionAnchor(lead.row, lead.column);\n mover.call(this);\n };\n Selection.prototype.selectTo = function (row, column) {\n this.$moveSelection(function () {\n this.moveCursorTo(row, column);\n });\n };\n Selection.prototype.selectToPosition = function (pos) {\n this.$moveSelection(function () {\n this.moveCursorToPosition(pos);\n });\n };\n Selection.prototype.moveTo = function (row, column) {\n this.clearSelection();\n this.moveCursorTo(row, column);\n };\n Selection.prototype.moveToPosition = function (pos) {\n this.clearSelection();\n this.moveCursorToPosition(pos);\n };\n Selection.prototype.selectUp = function () {\n this.$moveSelection(this.moveCursorUp);\n };\n Selection.prototype.selectDown = function () {\n this.$moveSelection(this.moveCursorDown);\n };\n Selection.prototype.selectRight = function () {\n this.$moveSelection(this.moveCursorRight);\n };\n Selection.prototype.selectLeft = function () {\n this.$moveSelection(this.moveCursorLeft);\n };\n Selection.prototype.selectLineStart = function () {\n this.$moveSelection(this.moveCursorLineStart);\n };\n Selection.prototype.selectLineEnd = function () {\n this.$moveSelection(this.moveCursorLineEnd);\n };\n Selection.prototype.selectFileEnd = function () {\n this.$moveSelection(this.moveCursorFileEnd);\n };\n Selection.prototype.selectFileStart = function () {\n this.$moveSelection(this.moveCursorFileStart);\n };\n Selection.prototype.selectWordRight = function () {\n this.$moveSelection(this.moveCursorWordRight);\n };\n Selection.prototype.selectWordLeft = function () {\n this.$moveSelection(this.moveCursorWordLeft);\n };\n Selection.prototype.getWordRange = function (row, column) {\n if (typeof column == \"undefined\") {\n var cursor = row || this.lead;\n row = cursor.row;\n column = cursor.column;\n }\n return this.session.getWordRange(row, column);\n };\n Selection.prototype.selectWord = function () {\n this.setSelectionRange(this.getWordRange());\n };\n Selection.prototype.selectAWord = function () {\n var cursor = this.getCursor();\n var range = this.session.getAWordRange(cursor.row, cursor.column);\n this.setSelectionRange(range);\n };\n Selection.prototype.getLineRange = function (row, excludeLastChar) {\n var rowStart = typeof row == \"number\" ? row : this.lead.row;\n var rowEnd;\n var foldLine = this.session.getFoldLine(rowStart);\n if (foldLine) {\n rowStart = foldLine.start.row;\n rowEnd = foldLine.end.row;\n }\n else {\n rowEnd = rowStart;\n }\n if (excludeLastChar === true)\n return new Range(rowStart, 0, rowEnd, this.session.getLine(rowEnd).length);\n else\n return new Range(rowStart, 0, rowEnd + 1, 0);\n };\n Selection.prototype.selectLine = function () {\n this.setSelectionRange(this.getLineRange());\n };\n Selection.prototype.moveCursorUp = function () {\n this.moveCursorBy(-1, 0);\n };\n Selection.prototype.moveCursorDown = function () {\n this.moveCursorBy(1, 0);\n };\n Selection.prototype.wouldMoveIntoSoftTab = function (cursor, tabSize, direction) {\n var start = cursor.column;\n var end = cursor.column + tabSize;\n if (direction < 0) {\n start = cursor.column - tabSize;\n end = cursor.column;\n }\n return this.session.isTabStop(cursor) && this.doc.getLine(cursor.row).slice(start, end).split(\" \").length - 1 == tabSize;\n };\n Selection.prototype.moveCursorLeft = function () {\n var cursor = this.lead.getPosition(), fold;\n if (fold = this.session.getFoldAt(cursor.row, cursor.column, -1)) {\n this.moveCursorTo(fold.start.row, fold.start.column);\n }\n else if (cursor.column === 0) {\n if (cursor.row > 0) {\n this.moveCursorTo(cursor.row - 1, this.doc.getLine(cursor.row - 1).length);\n }\n }\n else {\n var tabSize = this.session.getTabSize();\n if (this.wouldMoveIntoSoftTab(cursor, tabSize, -1) && !this.session.getNavigateWithinSoftTabs()) {\n this.moveCursorBy(0, -tabSize);\n }\n else {\n this.moveCursorBy(0, -1);\n }\n }\n };\n Selection.prototype.moveCursorRight = function () {\n var cursor = this.lead.getPosition(), fold;\n if (fold = this.session.getFoldAt(cursor.row, cursor.column, 1)) {\n this.moveCursorTo(fold.end.row, fold.end.column);\n }\n else if (this.lead.column == this.doc.getLine(this.lead.row).length) {\n if (this.lead.row < this.doc.getLength() - 1) {\n this.moveCursorTo(this.lead.row + 1, 0);\n }\n }\n else {\n var tabSize = this.session.getTabSize();\n var cursor = this.lead;\n if (this.wouldMoveIntoSoftTab(cursor, tabSize, 1) && !this.session.getNavigateWithinSoftTabs()) {\n this.moveCursorBy(0, tabSize);\n }\n else {\n this.moveCursorBy(0, 1);\n }\n }\n };\n Selection.prototype.moveCursorLineStart = function () {\n var row = this.lead.row;\n var column = this.lead.column;\n var screenRow = this.session.documentToScreenRow(row, column);\n var firstColumnPosition = this.session.screenToDocumentPosition(screenRow, 0);\n var beforeCursor = this.session.getDisplayLine(row, null, firstColumnPosition.row, firstColumnPosition.column);\n var leadingSpace = beforeCursor.match(/^\\s*/);\n if (leadingSpace[0].length != column && !this.session.$useEmacsStyleLineStart)\n firstColumnPosition.column += leadingSpace[0].length;\n this.moveCursorToPosition(firstColumnPosition);\n };\n Selection.prototype.moveCursorLineEnd = function () {\n var lead = this.lead;\n var lineEnd = this.session.getDocumentLastRowColumnPosition(lead.row, lead.column);\n if (this.lead.column == lineEnd.column) {\n var line = this.session.getLine(lineEnd.row);\n if (lineEnd.column == line.length) {\n var textEnd = line.search(/\\s+$/);\n if (textEnd > 0)\n lineEnd.column = textEnd;\n }\n }\n this.moveCursorTo(lineEnd.row, lineEnd.column);\n };\n Selection.prototype.moveCursorFileEnd = function () {\n var row = this.doc.getLength() - 1;\n var column = this.doc.getLine(row).length;\n this.moveCursorTo(row, column);\n };\n Selection.prototype.moveCursorFileStart = function () {\n this.moveCursorTo(0, 0);\n };\n Selection.prototype.moveCursorLongWordRight = function () {\n var row = this.lead.row;\n var column = this.lead.column;\n var line = this.doc.getLine(row);\n var rightOfCursor = line.substring(column);\n this.session.nonTokenRe.lastIndex = 0;\n this.session.tokenRe.lastIndex = 0;\n var fold = this.session.getFoldAt(row, column, 1);\n if (fold) {\n this.moveCursorTo(fold.end.row, fold.end.column);\n return;\n }\n if (this.session.nonTokenRe.exec(rightOfCursor)) {\n column += this.session.nonTokenRe.lastIndex;\n this.session.nonTokenRe.lastIndex = 0;\n rightOfCursor = line.substring(column);\n }\n if (column >= line.length) {\n this.moveCursorTo(row, line.length);\n this.moveCursorRight();\n if (row < this.doc.getLength() - 1)\n this.moveCursorWordRight();\n return;\n }\n if (this.session.tokenRe.exec(rightOfCursor)) {\n column += this.session.tokenRe.lastIndex;\n this.session.tokenRe.lastIndex = 0;\n }\n this.moveCursorTo(row, column);\n };\n Selection.prototype.moveCursorLongWordLeft = function () {\n var row = this.lead.row;\n var column = this.lead.column;\n var fold;\n if (fold = this.session.getFoldAt(row, column, -1)) {\n this.moveCursorTo(fold.start.row, fold.start.column);\n return;\n }\n var str = this.session.getFoldStringAt(row, column, -1);\n if (str == null) {\n str = this.doc.getLine(row).substring(0, column);\n }\n var leftOfCursor = lang.stringReverse(str);\n this.session.nonTokenRe.lastIndex = 0;\n this.session.tokenRe.lastIndex = 0;\n if (this.session.nonTokenRe.exec(leftOfCursor)) {\n column -= this.session.nonTokenRe.lastIndex;\n leftOfCursor = leftOfCursor.slice(this.session.nonTokenRe.lastIndex);\n this.session.nonTokenRe.lastIndex = 0;\n }\n if (column <= 0) {\n this.moveCursorTo(row, 0);\n this.moveCursorLeft();\n if (row > 0)\n this.moveCursorWordLeft();\n return;\n }\n if (this.session.tokenRe.exec(leftOfCursor)) {\n column -= this.session.tokenRe.lastIndex;\n this.session.tokenRe.lastIndex = 0;\n }\n this.moveCursorTo(row, column);\n };\n Selection.prototype.$shortWordEndIndex = function (rightOfCursor) {\n var index = 0, ch;\n var whitespaceRe = /\\s/;\n var tokenRe = this.session.tokenRe;\n tokenRe.lastIndex = 0;\n if (this.session.tokenRe.exec(rightOfCursor)) {\n index = this.session.tokenRe.lastIndex;\n }\n else {\n while ((ch = rightOfCursor[index]) && whitespaceRe.test(ch))\n index++;\n if (index < 1) {\n tokenRe.lastIndex = 0;\n while ((ch = rightOfCursor[index]) && !tokenRe.test(ch)) {\n tokenRe.lastIndex = 0;\n index++;\n if (whitespaceRe.test(ch)) {\n if (index > 2) {\n index--;\n break;\n }\n else {\n while ((ch = rightOfCursor[index]) && whitespaceRe.test(ch))\n index++;\n if (index > 2)\n break;\n }\n }\n }\n }\n }\n tokenRe.lastIndex = 0;\n return index;\n };\n Selection.prototype.moveCursorShortWordRight = function () {\n var row = this.lead.row;\n var column = this.lead.column;\n var line = this.doc.getLine(row);\n var rightOfCursor = line.substring(column);\n var fold = this.session.getFoldAt(row, column, 1);\n if (fold)\n return this.moveCursorTo(fold.end.row, fold.end.column);\n if (column == line.length) {\n var l = this.doc.getLength();\n do {\n row++;\n rightOfCursor = this.doc.getLine(row);\n } while (row < l && /^\\s*$/.test(rightOfCursor));\n if (!/^\\s+/.test(rightOfCursor))\n rightOfCursor = \"\";\n column = 0;\n }\n var index = this.$shortWordEndIndex(rightOfCursor);\n this.moveCursorTo(row, column + index);\n };\n Selection.prototype.moveCursorShortWordLeft = function () {\n var row = this.lead.row;\n var column = this.lead.column;\n var fold;\n if (fold = this.session.getFoldAt(row, column, -1))\n return this.moveCursorTo(fold.start.row, fold.start.column);\n var line = this.session.getLine(row).substring(0, column);\n if (column === 0) {\n do {\n row--;\n line = this.doc.getLine(row);\n } while (row > 0 && /^\\s*$/.test(line));\n column = line.length;\n if (!/\\s+$/.test(line))\n line = \"\";\n }\n var leftOfCursor = lang.stringReverse(line);\n var index = this.$shortWordEndIndex(leftOfCursor);\n return this.moveCursorTo(row, column - index);\n };\n Selection.prototype.moveCursorWordRight = function () {\n if (this.session.$selectLongWords)\n this.moveCursorLongWordRight();\n else\n this.moveCursorShortWordRight();\n };\n Selection.prototype.moveCursorWordLeft = function () {\n if (this.session.$selectLongWords)\n this.moveCursorLongWordLeft();\n else\n this.moveCursorShortWordLeft();\n };\n Selection.prototype.moveCursorBy = function (rows, chars) {\n var screenPos = this.session.documentToScreenPosition(this.lead.row, this.lead.column);\n var offsetX;\n if (chars === 0) {\n if (rows !== 0) {\n if (this.session.$bidiHandler.isBidiRow(screenPos.row, this.lead.row)) {\n offsetX = this.session.$bidiHandler.getPosLeft(screenPos.column);\n screenPos.column = Math.round(offsetX / this.session.$bidiHandler.charWidths[0]);\n }\n else {\n offsetX = screenPos.column * this.session.$bidiHandler.charWidths[0];\n }\n }\n if (this.$desiredColumn)\n screenPos.column = this.$desiredColumn;\n else\n this.$desiredColumn = screenPos.column;\n }\n if (rows != 0 && this.session.lineWidgets && this.session.lineWidgets[this.lead.row]) {\n var widget = this.session.lineWidgets[this.lead.row];\n if (rows < 0)\n rows -= widget.rowsAbove || 0;\n else if (rows > 0)\n rows += widget.rowCount - (widget.rowsAbove || 0);\n }\n var docPos = this.session.screenToDocumentPosition(screenPos.row + rows, screenPos.column, offsetX);\n if (rows !== 0 && chars === 0 && docPos.row === this.lead.row && docPos.column === this.lead.column) {\n }\n this.moveCursorTo(docPos.row, docPos.column + chars, chars === 0);\n };\n Selection.prototype.moveCursorToPosition = function (position) {\n this.moveCursorTo(position.row, position.column);\n };\n Selection.prototype.moveCursorTo = function (row, column, keepDesiredColumn) {\n var fold = this.session.getFoldAt(row, column, 1);\n if (fold) {\n row = fold.start.row;\n column = fold.start.column;\n }\n this.$keepDesiredColumnOnChange = true;\n var line = this.session.getLine(row);\n if (/[\\uDC00-\\uDFFF]/.test(line.charAt(column)) && line.charAt(column - 1)) {\n if (this.lead.row == row && this.lead.column == column + 1)\n column = column - 1;\n else\n column = column + 1;\n }\n this.lead.setPosition(row, column);\n this.$keepDesiredColumnOnChange = false;\n if (!keepDesiredColumn)\n this.$desiredColumn = null;\n };\n Selection.prototype.moveCursorToScreen = function (row, column, keepDesiredColumn) {\n var pos = this.session.screenToDocumentPosition(row, column);\n this.moveCursorTo(pos.row, pos.column, keepDesiredColumn);\n };\n Selection.prototype.detach = function () {\n this.lead.detach();\n this.anchor.detach();\n };\n Selection.prototype.fromOrientedRange = function (range) {\n this.setSelectionRange(range, range.cursor == range.start);\n this.$desiredColumn = range.desiredColumn || this.$desiredColumn;\n };\n Selection.prototype.toOrientedRange = function (range) {\n var r = this.getRange();\n if (range) {\n range.start.column = r.start.column;\n range.start.row = r.start.row;\n range.end.column = r.end.column;\n range.end.row = r.end.row;\n }\n else {\n range = r;\n }\n range.cursor = this.isBackwards() ? range.start : range.end;\n range.desiredColumn = this.$desiredColumn;\n return range;\n };\n Selection.prototype.getRangeOfMovements = function (func) {\n var start = this.getCursor();\n try {\n func(this);\n var end = this.getCursor();\n return Range.fromPoints(start, end);\n }\n catch (e) {\n return Range.fromPoints(start, start);\n }\n finally {\n this.moveCursorToPosition(start);\n }\n };\n Selection.prototype.toJSON = function () {\n if (this.rangeCount) { var data = this.ranges.map(function (r) {\n var r1 = r.clone();\n r1.isBackwards = r.cursor == r.start;\n return r1;\n });\n }\n else { var data = this.getRange();\n data.isBackwards = this.isBackwards();\n }\n return data;\n };\n Selection.prototype.fromJSON = function (data) {\n if (data.start == undefined) {\n if (this.rangeList && data.length > 1) {\n this.toSingleRange(data[0]);\n for (var i = data.length; i--;) {\n var r = Range.fromPoints(data[i].start, data[i].end);\n if (data[i].isBackwards)\n r.cursor = r.start;\n this.addRange(r, true);\n }\n return;\n }\n else {\n data = data[0];\n }\n }\n if (this.rangeList)\n this.toSingleRange(data);\n this.setSelectionRange(data, data.isBackwards);\n };\n Selection.prototype.isEqual = function (data) {\n if ((data.length || this.rangeCount) && data.length != this.rangeCount)\n return false;\n if (!data.length || !this.ranges)\n return this.getRange().isEqual(data);\n for (var i = this.ranges.length; i--;) {\n if (!this.ranges[i].isEqual(data[i]))\n return false;\n }\n return true;\n };\n return Selection;\n}());\nSelection.prototype.setSelectionAnchor = Selection.prototype.setAnchor;\nSelection.prototype.getSelectionAnchor = Selection.prototype.getAnchor;\nSelection.prototype.setSelectionRange = Selection.prototype.setRange;\noop.implement(Selection.prototype, EventEmitter);\nexports.Selection = Selection;\n\n});\n\nace.define(\"ace/tokenizer\",[\"require\",\"exports\",\"module\",\"ace/lib/report_error\"], function(require, exports, module){\"use strict\";\nvar reportError = require(\"./lib/report_error\").reportError;\nvar MAX_TOKEN_COUNT = 2000;\nvar Tokenizer = /** @class */ (function () {\n function Tokenizer(rules) {\n this.splitRegex;\n this.states = rules;\n this.regExps = {};\n this.matchMappings = {};\n for (var key in this.states) {\n var state = this.states[key];\n var ruleRegExps = [];\n var matchTotal = 0;\n var mapping = this.matchMappings[key] = { defaultToken: \"text\" };\n var flag = \"g\";\n var splitterRurles = [];\n for (var i = 0; i < state.length; i++) {\n var rule = state[i];\n if (rule.defaultToken)\n mapping.defaultToken = rule.defaultToken;\n if (rule.caseInsensitive && flag.indexOf(\"i\") === -1)\n flag += \"i\";\n if (rule.unicode && flag.indexOf(\"u\") === -1)\n flag += \"u\";\n if (rule.regex == null)\n continue;\n if (rule.regex instanceof RegExp)\n rule.regex = rule.regex.toString().slice(1, -1);\n var adjustedregex = rule.regex;\n var matchcount = new RegExp(\"(?:(\" + adjustedregex + \")|(.))\").exec(\"a\").length - 2;\n if (Array.isArray(rule.token)) {\n if (rule.token.length == 1 || matchcount == 1) {\n rule.token = rule.token[0];\n }\n else if (matchcount - 1 != rule.token.length) {\n this.reportError(\"number of classes and regexp groups doesn't match\", {\n rule: rule,\n groupCount: matchcount - 1\n });\n rule.token = rule.token[0];\n }\n else {\n rule.tokenArray = rule.token;\n rule.token = null;\n rule.onMatch = this.$arrayTokens;\n }\n }\n else if (typeof rule.token == \"function\" && !rule.onMatch) {\n if (matchcount > 1)\n rule.onMatch = this.$applyToken;\n else\n rule.onMatch = rule.token;\n }\n if (matchcount > 1) {\n if (/\\\\\\d/.test(rule.regex)) {\n adjustedregex = rule.regex.replace(/\\\\([0-9]+)/g, function (match, digit) {\n return \"\\\\\" + (parseInt(digit, 10) + matchTotal + 1);\n });\n }\n else {\n matchcount = 1;\n adjustedregex = this.removeCapturingGroups(rule.regex);\n }\n if (!rule.splitRegex && typeof rule.token != \"string\")\n splitterRurles.push(rule); // flag will be known only at the very end\n }\n mapping[matchTotal] = i;\n matchTotal += matchcount;\n ruleRegExps.push(adjustedregex);\n if (!rule.onMatch)\n rule.onMatch = null;\n }\n if (!ruleRegExps.length) {\n mapping[0] = 0;\n ruleRegExps.push(\"$\");\n }\n splitterRurles.forEach(function (rule) {\n rule.splitRegex = this.createSplitterRegexp(rule.regex, flag);\n }, this);\n this.regExps[key] = new RegExp(\"(\" + ruleRegExps.join(\")|(\") + \")|($)\", flag);\n }\n }\n Tokenizer.prototype.$setMaxTokenCount = function (m) {\n MAX_TOKEN_COUNT = m | 0;\n };\n Tokenizer.prototype.$applyToken = function (str) {\n var values = this.splitRegex.exec(str).slice(1);\n var types = this.token.apply(this, values);\n if (typeof types === \"string\")\n return [{ type: types, value: str }];\n var tokens = [];\n for (var i = 0, l = types.length; i < l; i++) {\n if (values[i])\n tokens[tokens.length] = {\n type: types[i],\n value: values[i]\n };\n }\n return tokens;\n };\n Tokenizer.prototype.$arrayTokens = function (str) {\n if (!str)\n return [];\n var values = this.splitRegex.exec(str);\n if (!values)\n return \"text\";\n var tokens = [];\n var types = this.tokenArray;\n for (var i = 0, l = types.length; i < l; i++) {\n if (values[i + 1])\n tokens[tokens.length] = {\n type: types[i],\n value: values[i + 1]\n };\n }\n return tokens;\n };\n Tokenizer.prototype.removeCapturingGroups = function (src) {\n var r = src.replace(/\\\\.|\\[(?:\\\\.|[^\\\\\\]])*|\\(\\?[:=!<]|(\\()/g, function (x, y) { return y ? \"(?:\" : x; });\n return r;\n };\n Tokenizer.prototype.createSplitterRegexp = function (src, flag) {\n if (src.indexOf(\"(?=\") != -1) {\n var stack = 0;\n var inChClass = false;\n var lastCapture = {};\n src.replace(/(\\\\.)|(\\((?:\\?[=!])?)|(\\))|([\\[\\]])/g, function (m, esc, parenOpen, parenClose, square, index) {\n if (inChClass) {\n inChClass = square != \"]\";\n }\n else if (square) {\n inChClass = true;\n }\n else if (parenClose) {\n if (stack == lastCapture.stack) {\n lastCapture.end = index + 1;\n lastCapture.stack = -1;\n }\n stack--;\n }\n else if (parenOpen) {\n stack++;\n if (parenOpen.length != 1) {\n lastCapture.stack = stack;\n lastCapture.start = index;\n }\n }\n return m;\n });\n if (lastCapture.end != null && /^\\)*$/.test(src.substr(lastCapture.end)))\n src = src.substring(0, lastCapture.start) + src.substr(lastCapture.end);\n }\n if (src.charAt(0) != \"^\")\n src = \"^\" + src;\n if (src.charAt(src.length - 1) != \"$\")\n src += \"$\";\n return new RegExp(src, (flag || \"\").replace(\"g\", \"\"));\n };\n Tokenizer.prototype.getLineTokens = function (line, startState) {\n if (startState && typeof startState != \"string\") {\n var stack = startState.slice(0);\n startState = stack[0];\n if (startState === \"#tmp\") {\n stack.shift();\n startState = stack.shift();\n }\n }\n else\n var stack = [];\n var currentState = /**@type{string}*/ (startState) || \"start\";\n var state = this.states[currentState];\n if (!state) {\n currentState = \"start\";\n state = this.states[currentState];\n }\n var mapping = this.matchMappings[currentState];\n var re = this.regExps[currentState];\n re.lastIndex = 0;\n var match, tokens = [];\n var lastIndex = 0;\n var matchAttempts = 0;\n var token = { type: null, value: \"\" };\n while (match = re.exec(line)) {\n var type = mapping.defaultToken;\n var rule = null;\n var value = match[0];\n var index = re.lastIndex;\n if (index - value.length > lastIndex) {\n var skipped = line.substring(lastIndex, index - value.length);\n if (token.type == type) {\n token.value += skipped;\n }\n else {\n if (token.type)\n tokens.push(token);\n token = { type: type, value: skipped };\n }\n }\n for (var i = 0; i < match.length - 2; i++) {\n if (match[i + 1] === undefined)\n continue;\n rule = state[mapping[i]];\n if (rule.onMatch)\n type = rule.onMatch(value, currentState, stack, line);\n else\n type = rule.token;\n if (rule.next) {\n if (typeof rule.next == \"string\") {\n currentState = rule.next;\n }\n else {\n currentState = rule.next(currentState, stack);\n }\n state = this.states[currentState];\n if (!state) {\n this.reportError(\"state doesn't exist\", currentState);\n currentState = \"start\";\n state = this.states[currentState];\n }\n mapping = this.matchMappings[currentState];\n lastIndex = index;\n re = this.regExps[currentState];\n re.lastIndex = index;\n }\n if (rule.consumeLineEnd)\n lastIndex = index;\n break;\n }\n if (value) {\n if (typeof type === \"string\") {\n if ((!rule || rule.merge !== false) && token.type === type) {\n token.value += value;\n }\n else {\n if (token.type)\n tokens.push(token);\n token = { type: type, value: value };\n }\n }\n else if (type) {\n if (token.type)\n tokens.push(token);\n token = { type: null, value: \"\" };\n for (var i = 0; i < type.length; i++)\n tokens.push(type[i]);\n }\n }\n if (lastIndex == line.length)\n break;\n lastIndex = index;\n if (matchAttempts++ > MAX_TOKEN_COUNT) {\n if (matchAttempts > 2 * line.length) {\n this.reportError(\"infinite loop with in ace tokenizer\", {\n startState: startState,\n line: line\n });\n }\n while (lastIndex < line.length) {\n if (token.type)\n tokens.push(token);\n token = {\n value: line.substring(lastIndex, lastIndex += 500),\n type: \"overflow\"\n };\n }\n currentState = \"start\";\n stack = [];\n break;\n }\n }\n if (token.type)\n tokens.push(token);\n if (stack.length > 1) {\n if (stack[0] !== currentState)\n stack.unshift(\"#tmp\", currentState);\n }\n return {\n tokens: tokens,\n state: stack.length ? stack : currentState\n };\n };\n return Tokenizer;\n}());\nTokenizer.prototype.reportError = reportError;\nexports.Tokenizer = Tokenizer;\n\n});\n\nace.define(\"ace/mode/text_highlight_rules\",[\"require\",\"exports\",\"module\",\"ace/lib/deep_copy\"], function(require, exports, module){\"use strict\";\nvar deepCopy = require(\"../lib/deep_copy\").deepCopy;\nvar TextHighlightRules;\nTextHighlightRules = function () {\n this.$rules = {\n \"start\": [{\n token: \"empty_line\",\n regex: '^$'\n }, {\n defaultToken: \"text\"\n }]\n };\n};\n(function () {\n this.addRules = function (rules, prefix) {\n if (!prefix) {\n for (var key in rules)\n this.$rules[key] = rules[key];\n return;\n }\n for (var key in rules) {\n var state = rules[key];\n for (var i = 0; i < state.length; i++) {\n var rule = state[i];\n if (rule.next || rule.onMatch) {\n if (typeof rule.next == \"string\") {\n if (rule.next.indexOf(prefix) !== 0)\n rule.next = prefix + rule.next;\n }\n if (rule.nextState && rule.nextState.indexOf(prefix) !== 0)\n rule.nextState = prefix + rule.nextState;\n }\n }\n this.$rules[prefix + key] = state;\n }\n };\n this.getRules = function () {\n return this.$rules;\n };\n this.embedRules = function (HighlightRules, prefix, escapeRules, states, append) {\n var embedRules = typeof HighlightRules == \"function\"\n ? new HighlightRules().getRules()\n : HighlightRules;\n if (states) {\n for (var i = 0; i < states.length; i++)\n states[i] = prefix + states[i];\n }\n else {\n states = [];\n for (var key in embedRules)\n states.push(prefix + key);\n }\n this.addRules(embedRules, prefix);\n if (escapeRules) {\n var addRules = Array.prototype[append ? \"push\" : \"unshift\"];\n for (var i = 0; i < states.length; i++)\n addRules.apply(this.$rules[states[i]], deepCopy(escapeRules));\n }\n if (!this.$embeds)\n this.$embeds = [];\n this.$embeds.push(prefix);\n };\n this.getEmbeds = function () {\n return this.$embeds;\n };\n var pushState = function (currentState, stack) {\n if (currentState != \"start\" || stack.length)\n stack.unshift(this.nextState, currentState);\n return this.nextState;\n };\n var popState = function (currentState, stack) {\n stack.shift();\n return stack.shift() || \"start\";\n };\n this.normalizeRules = function () {\n var id = 0;\n var rules = this.$rules;\n function processState(key) {\n var state = rules[key];\n state[\"processed\"] = true;\n for (var i = 0; i < state.length; i++) {\n var rule = state[i];\n var toInsert = null;\n if (Array.isArray(rule)) {\n toInsert = rule;\n rule = {};\n }\n if (!rule.regex && rule.start) {\n rule.regex = rule.start;\n if (!rule.next)\n rule.next = [];\n rule.next.push({\n defaultToken: rule.token\n }, {\n token: rule.token + \".end\",\n regex: rule.end || rule.start,\n next: \"pop\"\n });\n rule.token = rule.token + \".start\";\n rule.push = true;\n }\n var next = rule.next || rule.push;\n if (next && Array.isArray(next)) {\n var stateName = rule.stateName;\n if (!stateName) {\n stateName = rule.token;\n if (typeof stateName != \"string\")\n stateName = stateName[0] || \"\";\n if (rules[stateName])\n stateName += id++;\n }\n rules[stateName] = next;\n rule.next = stateName;\n processState(stateName);\n }\n else if (next == \"pop\") {\n rule.next = popState;\n }\n if (rule.push) {\n rule.nextState = rule.next || rule.push;\n rule.next = pushState;\n delete rule.push;\n }\n if (rule.rules) {\n for (var r in rule.rules) {\n if (rules[r]) {\n if (rules[r].push)\n rules[r].push.apply(rules[r], rule.rules[r]);\n }\n else {\n rules[r] = rule.rules[r];\n }\n }\n }\n var includeName = typeof rule == \"string\" ? rule : rule.include;\n if (includeName) {\n if (includeName === \"$self\")\n includeName = \"start\";\n if (Array.isArray(includeName))\n toInsert = includeName.map(function (x) { return rules[x]; });\n else\n toInsert = rules[includeName];\n }\n if (toInsert) {\n var args = [i, 1].concat(toInsert);\n if (rule.noEscape)\n args = args.filter(function (x) { return !x.next; });\n state.splice.apply(state, args);\n i--;\n }\n if (rule.keywordMap) {\n rule.token = this.createKeywordMapper(rule.keywordMap, rule.defaultToken || \"text\", rule.caseInsensitive);\n delete rule.defaultToken;\n }\n }\n }\n Object.keys(rules).forEach(processState, this);\n };\n this.createKeywordMapper = function (map, defaultToken, ignoreCase, splitChar) {\n var keywords = Object.create(null);\n this.$keywordList = [];\n Object.keys(map).forEach(function (className) {\n var a = map[className];\n var list = a.split(splitChar || \"|\");\n for (var i = list.length; i--;) {\n var word = list[i];\n this.$keywordList.push(word);\n if (ignoreCase)\n word = word.toLowerCase();\n keywords[word] = className;\n }\n }, this);\n map = null;\n return ignoreCase\n ? function (value) { return keywords[value.toLowerCase()] || defaultToken; }\n : function (value) { return keywords[value] || defaultToken; };\n };\n this.getKeywords = function () {\n return this.$keywords;\n };\n}).call(TextHighlightRules.prototype);\nexports.TextHighlightRules = TextHighlightRules;\n\n});\n\nace.define(\"ace/mode/behaviour\",[\"require\",\"exports\",\"module\"], function(require, exports, module){\"use strict\";\nvar Behaviour;\nBehaviour = function () {\n this.$behaviours = {};\n};\n(function () {\n this.add = function (name, action, callback) {\n switch (undefined) {\n case this.$behaviours:\n this.$behaviours = {};\n case this.$behaviours[name]:\n this.$behaviours[name] = {};\n }\n this.$behaviours[name][action] = callback;\n };\n this.addBehaviours = function (behaviours) {\n for (var key in behaviours) {\n for (var action in behaviours[key]) {\n this.add(key, action, behaviours[key][action]);\n }\n }\n };\n this.remove = function (name) {\n if (this.$behaviours && this.$behaviours[name]) {\n delete this.$behaviours[name];\n }\n };\n this.inherit = function (mode, filter) {\n if (typeof mode === \"function\") {\n var behaviours = new mode().getBehaviours(filter);\n }\n else {\n var behaviours = mode.getBehaviours(filter);\n }\n this.addBehaviours(behaviours);\n };\n this.getBehaviours = function (filter) {\n if (!filter) {\n return this.$behaviours;\n }\n else {\n var ret = {};\n for (var i = 0; i < filter.length; i++) {\n if (this.$behaviours[filter[i]]) {\n ret[filter[i]] = this.$behaviours[filter[i]];\n }\n }\n return ret;\n }\n };\n}).call(Behaviour.prototype);\nexports.Behaviour = Behaviour;\n\n});\n\nace.define(\"ace/token_iterator\",[\"require\",\"exports\",\"module\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar Range = require(\"./range\").Range;\nvar TokenIterator = /** @class */ (function () {\n function TokenIterator(session, initialRow, initialColumn) {\n this.$session = session;\n this.$row = initialRow;\n this.$rowTokens = session.getTokens(initialRow);\n var token = session.getTokenAt(initialRow, initialColumn);\n this.$tokenIndex = token ? token.index : -1;\n }\n TokenIterator.prototype.stepBackward = function () {\n this.$tokenIndex -= 1;\n while (this.$tokenIndex < 0) {\n this.$row -= 1;\n if (this.$row < 0) {\n this.$row = 0;\n return null;\n }\n this.$rowTokens = this.$session.getTokens(this.$row);\n this.$tokenIndex = this.$rowTokens.length - 1;\n }\n return this.$rowTokens[this.$tokenIndex];\n };\n TokenIterator.prototype.stepForward = function () {\n this.$tokenIndex += 1;\n var rowCount;\n while (this.$tokenIndex >= this.$rowTokens.length) {\n this.$row += 1;\n if (!rowCount)\n rowCount = this.$session.getLength();\n if (this.$row >= rowCount) {\n this.$row = rowCount - 1;\n return null;\n }\n this.$rowTokens = this.$session.getTokens(this.$row);\n this.$tokenIndex = 0;\n }\n return this.$rowTokens[this.$tokenIndex];\n };\n TokenIterator.prototype.getCurrentToken = function () {\n return this.$rowTokens[this.$tokenIndex];\n };\n TokenIterator.prototype.getCurrentTokenRow = function () {\n return this.$row;\n };\n TokenIterator.prototype.getCurrentTokenColumn = function () {\n var rowTokens = this.$rowTokens;\n var tokenIndex = this.$tokenIndex;\n var column = rowTokens[tokenIndex].start;\n if (column !== undefined)\n return column;\n column = 0;\n while (tokenIndex > 0) {\n tokenIndex -= 1;\n column += rowTokens[tokenIndex].value.length;\n }\n return column;\n };\n TokenIterator.prototype.getCurrentTokenPosition = function () {\n return { row: this.$row, column: this.getCurrentTokenColumn() };\n };\n TokenIterator.prototype.getCurrentTokenRange = function () {\n var token = this.$rowTokens[this.$tokenIndex];\n var column = this.getCurrentTokenColumn();\n return new Range(this.$row, column, this.$row, column + token.value.length);\n };\n return TokenIterator;\n}());\nexports.TokenIterator = TokenIterator;\n\n});\n\nace.define(\"ace/mode/behaviour/cstyle\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/mode/behaviour\",\"ace/token_iterator\",\"ace/lib/lang\"], function(require, exports, module){\"use strict\";\nvar oop = require(\"../../lib/oop\");\nvar Behaviour = require(\"../behaviour\").Behaviour;\nvar TokenIterator = require(\"../../token_iterator\").TokenIterator;\nvar lang = require(\"../../lib/lang\");\nvar SAFE_INSERT_IN_TOKENS = [\"text\", \"paren.rparen\", \"rparen\", \"paren\", \"punctuation.operator\"];\nvar SAFE_INSERT_BEFORE_TOKENS = [\"text\", \"paren.rparen\", \"rparen\", \"paren\", \"punctuation.operator\", \"comment\"];\nvar context;\nvar contextCache = {};\nvar defaultQuotes = { '\"': '\"', \"'\": \"'\" };\nvar initContext = function (editor) {\n var id = -1;\n if (editor.multiSelect) {\n id = editor.selection.index;\n if (contextCache.rangeCount != editor.multiSelect.rangeCount)\n contextCache = { rangeCount: editor.multiSelect.rangeCount };\n }\n if (contextCache[id])\n return context = contextCache[id];\n context = contextCache[id] = {\n autoInsertedBrackets: 0,\n autoInsertedRow: -1,\n autoInsertedLineEnd: \"\",\n maybeInsertedBrackets: 0,\n maybeInsertedRow: -1,\n maybeInsertedLineStart: \"\",\n maybeInsertedLineEnd: \"\"\n };\n};\nvar getWrapped = function (selection, selected, opening, closing) {\n var rowDiff = selection.end.row - selection.start.row;\n return {\n text: opening + selected + closing,\n selection: [\n 0,\n selection.start.column + 1,\n rowDiff,\n selection.end.column + (rowDiff ? 0 : 1)\n ]\n };\n};\nvar CstyleBehaviour;\nCstyleBehaviour = function (options) {\n options = options || {};\n this.add(\"braces\", \"insertion\", function (state, action, editor, session, text) {\n var cursor = editor.getCursorPosition();\n var line = session.doc.getLine(cursor.row);\n if (text == '{') {\n initContext(editor);\n var selection = editor.getSelectionRange();\n var selected = session.doc.getTextRange(selection);\n var token = session.getTokenAt(cursor.row, cursor.column);\n if (selected !== \"\" && selected !== \"{\" && editor.getWrapBehavioursEnabled()) {\n return getWrapped(selection, selected, '{', '}');\n }\n else if (token && /(?:string)\\.quasi|\\.xml/.test(token.type)) {\n var excludeTokens = [\n /tag\\-(?:open|name)/, /attribute\\-name/\n ];\n if (excludeTokens.some(function (el) { return el.test(token.type); }) || /(string)\\.quasi/.test(token.type)\n && token.value[cursor.column - token.start - 1] !== '$')\n return;\n CstyleBehaviour.recordAutoInsert(editor, session, \"}\");\n return {\n text: '{}',\n selection: [1, 1]\n };\n }\n else if (CstyleBehaviour.isSaneInsertion(editor, session)) {\n if (/[\\]\\}\\)]/.test(line[cursor.column]) || editor.inMultiSelectMode || options.braces) {\n CstyleBehaviour.recordAutoInsert(editor, session, \"}\");\n return {\n text: '{}',\n selection: [1, 1]\n };\n }\n else {\n CstyleBehaviour.recordMaybeInsert(editor, session, \"{\");\n return {\n text: '{',\n selection: [1, 1]\n };\n }\n }\n }\n else if (text == '}') {\n initContext(editor);\n var rightChar = line.substring(cursor.column, cursor.column + 1);\n if (rightChar == '}') {\n var matching = session.$findOpeningBracket('}', { column: cursor.column + 1, row: cursor.row });\n if (matching !== null && CstyleBehaviour.isAutoInsertedClosing(cursor, line, text)) {\n CstyleBehaviour.popAutoInsertedClosing();\n return {\n text: '',\n selection: [1, 1]\n };\n }\n }\n }\n else if (text == \"\\n\" || text == \"\\r\\n\") {\n initContext(editor);\n var closing = \"\";\n if (CstyleBehaviour.isMaybeInsertedClosing(cursor, line)) {\n closing = lang.stringRepeat(\"}\", context.maybeInsertedBrackets);\n CstyleBehaviour.clearMaybeInsertedClosing();\n }\n var rightChar = line.substring(cursor.column, cursor.column + 1);\n if (rightChar === '}') {\n var openBracePos = session.findMatchingBracket({ row: cursor.row, column: cursor.column + 1 }, '}');\n if (!openBracePos)\n return null;\n var next_indent = this.$getIndent(session.getLine(openBracePos.row));\n }\n else if (closing) {\n var next_indent = this.$getIndent(line);\n }\n else {\n CstyleBehaviour.clearMaybeInsertedClosing();\n return;\n }\n var indent = next_indent + session.getTabString();\n return {\n text: '\\n' + indent + '\\n' + next_indent + closing,\n selection: [1, indent.length, 1, indent.length]\n };\n }\n else {\n CstyleBehaviour.clearMaybeInsertedClosing();\n }\n });\n this.add(\"braces\", \"deletion\", function (state, action, editor, session, range) {\n var selected = session.doc.getTextRange(range);\n if (!range.isMultiLine() && selected == '{') {\n initContext(editor);\n var line = session.doc.getLine(range.start.row);\n var rightChar = line.substring(range.end.column, range.end.column + 1);\n if (rightChar == '}') {\n range.end.column++;\n return range;\n }\n else {\n context.maybeInsertedBrackets--;\n }\n }\n });\n this.add(\"parens\", \"insertion\", function (state, action, editor, session, text) {\n if (text == '(') {\n initContext(editor);\n var selection = editor.getSelectionRange();\n var selected = session.doc.getTextRange(selection);\n if (selected !== \"\" && editor.getWrapBehavioursEnabled()) {\n return getWrapped(selection, selected, '(', ')');\n }\n else if (CstyleBehaviour.isSaneInsertion(editor, session)) {\n CstyleBehaviour.recordAutoInsert(editor, session, \")\");\n return {\n text: '()',\n selection: [1, 1]\n };\n }\n }\n else if (text == ')') {\n initContext(editor);\n var cursor = editor.getCursorPosition();\n var line = session.doc.getLine(cursor.row);\n var rightChar = line.substring(cursor.column, cursor.column + 1);\n if (rightChar == ')') {\n var matching = session.$findOpeningBracket(')', { column: cursor.column + 1, row: cursor.row });\n if (matching !== null && CstyleBehaviour.isAutoInsertedClosing(cursor, line, text)) {\n CstyleBehaviour.popAutoInsertedClosing();\n return {\n text: '',\n selection: [1, 1]\n };\n }\n }\n }\n });\n this.add(\"parens\", \"deletion\", function (state, action, editor, session, range) {\n var selected = session.doc.getTextRange(range);\n if (!range.isMultiLine() && selected == '(') {\n initContext(editor);\n var line = session.doc.getLine(range.start.row);\n var rightChar = line.substring(range.start.column + 1, range.start.column + 2);\n if (rightChar == ')') {\n range.end.column++;\n return range;\n }\n }\n });\n this.add(\"brackets\", \"insertion\", function (state, action, editor, session, text) {\n if (text == '[') {\n initContext(editor);\n var selection = editor.getSelectionRange();\n var selected = session.doc.getTextRange(selection);\n if (selected !== \"\" && editor.getWrapBehavioursEnabled()) {\n return getWrapped(selection, selected, '[', ']');\n }\n else if (CstyleBehaviour.isSaneInsertion(editor, session)) {\n CstyleBehaviour.recordAutoInsert(editor, session, \"]\");\n return {\n text: '[]',\n selection: [1, 1]\n };\n }\n }\n else if (text == ']') {\n initContext(editor);\n var cursor = editor.getCursorPosition();\n var line = session.doc.getLine(cursor.row);\n var rightChar = line.substring(cursor.column, cursor.column + 1);\n if (rightChar == ']') {\n var matching = session.$findOpeningBracket(']', { column: cursor.column + 1, row: cursor.row });\n if (matching !== null && CstyleBehaviour.isAutoInsertedClosing(cursor, line, text)) {\n CstyleBehaviour.popAutoInsertedClosing();\n return {\n text: '',\n selection: [1, 1]\n };\n }\n }\n }\n });\n this.add(\"brackets\", \"deletion\", function (state, action, editor, session, range) {\n var selected = session.doc.getTextRange(range);\n if (!range.isMultiLine() && selected == '[') {\n initContext(editor);\n var line = session.doc.getLine(range.start.row);\n var rightChar = line.substring(range.start.column + 1, range.start.column + 2);\n if (rightChar == ']') {\n range.end.column++;\n return range;\n }\n }\n });\n this.add(\"string_dquotes\", \"insertion\", function (state, action, editor, session, text) {\n var quotes = session.$mode.$quotes || defaultQuotes;\n if (text.length == 1 && quotes[text]) {\n if (this.lineCommentStart && this.lineCommentStart.indexOf(text) != -1)\n return;\n initContext(editor);\n var quote = text;\n var selection = editor.getSelectionRange();\n var selected = session.doc.getTextRange(selection);\n if (selected !== \"\" && (selected.length != 1 || !quotes[selected]) && editor.getWrapBehavioursEnabled()) {\n return getWrapped(selection, selected, quote, quote);\n }\n else if (!selected) {\n var cursor = editor.getCursorPosition();\n var line = session.doc.getLine(cursor.row);\n var leftChar = line.substring(cursor.column - 1, cursor.column);\n var rightChar = line.substring(cursor.column, cursor.column + 1);\n var token = session.getTokenAt(cursor.row, cursor.column);\n var rightToken = session.getTokenAt(cursor.row, cursor.column + 1);\n if (leftChar == \"\\\\\" && token && /escape/.test(token.type))\n return null;\n var stringBefore = token && /string|escape/.test(token.type);\n var stringAfter = !rightToken || /string|escape/.test(rightToken.type);\n var pair;\n if (rightChar == quote) {\n pair = stringBefore !== stringAfter;\n if (pair && /string\\.end/.test(rightToken.type))\n pair = false;\n }\n else {\n if (stringBefore && !stringAfter)\n return null; // wrap string with different quote\n if (stringBefore && stringAfter)\n return null; // do not pair quotes inside strings\n var wordRe = session.$mode.tokenRe;\n wordRe.lastIndex = 0;\n var isWordBefore = wordRe.test(leftChar);\n wordRe.lastIndex = 0;\n var isWordAfter = wordRe.test(rightChar);\n var pairQuotesAfter = session.$mode.$pairQuotesAfter;\n var shouldPairQuotes = pairQuotesAfter && pairQuotesAfter[quote] && pairQuotesAfter[quote].test(leftChar);\n if ((!shouldPairQuotes && isWordBefore) || isWordAfter)\n return null; // before or after alphanumeric\n if (rightChar && !/[\\s;,.})\\]\\\\]/.test(rightChar))\n return null; // there is rightChar and it isn't closing\n var charBefore = line[cursor.column - 2];\n if (leftChar == quote && (charBefore == quote || wordRe.test(charBefore)))\n return null;\n pair = true;\n }\n return {\n text: pair ? quote + quote : \"\",\n selection: [1, 1]\n };\n }\n }\n });\n this.add(\"string_dquotes\", \"deletion\", function (state, action, editor, session, range) {\n var quotes = session.$mode.$quotes || defaultQuotes;\n var selected = session.doc.getTextRange(range);\n if (!range.isMultiLine() && quotes.hasOwnProperty(selected)) {\n initContext(editor);\n var line = session.doc.getLine(range.start.row);\n var rightChar = line.substring(range.start.column + 1, range.start.column + 2);\n if (rightChar == selected) {\n range.end.column++;\n return range;\n }\n }\n });\n if (options.closeDocComment !== false) {\n this.add(\"doc comment end\", \"insertion\", function (state, action, editor, session, text) {\n if (state === \"doc-start\" && (text === \"\\n\" || text === \"\\r\\n\") && editor.selection.isEmpty()) {\n var cursor = editor.getCursorPosition();\n if (cursor.column === 0) {\n return;\n }\n var line = session.doc.getLine(cursor.row);\n var nextLine = session.doc.getLine(cursor.row + 1);\n var tokens = session.getTokens(cursor.row);\n var index = 0;\n for (var i = 0; i < tokens.length; i++) {\n index += tokens[i].value.length;\n var currentToken = tokens[i];\n if (index >= cursor.column) {\n if (index === cursor.column) {\n if (!/\\.doc/.test(currentToken.type)) {\n return;\n }\n if (/\\*\\//.test(currentToken.value)) {\n var nextToken = tokens[i + 1];\n if (!nextToken || !/\\.doc/.test(nextToken.type)) {\n return;\n }\n }\n }\n var cursorPosInToken = cursor.column - (index - currentToken.value.length);\n var closeDocPos = currentToken.value.indexOf(\"*/\");\n var openDocPos = currentToken.value.indexOf(\"/**\", closeDocPos > -1 ? closeDocPos + 2 : 0);\n if (openDocPos !== -1 && cursorPosInToken > openDocPos && cursorPosInToken < openDocPos + 3) {\n return;\n }\n if (closeDocPos !== -1 && openDocPos !== -1 && cursorPosInToken >= closeDocPos\n && cursorPosInToken <= openDocPos || !/\\.doc/.test(currentToken.type)) {\n return;\n }\n break;\n }\n }\n var indent = this.$getIndent(line);\n if (/\\s*\\*/.test(nextLine)) {\n if (/^\\s*\\*/.test(line)) {\n return {\n text: text + indent + \"* \",\n selection: [1, 2 + indent.length, 1, 2 + indent.length]\n };\n }\n else {\n return {\n text: text + indent + \" * \",\n selection: [1, 3 + indent.length, 1, 3 + indent.length]\n };\n }\n }\n if (/\\/\\*\\*/.test(line.substring(0, cursor.column))) {\n return {\n text: text + indent + \" * \" + text + \" \" + indent + \"*/\",\n selection: [1, 4 + indent.length, 1, 4 + indent.length]\n };\n }\n }\n });\n }\n};\nCstyleBehaviour.isSaneInsertion = function (editor, session) {\n var cursor = editor.getCursorPosition();\n var iterator = new TokenIterator(session, cursor.row, cursor.column);\n if (!this.$matchTokenType(iterator.getCurrentToken() || \"text\", SAFE_INSERT_IN_TOKENS)) {\n if (/[)}\\]]/.test(editor.session.getLine(cursor.row)[cursor.column]))\n return true;\n var iterator2 = new TokenIterator(session, cursor.row, cursor.column + 1);\n if (!this.$matchTokenType(iterator2.getCurrentToken() || \"text\", SAFE_INSERT_IN_TOKENS))\n return false;\n }\n iterator.stepForward();\n return iterator.getCurrentTokenRow() !== cursor.row ||\n this.$matchTokenType(iterator.getCurrentToken() || \"text\", SAFE_INSERT_BEFORE_TOKENS);\n};\nCstyleBehaviour[\"$matchTokenType\"] = function (token, types) {\n return types.indexOf(token.type || token) > -1;\n};\nCstyleBehaviour[\"recordAutoInsert\"] = function (editor, session, bracket) {\n var cursor = editor.getCursorPosition();\n var line = session.doc.getLine(cursor.row);\n if (!this[\"isAutoInsertedClosing\"](cursor, line, context.autoInsertedLineEnd[0]))\n context.autoInsertedBrackets = 0;\n context.autoInsertedRow = cursor.row;\n context.autoInsertedLineEnd = bracket + line.substr(cursor.column);\n context.autoInsertedBrackets++;\n};\nCstyleBehaviour[\"recordMaybeInsert\"] = function (editor, session, bracket) {\n var cursor = editor.getCursorPosition();\n var line = session.doc.getLine(cursor.row);\n if (!this[\"isMaybeInsertedClosing\"](cursor, line))\n context.maybeInsertedBrackets = 0;\n context.maybeInsertedRow = cursor.row;\n context.maybeInsertedLineStart = line.substr(0, cursor.column) + bracket;\n context.maybeInsertedLineEnd = line.substr(cursor.column);\n context.maybeInsertedBrackets++;\n};\nCstyleBehaviour[\"isAutoInsertedClosing\"] = function (cursor, line, bracket) {\n return context.autoInsertedBrackets > 0 &&\n cursor.row === context.autoInsertedRow &&\n bracket === context.autoInsertedLineEnd[0] &&\n line.substr(cursor.column) === context.autoInsertedLineEnd;\n};\nCstyleBehaviour[\"isMaybeInsertedClosing\"] = function (cursor, line) {\n return context.maybeInsertedBrackets > 0 &&\n cursor.row === context.maybeInsertedRow &&\n line.substr(cursor.column) === context.maybeInsertedLineEnd &&\n line.substr(0, cursor.column) == context.maybeInsertedLineStart;\n};\nCstyleBehaviour[\"popAutoInsertedClosing\"] = function () {\n context.autoInsertedLineEnd = context.autoInsertedLineEnd.substr(1);\n context.autoInsertedBrackets--;\n};\nCstyleBehaviour[\"clearMaybeInsertedClosing\"] = function () {\n if (context) {\n context.maybeInsertedBrackets = 0;\n context.maybeInsertedRow = -1;\n }\n};\noop.inherits(CstyleBehaviour, Behaviour);\nexports.CstyleBehaviour = CstyleBehaviour;\n\n});\n\nace.define(\"ace/unicode\",[\"require\",\"exports\",\"module\"], function(require, exports, module){\"use strict\";\nvar wordChars = [48, 9, 8, 25, 5, 0, 2, 25, 48, 0, 11, 0, 5, 0, 6, 22,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57, 6, 14, 2, 9, 40, 1, 2, 0, 3, 1, 2, 0, 3, 0, 7, 3, 2, 6, 2, 2, 2, 0, 2, 0, 3, 1, 2, 12, 2, 2, 3, 4, 2, 0, 2, 5, 3, 9, 3, 1, 35, 0, 24, 1, 7, 9, 12, 0, 2, 0, 2, 0, 5, 9, 2, 35, 5, 19, 2, 5, 5, 7, 2, 35, 10, 0, 58, 73, 7, 77, 3, 37, 11, 42, 2, 0, 4, 328, 2, 3, 3, 6, 2, 0, 2, 3, 3, 40, 2, 3, 3, 32, 2, 3, 3, 6, 2, 0, 2, 3, 3, 14, 2, 56, 2, 3, 3, 66, 5, 0, 33, 15, 17, 84, 13, 619, 3, 16, 2, 25, 6, 74, 22, 12, 2, 6, 12, 20, 12, 19, 13, 12, 2, 2, 2, 1, 13, 51, 3, 29, 4, 0, 5, 1, 3, 9, 34, 2, 3, 9, 7, 87, 9, 42, 6, 69, 11, 28, 4, 11, 5, 11, 11, 39, 3, 4, 12, 43, 5, 25, 7, 10, 38, 27, 5, 62, 2, 28, 3, 10, 7, 9, 14, 0, 89, 75, 5, 9, 18, 8, 13, 42, 4, 11, 71, 55, 9, 9, 4, 48, 83, 2, 2, 30, 14, 230, 23, 280, 3, 5, 3, 37, 3, 5, 3, 7, 2, 0, 2, 0, 2, 0, 2, 30, 3, 52, 2, 6, 2, 0, 4, 2, 2, 6, 4, 3, 3, 5, 5, 12, 6, 2, 2, 6, 67, 1, 20, 0, 29, 0, 14, 0, 17, 4, 60, 12, 5, 0, 4, 11, 18, 0, 5, 0, 3, 9, 2, 0, 4, 4, 7, 0, 2, 0, 2, 0, 2, 3, 2, 10, 3, 3, 6, 4, 5, 0, 53, 1, 2684, 46, 2, 46, 2, 132, 7, 6, 15, 37, 11, 53, 10, 0, 17, 22, 10, 6, 2, 6, 2, 6, 2, 6, 2, 6, 2, 6, 2, 6, 2, 6, 2, 31, 48, 0, 470, 1, 36, 5, 2, 4, 6, 1, 5, 85, 3, 1, 3, 2, 2, 89, 2, 3, 6, 40, 4, 93, 18, 23, 57, 15, 513, 6581, 75, 20939, 53, 1164, 68, 45, 3, 268, 4, 27, 21, 31, 3, 13, 13, 1, 2, 24, 9, 69, 11, 1, 38, 8, 3, 102, 3, 1, 111, 44, 25, 51, 13, 68, 12, 9, 7, 23, 4, 0, 5, 45, 3, 35, 13, 28, 4, 64, 15, 10, 39, 54, 10, 13, 3, 9, 7, 22, 4, 1, 5, 66, 25, 2, 227, 42, 2, 1, 3, 9, 7, 11171, 13, 22, 5, 48, 8453, 301, 3, 61, 3, 105, 39, 6, 13, 4, 6, 11, 2, 12, 2, 4, 2, 0, 2, 1, 2, 1, 2, 107, 34, 362, 19, 63, 3, 53, 41, 11, 5, 15, 17, 6, 13, 1, 25, 2, 33, 4, 2, 134, 20, 9, 8, 25, 5, 0, 2, 25, 12, 88, 4, 5, 3, 5, 3, 5, 3, 2];\nvar code = 0;\nvar str = [];\nfor (var i = 0; i < wordChars.length; i += 2) {\n str.push(code += wordChars[i]);\n if (wordChars[i + 1])\n str.push(45, code += wordChars[i + 1]);\n}\nexports.wordChars = String.fromCharCode.apply(null, str);\n\n});\n\nace.define(\"ace/mode/text\",[\"require\",\"exports\",\"module\",\"ace/config\",\"ace/tokenizer\",\"ace/mode/text_highlight_rules\",\"ace/mode/behaviour/cstyle\",\"ace/unicode\",\"ace/lib/lang\",\"ace/token_iterator\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar config = require(\"../config\");\nvar Tokenizer = require(\"../tokenizer\").Tokenizer;\nvar TextHighlightRules = require(\"./text_highlight_rules\").TextHighlightRules;\nvar CstyleBehaviour = require(\"./behaviour/cstyle\").CstyleBehaviour;\nvar unicode = require(\"../unicode\");\nvar lang = require(\"../lib/lang\");\nvar TokenIterator = require(\"../token_iterator\").TokenIterator;\nvar Range = require(\"../range\").Range;\nvar Mode;\nMode = function () {\n this.HighlightRules = TextHighlightRules;\n};\n(function () {\n this.$defaultBehaviour = new CstyleBehaviour();\n this.tokenRe = new RegExp(\"^[\" + unicode.wordChars + \"\\\\$_]+\", \"g\");\n this.nonTokenRe = new RegExp(\"^(?:[^\" + unicode.wordChars + \"\\\\$_]|\\\\s])+\", \"g\");\n this.getTokenizer = function () {\n if (!this.$tokenizer) {\n this.$highlightRules = this.$highlightRules || new this.HighlightRules(this.$highlightRuleConfig);\n this.$tokenizer = new Tokenizer(this.$highlightRules.getRules());\n }\n return this.$tokenizer;\n };\n this.lineCommentStart = \"\";\n this.blockComment = \"\";\n this.toggleCommentLines = function (state, session, startRow, endRow) {\n var doc = session.doc;\n var ignoreBlankLines = true;\n var shouldRemove = true;\n var minIndent = Infinity;\n var tabSize = session.getTabSize();\n var insertAtTabStop = false;\n if (!this.lineCommentStart) {\n if (!this.blockComment)\n return false;\n var lineCommentStart = this.blockComment.start;\n var lineCommentEnd = this.blockComment.end;\n var regexpStart = new RegExp(\"^(\\\\s*)(?:\" + lang.escapeRegExp(lineCommentStart) + \")\");\n var regexpEnd = new RegExp(\"(?:\" + lang.escapeRegExp(lineCommentEnd) + \")\\\\s*$\");\n var comment = function (line, i) {\n if (testRemove(line, i))\n return;\n if (!ignoreBlankLines || /\\S/.test(line)) {\n doc.insertInLine({ row: i, column: line.length }, lineCommentEnd);\n doc.insertInLine({ row: i, column: minIndent }, lineCommentStart);\n }\n };\n var uncomment = function (line, i) {\n var m;\n if (m = line.match(regexpEnd))\n doc.removeInLine(i, line.length - m[0].length, line.length);\n if (m = line.match(regexpStart))\n doc.removeInLine(i, m[1].length, m[0].length);\n };\n var testRemove = function (line, row) {\n if (regexpStart.test(line))\n return true;\n var tokens = session.getTokens(row);\n for (var i = 0; i < tokens.length; i++) {\n if (tokens[i].type === \"comment\")\n return true;\n }\n };\n }\n else {\n if (Array.isArray(this.lineCommentStart)) {\n var regexpStart = this.lineCommentStart.map(lang.escapeRegExp).join(\"|\");\n var lineCommentStart = this.lineCommentStart[0];\n }\n else {\n var regexpStart = lang.escapeRegExp(this.lineCommentStart);\n var lineCommentStart = this.lineCommentStart;\n }\n regexpStart = new RegExp(\"^(\\\\s*)(?:\" + regexpStart + \") ?\");\n insertAtTabStop = session.getUseSoftTabs();\n var uncomment = function (line, i) {\n var m = line.match(regexpStart);\n if (!m)\n return;\n var start = m[1].length, end = m[0].length;\n if (!shouldInsertSpace(line, start, end) && m[0][end - 1] == \" \")\n end--;\n doc.removeInLine(i, start, end);\n };\n var commentWithSpace = lineCommentStart + \" \";\n var comment = function (line, i) {\n if (!ignoreBlankLines || /\\S/.test(line)) {\n if (shouldInsertSpace(line, minIndent, minIndent))\n doc.insertInLine({ row: i, column: minIndent }, commentWithSpace);\n else\n doc.insertInLine({ row: i, column: minIndent }, lineCommentStart);\n }\n };\n var testRemove = function (line, i) {\n return regexpStart.test(line);\n };\n var shouldInsertSpace = function (line, before, after) {\n var spaces = 0;\n while (before-- && line.charAt(before) == \" \")\n spaces++;\n if (spaces % tabSize != 0)\n return false;\n var spaces = 0;\n while (line.charAt(after++) == \" \")\n spaces++;\n if (tabSize > 2)\n return spaces % tabSize != tabSize - 1;\n else\n return spaces % tabSize == 0;\n };\n }\n function iter(fun) {\n for (var i = startRow; i <= endRow; i++)\n fun(doc.getLine(i), i);\n }\n var minEmptyLength = Infinity;\n iter(function (line, i) {\n var indent = line.search(/\\S/);\n if (indent !== -1) {\n if (indent < minIndent)\n minIndent = indent;\n if (shouldRemove && !testRemove(line, i))\n shouldRemove = false;\n }\n else if (minEmptyLength > line.length) {\n minEmptyLength = line.length;\n }\n });\n if (minIndent == Infinity) {\n minIndent = minEmptyLength;\n ignoreBlankLines = false;\n shouldRemove = false;\n }\n if (insertAtTabStop && minIndent % tabSize != 0)\n minIndent = Math.floor(minIndent / tabSize) * tabSize;\n iter(shouldRemove ? uncomment : comment);\n };\n this.toggleBlockComment = function (state, session, range, cursor) {\n var comment = this.blockComment;\n if (!comment)\n return;\n if (!comment.start && comment[0])\n comment = comment[0];\n var iterator = new TokenIterator(session, cursor.row, cursor.column);\n var token = iterator.getCurrentToken();\n var sel = session.selection;\n var initialRange = session.selection.toOrientedRange();\n var startRow, colDiff;\n if (token && /comment/.test(token.type)) {\n var startRange, endRange;\n while (token && /comment/.test(token.type)) {\n var i = token.value.indexOf(comment.start);\n if (i != -1) {\n var row = iterator.getCurrentTokenRow();\n var column = iterator.getCurrentTokenColumn() + i;\n startRange = new Range(row, column, row, column + comment.start.length);\n break;\n }\n token = iterator.stepBackward();\n }\n var iterator = new TokenIterator(session, cursor.row, cursor.column);\n var token = iterator.getCurrentToken();\n while (token && /comment/.test(token.type)) {\n var i = token.value.indexOf(comment.end);\n if (i != -1) {\n var row = iterator.getCurrentTokenRow();\n var column = iterator.getCurrentTokenColumn() + i;\n endRange = new Range(row, column, row, column + comment.end.length);\n break;\n }\n token = iterator.stepForward();\n }\n if (endRange)\n session.remove(endRange);\n if (startRange) {\n session.remove(startRange);\n startRow = startRange.start.row;\n colDiff = -comment.start.length;\n }\n }\n else {\n colDiff = comment.start.length;\n startRow = range.start.row;\n session.insert(range.end, comment.end);\n session.insert(range.start, comment.start);\n }\n if (initialRange.start.row == startRow)\n initialRange.start.column += colDiff;\n if (initialRange.end.row == startRow)\n initialRange.end.column += colDiff;\n session.selection.fromOrientedRange(initialRange);\n };\n this.getNextLineIndent = function (state, line, tab) {\n return this.$getIndent(line);\n };\n this.checkOutdent = function (state, line, input) {\n return false;\n };\n this.autoOutdent = function (state, doc, row) {\n };\n this.$getIndent = function (line) {\n return line.match(/^\\s*/)[0];\n };\n this.createWorker = function (session) {\n return null;\n };\n this.createModeDelegates = function (mapping) {\n this.$embeds = [];\n this.$modes = {};\n for (var i in mapping) {\n if (mapping[i]) {\n var Mode = mapping[i];\n var id = Mode.prototype.$id;\n var mode = config.$modes[id];\n if (!mode)\n config.$modes[id] = mode = new Mode();\n if (!config.$modes[i])\n config.$modes[i] = mode;\n this.$embeds.push(i);\n this.$modes[i] = mode;\n }\n }\n var delegations = [\"toggleBlockComment\", \"toggleCommentLines\", \"getNextLineIndent\",\n \"checkOutdent\", \"autoOutdent\", \"transformAction\", \"getCompletions\"];\n var _loop_1 = function (i) {\n (function (scope) {\n var functionName = delegations[i];\n var defaultHandler = scope[functionName];\n scope[delegations[i]] =\n function () {\n return this.$delegator(functionName, arguments, defaultHandler);\n };\n }(this_1));\n };\n var this_1 = this;\n for (var i = 0; i < delegations.length; i++) {\n _loop_1(i);\n }\n };\n this.$delegator = function (method, args, defaultHandler) {\n var state = args[0] || \"start\";\n if (typeof state != \"string\") {\n if (Array.isArray(state[2])) {\n var language = state[2][state[2].length - 1];\n var mode = this.$modes[language];\n if (mode)\n return mode[method].apply(mode, [state[1]].concat([].slice.call(args, 1)));\n }\n state = state[0] || \"start\";\n }\n for (var i = 0; i < this.$embeds.length; i++) {\n if (!this.$modes[this.$embeds[i]])\n continue;\n var split = state.split(this.$embeds[i]);\n if (!split[0] && split[1]) {\n args[0] = split[1];\n var mode = this.$modes[this.$embeds[i]];\n return mode[method].apply(mode, args);\n }\n }\n var ret = defaultHandler.apply(this, args);\n return defaultHandler ? ret : undefined;\n };\n this.transformAction = function (state, action, editor, session, param) {\n if (this.$behaviour) {\n var behaviours = this.$behaviour.getBehaviours();\n for (var key in behaviours) {\n if (behaviours[key][action]) {\n var ret = behaviours[key][action].apply(this, arguments);\n if (ret) {\n return ret;\n }\n }\n }\n }\n };\n this.getKeywords = function (append) {\n if (!this.completionKeywords) {\n var rules = this.$tokenizer[\"rules\"];\n var completionKeywords = [];\n for (var rule in rules) {\n var ruleItr = rules[rule];\n for (var r = 0, l = ruleItr.length; r < l; r++) {\n if (typeof ruleItr[r].token === \"string\") {\n if (/keyword|support|storage/.test(ruleItr[r].token))\n completionKeywords.push(ruleItr[r].regex);\n }\n else if (typeof ruleItr[r].token === \"object\") {\n for (var a = 0, aLength = ruleItr[r].token.length; a < aLength; a++) {\n if (/keyword|support|storage/.test(ruleItr[r].token[a])) {\n var rule = ruleItr[r].regex.match(/\\(.+?\\)/g)[a];\n completionKeywords.push(rule.substr(1, rule.length - 2));\n }\n }\n }\n }\n }\n this.completionKeywords = completionKeywords;\n }\n if (!append)\n return this.$keywordList;\n return completionKeywords.concat(this.$keywordList || []);\n };\n this.$createKeywordList = function () {\n if (!this.$highlightRules)\n this.getTokenizer();\n return this.$keywordList = this.$highlightRules.$keywordList || [];\n };\n this.getCompletions = function (state, session, pos, prefix) {\n var keywords = this.$keywordList || this.$createKeywordList();\n return keywords.map(function (word) {\n return {\n name: word,\n value: word,\n score: 0,\n meta: \"keyword\"\n };\n });\n };\n this.$id = \"ace/mode/text\";\n}).call(Mode.prototype);\nexports.Mode = Mode;\n\n});\n\nace.define(\"ace/line_widgets\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\"], function(require, exports, module){\"use strict\";\nvar dom = require(\"./lib/dom\");\nvar LineWidgets = /** @class */ (function () {\n function LineWidgets(session) {\n this.session = session;\n this.session.widgetManager = this;\n this.session.getRowLength = this.getRowLength;\n this.session.$getWidgetScreenLength = this.$getWidgetScreenLength;\n this.updateOnChange = this.updateOnChange.bind(this);\n this.renderWidgets = this.renderWidgets.bind(this);\n this.measureWidgets = this.measureWidgets.bind(this);\n this.session._changedWidgets = [];\n this.$onChangeEditor = this.$onChangeEditor.bind(this);\n this.session.on(\"change\", this.updateOnChange);\n this.session.on(\"changeFold\", this.updateOnFold);\n this.session.on(\"changeEditor\", this.$onChangeEditor);\n }\n LineWidgets.prototype.getRowLength = function (row) {\n var h;\n if (this.lineWidgets)\n h = this.lineWidgets[row] && this.lineWidgets[row].rowCount || 0;\n else\n h = 0;\n if (!this[\"$useWrapMode\"] || !this[\"$wrapData\"][row]) {\n return 1 + h;\n }\n else {\n return this[\"$wrapData\"][row].length + 1 + h;\n }\n };\n LineWidgets.prototype.$getWidgetScreenLength = function () {\n var screenRows = 0;\n this.lineWidgets.forEach(function (w) {\n if (w && w.rowCount && !w.hidden)\n screenRows += w.rowCount;\n });\n return screenRows;\n };\n LineWidgets.prototype.$onChangeEditor = function (e) {\n this.attach(e.editor);\n };\n LineWidgets.prototype.attach = function (editor) {\n if (editor && editor.widgetManager && editor.widgetManager != this)\n editor.widgetManager.detach();\n if (this.editor == editor)\n return;\n this.detach();\n this.editor = editor;\n if (editor) {\n editor.widgetManager = this;\n editor.renderer.on(\"beforeRender\", this.measureWidgets);\n editor.renderer.on(\"afterRender\", this.renderWidgets);\n }\n };\n LineWidgets.prototype.detach = function (e) {\n var editor = this.editor;\n if (!editor)\n return;\n this.editor = null;\n editor.widgetManager = null;\n editor.renderer.off(\"beforeRender\", this.measureWidgets);\n editor.renderer.off(\"afterRender\", this.renderWidgets);\n var lineWidgets = this.session.lineWidgets;\n lineWidgets && lineWidgets.forEach(function (w) {\n if (w && w.el && w.el.parentNode) {\n w._inDocument = false;\n w.el.parentNode.removeChild(w.el);\n }\n });\n };\n LineWidgets.prototype.updateOnFold = function (e, session) {\n var lineWidgets = session.lineWidgets;\n if (!lineWidgets || !e.action)\n return;\n var fold = e.data;\n var start = fold.start.row;\n var end = fold.end.row;\n var hide = e.action == \"add\";\n for (var i = start + 1; i < end; i++) {\n if (lineWidgets[i])\n lineWidgets[i].hidden = hide;\n }\n if (lineWidgets[end]) {\n if (hide) {\n if (!lineWidgets[start])\n lineWidgets[start] = lineWidgets[end];\n else\n lineWidgets[end].hidden = hide;\n }\n else {\n if (lineWidgets[start] == lineWidgets[end])\n lineWidgets[start] = undefined;\n lineWidgets[end].hidden = hide;\n }\n }\n };\n LineWidgets.prototype.updateOnChange = function (delta) {\n var lineWidgets = this.session.lineWidgets;\n if (!lineWidgets)\n return;\n var startRow = delta.start.row;\n var len = delta.end.row - startRow;\n if (len === 0) {\n }\n else if (delta.action == \"remove\") {\n var removed = lineWidgets.splice(startRow + 1, len);\n if (!lineWidgets[startRow] && removed[removed.length - 1]) {\n lineWidgets[startRow] = removed.pop();\n }\n removed.forEach(function (w) {\n w && this.removeLineWidget(w);\n }, this);\n this.$updateRows();\n }\n else {\n var args = new Array(len);\n if (lineWidgets[startRow] && lineWidgets[startRow].column != null) {\n if (delta.start.column > lineWidgets[startRow].column)\n startRow++;\n }\n args.unshift(startRow, 0);\n lineWidgets.splice.apply(lineWidgets, args);\n this.$updateRows();\n }\n };\n LineWidgets.prototype.$updateRows = function () {\n var lineWidgets = this.session.lineWidgets;\n if (!lineWidgets)\n return;\n var noWidgets = true;\n lineWidgets.forEach(function (w, i) {\n if (w) {\n noWidgets = false;\n w.row = i;\n while (w.$oldWidget) {\n w.$oldWidget.row = i;\n w = w.$oldWidget;\n }\n }\n });\n if (noWidgets)\n this.session.lineWidgets = null;\n };\n LineWidgets.prototype.$registerLineWidget = function (w) {\n if (!this.session.lineWidgets)\n this.session.lineWidgets = new Array(this.session.getLength());\n var old = this.session.lineWidgets[w.row];\n if (old) {\n w.$oldWidget = old;\n if (old.el && old.el.parentNode) {\n old.el.parentNode.removeChild(old.el);\n old._inDocument = false;\n }\n }\n this.session.lineWidgets[w.row] = w;\n return w;\n };\n LineWidgets.prototype.addLineWidget = function (w) {\n this.$registerLineWidget(w);\n w.session = this.session;\n if (!this.editor)\n return w;\n var renderer = this.editor.renderer;\n if (w.html && !w.el) {\n w.el = dom.createElement(\"div\");\n w.el.innerHTML = w.html;\n }\n if (w.text && !w.el) {\n w.el = dom.createElement(\"div\");\n w.el.textContent = w.text;\n }\n if (w.el) {\n dom.addCssClass(w.el, \"ace_lineWidgetContainer\");\n if (w.className) {\n dom.addCssClass(w.el, w.className);\n }\n w.el.style.position = \"absolute\";\n w.el.style.zIndex = \"5\";\n renderer.container.appendChild(w.el);\n w._inDocument = true;\n if (!w.coverGutter) {\n w.el.style.zIndex = \"3\";\n }\n if (w.pixelHeight == null) {\n w.pixelHeight = w.el.offsetHeight;\n }\n }\n if (w.rowCount == null) {\n w.rowCount = w.pixelHeight / renderer.layerConfig.lineHeight;\n }\n var fold = this.session.getFoldAt(w.row, 0);\n w.$fold = fold;\n if (fold) {\n var lineWidgets = this.session.lineWidgets;\n if (w.row == fold.end.row && !lineWidgets[fold.start.row])\n lineWidgets[fold.start.row] = w;\n else\n w.hidden = true;\n }\n this.session._emit(\"changeFold\", { data: { start: { row: w.row } } });\n this.$updateRows();\n this.renderWidgets(null, renderer);\n this.onWidgetChanged(w);\n return w;\n };\n LineWidgets.prototype.removeLineWidget = function (w) {\n w._inDocument = false;\n w.session = null;\n if (w.el && w.el.parentNode)\n w.el.parentNode.removeChild(w.el);\n if (w.editor && w.editor.destroy)\n try {\n w.editor.destroy();\n }\n catch (e) { }\n if (this.session.lineWidgets) {\n var w1 = this.session.lineWidgets[w.row];\n if (w1 == w) {\n this.session.lineWidgets[w.row] = w.$oldWidget;\n if (w.$oldWidget)\n this.onWidgetChanged(w.$oldWidget);\n }\n else {\n while (w1) {\n if (w1.$oldWidget == w) {\n w1.$oldWidget = w.$oldWidget;\n break;\n }\n w1 = w1.$oldWidget;\n }\n }\n }\n this.session._emit(\"changeFold\", { data: { start: { row: w.row } } });\n this.$updateRows();\n };\n LineWidgets.prototype.getWidgetsAtRow = function (row) {\n var lineWidgets = this.session.lineWidgets;\n var w = lineWidgets && lineWidgets[row];\n var list = [];\n while (w) {\n list.push(w);\n w = w.$oldWidget;\n }\n return list;\n };\n LineWidgets.prototype.onWidgetChanged = function (w) {\n this.session._changedWidgets.push(w);\n this.editor && this.editor.renderer.updateFull();\n };\n LineWidgets.prototype.measureWidgets = function (e, renderer) {\n var changedWidgets = this.session._changedWidgets;\n var config = renderer.layerConfig;\n if (!changedWidgets || !changedWidgets.length)\n return;\n var min = Infinity;\n for (var i = 0; i < changedWidgets.length; i++) {\n var w = changedWidgets[i];\n if (!w || !w.el)\n continue;\n if (w.session != this.session)\n continue;\n if (!w._inDocument) {\n if (this.session.lineWidgets[w.row] != w)\n continue;\n w._inDocument = true;\n renderer.container.appendChild(w.el);\n }\n w.h = w.el.offsetHeight;\n if (!w.fixedWidth) {\n w.w = w.el.offsetWidth;\n w.screenWidth = Math.ceil(w.w / config.characterWidth);\n }\n var rowCount = w.h / config.lineHeight;\n if (w.coverLine) {\n rowCount -= this.session.getRowLineCount(w.row);\n if (rowCount < 0)\n rowCount = 0;\n }\n if (w.rowCount != rowCount) {\n w.rowCount = rowCount;\n if (w.row < min)\n min = w.row;\n }\n }\n if (min != Infinity) {\n this.session._emit(\"changeFold\", { data: { start: { row: min } } });\n this.session.lineWidgetWidth = null;\n }\n this.session._changedWidgets = [];\n };\n LineWidgets.prototype.renderWidgets = function (e, renderer) {\n var config = renderer.layerConfig;\n var lineWidgets = this.session.lineWidgets;\n if (!lineWidgets)\n return;\n var first = Math.min(this.firstRow, config.firstRow);\n var last = Math.max(this.lastRow, config.lastRow, lineWidgets.length);\n while (first > 0 && !lineWidgets[first])\n first--;\n this.firstRow = config.firstRow;\n this.lastRow = config.lastRow;\n renderer.$cursorLayer.config = config;\n for (var i = first; i <= last; i++) {\n var w = lineWidgets[i];\n if (!w || !w.el)\n continue;\n if (w.hidden) {\n w.el.style.top = -100 - (w.pixelHeight || 0) + \"px\";\n continue;\n }\n if (!w._inDocument) {\n w._inDocument = true;\n renderer.container.appendChild(w.el);\n }\n var top = renderer.$cursorLayer.getPixelPosition({ row: i, column: 0 }, true).top;\n if (!w.coverLine)\n top += config.lineHeight * this.session.getRowLineCount(w.row);\n w.el.style.top = top - config.offset + \"px\";\n var left = w.coverGutter ? 0 : renderer.gutterWidth;\n if (!w.fixedWidth)\n left -= renderer.scrollLeft;\n w.el.style.left = left + \"px\";\n if (w.fullWidth && w.screenWidth) {\n w.el.style.minWidth = config.width + 2 * config.padding + \"px\";\n }\n if (w.fixedWidth) {\n w.el.style.right = renderer.scrollBar.getWidth() + \"px\";\n }\n else {\n w.el.style.right = \"\";\n }\n }\n };\n return LineWidgets;\n}());\nexports.LineWidgets = LineWidgets;\n\n});\n\nace.define(\"ace/apply_delta\",[\"require\",\"exports\",\"module\"], function(require, exports, module){\"use strict\";\nfunction throwDeltaError(delta, errorText) {\n console.log(\"Invalid Delta:\", delta);\n throw \"Invalid Delta: \" + errorText;\n}\nfunction positionInDocument(docLines, position) {\n return position.row >= 0 && position.row < docLines.length &&\n position.column >= 0 && position.column <= docLines[position.row].length;\n}\nfunction validateDelta(docLines, delta) {\n if (delta.action != \"insert\" && delta.action != \"remove\")\n throwDeltaError(delta, \"delta.action must be 'insert' or 'remove'\");\n if (!(delta.lines instanceof Array))\n throwDeltaError(delta, \"delta.lines must be an Array\");\n if (!delta.start || !delta.end)\n throwDeltaError(delta, \"delta.start/end must be an present\");\n var start = delta.start;\n if (!positionInDocument(docLines, delta.start))\n throwDeltaError(delta, \"delta.start must be contained in document\");\n var end = delta.end;\n if (delta.action == \"remove\" && !positionInDocument(docLines, end))\n throwDeltaError(delta, \"delta.end must contained in document for 'remove' actions\");\n var numRangeRows = end.row - start.row;\n var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));\n if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)\n throwDeltaError(delta, \"delta.range must match delta lines\");\n}\nexports.applyDelta = function (docLines, delta, doNotValidate) {\n var row = delta.start.row;\n var startColumn = delta.start.column;\n var line = docLines[row] || \"\";\n switch (delta.action) {\n case \"insert\":\n var lines = delta.lines;\n if (lines.length === 1) {\n docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);\n }\n else {\n var args = [row, 1].concat(delta.lines);\n docLines.splice.apply(docLines, args);\n docLines[row] = line.substring(0, startColumn) + docLines[row];\n docLines[row + delta.lines.length - 1] += line.substring(startColumn);\n }\n break;\n case \"remove\":\n var endColumn = delta.end.column;\n var endRow = delta.end.row;\n if (row === endRow) {\n docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);\n }\n else {\n docLines.splice(row, endRow - row + 1, line.substring(0, startColumn) + docLines[endRow].substring(endColumn));\n }\n break;\n }\n};\n\n});\n\nace.define(\"ace/anchor\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/event_emitter\"], function(require, exports, module){\"use strict\";\nvar oop = require(\"./lib/oop\");\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar Anchor = /** @class */ (function () {\n function Anchor(doc, row, column) {\n this.$onChange = this.onChange.bind(this);\n this.attach(doc);\n if (typeof row != \"number\")\n this.setPosition(row.row, row.column);\n else\n this.setPosition(row, column);\n }\n Anchor.prototype.getPosition = function () {\n return this.$clipPositionToDocument(this.row, this.column);\n };\n Anchor.prototype.getDocument = function () {\n return this.document;\n };\n Anchor.prototype.onChange = function (delta) {\n if (delta.start.row == delta.end.row && delta.start.row != this.row)\n return;\n if (delta.start.row > this.row)\n return;\n var point = $getTransformedPoint(delta, { row: this.row, column: this.column }, this.$insertRight);\n this.setPosition(point.row, point.column, true);\n };\n Anchor.prototype.setPosition = function (row, column, noClip) {\n var pos;\n if (noClip) {\n pos = {\n row: row,\n column: column\n };\n }\n else {\n pos = this.$clipPositionToDocument(row, column);\n }\n if (this.row == pos.row && this.column == pos.column)\n return;\n var old = {\n row: this.row,\n column: this.column\n };\n this.row = pos.row;\n this.column = pos.column;\n this._signal(\"change\", {\n old: old,\n value: pos\n });\n };\n Anchor.prototype.detach = function () {\n this.document.off(\"change\", this.$onChange);\n };\n Anchor.prototype.attach = function (doc) {\n this.document = doc || this.document;\n this.document.on(\"change\", this.$onChange);\n };\n Anchor.prototype.$clipPositionToDocument = function (row, column) {\n var pos = {};\n if (row >= this.document.getLength()) {\n pos.row = Math.max(0, this.document.getLength() - 1);\n pos.column = this.document.getLine(pos.row).length;\n }\n else if (row < 0) {\n pos.row = 0;\n pos.column = 0;\n }\n else {\n pos.row = row;\n pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));\n }\n if (column < 0)\n pos.column = 0;\n return pos;\n };\n return Anchor;\n}());\nAnchor.prototype.$insertRight = false;\noop.implement(Anchor.prototype, EventEmitter);\nfunction $pointsInOrder(point1, point2, equalPointsInOrder) {\n var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;\n return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);\n}\nfunction $getTransformedPoint(delta, point, moveIfEqual) {\n var deltaIsInsert = delta.action == \"insert\";\n var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);\n var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);\n var deltaStart = delta.start;\n var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.\n if ($pointsInOrder(point, deltaStart, moveIfEqual)) {\n return {\n row: point.row,\n column: point.column\n };\n }\n if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {\n return {\n row: point.row + deltaRowShift,\n column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)\n };\n }\n return {\n row: deltaStart.row,\n column: deltaStart.column\n };\n}\nexports.Anchor = Anchor;\n\n});\n\nace.define(\"ace/document\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/apply_delta\",\"ace/lib/event_emitter\",\"ace/range\",\"ace/anchor\"], function(require, exports, module){\"use strict\";\nvar oop = require(\"./lib/oop\");\nvar applyDelta = require(\"./apply_delta\").applyDelta;\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar Range = require(\"./range\").Range;\nvar Anchor = require(\"./anchor\").Anchor;\nvar Document = /** @class */ (function () {\n function Document(textOrLines) {\n this.$lines = [\"\"];\n if (textOrLines.length === 0) {\n this.$lines = [\"\"];\n }\n else if (Array.isArray(textOrLines)) {\n this.insertMergedLines({ row: 0, column: 0 }, textOrLines);\n }\n else {\n this.insert({ row: 0, column: 0 }, textOrLines);\n }\n }\n Document.prototype.setValue = function (text) {\n var len = this.getLength() - 1;\n this.remove(new Range(0, 0, len, this.getLine(len).length));\n this.insert({ row: 0, column: 0 }, text || \"\");\n };\n Document.prototype.getValue = function () {\n return this.getAllLines().join(this.getNewLineCharacter());\n };\n Document.prototype.createAnchor = function (row, column) {\n return new Anchor(this, row, column);\n };\n Document.prototype.$detectNewLine = function (text) {\n var match = text.match(/^.*?(\\r\\n|\\r|\\n)/m);\n this.$autoNewLine = match ? match[1] : \"\\n\";\n this._signal(\"changeNewLineMode\");\n };\n Document.prototype.getNewLineCharacter = function () {\n switch (this.$newLineMode) {\n case \"windows\":\n return \"\\r\\n\";\n case \"unix\":\n return \"\\n\";\n default:\n return this.$autoNewLine || \"\\n\";\n }\n };\n Document.prototype.setNewLineMode = function (newLineMode) {\n if (this.$newLineMode === newLineMode)\n return;\n this.$newLineMode = newLineMode;\n this._signal(\"changeNewLineMode\");\n };\n Document.prototype.getNewLineMode = function () {\n return this.$newLineMode;\n };\n Document.prototype.isNewLine = function (text) {\n return (text == \"\\r\\n\" || text == \"\\r\" || text == \"\\n\");\n };\n Document.prototype.getLine = function (row) {\n return this.$lines[row] || \"\";\n };\n Document.prototype.getLines = function (firstRow, lastRow) {\n return this.$lines.slice(firstRow, lastRow + 1);\n };\n Document.prototype.getAllLines = function () {\n return this.getLines(0, this.getLength());\n };\n Document.prototype.getLength = function () {\n return this.$lines.length;\n };\n Document.prototype.getTextRange = function (range) {\n return this.getLinesForRange(range).join(this.getNewLineCharacter());\n };\n Document.prototype.getLinesForRange = function (range) {\n var lines;\n if (range.start.row === range.end.row) {\n lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];\n }\n else {\n lines = this.getLines(range.start.row, range.end.row);\n lines[0] = (lines[0] || \"\").substring(range.start.column);\n var l = lines.length - 1;\n if (range.end.row - range.start.row == l)\n lines[l] = lines[l].substring(0, range.end.column);\n }\n return lines;\n };\n Document.prototype.insertLines = function (row, lines) {\n console.warn(\"Use of document.insertLines is deprecated. Use the insertFullLines method instead.\");\n return this.insertFullLines(row, lines);\n };\n Document.prototype.removeLines = function (firstRow, lastRow) {\n console.warn(\"Use of document.removeLines is deprecated. Use the removeFullLines method instead.\");\n return this.removeFullLines(firstRow, lastRow);\n };\n Document.prototype.insertNewLine = function (position) {\n console.warn(\"Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.\");\n return this.insertMergedLines(position, [\"\", \"\"]);\n };\n Document.prototype.insert = function (position, text) {\n if (this.getLength() <= 1)\n this.$detectNewLine(text);\n return this.insertMergedLines(position, this.$split(text));\n };\n Document.prototype.insertInLine = function (position, text) {\n var start = this.clippedPos(position.row, position.column);\n var end = this.pos(position.row, position.column + text.length);\n this.applyDelta({\n start: start,\n end: end,\n action: \"insert\",\n lines: [text]\n }, true);\n return this.clonePos(end);\n };\n Document.prototype.clippedPos = function (row, column) {\n var length = this.getLength();\n if (row === undefined) {\n row = length;\n }\n else if (row < 0) {\n row = 0;\n }\n else if (row >= length) {\n row = length - 1;\n column = undefined;\n }\n var line = this.getLine(row);\n if (column == undefined)\n column = line.length;\n column = Math.min(Math.max(column, 0), line.length);\n return { row: row, column: column };\n };\n Document.prototype.clonePos = function (pos) {\n return { row: pos.row, column: pos.column };\n };\n Document.prototype.pos = function (row, column) {\n return { row: row, column: column };\n };\n Document.prototype.$clipPosition = function (position) {\n var length = this.getLength();\n if (position.row >= length) {\n position.row = Math.max(0, length - 1);\n position.column = this.getLine(length - 1).length;\n }\n else {\n position.row = Math.max(0, position.row);\n position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);\n }\n return position;\n };\n Document.prototype.insertFullLines = function (row, lines) {\n row = Math.min(Math.max(row, 0), this.getLength());\n var column = 0;\n if (row < this.getLength()) {\n lines = lines.concat([\"\"]);\n column = 0;\n }\n else {\n lines = [\"\"].concat(lines);\n row--;\n column = this.$lines[row].length;\n }\n this.insertMergedLines({ row: row, column: column }, lines);\n };\n Document.prototype.insertMergedLines = function (position, lines) {\n var start = this.clippedPos(position.row, position.column);\n var end = {\n row: start.row + lines.length - 1,\n column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length\n };\n this.applyDelta({\n start: start,\n end: end,\n action: \"insert\",\n lines: lines\n });\n return this.clonePos(end);\n };\n Document.prototype.remove = function (range) {\n var start = this.clippedPos(range.start.row, range.start.column);\n var end = this.clippedPos(range.end.row, range.end.column);\n this.applyDelta({\n start: start,\n end: end,\n action: \"remove\",\n lines: this.getLinesForRange({ start: start, end: end })\n });\n return this.clonePos(start);\n };\n Document.prototype.removeInLine = function (row, startColumn, endColumn) {\n var start = this.clippedPos(row, startColumn);\n var end = this.clippedPos(row, endColumn);\n this.applyDelta({\n start: start,\n end: end,\n action: \"remove\",\n lines: this.getLinesForRange({ start: start, end: end })\n }, true);\n return this.clonePos(start);\n };\n Document.prototype.removeFullLines = function (firstRow, lastRow) {\n firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);\n lastRow = Math.min(Math.max(0, lastRow), this.getLength() - 1);\n var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;\n var deleteLastNewLine = lastRow < this.getLength() - 1;\n var startRow = (deleteFirstNewLine ? firstRow - 1 : firstRow);\n var startCol = (deleteFirstNewLine ? this.getLine(startRow).length : 0);\n var endRow = (deleteLastNewLine ? lastRow + 1 : lastRow);\n var endCol = (deleteLastNewLine ? 0 : this.getLine(endRow).length);\n var range = new Range(startRow, startCol, endRow, endCol);\n var deletedLines = this.$lines.slice(firstRow, lastRow + 1);\n this.applyDelta({\n start: range.start,\n end: range.end,\n action: \"remove\",\n lines: this.getLinesForRange(range)\n });\n return deletedLines;\n };\n Document.prototype.removeNewLine = function (row) {\n if (row < this.getLength() - 1 && row >= 0) {\n this.applyDelta({\n start: this.pos(row, this.getLine(row).length),\n end: this.pos(row + 1, 0),\n action: \"remove\",\n lines: [\"\", \"\"]\n });\n }\n };\n Document.prototype.replace = function (range, text) {\n if (!(range instanceof Range))\n range = Range.fromPoints(range.start, range.end);\n if (text.length === 0 && range.isEmpty())\n return range.start;\n if (text == this.getTextRange(range))\n return range.end;\n this.remove(range);\n var end;\n if (text) {\n end = this.insert(range.start, text);\n }\n else {\n end = range.start;\n }\n return end;\n };\n Document.prototype.applyDeltas = function (deltas) {\n for (var i = 0; i < deltas.length; i++) {\n this.applyDelta(deltas[i]);\n }\n };\n Document.prototype.revertDeltas = function (deltas) {\n for (var i = deltas.length - 1; i >= 0; i--) {\n this.revertDelta(deltas[i]);\n }\n };\n Document.prototype.applyDelta = function (delta, doNotValidate) {\n var isInsert = delta.action == \"insert\";\n if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]\n : !Range.comparePoints(delta.start, delta.end)) {\n return;\n }\n if (isInsert && delta.lines.length > 20000) {\n this.$splitAndapplyLargeDelta(delta, 20000);\n }\n else {\n applyDelta(this.$lines, delta, doNotValidate);\n this._signal(\"change\", delta);\n }\n };\n Document.prototype.$safeApplyDelta = function (delta) {\n var docLength = this.$lines.length;\n if (delta.action == \"remove\" && delta.start.row < docLength && delta.end.row < docLength\n || delta.action == \"insert\" && delta.start.row <= docLength) {\n this.applyDelta(delta);\n }\n };\n Document.prototype.$splitAndapplyLargeDelta = function (delta, MAX) {\n var lines = delta.lines;\n var l = lines.length - MAX + 1;\n var row = delta.start.row;\n var column = delta.start.column;\n for (var from = 0, to = 0; from < l; from = to) {\n to += MAX - 1;\n var chunk = lines.slice(from, to);\n chunk.push(\"\");\n this.applyDelta({\n start: this.pos(row + from, column),\n end: this.pos(row + to, column = 0),\n action: delta.action,\n lines: chunk\n }, true);\n }\n delta.lines = lines.slice(from);\n delta.start.row = row + from;\n delta.start.column = column;\n this.applyDelta(delta, true);\n };\n Document.prototype.revertDelta = function (delta) {\n this.$safeApplyDelta({\n start: this.clonePos(delta.start),\n end: this.clonePos(delta.end),\n action: (delta.action == \"insert\" ? \"remove\" : \"insert\"),\n lines: delta.lines.slice()\n });\n };\n Document.prototype.indexToPosition = function (index, startRow) {\n var lines = this.$lines || this.getAllLines();\n var newlineLength = this.getNewLineCharacter().length;\n for (var i = startRow || 0, l = lines.length; i < l; i++) {\n index -= lines[i].length + newlineLength;\n if (index < 0)\n return { row: i, column: index + lines[i].length + newlineLength };\n }\n return { row: l - 1, column: index + lines[l - 1].length + newlineLength };\n };\n Document.prototype.positionToIndex = function (pos, startRow) {\n var lines = this.$lines || this.getAllLines();\n var newlineLength = this.getNewLineCharacter().length;\n var index = 0;\n var row = Math.min(pos.row, lines.length);\n for (var i = startRow || 0; i < row; ++i)\n index += lines[i].length + newlineLength;\n return index + pos.column;\n };\n Document.prototype.$split = function (text) {\n return text.split(/\\r\\n|\\r|\\n/);\n };\n return Document;\n}());\nDocument.prototype.$autoNewLine = \"\";\nDocument.prototype.$newLineMode = \"auto\";\noop.implement(Document.prototype, EventEmitter);\nexports.Document = Document;\n\n});\n\nace.define(\"ace/background_tokenizer\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/event_emitter\"], function(require, exports, module){\"use strict\";\nvar oop = require(\"./lib/oop\");\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar BackgroundTokenizer = /** @class */ (function () {\n function BackgroundTokenizer(tokenizer, session) {\n this.running = false;\n this.lines = [];\n this.states = [];\n this.currentLine = 0;\n this.tokenizer = tokenizer;\n var self = this;\n this.$worker = function () {\n if (!self.running) {\n return;\n }\n var workerStart = new Date();\n var currentLine = self.currentLine;\n var endLine = -1;\n var doc = self.doc;\n var startLine = currentLine;\n while (self.lines[currentLine])\n currentLine++;\n var len = doc.getLength();\n var processedLines = 0;\n self.running = false;\n while (currentLine < len) {\n self.$tokenizeRow(currentLine);\n endLine = currentLine;\n do {\n currentLine++;\n } while (self.lines[currentLine]);\n processedLines++;\n if ((processedLines % 5 === 0) && (new Date() - workerStart) > 20) {\n self.running = setTimeout(self.$worker, 20);\n break;\n }\n }\n self.currentLine = currentLine;\n if (endLine == -1)\n endLine = currentLine;\n if (startLine <= endLine)\n self.fireUpdateEvent(startLine, endLine);\n };\n }\n BackgroundTokenizer.prototype.setTokenizer = function (tokenizer) {\n this.tokenizer = tokenizer;\n this.lines = [];\n this.states = [];\n this.start(0);\n };\n BackgroundTokenizer.prototype.setDocument = function (doc) {\n this.doc = doc;\n this.lines = [];\n this.states = [];\n this.stop();\n };\n BackgroundTokenizer.prototype.fireUpdateEvent = function (firstRow, lastRow) {\n var data = {\n first: firstRow,\n last: lastRow\n };\n this._signal(\"update\", { data: data });\n };\n BackgroundTokenizer.prototype.start = function (startRow) {\n this.currentLine = Math.min(startRow || 0, this.currentLine, this.doc.getLength());\n this.lines.splice(this.currentLine, this.lines.length);\n this.states.splice(this.currentLine, this.states.length);\n this.stop();\n this.running = setTimeout(this.$worker, 700);\n };\n BackgroundTokenizer.prototype.scheduleStart = function () {\n if (!this.running)\n this.running = setTimeout(this.$worker, 700);\n };\n BackgroundTokenizer.prototype.$updateOnChange = function (delta) {\n var startRow = delta.start.row;\n var len = delta.end.row - startRow;\n if (len === 0) {\n this.lines[startRow] = null;\n }\n else if (delta.action == \"remove\") {\n this.lines.splice(startRow, len + 1, null);\n this.states.splice(startRow, len + 1, null);\n }\n else {\n var args = Array(len + 1);\n args.unshift(startRow, 1);\n this.lines.splice.apply(this.lines, args);\n this.states.splice.apply(this.states, args);\n }\n this.currentLine = Math.min(startRow, this.currentLine, this.doc.getLength());\n this.stop();\n };\n BackgroundTokenizer.prototype.stop = function () {\n if (this.running)\n clearTimeout(this.running);\n this.running = false;\n };\n BackgroundTokenizer.prototype.getTokens = function (row) {\n return this.lines[row] || this.$tokenizeRow(row);\n };\n BackgroundTokenizer.prototype.getState = function (row) {\n if (this.currentLine == row)\n this.$tokenizeRow(row);\n return this.states[row] || \"start\";\n };\n BackgroundTokenizer.prototype.$tokenizeRow = function (row) {\n var line = this.doc.getLine(row);\n var state = this.states[row - 1];\n var data = this.tokenizer.getLineTokens(line, state, row);\n if (this.states[row] + \"\" !== data.state + \"\") {\n this.states[row] = data.state;\n this.lines[row + 1] = null;\n if (this.currentLine > row + 1)\n this.currentLine = row + 1;\n }\n else if (this.currentLine == row) {\n this.currentLine = row + 1;\n }\n return this.lines[row] = data.tokens;\n };\n BackgroundTokenizer.prototype.cleanup = function () {\n this.running = false;\n this.lines = [];\n this.states = [];\n this.currentLine = 0;\n this.removeAllListeners();\n };\n return BackgroundTokenizer;\n}());\noop.implement(BackgroundTokenizer.prototype, EventEmitter);\nexports.BackgroundTokenizer = BackgroundTokenizer;\n\n});\n\nace.define(\"ace/search_highlight\",[\"require\",\"exports\",\"module\",\"ace/lib/lang\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar lang = require(\"./lib/lang\");\nvar Range = require(\"./range\").Range;\nvar SearchHighlight = /** @class */ (function () {\n function SearchHighlight(regExp, clazz, type) {\n if (type === void 0) { type = \"text\"; }\n this.setRegexp(regExp);\n this.clazz = clazz;\n this.type = type;\n }\n SearchHighlight.prototype.setRegexp = function (regExp) {\n if (this.regExp + \"\" == regExp + \"\")\n return;\n this.regExp = regExp;\n this.cache = [];\n };\n SearchHighlight.prototype.update = function (html, markerLayer, session, config) {\n if (!this.regExp)\n return;\n var start = config.firstRow, end = config.lastRow;\n var renderedMarkerRanges = {};\n for (var i = start; i <= end; i++) {\n var ranges = this.cache[i];\n if (ranges == null) {\n ranges = lang.getMatchOffsets(session.getLine(i), this.regExp);\n if (ranges.length > this.MAX_RANGES)\n ranges = ranges.slice(0, this.MAX_RANGES);\n ranges = ranges.map(function (match) {\n return new Range(i, match.offset, i, match.offset + match.length);\n });\n this.cache[i] = ranges.length ? ranges : \"\";\n }\n for (var j = ranges.length; j--;) {\n var rangeToAddMarkerTo = ranges[j].toScreenRange(session);\n var rangeAsString = rangeToAddMarkerTo.toString();\n if (renderedMarkerRanges[rangeAsString])\n continue;\n renderedMarkerRanges[rangeAsString] = true;\n markerLayer.drawSingleLineMarker(html, rangeToAddMarkerTo, this.clazz, config);\n }\n }\n };\n return SearchHighlight;\n}());\nSearchHighlight.prototype.MAX_RANGES = 500;\nexports.SearchHighlight = SearchHighlight;\n\n});\n\nace.define(\"ace/undomanager\",[\"require\",\"exports\",\"module\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar UndoManager = /** @class */ (function () {\n function UndoManager() {\n this.$keepRedoStack;\n this.$maxRev = 0;\n this.$fromUndo = false;\n this.$undoDepth = Infinity;\n this.reset();\n }\n UndoManager.prototype.addSession = function (session) {\n this.$session = session;\n };\n UndoManager.prototype.add = function (delta, allowMerge, session) {\n if (this.$fromUndo)\n return;\n if (delta == this.$lastDelta)\n return;\n if (!this.$keepRedoStack)\n this.$redoStack.length = 0;\n if (allowMerge === false || !this.lastDeltas) {\n this.lastDeltas = [];\n var undoStackLength = this.$undoStack.length;\n if (undoStackLength > this.$undoDepth - 1) {\n this.$undoStack.splice(0, undoStackLength - this.$undoDepth + 1);\n }\n this.$undoStack.push(this.lastDeltas);\n delta.id = this.$rev = ++this.$maxRev;\n }\n if (delta.action == \"remove\" || delta.action == \"insert\")\n this.$lastDelta = delta;\n this.lastDeltas.push(delta);\n };\n UndoManager.prototype.addSelection = function (selection, rev) {\n this.selections.push({\n value: selection,\n rev: rev || this.$rev\n });\n };\n UndoManager.prototype.startNewGroup = function () {\n this.lastDeltas = null;\n return this.$rev;\n };\n UndoManager.prototype.markIgnored = function (from, to) {\n if (to == null)\n to = this.$rev + 1;\n var stack = this.$undoStack;\n for (var i = stack.length; i--;) {\n var delta = stack[i][0];\n if (delta.id <= from)\n break;\n if (delta.id < to)\n delta.ignore = true;\n }\n this.lastDeltas = null;\n };\n UndoManager.prototype.getSelection = function (rev, after) {\n var stack = this.selections;\n for (var i = stack.length; i--;) {\n var selection = stack[i];\n if (selection.rev < rev) {\n if (after)\n selection = stack[i + 1];\n return selection;\n }\n }\n };\n UndoManager.prototype.getRevision = function () {\n return this.$rev;\n };\n UndoManager.prototype.getDeltas = function (from, to) {\n if (to == null)\n to = this.$rev + 1;\n var stack = this.$undoStack;\n var end = null, start = 0;\n for (var i = stack.length; i--;) {\n var delta = stack[i][0];\n if (delta.id < to && !end)\n end = i + 1;\n if (delta.id <= from) {\n start = i + 1;\n break;\n }\n }\n return stack.slice(start, end);\n };\n UndoManager.prototype.getChangedRanges = function (from, to) {\n if (to == null)\n to = this.$rev + 1;\n };\n UndoManager.prototype.getChangedLines = function (from, to) {\n if (to == null)\n to = this.$rev + 1;\n };\n UndoManager.prototype.undo = function (session, dontSelect) {\n this.lastDeltas = null;\n var stack = this.$undoStack;\n if (!rearrangeUndoStack(stack, stack.length))\n return;\n if (!session)\n session = this.$session;\n if (this.$redoStackBaseRev !== this.$rev && this.$redoStack.length)\n this.$redoStack = [];\n this.$fromUndo = true;\n var deltaSet = stack.pop();\n var undoSelectionRange = null;\n if (deltaSet) {\n undoSelectionRange = session.undoChanges(deltaSet, dontSelect);\n this.$redoStack.push(deltaSet);\n this.$syncRev();\n }\n this.$fromUndo = false;\n return undoSelectionRange;\n };\n UndoManager.prototype.redo = function (session, dontSelect) {\n this.lastDeltas = null;\n if (!session)\n session = this.$session;\n this.$fromUndo = true;\n if (this.$redoStackBaseRev != this.$rev) {\n var diff = this.getDeltas(this.$redoStackBaseRev, this.$rev + 1);\n rebaseRedoStack(this.$redoStack, diff);\n this.$redoStackBaseRev = this.$rev;\n this.$redoStack.forEach(function (x) {\n x[0].id = ++this.$maxRev;\n }, this);\n }\n var deltaSet = this.$redoStack.pop();\n var redoSelectionRange = null;\n if (deltaSet) {\n redoSelectionRange = session.redoChanges(deltaSet, dontSelect);\n this.$undoStack.push(deltaSet);\n this.$syncRev();\n }\n this.$fromUndo = false;\n return redoSelectionRange;\n };\n UndoManager.prototype.$syncRev = function () {\n var stack = this.$undoStack;\n var nextDelta = stack[stack.length - 1];\n var id = nextDelta && nextDelta[0].id || 0;\n this.$redoStackBaseRev = id;\n this.$rev = id;\n };\n UndoManager.prototype.reset = function () {\n this.lastDeltas = null;\n this.$lastDelta = null;\n this.$undoStack = [];\n this.$redoStack = [];\n this.$rev = 0;\n this.mark = 0;\n this.$redoStackBaseRev = this.$rev;\n this.selections = [];\n };\n UndoManager.prototype.canUndo = function () {\n return this.$undoStack.length > 0;\n };\n UndoManager.prototype.canRedo = function () {\n return this.$redoStack.length > 0;\n };\n UndoManager.prototype.bookmark = function (rev) {\n if (rev == undefined)\n rev = this.$rev;\n this.mark = rev;\n };\n UndoManager.prototype.isAtBookmark = function () {\n return this.$rev === this.mark;\n };\n UndoManager.prototype.toJSON = function () {\n return {\n $redoStack: this.$redoStack,\n $undoStack: this.$undoStack\n };\n };\n UndoManager.prototype.fromJSON = function (json) {\n this.reset();\n this.$undoStack = json.$undoStack;\n this.$redoStack = json.$redoStack;\n };\n UndoManager.prototype.$prettyPrint = function (delta) {\n if (delta)\n return stringifyDelta(delta);\n return stringifyDelta(this.$undoStack) + \"\\n---\\n\" + stringifyDelta(this.$redoStack);\n };\n return UndoManager;\n}());\nUndoManager.prototype.hasUndo = UndoManager.prototype.canUndo;\nUndoManager.prototype.hasRedo = UndoManager.prototype.canRedo;\nUndoManager.prototype.isClean = UndoManager.prototype.isAtBookmark;\nUndoManager.prototype.markClean = UndoManager.prototype.bookmark;\nfunction rearrangeUndoStack(stack, pos) {\n for (var i = pos; i--;) {\n var deltaSet = stack[i];\n if (deltaSet && !deltaSet[0].ignore) {\n while (i < pos - 1) {\n var swapped = swapGroups(stack[i], stack[i + 1]);\n stack[i] = swapped[0];\n stack[i + 1] = swapped[1];\n i++;\n }\n return true;\n }\n }\n}\nvar Range = require(\"./range\").Range;\nvar cmp = Range.comparePoints;\nvar comparePoints = Range.comparePoints;\nfunction $updateMarkers(delta) {\n var isInsert = delta.action == \"insert\";\n var start = delta.start;\n var end = delta.end;\n var rowShift = (end.row - start.row) * (isInsert ? 1 : -1);\n var colShift = (end.column - start.column) * (isInsert ? 1 : -1);\n if (isInsert)\n end = start;\n for (var i in this.marks) {\n var point = this.marks[i];\n var cmp = comparePoints(point, start);\n if (cmp < 0) {\n continue; // delta starts after the range\n }\n if (cmp === 0) {\n if (isInsert) {\n if (point.bias == 1) {\n cmp = 1;\n }\n else {\n point.bias == -1;\n continue;\n }\n }\n }\n var cmp2 = isInsert ? cmp : comparePoints(point, end);\n if (cmp2 > 0) {\n point.row += rowShift;\n point.column += point.row == end.row ? colShift : 0;\n continue;\n }\n if (!isInsert && cmp2 <= 0) {\n point.row = start.row;\n point.column = start.column;\n if (cmp2 === 0)\n point.bias = 1;\n }\n }\n}\nfunction clonePos(pos) {\n return { row: pos.row, column: pos.column };\n}\nfunction cloneDelta(d) {\n return {\n start: clonePos(d.start),\n end: clonePos(d.end),\n action: d.action,\n lines: d.lines.slice()\n };\n}\nfunction stringifyDelta(d) {\n d = d || this;\n if (Array.isArray(d)) {\n return d.map(stringifyDelta).join(\"\\n\");\n }\n var type = \"\";\n if (d.action) {\n type = d.action == \"insert\" ? \"+\" : \"-\";\n type += \"[\" + d.lines + \"]\";\n }\n else if (d.value) {\n if (Array.isArray(d.value)) {\n type = d.value.map(stringifyRange).join(\"\\n\");\n }\n else {\n type = stringifyRange(d.value);\n }\n }\n if (d.start) {\n type += stringifyRange(d);\n }\n if (d.id || d.rev) {\n type += \"\\t(\" + (d.id || d.rev) + \")\";\n }\n return type;\n}\nfunction stringifyRange(r) {\n return r.start.row + \":\" + r.start.column\n + \"=>\" + r.end.row + \":\" + r.end.column;\n}\nfunction swap(d1, d2) {\n var i1 = d1.action == \"insert\";\n var i2 = d2.action == \"insert\";\n if (i1 && i2) {\n if (cmp(d2.start, d1.end) >= 0) {\n shift(d2, d1, -1);\n }\n else if (cmp(d2.start, d1.start) <= 0) {\n shift(d1, d2, +1);\n }\n else {\n return null;\n }\n }\n else if (i1 && !i2) {\n if (cmp(d2.start, d1.end) >= 0) {\n shift(d2, d1, -1);\n }\n else if (cmp(d2.end, d1.start) <= 0) {\n shift(d1, d2, -1);\n }\n else {\n return null;\n }\n }\n else if (!i1 && i2) {\n if (cmp(d2.start, d1.start) >= 0) {\n shift(d2, d1, +1);\n }\n else if (cmp(d2.start, d1.start) <= 0) {\n shift(d1, d2, +1);\n }\n else {\n return null;\n }\n }\n else if (!i1 && !i2) {\n if (cmp(d2.start, d1.start) >= 0) {\n shift(d2, d1, +1);\n }\n else if (cmp(d2.end, d1.start) <= 0) {\n shift(d1, d2, -1);\n }\n else {\n return null;\n }\n }\n return [d2, d1];\n}\nfunction swapGroups(ds1, ds2) {\n for (var i = ds1.length; i--;) {\n for (var j = 0; j < ds2.length; j++) {\n if (!swap(ds1[i], ds2[j])) {\n while (i < ds1.length) {\n while (j--) {\n swap(ds2[j], ds1[i]);\n }\n j = ds2.length;\n i++;\n }\n return [ds1, ds2];\n }\n }\n }\n ds1.selectionBefore = ds2.selectionBefore =\n ds1.selectionAfter = ds2.selectionAfter = null;\n return [ds2, ds1];\n}\nfunction xform(d1, c1) {\n var i1 = d1.action == \"insert\";\n var i2 = c1.action == \"insert\";\n if (i1 && i2) {\n if (cmp(d1.start, c1.start) < 0) {\n shift(c1, d1, 1);\n }\n else {\n shift(d1, c1, 1);\n }\n }\n else if (i1 && !i2) {\n if (cmp(d1.start, c1.end) >= 0) {\n shift(d1, c1, -1);\n }\n else if (cmp(d1.start, c1.start) <= 0) {\n shift(c1, d1, +1);\n }\n else {\n shift(d1, Range.fromPoints(c1.start, d1.start), -1);\n shift(c1, d1, +1);\n }\n }\n else if (!i1 && i2) {\n if (cmp(c1.start, d1.end) >= 0) {\n shift(c1, d1, -1);\n }\n else if (cmp(c1.start, d1.start) <= 0) {\n shift(d1, c1, +1);\n }\n else {\n shift(c1, Range.fromPoints(d1.start, c1.start), -1);\n shift(d1, c1, +1);\n }\n }\n else if (!i1 && !i2) {\n if (cmp(c1.start, d1.end) >= 0) {\n shift(c1, d1, -1);\n }\n else if (cmp(c1.end, d1.start) <= 0) {\n shift(d1, c1, -1);\n }\n else {\n var before, after;\n if (cmp(d1.start, c1.start) < 0) {\n before = d1;\n d1 = splitDelta(d1, c1.start);\n }\n if (cmp(d1.end, c1.end) > 0) {\n after = splitDelta(d1, c1.end);\n }\n shiftPos(c1.end, d1.start, d1.end, -1);\n if (after && !before) {\n d1.lines = after.lines;\n d1.start = after.start;\n d1.end = after.end;\n after = d1;\n }\n return [c1, before, after].filter(Boolean);\n }\n }\n return [c1, d1];\n}\nfunction shift(d1, d2, dir) {\n shiftPos(d1.start, d2.start, d2.end, dir);\n shiftPos(d1.end, d2.start, d2.end, dir);\n}\nfunction shiftPos(pos, start, end, dir) {\n if (pos.row == (dir == 1 ? start : end).row) {\n pos.column += dir * (end.column - start.column);\n }\n pos.row += dir * (end.row - start.row);\n}\nfunction splitDelta(c, pos) {\n var lines = c.lines;\n var end = c.end;\n c.end = clonePos(pos);\n var rowsBefore = c.end.row - c.start.row;\n var otherLines = lines.splice(rowsBefore, lines.length);\n var col = rowsBefore ? pos.column : pos.column - c.start.column;\n lines.push(otherLines[0].substring(0, col));\n otherLines[0] = otherLines[0].substr(col);\n var rest = {\n start: clonePos(pos),\n end: end,\n lines: otherLines,\n action: c.action\n };\n return rest;\n}\nfunction moveDeltasByOne(redoStack, d) {\n d = cloneDelta(d);\n for (var j = redoStack.length; j--;) {\n var deltaSet = redoStack[j];\n for (var i = 0; i < deltaSet.length; i++) {\n var x = deltaSet[i];\n var xformed = xform(x, d);\n d = xformed[0];\n if (xformed.length != 2) {\n if (xformed[2]) {\n deltaSet.splice(i + 1, 1, xformed[1], xformed[2]);\n i++;\n }\n else if (!xformed[1]) {\n deltaSet.splice(i, 1);\n i--;\n }\n }\n }\n if (!deltaSet.length) {\n redoStack.splice(j, 1);\n }\n }\n return redoStack;\n}\nfunction rebaseRedoStack(redoStack, deltaSets) {\n for (var i = 0; i < deltaSets.length; i++) {\n var deltas = deltaSets[i];\n for (var j = 0; j < deltas.length; j++) {\n moveDeltasByOne(redoStack, deltas[j]);\n }\n }\n}\nexports.UndoManager = UndoManager;\n\n});\n\nace.define(\"ace/edit_session/fold_line\",[\"require\",\"exports\",\"module\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar Range = require(\"../range\").Range;\nvar FoldLine = /** @class */ (function () {\n function FoldLine(foldData, folds) {\n this.foldData = foldData;\n if (Array.isArray(folds)) {\n this.folds = folds;\n }\n else {\n folds = this.folds = [folds];\n }\n var last = folds[folds.length - 1];\n this.range = new Range(folds[0].start.row, folds[0].start.column, last.end.row, last.end.column);\n this.start = this.range.start;\n this.end = this.range.end;\n this.folds.forEach(function (fold) {\n fold.setFoldLine(this);\n }, this);\n }\n FoldLine.prototype.shiftRow = function (shift) {\n this.start.row += shift;\n this.end.row += shift;\n this.folds.forEach(function (fold) {\n fold.start.row += shift;\n fold.end.row += shift;\n });\n };\n FoldLine.prototype.addFold = function (fold) {\n if (fold.sameRow) {\n if (fold.start.row < this.startRow || fold.endRow > this.endRow) {\n throw new Error(\"Can't add a fold to this FoldLine as it has no connection\");\n }\n this.folds.push(fold);\n this.folds.sort(function (a, b) {\n return -a.range.compareEnd(b.start.row, b.start.column);\n });\n if (this.range.compareEnd(fold.start.row, fold.start.column) > 0) {\n this.end.row = fold.end.row;\n this.end.column = fold.end.column;\n }\n else if (this.range.compareStart(fold.end.row, fold.end.column) < 0) {\n this.start.row = fold.start.row;\n this.start.column = fold.start.column;\n }\n }\n else if (fold.start.row == this.end.row) {\n this.folds.push(fold);\n this.end.row = fold.end.row;\n this.end.column = fold.end.column;\n }\n else if (fold.end.row == this.start.row) {\n this.folds.unshift(fold);\n this.start.row = fold.start.row;\n this.start.column = fold.start.column;\n }\n else {\n throw new Error(\"Trying to add fold to FoldRow that doesn't have a matching row\");\n }\n fold.foldLine = this;\n };\n FoldLine.prototype.containsRow = function (row) {\n return row >= this.start.row && row <= this.end.row;\n };\n FoldLine.prototype.walk = function (callback, endRow, endColumn) {\n var lastEnd = 0, folds = this.folds, fold, cmp, stop, isNewRow = true;\n if (endRow == null) {\n endRow = this.end.row;\n endColumn = this.end.column;\n }\n for (var i = 0; i < folds.length; i++) {\n fold = folds[i];\n cmp = fold.range.compareStart(endRow, endColumn);\n if (cmp == -1) {\n callback(null, endRow, endColumn, lastEnd, isNewRow);\n return;\n }\n stop = callback(null, fold.start.row, fold.start.column, lastEnd, isNewRow);\n stop = !stop && callback(fold.placeholder, fold.start.row, fold.start.column, lastEnd);\n if (stop || cmp === 0) {\n return;\n }\n isNewRow = !fold.sameRow;\n lastEnd = fold.end.column;\n }\n callback(null, endRow, endColumn, lastEnd, isNewRow);\n };\n FoldLine.prototype.getNextFoldTo = function (row, column) {\n var fold, cmp;\n for (var i = 0; i < this.folds.length; i++) {\n fold = this.folds[i];\n cmp = fold.range.compareEnd(row, column);\n if (cmp == -1) {\n return {\n fold: fold,\n kind: \"after\"\n };\n }\n else if (cmp === 0) {\n return {\n fold: fold,\n kind: \"inside\"\n };\n }\n }\n return null;\n };\n FoldLine.prototype.addRemoveChars = function (row, column, len) {\n var ret = this.getNextFoldTo(row, column), fold, folds;\n if (ret) {\n fold = ret.fold;\n if (ret.kind == \"inside\"\n && fold.start.column != column\n && fold.start.row != row) {\n window.console && window.console.log(row, column, fold);\n }\n else if (fold.start.row == row) {\n folds = this.folds;\n var i = folds.indexOf(fold);\n if (i === 0) {\n this.start.column += len;\n }\n for (i; i < folds.length; i++) {\n fold = folds[i];\n fold.start.column += len;\n if (!fold.sameRow) {\n return;\n }\n fold.end.column += len;\n }\n this.end.column += len;\n }\n }\n };\n FoldLine.prototype.split = function (row, column) {\n var pos = this.getNextFoldTo(row, column);\n if (!pos || pos.kind == \"inside\")\n return null;\n var fold = pos.fold;\n var folds = this.folds;\n var foldData = this.foldData;\n var i = folds.indexOf(fold);\n var foldBefore = folds[i - 1];\n this.end.row = foldBefore.end.row;\n this.end.column = foldBefore.end.column;\n folds = folds.splice(i, folds.length - i);\n var newFoldLine = new FoldLine(foldData, folds);\n foldData.splice(foldData.indexOf(this) + 1, 0, newFoldLine);\n return newFoldLine;\n };\n FoldLine.prototype.merge = function (foldLineNext) {\n var folds = foldLineNext.folds;\n for (var i = 0; i < folds.length; i++) {\n this.addFold(folds[i]);\n }\n var foldData = this.foldData;\n foldData.splice(foldData.indexOf(foldLineNext), 1);\n };\n FoldLine.prototype.toString = function () {\n var ret = [this.range.toString() + \": [\"];\n this.folds.forEach(function (fold) {\n ret.push(\" \" + fold.toString());\n });\n ret.push(\"]\");\n return ret.join(\"\\n\");\n };\n FoldLine.prototype.idxToPosition = function (idx) {\n var lastFoldEndColumn = 0;\n for (var i = 0; i < this.folds.length; i++) {\n var fold = this.folds[i];\n idx -= fold.start.column - lastFoldEndColumn;\n if (idx < 0) {\n return {\n row: fold.start.row,\n column: fold.start.column + idx\n };\n }\n idx -= fold.placeholder.length;\n if (idx < 0) {\n return fold.start;\n }\n lastFoldEndColumn = fold.end.column;\n }\n return {\n row: this.end.row,\n column: this.end.column + idx\n };\n };\n return FoldLine;\n}());\nexports.FoldLine = FoldLine;\n\n});\n\nace.define(\"ace/range_list\",[\"require\",\"exports\",\"module\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar Range = require(\"./range\").Range;\nvar comparePoints = Range.comparePoints;\nvar RangeList = /** @class */ (function () {\n function RangeList() {\n this.ranges = [];\n this.$bias = 1;\n }\n RangeList.prototype.pointIndex = function (pos, excludeEdges, startIndex) {\n var list = this.ranges;\n for (var i = startIndex || 0; i < list.length; i++) {\n var range = list[i];\n var cmpEnd = comparePoints(pos, range.end);\n if (cmpEnd > 0)\n continue;\n var cmpStart = comparePoints(pos, range.start);\n if (cmpEnd === 0)\n return excludeEdges && cmpStart !== 0 ? -i - 2 : i;\n if (cmpStart > 0 || (cmpStart === 0 && !excludeEdges))\n return i;\n return -i - 1;\n }\n return -i - 1;\n };\n RangeList.prototype.add = function (range) {\n var excludeEdges = !range.isEmpty();\n var startIndex = this.pointIndex(range.start, excludeEdges);\n if (startIndex < 0)\n startIndex = -startIndex - 1;\n var endIndex = this.pointIndex(range.end, excludeEdges, startIndex);\n if (endIndex < 0)\n endIndex = -endIndex - 1;\n else\n endIndex++;\n return this.ranges.splice(startIndex, endIndex - startIndex, range);\n };\n RangeList.prototype.addList = function (list) {\n var removed = [];\n for (var i = list.length; i--;) {\n removed.push.apply(removed, this.add(list[i]));\n }\n return removed;\n };\n RangeList.prototype.substractPoint = function (pos) {\n var i = this.pointIndex(pos);\n if (i >= 0)\n return this.ranges.splice(i, 1);\n };\n RangeList.prototype.merge = function () {\n var removed = [];\n var list = this.ranges;\n list = list.sort(function (a, b) {\n return comparePoints(a.start, b.start);\n });\n var next = list[0], range;\n for (var i = 1; i < list.length; i++) {\n range = next;\n next = list[i];\n var cmp = comparePoints(range.end, next.start);\n if (cmp < 0)\n continue;\n if (cmp == 0 && !range.isEmpty() && !next.isEmpty())\n continue;\n if (comparePoints(range.end, next.end) < 0) {\n range.end.row = next.end.row;\n range.end.column = next.end.column;\n }\n list.splice(i, 1);\n removed.push(next);\n next = range;\n i--;\n }\n this.ranges = list;\n return removed;\n };\n RangeList.prototype.contains = function (row, column) {\n return this.pointIndex({ row: row, column: column }) >= 0;\n };\n RangeList.prototype.containsPoint = function (pos) {\n return this.pointIndex(pos) >= 0;\n };\n RangeList.prototype.rangeAtPoint = function (pos) {\n var i = this.pointIndex(pos);\n if (i >= 0)\n return this.ranges[i];\n };\n RangeList.prototype.clipRows = function (startRow, endRow) {\n var list = this.ranges;\n if (list[0].start.row > endRow || list[list.length - 1].start.row < startRow)\n return [];\n var startIndex = this.pointIndex({ row: startRow, column: 0 });\n if (startIndex < 0)\n startIndex = -startIndex - 1;\n var endIndex = this.pointIndex({ row: endRow, column: 0 }, startIndex);\n if (endIndex < 0)\n endIndex = -endIndex - 1;\n var clipped = [];\n for (var i = startIndex; i < endIndex; i++) {\n clipped.push(list[i]);\n }\n return clipped;\n };\n RangeList.prototype.removeAll = function () {\n return this.ranges.splice(0, this.ranges.length);\n };\n RangeList.prototype.attach = function (session) {\n if (this.session)\n this.detach();\n this.session = session;\n this.onChange = this.$onChange.bind(this);\n this.session.on('change', this.onChange);\n };\n RangeList.prototype.detach = function () {\n if (!this.session)\n return;\n this.session.removeListener('change', this.onChange);\n this.session = null;\n };\n RangeList.prototype.$onChange = function (delta) {\n var start = delta.start;\n var end = delta.end;\n var startRow = start.row;\n var endRow = end.row;\n var ranges = this.ranges;\n for (var i = 0, n = ranges.length; i < n; i++) {\n var r = ranges[i];\n if (r.end.row >= startRow)\n break;\n }\n if (delta.action == \"insert\") {\n var lineDif = endRow - startRow;\n var colDiff = -start.column + end.column;\n for (; i < n; i++) {\n var r = ranges[i];\n if (r.start.row > startRow)\n break;\n if (r.start.row == startRow && r.start.column >= start.column) {\n if (r.start.column == start.column && this.$bias <= 0) {\n }\n else {\n r.start.column += colDiff;\n r.start.row += lineDif;\n }\n }\n if (r.end.row == startRow && r.end.column >= start.column) {\n if (r.end.column == start.column && this.$bias < 0) {\n continue;\n }\n if (r.end.column == start.column && colDiff > 0 && i < n - 1) {\n if (r.end.column > r.start.column && r.end.column == ranges[i + 1].start.column)\n r.end.column -= colDiff;\n }\n r.end.column += colDiff;\n r.end.row += lineDif;\n }\n }\n }\n else {\n var lineDif = startRow - endRow;\n var colDiff = start.column - end.column;\n for (; i < n; i++) {\n var r = ranges[i];\n if (r.start.row > endRow)\n break;\n if (r.end.row < endRow\n && (startRow < r.end.row\n || startRow == r.end.row && start.column < r.end.column)) {\n r.end.row = startRow;\n r.end.column = start.column;\n }\n else if (r.end.row == endRow) {\n if (r.end.column <= end.column) {\n if (lineDif || r.end.column > start.column) {\n r.end.column = start.column;\n r.end.row = start.row;\n }\n }\n else {\n r.end.column += colDiff;\n r.end.row += lineDif;\n }\n }\n else if (r.end.row > endRow) {\n r.end.row += lineDif;\n }\n if (r.start.row < endRow\n && (startRow < r.start.row\n || startRow == r.start.row && start.column < r.start.column)) {\n r.start.row = startRow;\n r.start.column = start.column;\n }\n else if (r.start.row == endRow) {\n if (r.start.column <= end.column) {\n if (lineDif || r.start.column > start.column) {\n r.start.column = start.column;\n r.start.row = start.row;\n }\n }\n else {\n r.start.column += colDiff;\n r.start.row += lineDif;\n }\n }\n else if (r.start.row > endRow) {\n r.start.row += lineDif;\n }\n }\n }\n if (lineDif != 0 && i < n) {\n for (; i < n; i++) {\n var r = ranges[i];\n r.start.row += lineDif;\n r.end.row += lineDif;\n }\n }\n };\n return RangeList;\n}());\nRangeList.prototype.comparePoints = comparePoints;\nexports.RangeList = RangeList;\n\n});\n\nace.define(\"ace/edit_session/fold\",[\"require\",\"exports\",\"module\",\"ace/range_list\"], function(require, exports, module){\"use strict\";\nvar __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar RangeList = require(\"../range_list\").RangeList;\nvar Fold = /** @class */ (function (_super) {\n __extends(Fold, _super);\n function Fold(range, placeholder) {\n var _this = _super.call(this) || this;\n _this.foldLine = null;\n _this.placeholder = placeholder;\n _this.range = range;\n _this.start = range.start;\n _this.end = range.end;\n _this.sameRow = range.start.row == range.end.row;\n _this.subFolds = _this.ranges = [];\n return _this;\n }\n Fold.prototype.toString = function () {\n return '\"' + this.placeholder + '\" ' + this.range.toString();\n };\n Fold.prototype.setFoldLine = function (foldLine) {\n this.foldLine = foldLine;\n this.subFolds.forEach(function (fold) {\n fold.setFoldLine(foldLine);\n });\n };\n Fold.prototype.clone = function () {\n var range = this.range.clone();\n var fold = new Fold(range, this.placeholder);\n this.subFolds.forEach(function (subFold) {\n fold.subFolds.push(subFold.clone());\n });\n fold.collapseChildren = this.collapseChildren;\n return fold;\n };\n Fold.prototype.addSubFold = function (fold) {\n if (this.range.isEqual(fold))\n return;\n consumeRange(fold, this.start);\n var row = fold.start.row, column = fold.start.column;\n for (var i = 0, cmp = -1; i < this.subFolds.length; i++) {\n cmp = this.subFolds[i].range.compare(row, column);\n if (cmp != 1)\n break;\n }\n var afterStart = this.subFolds[i];\n var firstConsumed = 0;\n if (cmp == 0) {\n if (afterStart.range.containsRange(fold))\n return afterStart.addSubFold(fold);\n else\n firstConsumed = 1;\n }\n var row = fold.range.end.row, column = fold.range.end.column;\n for (var j = i, cmp = -1; j < this.subFolds.length; j++) {\n cmp = this.subFolds[j].range.compare(row, column);\n if (cmp != 1)\n break;\n }\n if (cmp == 0)\n j++;\n var consumedFolds = this.subFolds.splice(i, j - i, fold);\n var last = cmp == 0 ? consumedFolds.length - 1 : consumedFolds.length;\n for (var k = firstConsumed; k < last; k++) {\n fold.addSubFold(consumedFolds[k]);\n }\n fold.setFoldLine(this.foldLine);\n return fold;\n };\n Fold.prototype.restoreRange = function (range) {\n return restoreRange(range, this.start);\n };\n return Fold;\n}(RangeList));\nfunction consumePoint(point, anchor) {\n point.row -= anchor.row;\n if (point.row == 0)\n point.column -= anchor.column;\n}\nfunction consumeRange(range, anchor) {\n consumePoint(range.start, anchor);\n consumePoint(range.end, anchor);\n}\nfunction restorePoint(point, anchor) {\n if (point.row == 0)\n point.column += anchor.column;\n point.row += anchor.row;\n}\nfunction restoreRange(range, anchor) {\n restorePoint(range.start, anchor);\n restorePoint(range.end, anchor);\n}\nexports.Fold = Fold;\n\n});\n\nace.define(\"ace/edit_session/folding\",[\"require\",\"exports\",\"module\",\"ace/range\",\"ace/edit_session/fold_line\",\"ace/edit_session/fold\",\"ace/token_iterator\",\"ace/mouse/mouse_event\"], function(require, exports, module){// @ts-nocheck\n\"use strict\";\nvar Range = require(\"../range\").Range;\nvar FoldLine = require(\"./fold_line\").FoldLine;\nvar Fold = require(\"./fold\").Fold;\nvar TokenIterator = require(\"../token_iterator\").TokenIterator;\nvar MouseEvent = require(\"../mouse/mouse_event\").MouseEvent;\nfunction Folding() {\n this.getFoldAt = function (row, column, side) {\n var foldLine = this.getFoldLine(row);\n if (!foldLine)\n return null;\n var folds = foldLine.folds;\n for (var i = 0; i < folds.length; i++) {\n var range = folds[i].range;\n if (range.contains(row, column)) {\n if (side == 1 && range.isEnd(row, column) && !range.isEmpty()) {\n continue;\n }\n else if (side == -1 && range.isStart(row, column) && !range.isEmpty()) {\n continue;\n }\n return folds[i];\n }\n }\n };\n this.getFoldsInRange = function (range) {\n var start = range.start;\n var end = range.end;\n var foldLines = this.$foldData;\n var foundFolds = [];\n start.column += 1;\n end.column -= 1;\n for (var i = 0; i < foldLines.length; i++) {\n var cmp = foldLines[i].range.compareRange(range);\n if (cmp == 2) {\n continue;\n }\n else if (cmp == -2) {\n break;\n }\n var folds = foldLines[i].folds;\n for (var j = 0; j < folds.length; j++) {\n var fold = folds[j];\n cmp = fold.range.compareRange(range);\n if (cmp == -2) {\n break;\n }\n else if (cmp == 2) {\n continue;\n }\n else \n if (cmp == 42) {\n break;\n }\n foundFolds.push(fold);\n }\n }\n start.column -= 1;\n end.column += 1;\n return foundFolds;\n };\n this.getFoldsInRangeList = function (ranges) {\n if (Array.isArray(ranges)) {\n var folds = [];\n ranges.forEach(function (range) {\n folds = folds.concat(this.getFoldsInRange(range));\n }, this);\n }\n else {\n var folds = this.getFoldsInRange(ranges);\n }\n return folds;\n };\n this.getAllFolds = function () {\n var folds = [];\n var foldLines = this.$foldData;\n for (var i = 0; i < foldLines.length; i++)\n for (var j = 0; j < foldLines[i].folds.length; j++)\n folds.push(foldLines[i].folds[j]);\n return folds;\n };\n this.getFoldStringAt = function (row, column, trim, foldLine) {\n foldLine = foldLine || this.getFoldLine(row);\n if (!foldLine)\n return null;\n var lastFold = {\n end: { column: 0 }\n };\n var str, fold;\n for (var i = 0; i < foldLine.folds.length; i++) {\n fold = foldLine.folds[i];\n var cmp = fold.range.compareEnd(row, column);\n if (cmp == -1) {\n str = this\n .getLine(fold.start.row)\n .substring(lastFold.end.column, fold.start.column);\n break;\n }\n else if (cmp === 0) {\n return null;\n }\n lastFold = fold;\n }\n if (!str)\n str = this.getLine(fold.start.row).substring(lastFold.end.column);\n if (trim == -1)\n return str.substring(0, column - lastFold.end.column);\n else if (trim == 1)\n return str.substring(column - lastFold.end.column);\n else\n return str;\n };\n this.getFoldLine = function (docRow, startFoldLine) {\n var foldData = this.$foldData;\n var i = 0;\n if (startFoldLine)\n i = foldData.indexOf(startFoldLine);\n if (i == -1)\n i = 0;\n for (i; i < foldData.length; i++) {\n var foldLine = foldData[i];\n if (foldLine.start.row <= docRow && foldLine.end.row >= docRow) {\n return foldLine;\n }\n else if (foldLine.end.row > docRow) {\n return null;\n }\n }\n return null;\n };\n this.getNextFoldLine = function (docRow, startFoldLine) {\n var foldData = this.$foldData;\n var i = 0;\n if (startFoldLine)\n i = foldData.indexOf(startFoldLine);\n if (i == -1)\n i = 0;\n for (i; i < foldData.length; i++) {\n var foldLine = foldData[i];\n if (foldLine.end.row >= docRow) {\n return foldLine;\n }\n }\n return null;\n };\n this.getFoldedRowCount = function (first, last) {\n var foldData = this.$foldData, rowCount = last - first + 1;\n for (var i = 0; i < foldData.length; i++) {\n var foldLine = foldData[i], end = foldLine.end.row, start = foldLine.start.row;\n if (end >= last) {\n if (start < last) {\n if (start >= first)\n rowCount -= last - start;\n else\n rowCount = 0; // in one fold\n }\n break;\n }\n else if (end >= first) {\n if (start >= first) // fold inside range\n rowCount -= end - start;\n else\n rowCount -= end - first + 1;\n }\n }\n return rowCount;\n };\n this.$addFoldLine = function (foldLine) {\n this.$foldData.push(foldLine);\n this.$foldData.sort(function (a, b) {\n return a.start.row - b.start.row;\n });\n return foldLine;\n };\n this.addFold = function (placeholder, range) {\n var foldData = this.$foldData;\n var added = false;\n var fold;\n if (placeholder instanceof Fold)\n fold = placeholder;\n else {\n fold = new Fold(range, placeholder);\n fold.collapseChildren = range.collapseChildren;\n }\n this.$clipRangeToDocument(fold.range);\n var startRow = fold.start.row;\n var startColumn = fold.start.column;\n var endRow = fold.end.row;\n var endColumn = fold.end.column;\n var startFold = this.getFoldAt(startRow, startColumn, 1);\n var endFold = this.getFoldAt(endRow, endColumn, -1);\n if (startFold && endFold == startFold)\n return startFold.addSubFold(fold);\n if (startFold && !startFold.range.isStart(startRow, startColumn))\n this.removeFold(startFold);\n if (endFold && !endFold.range.isEnd(endRow, endColumn))\n this.removeFold(endFold);\n var folds = this.getFoldsInRange(fold.range);\n if (folds.length > 0) {\n this.removeFolds(folds);\n if (!fold.collapseChildren) {\n folds.forEach(function (subFold) {\n fold.addSubFold(subFold);\n });\n }\n }\n for (var i = 0; i < foldData.length; i++) {\n var foldLine = foldData[i];\n if (endRow == foldLine.start.row) {\n foldLine.addFold(fold);\n added = true;\n break;\n }\n else if (startRow == foldLine.end.row) {\n foldLine.addFold(fold);\n added = true;\n if (!fold.sameRow) {\n var foldLineNext = foldData[i + 1];\n if (foldLineNext && foldLineNext.start.row == endRow) {\n foldLine.merge(foldLineNext);\n break;\n }\n }\n break;\n }\n else if (endRow <= foldLine.start.row) {\n break;\n }\n }\n if (!added)\n foldLine = this.$addFoldLine(new FoldLine(this.$foldData, fold));\n if (this.$useWrapMode)\n this.$updateWrapData(foldLine.start.row, foldLine.start.row);\n else\n this.$updateRowLengthCache(foldLine.start.row, foldLine.start.row);\n this.$modified = true;\n this._signal(\"changeFold\", { data: fold, action: \"add\" });\n return fold;\n };\n this.addFolds = function (folds) {\n folds.forEach(function (fold) {\n this.addFold(fold);\n }, this);\n };\n this.removeFold = function (fold) {\n var foldLine = fold.foldLine;\n var startRow = foldLine.start.row;\n var endRow = foldLine.end.row;\n var foldLines = this.$foldData;\n var folds = foldLine.folds;\n if (folds.length == 1) {\n foldLines.splice(foldLines.indexOf(foldLine), 1);\n }\n else \n if (foldLine.range.isEnd(fold.end.row, fold.end.column)) {\n folds.pop();\n foldLine.end.row = folds[folds.length - 1].end.row;\n foldLine.end.column = folds[folds.length - 1].end.column;\n }\n else \n if (foldLine.range.isStart(fold.start.row, fold.start.column)) {\n folds.shift();\n foldLine.start.row = folds[0].start.row;\n foldLine.start.column = folds[0].start.column;\n }\n else \n if (fold.sameRow) {\n folds.splice(folds.indexOf(fold), 1);\n }\n else \n {\n var newFoldLine = foldLine.split(fold.start.row, fold.start.column);\n folds = newFoldLine.folds;\n folds.shift();\n newFoldLine.start.row = folds[0].start.row;\n newFoldLine.start.column = folds[0].start.column;\n }\n if (!this.$updating) {\n if (this.$useWrapMode)\n this.$updateWrapData(startRow, endRow);\n else\n this.$updateRowLengthCache(startRow, endRow);\n }\n this.$modified = true;\n this._signal(\"changeFold\", { data: fold, action: \"remove\" });\n };\n this.removeFolds = function (folds) {\n var cloneFolds = [];\n for (var i = 0; i < folds.length; i++) {\n cloneFolds.push(folds[i]);\n }\n cloneFolds.forEach(function (fold) {\n this.removeFold(fold);\n }, this);\n this.$modified = true;\n };\n this.expandFold = function (fold) {\n this.removeFold(fold);\n fold.subFolds.forEach(function (subFold) {\n fold.restoreRange(subFold);\n this.addFold(subFold);\n }, this);\n if (fold.collapseChildren > 0) {\n this.foldAll(fold.start.row + 1, fold.end.row, fold.collapseChildren - 1);\n }\n fold.subFolds = [];\n };\n this.expandFolds = function (folds) {\n folds.forEach(function (fold) {\n this.expandFold(fold);\n }, this);\n };\n this.unfold = function (location, expandInner) {\n var range, folds;\n if (location == null) {\n range = new Range(0, 0, this.getLength(), 0);\n if (expandInner == null)\n expandInner = true;\n }\n else if (typeof location == \"number\") {\n range = new Range(location, 0, location, this.getLine(location).length);\n }\n else if (\"row\" in location) {\n range = Range.fromPoints(location, location);\n }\n else if (Array.isArray(location)) {\n folds = [];\n location.forEach(function (range) {\n folds = folds.concat(this.unfold(range));\n }, this);\n return folds;\n }\n else {\n range = location;\n }\n folds = this.getFoldsInRangeList(range);\n var outermostFolds = folds;\n while (folds.length == 1\n && Range.comparePoints(folds[0].start, range.start) < 0\n && Range.comparePoints(folds[0].end, range.end) > 0) {\n this.expandFolds(folds);\n folds = this.getFoldsInRangeList(range);\n }\n if (expandInner != false) {\n this.removeFolds(folds);\n }\n else {\n this.expandFolds(folds);\n }\n if (outermostFolds.length)\n return outermostFolds;\n };\n this.isRowFolded = function (docRow, startFoldRow) {\n return !!this.getFoldLine(docRow, startFoldRow);\n };\n this.getRowFoldEnd = function (docRow, startFoldRow) {\n var foldLine = this.getFoldLine(docRow, startFoldRow);\n return foldLine ? foldLine.end.row : docRow;\n };\n this.getRowFoldStart = function (docRow, startFoldRow) {\n var foldLine = this.getFoldLine(docRow, startFoldRow);\n return foldLine ? foldLine.start.row : docRow;\n };\n this.getFoldDisplayLine = function (foldLine, endRow, endColumn, startRow, startColumn) {\n if (startRow == null)\n startRow = foldLine.start.row;\n if (startColumn == null)\n startColumn = 0;\n if (endRow == null)\n endRow = foldLine.end.row;\n if (endColumn == null)\n endColumn = this.getLine(endRow).length;\n var doc = this.doc;\n var textLine = \"\";\n foldLine.walk(function (placeholder, row, column, lastColumn) {\n if (row < startRow)\n return;\n if (row == startRow) {\n if (column < startColumn)\n return;\n lastColumn = Math.max(startColumn, lastColumn);\n }\n if (placeholder != null) {\n textLine += placeholder;\n }\n else {\n textLine += doc.getLine(row).substring(lastColumn, column);\n }\n }, endRow, endColumn);\n return textLine;\n };\n this.getDisplayLine = function (row, endColumn, startRow, startColumn) {\n var foldLine = this.getFoldLine(row);\n if (!foldLine) {\n var line;\n line = this.doc.getLine(row);\n return line.substring(startColumn || 0, endColumn || line.length);\n }\n else {\n return this.getFoldDisplayLine(foldLine, row, endColumn, startRow, startColumn);\n }\n };\n this.$cloneFoldData = function () {\n var fd = [];\n fd = this.$foldData.map(function (foldLine) {\n var folds = foldLine.folds.map(function (fold) {\n return fold.clone();\n });\n return new FoldLine(fd, folds);\n });\n return fd;\n };\n this.toggleFold = function (tryToUnfold) {\n var selection = this.selection;\n var range = selection.getRange();\n var fold;\n var bracketPos;\n if (range.isEmpty()) {\n var cursor = range.start;\n fold = this.getFoldAt(cursor.row, cursor.column);\n if (fold) {\n this.expandFold(fold);\n return;\n }\n else if (bracketPos = this.findMatchingBracket(cursor)) {\n if (range.comparePoint(bracketPos) == 1) {\n range.end = bracketPos;\n }\n else {\n range.start = bracketPos;\n range.start.column++;\n range.end.column--;\n }\n }\n else if (bracketPos = this.findMatchingBracket({ row: cursor.row, column: cursor.column + 1 })) {\n if (range.comparePoint(bracketPos) == 1)\n range.end = bracketPos;\n else\n range.start = bracketPos;\n range.start.column++;\n }\n else {\n range = this.getCommentFoldRange(cursor.row, cursor.column) || range;\n }\n }\n else {\n var folds = this.getFoldsInRange(range);\n if (tryToUnfold && folds.length) {\n this.expandFolds(folds);\n return;\n }\n else if (folds.length == 1) {\n fold = folds[0];\n }\n }\n if (!fold)\n fold = this.getFoldAt(range.start.row, range.start.column);\n if (fold && fold.range.toString() == range.toString()) {\n this.expandFold(fold);\n return;\n }\n var placeholder = \"...\";\n if (!range.isMultiLine()) {\n placeholder = this.getTextRange(range);\n if (placeholder.length < 4)\n return;\n placeholder = placeholder.trim().substring(0, 2) + \"..\";\n }\n this.addFold(placeholder, range);\n };\n this.getCommentFoldRange = function (row, column, dir) {\n var iterator = new TokenIterator(this, row, column);\n var token = iterator.getCurrentToken();\n var type = token && token.type;\n if (token && /^comment|string/.test(type)) {\n type = type.match(/comment|string/)[0];\n if (type == \"comment\")\n type += \"|doc-start|\\\\.doc\";\n var re = new RegExp(type);\n var range = new Range();\n if (dir != 1) {\n do {\n token = iterator.stepBackward();\n } while (token && re.test(token.type));\n token = iterator.stepForward();\n }\n range.start.row = iterator.getCurrentTokenRow();\n range.start.column = iterator.getCurrentTokenColumn() + token.value.length;\n iterator = new TokenIterator(this, row, column);\n var initState = this.getState(iterator.$row);\n if (dir != -1) {\n var lastRow = -1;\n do {\n token = iterator.stepForward();\n if (lastRow == -1) {\n var state = this.getState(iterator.$row);\n if (initState.toString() !== state.toString())\n lastRow = iterator.$row;\n }\n else if (iterator.$row > lastRow) {\n break;\n }\n } while (token && re.test(token.type));\n token = iterator.stepBackward();\n }\n else\n token = iterator.getCurrentToken();\n range.end.row = iterator.getCurrentTokenRow();\n range.end.column = iterator.getCurrentTokenColumn();\n return range;\n }\n };\n this.foldAll = function (startRow, endRow, depth, test) {\n if (depth == undefined)\n depth = 100000; // JSON.stringify doesn't hanle Infinity\n var foldWidgets = this.foldWidgets;\n if (!foldWidgets)\n return; // mode doesn't support folding\n endRow = endRow || this.getLength();\n startRow = startRow || 0;\n for (var row = startRow; row < endRow; row++) {\n if (foldWidgets[row] == null)\n foldWidgets[row] = this.getFoldWidget(row);\n if (foldWidgets[row] != \"start\")\n continue;\n if (test && !test(row))\n continue;\n var range = this.getFoldWidgetRange(row);\n if (range && range.isMultiLine()\n && range.end.row <= endRow\n && range.start.row >= startRow) {\n row = range.end.row;\n range.collapseChildren = depth;\n this.addFold(\"...\", range);\n }\n }\n };\n this.foldToLevel = function (level) {\n this.foldAll();\n while (level-- > 0)\n this.unfold(null, false);\n };\n this.foldAllComments = function () {\n var session = this;\n this.foldAll(null, null, null, function (row) {\n var tokens = session.getTokens(row);\n for (var i = 0; i < tokens.length; i++) {\n var token = tokens[i];\n if (token.type == \"text\" && /^\\s+$/.test(token.value))\n continue;\n if (/comment/.test(token.type))\n return true;\n return false;\n }\n });\n };\n this.$foldStyles = {\n \"manual\": 1,\n \"markbegin\": 1,\n \"markbeginend\": 1\n };\n this.$foldStyle = \"markbegin\";\n this.setFoldStyle = function (style) {\n if (!this.$foldStyles[style])\n throw new Error(\"invalid fold style: \" + style + \"[\" + Object.keys(this.$foldStyles).join(\", \") + \"]\");\n if (this.$foldStyle == style)\n return;\n this.$foldStyle = style;\n if (style == \"manual\")\n this.unfold();\n var mode = this.$foldMode;\n this.$setFolding(null);\n this.$setFolding(mode);\n };\n this.$setFolding = function (foldMode) {\n if (this.$foldMode == foldMode)\n return;\n this.$foldMode = foldMode;\n this.off('change', this.$updateFoldWidgets);\n this.off('tokenizerUpdate', this.$tokenizerUpdateFoldWidgets);\n this._signal(\"changeAnnotation\");\n if (!foldMode || this.$foldStyle == \"manual\") {\n this.foldWidgets = null;\n return;\n }\n this.foldWidgets = [];\n this.getFoldWidget = foldMode.getFoldWidget.bind(foldMode, this, this.$foldStyle);\n this.getFoldWidgetRange = foldMode.getFoldWidgetRange.bind(foldMode, this, this.$foldStyle);\n this.$updateFoldWidgets = this.updateFoldWidgets.bind(this);\n this.$tokenizerUpdateFoldWidgets = this.tokenizerUpdateFoldWidgets.bind(this);\n this.on('change', this.$updateFoldWidgets);\n this.on('tokenizerUpdate', this.$tokenizerUpdateFoldWidgets);\n };\n this.getParentFoldRangeData = function (row, ignoreCurrent) {\n var fw = this.foldWidgets;\n if (!fw || (ignoreCurrent && fw[row]))\n return {};\n var i = row - 1, firstRange;\n while (i >= 0) {\n var c = fw[i];\n if (c == null)\n c = fw[i] = this.getFoldWidget(i);\n if (c == \"start\") {\n var range = this.getFoldWidgetRange(i);\n if (!firstRange)\n firstRange = range;\n if (range && range.end.row >= row)\n break;\n }\n i--;\n }\n return {\n range: i !== -1 && range,\n firstRange: firstRange\n };\n };\n this.onFoldWidgetClick = function (row, e) {\n if (e instanceof MouseEvent)\n e = e.domEvent;\n var options = {\n children: e.shiftKey,\n all: e.ctrlKey || e.metaKey,\n siblings: e.altKey\n };\n var range = this.$toggleFoldWidget(row, options);\n if (!range) {\n var el = (e.target || e.srcElement);\n if (el && /ace_fold-widget/.test(el.className))\n el.className += \" ace_invalid\";\n }\n };\n this.$toggleFoldWidget = function (row, options) {\n if (!this.getFoldWidget)\n return;\n var type = this.getFoldWidget(row);\n var line = this.getLine(row);\n var dir = type === \"end\" ? -1 : 1;\n var fold = this.getFoldAt(row, dir === -1 ? 0 : line.length, dir);\n if (fold) {\n if (options.children || options.all)\n this.removeFold(fold);\n else\n this.expandFold(fold);\n return fold;\n }\n var range = this.getFoldWidgetRange(row, true);\n if (range && !range.isMultiLine()) {\n fold = this.getFoldAt(range.start.row, range.start.column, 1);\n if (fold && range.isEqual(fold.range)) {\n this.removeFold(fold);\n return fold;\n }\n }\n if (options.siblings) {\n var data = this.getParentFoldRangeData(row);\n if (data.range) {\n var startRow = data.range.start.row + 1;\n var endRow = data.range.end.row;\n }\n this.foldAll(startRow, endRow, options.all ? 10000 : 0);\n }\n else if (options.children) {\n endRow = range ? range.end.row : this.getLength();\n this.foldAll(row + 1, endRow, options.all ? 10000 : 0);\n }\n else if (range) {\n if (options.all)\n range.collapseChildren = 10000;\n this.addFold(\"...\", range);\n }\n return range;\n };\n this.toggleFoldWidget = function (toggleParent) {\n var row = this.selection.getCursor().row;\n row = this.getRowFoldStart(row);\n var range = this.$toggleFoldWidget(row, {});\n if (range)\n return;\n var data = this.getParentFoldRangeData(row, true);\n range = data.range || data.firstRange;\n if (range) {\n row = range.start.row;\n var fold = this.getFoldAt(row, this.getLine(row).length, 1);\n if (fold) {\n this.removeFold(fold);\n }\n else {\n this.addFold(\"...\", range);\n }\n }\n };\n this.updateFoldWidgets = function (delta) {\n var firstRow = delta.start.row;\n var len = delta.end.row - firstRow;\n if (len === 0) {\n this.foldWidgets[firstRow] = null;\n }\n else if (delta.action == 'remove') {\n this.foldWidgets.splice(firstRow, len + 1, null);\n }\n else {\n var args = Array(len + 1);\n args.unshift(firstRow, 1);\n this.foldWidgets.splice.apply(this.foldWidgets, args);\n }\n };\n this.tokenizerUpdateFoldWidgets = function (e) {\n var rows = e.data;\n if (rows.first != rows.last) {\n if (this.foldWidgets.length > rows.first)\n this.foldWidgets.splice(rows.first, this.foldWidgets.length);\n }\n };\n}\nexports.Folding = Folding;\n\n});\n\nace.define(\"ace/edit_session/bracket_match\",[\"require\",\"exports\",\"module\",\"ace/token_iterator\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar TokenIterator = require(\"../token_iterator\").TokenIterator;\nvar Range = require(\"../range\").Range;\nfunction BracketMatch() {\n this.findMatchingBracket = function (position, chr) {\n if (position.column == 0)\n return null;\n var charBeforeCursor = chr || this.getLine(position.row).charAt(position.column - 1);\n if (charBeforeCursor == \"\")\n return null;\n var match = charBeforeCursor.match(/([\\(\\[\\{])|([\\)\\]\\}])/);\n if (!match)\n return null;\n if (match[1])\n return this.$findClosingBracket(match[1], position);\n else\n return this.$findOpeningBracket(match[2], position);\n };\n this.getBracketRange = function (pos) {\n var line = this.getLine(pos.row);\n var before = true, range;\n var chr = line.charAt(pos.column - 1);\n var match = chr && chr.match(/([\\(\\[\\{])|([\\)\\]\\}])/);\n if (!match) {\n chr = line.charAt(pos.column);\n pos = { row: pos.row, column: pos.column + 1 };\n match = chr && chr.match(/([\\(\\[\\{])|([\\)\\]\\}])/);\n before = false;\n }\n if (!match)\n return null;\n if (match[1]) {\n var bracketPos = this.$findClosingBracket(match[1], pos);\n if (!bracketPos)\n return null;\n range = Range.fromPoints(pos, bracketPos);\n if (!before) {\n range.end.column++;\n range.start.column--;\n }\n range.cursor = range.end;\n }\n else {\n var bracketPos = this.$findOpeningBracket(match[2], pos);\n if (!bracketPos)\n return null;\n range = Range.fromPoints(bracketPos, pos);\n if (!before) {\n range.start.column++;\n range.end.column--;\n }\n range.cursor = range.start;\n }\n return range;\n };\n this.getMatchingBracketRanges = function (pos, isBackwards) {\n var line = this.getLine(pos.row);\n var bracketsRegExp = /([\\(\\[\\{])|([\\)\\]\\}])/;\n var chr = !isBackwards && line.charAt(pos.column - 1);\n var match = chr && chr.match(bracketsRegExp);\n if (!match) {\n chr = (isBackwards === undefined || isBackwards) && line.charAt(pos.column);\n pos = {\n row: pos.row,\n column: pos.column + 1\n };\n match = chr && chr.match(bracketsRegExp);\n }\n if (!match)\n return null;\n var startRange = new Range(pos.row, pos.column - 1, pos.row, pos.column);\n var bracketPos = match[1] ? this.$findClosingBracket(match[1], pos)\n : this.$findOpeningBracket(match[2], pos);\n if (!bracketPos)\n return [startRange];\n var endRange = new Range(bracketPos.row, bracketPos.column, bracketPos.row, bracketPos.column + 1);\n return [startRange, endRange];\n };\n this.$brackets = {\n \")\": \"(\",\n \"(\": \")\",\n \"]\": \"[\",\n \"[\": \"]\",\n \"{\": \"}\",\n \"}\": \"{\",\n \"<\": \">\",\n \">\": \"<\"\n };\n this.$findOpeningBracket = function (bracket, position, typeRe) {\n var openBracket = this.$brackets[bracket];\n var depth = 1;\n var iterator = new TokenIterator(this, position.row, position.column);\n var token = iterator.getCurrentToken();\n if (!token)\n token = iterator.stepForward();\n if (!token)\n return;\n if (!typeRe) {\n typeRe = new RegExp(\"(\\\\.?\" +\n token.type.replace(\".\", \"\\\\.\").replace(\"rparen\", \".paren\")\n .replace(/\\b(?:end)\\b/, \"(?:start|begin|end)\")\n .replace(/-close\\b/, \"-(close|open)\")\n + \")+\");\n }\n var valueIndex = position.column - iterator.getCurrentTokenColumn() - 2;\n var value = token.value;\n while (true) {\n while (valueIndex >= 0) {\n var chr = value.charAt(valueIndex);\n if (chr == openBracket) {\n depth -= 1;\n if (depth == 0) {\n return { row: iterator.getCurrentTokenRow(),\n column: valueIndex + iterator.getCurrentTokenColumn() };\n }\n }\n else if (chr == bracket) {\n depth += 1;\n }\n valueIndex -= 1;\n }\n do {\n token = iterator.stepBackward();\n } while (token && !typeRe.test(token.type));\n if (token == null)\n break;\n value = token.value;\n valueIndex = value.length - 1;\n }\n return null;\n };\n this.$findClosingBracket = function (bracket, position, typeRe) {\n var closingBracket = this.$brackets[bracket];\n var depth = 1;\n var iterator = new TokenIterator(this, position.row, position.column);\n var token = iterator.getCurrentToken();\n if (!token)\n token = iterator.stepForward();\n if (!token)\n return;\n if (!typeRe) {\n typeRe = new RegExp(\"(\\\\.?\" +\n token.type.replace(\".\", \"\\\\.\").replace(\"lparen\", \".paren\")\n .replace(/\\b(?:start|begin)\\b/, \"(?:start|begin|end)\")\n .replace(/-open\\b/, \"-(close|open)\")\n + \")+\");\n }\n var valueIndex = position.column - iterator.getCurrentTokenColumn();\n while (true) {\n var value = token.value;\n var valueLength = value.length;\n while (valueIndex < valueLength) {\n var chr = value.charAt(valueIndex);\n if (chr == closingBracket) {\n depth -= 1;\n if (depth == 0) {\n return { row: iterator.getCurrentTokenRow(),\n column: valueIndex + iterator.getCurrentTokenColumn() };\n }\n }\n else if (chr == bracket) {\n depth += 1;\n }\n valueIndex += 1;\n }\n do {\n token = iterator.stepForward();\n } while (token && !typeRe.test(token.type));\n if (token == null)\n break;\n valueIndex = 0;\n }\n return null;\n };\n this.getMatchingTags = function (pos) {\n var iterator = new TokenIterator(this, pos.row, pos.column);\n var token = this.$findTagName(iterator);\n if (!token)\n return;\n var prevToken = iterator.stepBackward();\n if (prevToken.value === '<') {\n return this.$findClosingTag(iterator, token);\n }\n else {\n return this.$findOpeningTag(iterator, token);\n }\n };\n this.$findTagName = function (iterator) {\n var token = iterator.getCurrentToken();\n var found = false;\n var backward = false;\n if (token && token.type.indexOf('tag-name') === -1) {\n do {\n if (backward)\n token = iterator.stepBackward();\n else\n token = iterator.stepForward();\n if (token) {\n if (token.value === \"/>\") {\n backward = true;\n }\n else if (token.type.indexOf('tag-name') !== -1) {\n found = true;\n }\n }\n } while (token && !found);\n }\n return token;\n };\n this.$findClosingTag = function (iterator, token) {\n var prevToken;\n var currentTag = token.value;\n var tag = token.value;\n var depth = 0;\n var openTagStart = new Range(iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn(), iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn() + 1);\n token = iterator.stepForward();\n var openTagName = new Range(iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn(), iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn() + token.value.length);\n var foundOpenTagEnd = false;\n do {\n prevToken = token;\n if (prevToken.type.indexOf('tag-close') !== -1 && !foundOpenTagEnd) {\n var openTagEnd = new Range(iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn(), iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn() + 1); //Range for `>`\n foundOpenTagEnd = true;\n }\n token = iterator.stepForward();\n if (token) {\n if (token.value === '>' && !foundOpenTagEnd) {\n var openTagEnd = new Range(iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn(), iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn() + 1); //Range for `>`\n foundOpenTagEnd = true;\n }\n if (token.type.indexOf('tag-name') !== -1) {\n currentTag = token.value;\n if (tag === currentTag) {\n if (prevToken.value === '<') {\n depth++;\n }\n else if (prevToken.value === '') {\n var closeTagEnd = new Range(iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn(), iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn() + 1); //Range for >\n }\n else {\n return;\n }\n }\n }\n }\n }\n else if (tag === currentTag && token.value === '/>') { // self-closing tag\n depth--;\n if (depth < 0) { //found self-closing tag end\n var closeTagStart = new Range(iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn(), iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn() + 2);\n var closeTagName = closeTagStart;\n var closeTagEnd = closeTagName;\n var openTagEnd = new Range(openTagName.end.row, openTagName.end.column, openTagName.end.row, openTagName.end.column + 1);\n }\n }\n }\n } while (token && depth >= 0);\n if (openTagStart && openTagEnd && closeTagStart && closeTagEnd && openTagName && closeTagName) {\n return {\n openTag: new Range(openTagStart.start.row, openTagStart.start.column, openTagEnd.end.row, openTagEnd.end.column),\n closeTag: new Range(closeTagStart.start.row, closeTagStart.start.column, closeTagEnd.end.row, closeTagEnd.end.column),\n openTagName: openTagName,\n closeTagName: closeTagName\n };\n }\n };\n this.$findOpeningTag = function (iterator, token) {\n var prevToken = iterator.getCurrentToken();\n var tag = token.value;\n var depth = 0;\n var startRow = iterator.getCurrentTokenRow();\n var startColumn = iterator.getCurrentTokenColumn();\n var endColumn = startColumn + 2;\n var closeTagStart = new Range(startRow, startColumn, startRow, endColumn); //Range for \")\n return;\n var closeTagEnd = new Range(iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn(), iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn() + 1); //Range for >\n iterator.stepBackward();\n iterator.stepBackward();\n do {\n token = prevToken;\n startRow = iterator.getCurrentTokenRow();\n startColumn = iterator.getCurrentTokenColumn();\n endColumn = startColumn + token.value.length;\n prevToken = iterator.stepBackward();\n if (token) {\n if (token.type.indexOf('tag-name') !== -1) {\n if (tag === token.value) {\n if (prevToken.value === '<') {\n depth++;\n if (depth > 0) { //found opening tag\n var openTagName = new Range(startRow, startColumn, startRow, endColumn);\n var openTagStart = new Range(iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn(), iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn() + 1); //Range for <\n do {\n token = iterator.stepForward();\n } while (token && token.value !== '>');\n var openTagEnd = new Range(iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn(), iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn() + 1); //Range for >\n }\n }\n else if (prevToken.value === '') { // self-closing tag\n var stepCount = 0;\n var tmpToken = prevToken;\n while (tmpToken) {\n if (tmpToken.type.indexOf('tag-name') !== -1 && tmpToken.value === tag) {\n depth--;\n break;\n }\n else if (tmpToken.value === '<') {\n break;\n }\n tmpToken = iterator.stepBackward();\n stepCount++;\n }\n for (var i = 0; i < stepCount; i++) {\n iterator.stepForward();\n }\n }\n }\n } while (prevToken && depth <= 0);\n if (openTagStart && openTagEnd && closeTagStart && closeTagEnd && openTagName && closeTagName) {\n return {\n openTag: new Range(openTagStart.start.row, openTagStart.start.column, openTagEnd.end.row, openTagEnd.end.column),\n closeTag: new Range(closeTagStart.start.row, closeTagStart.start.column, closeTagEnd.end.row, closeTagEnd.end.column),\n openTagName: openTagName,\n closeTagName: closeTagName\n };\n }\n };\n}\nexports.BracketMatch = BracketMatch;\n\n});\n\nace.define(\"ace/edit_session\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/lang\",\"ace/bidihandler\",\"ace/config\",\"ace/lib/event_emitter\",\"ace/selection\",\"ace/mode/text\",\"ace/range\",\"ace/line_widgets\",\"ace/document\",\"ace/background_tokenizer\",\"ace/search_highlight\",\"ace/undomanager\",\"ace/edit_session/folding\",\"ace/edit_session/bracket_match\"], function(require, exports, module){\"use strict\";\nvar oop = require(\"./lib/oop\");\nvar lang = require(\"./lib/lang\");\nvar BidiHandler = require(\"./bidihandler\").BidiHandler;\nvar config = require(\"./config\");\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar Selection = require(\"./selection\").Selection;\nvar TextMode = require(\"./mode/text\").Mode;\nvar Range = require(\"./range\").Range;\nvar LineWidgets = require(\"./line_widgets\").LineWidgets;\nvar Document = require(\"./document\").Document;\nvar BackgroundTokenizer = require(\"./background_tokenizer\").BackgroundTokenizer;\nvar SearchHighlight = require(\"./search_highlight\").SearchHighlight;\nvar UndoManager = require(\"./undomanager\").UndoManager;\nvar EditSession = /** @class */ (function () {\n function EditSession(text, mode) { this.doc;\n this.$breakpoints = [];\n this.$decorations = [];\n this.$frontMarkers = {};\n this.$backMarkers = {};\n this.$markerId = 1;\n this.$undoSelect = true;\n this.$editor = null;\n this.prevOp = {};\n this.$foldData = [];\n this.id = \"session\" + (++EditSession.$uid);\n this.$foldData.toString = function () {\n return this.join(\"\\n\");\n };\n this.bgTokenizer = new BackgroundTokenizer((new TextMode()).getTokenizer(), this);\n var _self = this;\n this.bgTokenizer.on(\"update\", function (e) {\n _self._signal(\"tokenizerUpdate\", e);\n });\n this.on(\"changeFold\", this.onChangeFold.bind(this));\n this.$onChange = this.onChange.bind(this);\n if (typeof text != \"object\" || !text.getLine)\n text = new Document(/**@type{string}*/ (text));\n this.setDocument(text);\n this.selection = new Selection(this);\n this.$onSelectionChange = this.onSelectionChange.bind(this);\n this.selection.on(\"changeSelection\", this.$onSelectionChange);\n this.selection.on(\"changeCursor\", this.$onSelectionChange);\n this.$bidiHandler = new BidiHandler(this);\n config.resetOptions(this);\n this.setMode(mode);\n config._signal(\"session\", this);\n this.destroyed = false;\n this.$initOperationListeners();\n }\n EditSession.prototype.$initOperationListeners = function () {\n var _this = this;\n this.curOp = null;\n this.on(\"change\", function () {\n if (!_this.curOp) {\n _this.startOperation();\n _this.curOp.selectionBefore = _this.$lastSel;\n }\n _this.curOp.docChanged = true;\n }, true);\n this.on(\"changeSelection\", function () {\n if (!_this.curOp) {\n _this.startOperation();\n _this.curOp.selectionBefore = _this.$lastSel;\n }\n _this.curOp.selectionChanged = true;\n }, true);\n this.$operationResetTimer = lang.delayedCall(this.endOperation.bind(this, true));\n };\n EditSession.prototype.startOperation = function (commandEvent) {\n if (this.curOp) {\n if (!commandEvent || this.curOp.command) {\n return;\n }\n this.prevOp = this.curOp;\n }\n if (!commandEvent) {\n commandEvent = {};\n }\n this.$operationResetTimer.schedule();\n this.curOp = {\n command: commandEvent.command || {},\n args: commandEvent.args\n };\n this.curOp.selectionBefore = this.selection.toJSON();\n this._signal(\"startOperation\", commandEvent);\n };\n EditSession.prototype.endOperation = function (e) {\n if (this.curOp) {\n if (e && e.returnValue === false) {\n this.curOp = null;\n this._signal(\"endOperation\", e);\n return;\n }\n if (e == true && this.curOp.command && this.curOp.command.name == \"mouse\") {\n return;\n }\n var currentSelection = this.selection.toJSON();\n this.curOp.selectionAfter = currentSelection;\n this.$lastSel = this.selection.toJSON();\n this.getUndoManager().addSelection(currentSelection);\n this._signal(\"beforeEndOperation\");\n this.prevOp = this.curOp;\n this.curOp = null;\n this._signal(\"endOperation\", e);\n }\n };\n EditSession.prototype.setDocument = function (doc) {\n if (this.doc)\n this.doc.off(\"change\", this.$onChange);\n this.doc = doc;\n doc.on(\"change\", this.$onChange, true);\n this.bgTokenizer.setDocument(this.getDocument());\n this.resetCaches();\n };\n EditSession.prototype.getDocument = function () {\n return this.doc;\n };\n Object.defineProperty(EditSession.prototype, \"widgetManager\", {\n get: function () {\n var widgetManager = new LineWidgets(this);\n this.widgetManager = widgetManager;\n if (this.$editor)\n widgetManager.attach(this.$editor);\n return widgetManager;\n },\n set: function (value) {\n Object.defineProperty(this, \"widgetManager\", {\n writable: true,\n enumerable: true,\n configurable: true,\n value: value,\n });\n },\n enumerable: false,\n configurable: true\n });\n EditSession.prototype.$resetRowCache = function (docRow) {\n if (!docRow) {\n this.$docRowCache = [];\n this.$screenRowCache = [];\n return;\n }\n var l = this.$docRowCache.length;\n var i = this.$getRowCacheIndex(this.$docRowCache, docRow) + 1;\n if (l > i) {\n this.$docRowCache.splice(i, l);\n this.$screenRowCache.splice(i, l);\n }\n };\n EditSession.prototype.$getRowCacheIndex = function (cacheArray, val) {\n var low = 0;\n var hi = cacheArray.length - 1;\n while (low <= hi) {\n var mid = (low + hi) >> 1;\n var c = cacheArray[mid];\n if (val > c)\n low = mid + 1;\n else if (val < c)\n hi = mid - 1;\n else\n return mid;\n }\n return low - 1;\n };\n EditSession.prototype.resetCaches = function () {\n this.$modified = true;\n this.$wrapData = [];\n this.$rowLengthCache = [];\n this.$resetRowCache(0);\n if (!this.destroyed)\n this.bgTokenizer.start(0);\n };\n EditSession.prototype.onChangeFold = function (e) {\n var fold = e.data;\n this.$resetRowCache(fold.start.row);\n };\n EditSession.prototype.onChange = function (delta) {\n this.$modified = true;\n this.$bidiHandler.onChange(delta);\n this.$resetRowCache(delta.start.row);\n var removedFolds = this.$updateInternalDataOnChange(delta);\n if (!this.$fromUndo && this.$undoManager) {\n if (removedFolds && removedFolds.length) {\n this.$undoManager.add({\n action: \"removeFolds\",\n folds: removedFolds\n }, this.mergeUndoDeltas);\n this.mergeUndoDeltas = true;\n }\n this.$undoManager.add(delta, this.mergeUndoDeltas);\n this.mergeUndoDeltas = true;\n this.$informUndoManager.schedule();\n }\n this.bgTokenizer.$updateOnChange(delta);\n this._signal(\"change\", delta);\n };\n EditSession.prototype.onSelectionChange = function () {\n this._signal(\"changeSelection\");\n };\n EditSession.prototype.setValue = function (text) {\n this.doc.setValue(text);\n this.selection.moveTo(0, 0);\n this.$resetRowCache(0);\n this.setUndoManager(this.$undoManager);\n this.getUndoManager().reset();\n };\n EditSession.fromJSON = function (session) {\n if (typeof session == \"string\")\n session = JSON.parse(session);\n var undoManager = new UndoManager();\n undoManager.$undoStack = session.history.undo;\n undoManager.$redoStack = session.history.redo;\n undoManager.mark = session.history.mark;\n undoManager.$rev = session.history.rev;\n var editSession = new EditSession(session.value);\n session.folds.forEach(function (fold) {\n editSession.addFold(\"...\", Range.fromPoints(fold.start, fold.end));\n });\n editSession.setAnnotations(session.annotations);\n editSession.setBreakpoints(session.breakpoints);\n editSession.setMode(session.mode);\n editSession.setScrollLeft(session.scrollLeft);\n editSession.setScrollTop(session.scrollTop);\n editSession.setUndoManager(undoManager);\n editSession.selection.fromJSON(session.selection);\n return editSession;\n };\n EditSession.prototype.toJSON = function () {\n return {\n annotations: this.$annotations,\n breakpoints: this.$breakpoints,\n folds: this.getAllFolds().map(function (fold) {\n return fold.range;\n }),\n history: this.getUndoManager(),\n mode: this.$mode.$id,\n scrollLeft: this.$scrollLeft,\n scrollTop: this.$scrollTop,\n selection: this.selection.toJSON(),\n value: this.doc.getValue()\n };\n };\n EditSession.prototype.toString = function () {\n return this.doc.getValue();\n };\n EditSession.prototype.getSelection = function () {\n return this.selection;\n };\n EditSession.prototype.getState = function (row) {\n return this.bgTokenizer.getState(row);\n };\n EditSession.prototype.getTokens = function (row) {\n return this.bgTokenizer.getTokens(row);\n };\n EditSession.prototype.getTokenAt = function (row, column) {\n var tokens = this.bgTokenizer.getTokens(row);\n var token, c = 0;\n if (column == null) {\n var i = tokens.length - 1;\n c = this.getLine(row).length;\n }\n else {\n for (var i = 0; i < tokens.length; i++) {\n c += tokens[i].value.length;\n if (c >= column)\n break;\n }\n }\n token = tokens[i];\n if (!token)\n return null;\n token.index = i;\n token.start = c - token.value.length;\n return token;\n };\n EditSession.prototype.setUndoManager = function (undoManager) {\n this.$undoManager = undoManager;\n if (this.$informUndoManager)\n this.$informUndoManager.cancel();\n if (undoManager) {\n var self = this;\n undoManager.addSession(this);\n this.$syncInformUndoManager = function () {\n self.$informUndoManager.cancel();\n self.mergeUndoDeltas = false;\n };\n this.$informUndoManager = lang.delayedCall(this.$syncInformUndoManager);\n }\n else {\n this.$syncInformUndoManager = function () { };\n }\n };\n EditSession.prototype.markUndoGroup = function () {\n if (this.$syncInformUndoManager)\n this.$syncInformUndoManager();\n };\n EditSession.prototype.getUndoManager = function () {\n return this.$undoManager || this.$defaultUndoManager;\n };\n EditSession.prototype.getTabString = function () {\n if (this.getUseSoftTabs()) {\n return lang.stringRepeat(\" \", this.getTabSize());\n }\n else {\n return \"\\t\";\n }\n };\n EditSession.prototype.setUseSoftTabs = function (val) {\n this.setOption(\"useSoftTabs\", val);\n };\n EditSession.prototype.getUseSoftTabs = function () {\n return this.$useSoftTabs && !this.$mode.$indentWithTabs;\n };\n EditSession.prototype.setTabSize = function (tabSize) {\n this.setOption(\"tabSize\", tabSize);\n };\n EditSession.prototype.getTabSize = function () {\n return this.$tabSize;\n };\n EditSession.prototype.isTabStop = function (position) {\n return this.$useSoftTabs && (position.column % this.$tabSize === 0);\n };\n EditSession.prototype.setNavigateWithinSoftTabs = function (navigateWithinSoftTabs) {\n this.setOption(\"navigateWithinSoftTabs\", navigateWithinSoftTabs);\n };\n EditSession.prototype.getNavigateWithinSoftTabs = function () {\n return this.$navigateWithinSoftTabs;\n };\n EditSession.prototype.setOverwrite = function (overwrite) {\n this.setOption(\"overwrite\", overwrite);\n };\n EditSession.prototype.getOverwrite = function () {\n return this.$overwrite;\n };\n EditSession.prototype.toggleOverwrite = function () {\n this.setOverwrite(!this.$overwrite);\n };\n EditSession.prototype.addGutterDecoration = function (row, className) {\n if (!this.$decorations[row])\n this.$decorations[row] = \"\";\n this.$decorations[row] += \" \" + className;\n this._signal(\"changeBreakpoint\", {});\n };\n EditSession.prototype.removeGutterDecoration = function (row, className) {\n this.$decorations[row] = (this.$decorations[row] || \"\").replace(\" \" + className, \"\");\n this._signal(\"changeBreakpoint\", {});\n };\n EditSession.prototype.getBreakpoints = function () {\n return this.$breakpoints;\n };\n EditSession.prototype.setBreakpoints = function (rows) {\n this.$breakpoints = [];\n for (var i = 0; i < rows.length; i++) {\n this.$breakpoints[rows[i]] = \"ace_breakpoint\";\n }\n this._signal(\"changeBreakpoint\", {});\n };\n EditSession.prototype.clearBreakpoints = function () {\n this.$breakpoints = [];\n this._signal(\"changeBreakpoint\", {});\n };\n EditSession.prototype.setBreakpoint = function (row, className) {\n if (className === undefined)\n className = \"ace_breakpoint\";\n if (className)\n this.$breakpoints[row] = className;\n else\n delete this.$breakpoints[row];\n this._signal(\"changeBreakpoint\", {});\n };\n EditSession.prototype.clearBreakpoint = function (row) {\n delete this.$breakpoints[row];\n this._signal(\"changeBreakpoint\", {});\n };\n EditSession.prototype.addMarker = function (range, clazz, type, inFront) {\n var id = this.$markerId++;\n var marker = {\n range: range,\n type: type || \"line\",\n renderer: typeof type == \"function\" ? type : null,\n clazz: clazz,\n inFront: !!inFront,\n id: id\n };\n if (inFront) {\n this.$frontMarkers[id] = marker;\n this._signal(\"changeFrontMarker\");\n }\n else {\n this.$backMarkers[id] = marker;\n this._signal(\"changeBackMarker\");\n }\n return id;\n };\n EditSession.prototype.addDynamicMarker = function (marker, inFront) {\n if (!marker.update)\n return;\n var id = this.$markerId++;\n marker.id = id;\n marker.inFront = !!inFront;\n if (inFront) {\n this.$frontMarkers[id] = marker;\n this._signal(\"changeFrontMarker\");\n }\n else {\n this.$backMarkers[id] = marker;\n this._signal(\"changeBackMarker\");\n }\n return marker;\n };\n EditSession.prototype.removeMarker = function (markerId) {\n var marker = this.$frontMarkers[markerId] || this.$backMarkers[markerId];\n if (!marker)\n return;\n var markers = marker.inFront ? this.$frontMarkers : this.$backMarkers;\n delete (markers[markerId]);\n this._signal(marker.inFront ? \"changeFrontMarker\" : \"changeBackMarker\");\n };\n EditSession.prototype.getMarkers = function (inFront) {\n return inFront ? this.$frontMarkers : this.$backMarkers;\n };\n EditSession.prototype.highlight = function (re) {\n if (!this.$searchHighlight) {\n var highlight = new SearchHighlight(null, \"ace_selected-word\", \"text\");\n this.$searchHighlight = this.addDynamicMarker(highlight);\n }\n this.$searchHighlight.setRegexp(re);\n };\n EditSession.prototype.highlightLines = function (startRow, endRow, clazz, inFront) {\n if (typeof endRow != \"number\") {\n clazz = endRow;\n endRow = startRow;\n }\n if (!clazz)\n clazz = \"ace_step\";\n var range = new Range(startRow, 0, endRow, Infinity);\n range.id = this.addMarker(range, clazz, \"fullLine\", inFront);\n return range;\n };\n EditSession.prototype.setAnnotations = function (annotations) {\n this.$annotations = annotations;\n this._signal(\"changeAnnotation\", {});\n };\n EditSession.prototype.getAnnotations = function () {\n return this.$annotations || [];\n };\n EditSession.prototype.clearAnnotations = function () {\n this.setAnnotations([]);\n };\n EditSession.prototype.$detectNewLine = function (text) {\n var match = text.match(/^.*?(\\r?\\n)/m);\n if (match) {\n this.$autoNewLine = match[1];\n }\n else {\n this.$autoNewLine = \"\\n\";\n }\n };\n EditSession.prototype.getWordRange = function (row, column) {\n var line = this.getLine(row);\n var inToken = false;\n if (column > 0)\n inToken = !!line.charAt(column - 1).match(this.tokenRe);\n if (!inToken)\n inToken = !!line.charAt(column).match(this.tokenRe);\n if (inToken)\n var re = this.tokenRe;\n else if (/^\\s+$/.test(line.slice(column - 1, column + 1)))\n var re = /\\s/;\n else\n var re = this.nonTokenRe;\n var start = column;\n if (start > 0) {\n do {\n start--;\n } while (start >= 0 && line.charAt(start).match(re));\n start++;\n }\n var end = column;\n while (end < line.length && line.charAt(end).match(re)) {\n end++;\n }\n return new Range(row, start, row, end);\n };\n EditSession.prototype.getAWordRange = function (row, column) {\n var wordRange = this.getWordRange(row, column);\n var line = this.getLine(wordRange.end.row);\n while (line.charAt(wordRange.end.column).match(/[ \\t]/)) {\n wordRange.end.column += 1;\n }\n return wordRange;\n };\n EditSession.prototype.setNewLineMode = function (newLineMode) {\n this.doc.setNewLineMode(newLineMode);\n };\n EditSession.prototype.getNewLineMode = function () {\n return this.doc.getNewLineMode();\n };\n EditSession.prototype.setUseWorker = function (useWorker) { this.setOption(\"useWorker\", useWorker); };\n EditSession.prototype.getUseWorker = function () { return this.$useWorker; };\n EditSession.prototype.onReloadTokenizer = function (e) {\n var rows = e.data;\n this.bgTokenizer.start(rows.first);\n this._signal(\"tokenizerUpdate\", e);\n };\n EditSession.prototype.setMode = function (mode, cb) {\n if (mode && typeof mode === \"object\") {\n if (mode.getTokenizer)\n return this.$onChangeMode(mode);\n var options = mode;\n var path = options.path;\n }\n else {\n path = /**@type{string}*/ (mode) || \"ace/mode/text\";\n }\n if (!this.$modes[\"ace/mode/text\"])\n this.$modes[\"ace/mode/text\"] = new TextMode();\n if (this.$modes[path] && !options) {\n this.$onChangeMode(this.$modes[path]);\n cb && cb();\n return;\n }\n this.$modeId = path;\n config.loadModule([\"mode\", path], function (m) {\n if (this.$modeId !== path)\n return cb && cb();\n if (this.$modes[path] && !options) {\n this.$onChangeMode(this.$modes[path]);\n }\n else if (m && m.Mode) {\n m = new m.Mode(options);\n if (!options) {\n this.$modes[path] = m;\n m.$id = path;\n }\n this.$onChangeMode(m);\n }\n cb && cb();\n }.bind(this));\n if (!this.$mode)\n this.$onChangeMode(this.$modes[\"ace/mode/text\"], true);\n };\n EditSession.prototype.$onChangeMode = function (mode, $isPlaceholder) {\n if (!$isPlaceholder)\n this.$modeId = mode.$id;\n if (this.$mode === mode)\n return;\n var oldMode = this.$mode;\n this.$mode = mode;\n this.$stopWorker();\n if (this.$useWorker)\n this.$startWorker();\n var tokenizer = mode.getTokenizer();\n if (tokenizer.on !== undefined) {\n var onReloadTokenizer = this.onReloadTokenizer.bind(this);\n tokenizer.on(\"update\", onReloadTokenizer);\n }\n this.bgTokenizer.setTokenizer(tokenizer);\n this.bgTokenizer.setDocument(this.getDocument());\n this.tokenRe = mode.tokenRe;\n this.nonTokenRe = mode.nonTokenRe;\n if (!$isPlaceholder) {\n if (mode.attachToSession)\n mode.attachToSession(this);\n this.$options.wrapMethod.set.call(this, this.$wrapMethod);\n this.$setFolding(mode.foldingRules);\n this.bgTokenizer.start(0);\n this._emit(\"changeMode\", { oldMode: oldMode, mode: mode });\n }\n };\n EditSession.prototype.$stopWorker = function () {\n if (this.$worker) {\n this.$worker.terminate();\n this.$worker = null;\n }\n };\n EditSession.prototype.$startWorker = function () {\n try {\n this.$worker = this.$mode.createWorker(this);\n }\n catch (e) {\n config.warn(\"Could not load worker\", e);\n this.$worker = null;\n }\n };\n EditSession.prototype.getMode = function () {\n return this.$mode;\n };\n EditSession.prototype.setScrollTop = function (scrollTop) {\n if (this.$scrollTop === scrollTop || isNaN(scrollTop))\n return;\n this.$scrollTop = scrollTop;\n this._signal(\"changeScrollTop\", scrollTop);\n };\n EditSession.prototype.getScrollTop = function () {\n return this.$scrollTop;\n };\n EditSession.prototype.setScrollLeft = function (scrollLeft) {\n if (this.$scrollLeft === scrollLeft || isNaN(scrollLeft))\n return;\n this.$scrollLeft = scrollLeft;\n this._signal(\"changeScrollLeft\", scrollLeft);\n };\n EditSession.prototype.getScrollLeft = function () {\n return this.$scrollLeft;\n };\n EditSession.prototype.getScreenWidth = function () {\n this.$computeWidth();\n if (this.lineWidgets)\n return Math.max(this.getLineWidgetMaxWidth(), this.screenWidth);\n return this.screenWidth;\n };\n EditSession.prototype.getLineWidgetMaxWidth = function () {\n if (this.lineWidgetsWidth != null)\n return this.lineWidgetsWidth;\n var width = 0;\n this.lineWidgets.forEach(function (w) {\n if (w && w.screenWidth > width)\n width = w.screenWidth;\n });\n return this.lineWidgetWidth = width;\n };\n EditSession.prototype.$computeWidth = function (force) {\n if (this.$modified || force) {\n this.$modified = false;\n if (this.$useWrapMode)\n return this.screenWidth = this.$wrapLimit;\n var lines = this.doc.getAllLines();\n var cache = this.$rowLengthCache;\n var longestScreenLine = 0;\n var foldIndex = 0;\n var foldLine = this.$foldData[foldIndex];\n var foldStart = foldLine ? foldLine.start.row : Infinity;\n var len = lines.length;\n for (var i = 0; i < len; i++) {\n if (i > foldStart) {\n i = foldLine.end.row + 1;\n if (i >= len)\n break;\n foldLine = this.$foldData[foldIndex++];\n foldStart = foldLine ? foldLine.start.row : Infinity;\n }\n if (cache[i] == null)\n cache[i] = this.$getStringScreenWidth(lines[i])[0];\n if (cache[i] > longestScreenLine)\n longestScreenLine = cache[i];\n }\n this.screenWidth = longestScreenLine;\n }\n };\n EditSession.prototype.getLine = function (row) {\n return this.doc.getLine(row);\n };\n EditSession.prototype.getLines = function (firstRow, lastRow) {\n return this.doc.getLines(firstRow, lastRow);\n };\n EditSession.prototype.getLength = function () {\n return this.doc.getLength();\n };\n EditSession.prototype.getTextRange = function (range) {\n return this.doc.getTextRange(range || this.selection.getRange());\n };\n EditSession.prototype.insert = function (position, text) {\n return this.doc.insert(position, text);\n };\n EditSession.prototype.remove = function (range) {\n return this.doc.remove(range);\n };\n EditSession.prototype.removeFullLines = function (firstRow, lastRow) {\n return this.doc.removeFullLines(firstRow, lastRow);\n };\n EditSession.prototype.undoChanges = function (deltas, dontSelect) {\n if (!deltas.length)\n return;\n this.$fromUndo = true;\n for (var i = deltas.length - 1; i != -1; i--) {\n var delta = deltas[i];\n if (delta.action == \"insert\" || delta.action == \"remove\") {\n this.doc.revertDelta(delta);\n }\n else if (delta.folds) {\n this.addFolds(delta.folds);\n }\n }\n if (!dontSelect && this.$undoSelect) {\n if (deltas.selectionBefore)\n this.selection.fromJSON(deltas.selectionBefore);\n else\n this.selection.setRange(this.$getUndoSelection(deltas, true));\n }\n this.$fromUndo = false;\n };\n EditSession.prototype.redoChanges = function (deltas, dontSelect) {\n if (!deltas.length)\n return;\n this.$fromUndo = true;\n for (var i = 0; i < deltas.length; i++) {\n var delta = deltas[i];\n if (delta.action == \"insert\" || delta.action == \"remove\") {\n this.doc.$safeApplyDelta(delta);\n }\n }\n if (!dontSelect && this.$undoSelect) {\n if (deltas.selectionAfter)\n this.selection.fromJSON(deltas.selectionAfter);\n else\n this.selection.setRange(this.$getUndoSelection(deltas, false));\n }\n this.$fromUndo = false;\n };\n EditSession.prototype.setUndoSelect = function (enable) {\n this.$undoSelect = enable;\n };\n EditSession.prototype.$getUndoSelection = function (deltas, isUndo) {\n function isInsert(delta) {\n return isUndo ? delta.action !== \"insert\" : delta.action === \"insert\";\n }\n var range, point;\n for (var i = 0; i < deltas.length; i++) {\n var delta = deltas[i];\n if (!delta.start)\n continue; // skip folds\n if (!range) {\n if (isInsert(delta)) {\n range = Range.fromPoints(delta.start, delta.end);\n }\n else {\n range = Range.fromPoints(delta.start, delta.start);\n }\n continue;\n }\n if (isInsert(delta)) {\n point = delta.start;\n if (range.compare(point.row, point.column) == -1) {\n range.setStart(point);\n }\n point = delta.end;\n if (range.compare(point.row, point.column) == 1) {\n range.setEnd(point);\n }\n }\n else {\n point = delta.start;\n if (range.compare(point.row, point.column) == -1) {\n range = Range.fromPoints(delta.start, delta.start);\n }\n }\n }\n return range;\n };\n EditSession.prototype.replace = function (range, text) {\n return this.doc.replace(range, text);\n };\n EditSession.prototype.moveText = function (fromRange, toPosition, copy) {\n var text = this.getTextRange(fromRange);\n var folds = this.getFoldsInRange(fromRange);\n var toRange = Range.fromPoints(toPosition, toPosition);\n if (!copy) {\n this.remove(fromRange);\n var rowDiff = fromRange.start.row - fromRange.end.row;\n var collDiff = rowDiff ? -fromRange.end.column : fromRange.start.column - fromRange.end.column;\n if (collDiff) {\n if (toRange.start.row == fromRange.end.row && toRange.start.column > fromRange.end.column)\n toRange.start.column += collDiff;\n if (toRange.end.row == fromRange.end.row && toRange.end.column > fromRange.end.column)\n toRange.end.column += collDiff;\n }\n if (rowDiff && toRange.start.row >= fromRange.end.row) {\n toRange.start.row += rowDiff;\n toRange.end.row += rowDiff;\n }\n }\n toRange.end = this.insert(toRange.start, text);\n if (folds.length) {\n var oldStart = fromRange.start;\n var newStart = toRange.start;\n var rowDiff = newStart.row - oldStart.row;\n var collDiff = newStart.column - oldStart.column;\n this.addFolds(folds.map(function (x) {\n x = x.clone();\n if (x.start.row == oldStart.row)\n x.start.column += collDiff;\n if (x.end.row == oldStart.row)\n x.end.column += collDiff;\n x.start.row += rowDiff;\n x.end.row += rowDiff;\n return x;\n }));\n }\n return toRange;\n };\n EditSession.prototype.indentRows = function (startRow, endRow, indentString) {\n indentString = indentString.replace(/\\t/g, this.getTabString());\n for (var row = startRow; row <= endRow; row++)\n this.doc.insertInLine({ row: row, column: 0 }, indentString);\n };\n EditSession.prototype.outdentRows = function (range) {\n var rowRange = range.collapseRows();\n var deleteRange = new Range(0, 0, 0, 0);\n var size = this.getTabSize();\n for (var i = rowRange.start.row; i <= rowRange.end.row; ++i) {\n var line = this.getLine(i);\n deleteRange.start.row = i;\n deleteRange.end.row = i;\n for (var j = 0; j < size; ++j)\n if (line.charAt(j) != ' ')\n break;\n if (j < size && line.charAt(j) == '\\t') {\n deleteRange.start.column = j;\n deleteRange.end.column = j + 1;\n }\n else {\n deleteRange.start.column = 0;\n deleteRange.end.column = j;\n }\n this.remove(deleteRange);\n }\n };\n EditSession.prototype.$moveLines = function (firstRow, lastRow, dir) {\n firstRow = this.getRowFoldStart(firstRow);\n lastRow = this.getRowFoldEnd(lastRow);\n if (dir < 0) {\n var row = this.getRowFoldStart(firstRow + dir);\n if (row < 0)\n return 0;\n var diff = row - firstRow;\n }\n else if (dir > 0) {\n var row = this.getRowFoldEnd(lastRow + dir);\n if (row > this.doc.getLength() - 1)\n return 0;\n var diff = row - lastRow;\n }\n else {\n firstRow = this.$clipRowToDocument(firstRow);\n lastRow = this.$clipRowToDocument(lastRow);\n var diff = lastRow - firstRow + 1;\n }\n var range = new Range(firstRow, 0, lastRow, Number.MAX_VALUE);\n var folds = this.getFoldsInRange(range).map(function (x) {\n x = x.clone();\n x.start.row += diff;\n x.end.row += diff;\n return x;\n });\n var lines = dir == 0\n ? this.doc.getLines(firstRow, lastRow)\n : this.doc.removeFullLines(firstRow, lastRow);\n this.doc.insertFullLines(firstRow + diff, lines);\n folds.length && this.addFolds(folds);\n return diff;\n };\n EditSession.prototype.moveLinesUp = function (firstRow, lastRow) {\n return this.$moveLines(firstRow, lastRow, -1);\n };\n EditSession.prototype.moveLinesDown = function (firstRow, lastRow) {\n return this.$moveLines(firstRow, lastRow, 1);\n };\n EditSession.prototype.duplicateLines = function (firstRow, lastRow) {\n return this.$moveLines(firstRow, lastRow, 0);\n };\n EditSession.prototype.$clipRowToDocument = function (row) {\n return Math.max(0, Math.min(row, this.doc.getLength() - 1));\n };\n EditSession.prototype.$clipColumnToRow = function (row, column) {\n if (column < 0)\n return 0;\n return Math.min(this.doc.getLine(row).length, column);\n };\n EditSession.prototype.$clipPositionToDocument = function (row, column) {\n column = Math.max(0, column);\n if (row < 0) {\n row = 0;\n column = 0;\n }\n else {\n var len = this.doc.getLength();\n if (row >= len) {\n row = len - 1;\n column = this.doc.getLine(len - 1).length;\n }\n else {\n column = Math.min(this.doc.getLine(row).length, column);\n }\n }\n return {\n row: row,\n column: column\n };\n };\n EditSession.prototype.$clipRangeToDocument = function (range) {\n if (range.start.row < 0) {\n range.start.row = 0;\n range.start.column = 0;\n }\n else {\n range.start.column = this.$clipColumnToRow(range.start.row, range.start.column);\n }\n var len = this.doc.getLength() - 1;\n if (range.end.row > len) {\n range.end.row = len;\n range.end.column = this.doc.getLine(len).length;\n }\n else {\n range.end.column = this.$clipColumnToRow(range.end.row, range.end.column);\n }\n return range;\n };\n EditSession.prototype.setUseWrapMode = function (useWrapMode) {\n if (useWrapMode != this.$useWrapMode) {\n this.$useWrapMode = useWrapMode;\n this.$modified = true;\n this.$resetRowCache(0);\n if (useWrapMode) {\n var len = this.getLength();\n this.$wrapData = Array(len);\n this.$updateWrapData(0, len - 1);\n }\n this._signal(\"changeWrapMode\");\n }\n };\n EditSession.prototype.getUseWrapMode = function () {\n return this.$useWrapMode;\n };\n EditSession.prototype.setWrapLimitRange = function (min, max) {\n if (this.$wrapLimitRange.min !== min || this.$wrapLimitRange.max !== max) {\n this.$wrapLimitRange = { min: min, max: max };\n this.$modified = true;\n this.$bidiHandler.markAsDirty();\n if (this.$useWrapMode)\n this._signal(\"changeWrapMode\");\n }\n };\n EditSession.prototype.adjustWrapLimit = function (desiredLimit, $printMargin) {\n var limits = this.$wrapLimitRange;\n if (limits.max < 0)\n limits = { min: $printMargin, max: $printMargin };\n var wrapLimit = this.$constrainWrapLimit(desiredLimit, limits.min, limits.max);\n if (wrapLimit != this.$wrapLimit && wrapLimit > 1) {\n this.$wrapLimit = wrapLimit;\n this.$modified = true;\n if (this.$useWrapMode) {\n this.$updateWrapData(0, this.getLength() - 1);\n this.$resetRowCache(0);\n this._signal(\"changeWrapLimit\");\n }\n return true;\n }\n return false;\n };\n EditSession.prototype.$constrainWrapLimit = function (wrapLimit, min, max) {\n if (min)\n wrapLimit = Math.max(min, wrapLimit);\n if (max)\n wrapLimit = Math.min(max, wrapLimit);\n return wrapLimit;\n };\n EditSession.prototype.getWrapLimit = function () {\n return this.$wrapLimit;\n };\n EditSession.prototype.setWrapLimit = function (limit) {\n this.setWrapLimitRange(limit, limit);\n };\n EditSession.prototype.getWrapLimitRange = function () {\n return {\n min: this.$wrapLimitRange.min,\n max: this.$wrapLimitRange.max\n };\n };\n EditSession.prototype.$updateInternalDataOnChange = function (delta) {\n var useWrapMode = this.$useWrapMode;\n var action = delta.action;\n var start = delta.start;\n var end = delta.end;\n var firstRow = start.row;\n var lastRow = end.row;\n var len = lastRow - firstRow;\n var removedFolds = null;\n this.$updating = true;\n if (len != 0) {\n if (action === \"remove\") {\n this[useWrapMode ? \"$wrapData\" : \"$rowLengthCache\"].splice(firstRow, len);\n var foldLines = this.$foldData;\n removedFolds = this.getFoldsInRange(delta);\n this.removeFolds(removedFolds);\n var foldLine = this.getFoldLine(end.row);\n var idx = 0;\n if (foldLine) {\n foldLine.addRemoveChars(end.row, end.column, start.column - end.column);\n foldLine.shiftRow(-len);\n var foldLineBefore = this.getFoldLine(firstRow);\n if (foldLineBefore && foldLineBefore !== foldLine) {\n foldLineBefore.merge(foldLine);\n foldLine = foldLineBefore;\n }\n idx = foldLines.indexOf(foldLine) + 1;\n }\n for (idx; idx < foldLines.length; idx++) {\n var foldLine = foldLines[idx];\n if (foldLine.start.row >= end.row) {\n foldLine.shiftRow(-len);\n }\n }\n lastRow = firstRow;\n }\n else {\n var args = Array(len);\n args.unshift(firstRow, 0);\n var arr = useWrapMode ? this.$wrapData : this.$rowLengthCache;\n arr.splice.apply(arr, args);\n var foldLines = this.$foldData;\n var foldLine = this.getFoldLine(firstRow);\n var idx = 0;\n if (foldLine) {\n var cmp = foldLine.range.compareInside(start.row, start.column);\n if (cmp == 0) {\n foldLine = foldLine.split(start.row, start.column);\n if (foldLine) {\n foldLine.shiftRow(len);\n foldLine.addRemoveChars(lastRow, 0, end.column - start.column);\n }\n }\n else \n if (cmp == -1) {\n foldLine.addRemoveChars(firstRow, 0, end.column - start.column);\n foldLine.shiftRow(len);\n }\n idx = foldLines.indexOf(foldLine) + 1;\n }\n for (idx; idx < foldLines.length; idx++) {\n var foldLine = foldLines[idx];\n if (foldLine.start.row >= firstRow) {\n foldLine.shiftRow(len);\n }\n }\n }\n }\n else {\n len = Math.abs(delta.start.column - delta.end.column);\n if (action === \"remove\") {\n removedFolds = this.getFoldsInRange(delta);\n this.removeFolds(removedFolds);\n len = -len;\n }\n var foldLine = this.getFoldLine(firstRow);\n if (foldLine) {\n foldLine.addRemoveChars(firstRow, start.column, len);\n }\n }\n if (useWrapMode && this.$wrapData.length != this.doc.getLength()) {\n console.error(\"doc.getLength() and $wrapData.length have to be the same!\");\n }\n this.$updating = false;\n if (useWrapMode)\n this.$updateWrapData(firstRow, lastRow);\n else\n this.$updateRowLengthCache(firstRow, lastRow);\n return removedFolds;\n };\n EditSession.prototype.$updateRowLengthCache = function (firstRow, lastRow) {\n this.$rowLengthCache[firstRow] = null;\n this.$rowLengthCache[lastRow] = null;\n };\n EditSession.prototype.$updateWrapData = function (firstRow, lastRow) {\n var lines = this.doc.getAllLines();\n var tabSize = this.getTabSize();\n var wrapData = this.$wrapData;\n var wrapLimit = this.$wrapLimit;\n var tokens;\n var foldLine;\n var row = firstRow;\n lastRow = Math.min(lastRow, lines.length - 1);\n while (row <= lastRow) {\n foldLine = this.getFoldLine(row, foldLine);\n if (!foldLine) {\n tokens = this.$getDisplayTokens(lines[row]);\n wrapData[row] = this.$computeWrapSplits(tokens, wrapLimit, tabSize);\n row++;\n }\n else {\n tokens = [];\n foldLine.walk(function (placeholder, row, column, lastColumn) {\n var walkTokens;\n if (placeholder != null) {\n walkTokens = this.$getDisplayTokens(placeholder, tokens.length);\n walkTokens[0] = PLACEHOLDER_START;\n for (var i = 1; i < walkTokens.length; i++) {\n walkTokens[i] = PLACEHOLDER_BODY;\n }\n }\n else {\n walkTokens = this.$getDisplayTokens(lines[row].substring(lastColumn, column), tokens.length);\n }\n tokens = tokens.concat(walkTokens);\n }.bind(this), foldLine.end.row, lines[foldLine.end.row].length + 1);\n wrapData[foldLine.start.row] = this.$computeWrapSplits(tokens, wrapLimit, tabSize);\n row = foldLine.end.row + 1;\n }\n }\n };\n EditSession.prototype.$computeWrapSplits = function (tokens, wrapLimit, tabSize) {\n if (tokens.length == 0) {\n return [];\n }\n var splits = [];\n var displayLength = tokens.length;\n var lastSplit = 0, lastDocSplit = 0;\n var isCode = this.$wrapAsCode;\n var indentedSoftWrap = this.$indentedSoftWrap;\n var maxIndent = wrapLimit <= Math.max(2 * tabSize, 8)\n || indentedSoftWrap === false ? 0 : Math.floor(wrapLimit / 2);\n function getWrapIndent() {\n var indentation = 0;\n if (maxIndent === 0)\n return indentation;\n if (indentedSoftWrap) {\n for (var i = 0; i < tokens.length; i++) {\n var token = tokens[i];\n if (token == SPACE)\n indentation += 1;\n else if (token == TAB)\n indentation += tabSize;\n else if (token == TAB_SPACE)\n continue;\n else\n break;\n }\n }\n if (isCode && indentedSoftWrap !== false)\n indentation += tabSize;\n return Math.min(indentation, maxIndent);\n }\n function addSplit(screenPos) {\n var len = screenPos - lastSplit;\n for (var i = lastSplit; i < screenPos; i++) {\n var ch = tokens[i];\n if (ch === 12 || ch === 2)\n len -= 1;\n }\n if (!splits.length) {\n indent = getWrapIndent();\n splits.indent = indent;\n }\n lastDocSplit += len;\n splits.push(lastDocSplit);\n lastSplit = screenPos;\n }\n var indent = 0;\n while (displayLength - lastSplit > wrapLimit - indent) {\n var split = lastSplit + wrapLimit - indent;\n if (tokens[split - 1] >= SPACE && tokens[split] >= SPACE) {\n addSplit(split);\n continue;\n }\n if (tokens[split] == PLACEHOLDER_START || tokens[split] == PLACEHOLDER_BODY) {\n for (split; split != lastSplit - 1; split--) {\n if (tokens[split] == PLACEHOLDER_START) {\n break;\n }\n }\n if (split > lastSplit) {\n addSplit(split);\n continue;\n }\n split = lastSplit + wrapLimit;\n for (split; split < tokens.length; split++) {\n if (tokens[split] != PLACEHOLDER_BODY) {\n break;\n }\n }\n if (split == tokens.length) {\n break; // Breaks the while-loop.\n }\n addSplit(split);\n continue;\n }\n var minSplit = Math.max(split - (wrapLimit - (wrapLimit >> 2)), lastSplit - 1);\n while (split > minSplit && tokens[split] < PLACEHOLDER_START) {\n split--;\n }\n if (isCode) {\n while (split > minSplit && tokens[split] < PLACEHOLDER_START) {\n split--;\n }\n while (split > minSplit && tokens[split] == PUNCTUATION) {\n split--;\n }\n }\n else {\n while (split > minSplit && tokens[split] < SPACE) {\n split--;\n }\n }\n if (split > minSplit) {\n addSplit(++split);\n continue;\n }\n split = lastSplit + wrapLimit;\n if (tokens[split] == CHAR_EXT)\n split--;\n addSplit(split - indent);\n }\n return splits;\n };\n EditSession.prototype.$getDisplayTokens = function (str, offset) {\n var arr = [];\n var tabSize;\n offset = offset || 0;\n for (var i = 0; i < str.length; i++) {\n var c = str.charCodeAt(i);\n if (c == 9) {\n tabSize = this.getScreenTabSize(arr.length + offset);\n arr.push(TAB);\n for (var n = 1; n < tabSize; n++) {\n arr.push(TAB_SPACE);\n }\n }\n else if (c == 32) {\n arr.push(SPACE);\n }\n else if ((c > 39 && c < 48) || (c > 57 && c < 64)) {\n arr.push(PUNCTUATION);\n }\n else if (c >= 0x1100 && isFullWidth(c)) {\n arr.push(CHAR, CHAR_EXT);\n }\n else {\n arr.push(CHAR);\n }\n }\n return arr;\n };\n EditSession.prototype.$getStringScreenWidth = function (str, maxScreenColumn, screenColumn) {\n if (maxScreenColumn == 0)\n return [0, 0];\n if (maxScreenColumn == null)\n maxScreenColumn = Infinity;\n screenColumn = screenColumn || 0;\n var c, column;\n for (column = 0; column < str.length; column++) {\n c = str.charCodeAt(column);\n if (c == 9) {\n screenColumn += this.getScreenTabSize(screenColumn);\n }\n else if (c >= 0x1100 && isFullWidth(c)) {\n screenColumn += 2;\n }\n else {\n screenColumn += 1;\n }\n if (screenColumn > maxScreenColumn) {\n break;\n }\n }\n return [screenColumn, column];\n };\n EditSession.prototype.getRowLength = function (row) {\n var h = 1;\n if (this.lineWidgets)\n h += this.lineWidgets[row] && this.lineWidgets[row].rowCount || 0;\n if (!this.$useWrapMode || !this.$wrapData[row])\n return h;\n else\n return this.$wrapData[row].length + h;\n };\n EditSession.prototype.getRowLineCount = function (row) {\n if (!this.$useWrapMode || !this.$wrapData[row]) {\n return 1;\n }\n else {\n return this.$wrapData[row].length + 1;\n }\n };\n EditSession.prototype.getRowWrapIndent = function (screenRow) {\n if (this.$useWrapMode) {\n var pos = this.screenToDocumentPosition(screenRow, Number.MAX_VALUE);\n var splits = this.$wrapData[pos.row];\n return splits.length && splits[0] < pos.column ? splits.indent : 0;\n }\n else {\n return 0;\n }\n };\n EditSession.prototype.getScreenLastRowColumn = function (screenRow) {\n var pos = this.screenToDocumentPosition(screenRow, Number.MAX_VALUE);\n return this.documentToScreenColumn(pos.row, pos.column);\n };\n EditSession.prototype.getDocumentLastRowColumn = function (docRow, docColumn) {\n var screenRow = this.documentToScreenRow(docRow, docColumn);\n return this.getScreenLastRowColumn(screenRow);\n };\n EditSession.prototype.getDocumentLastRowColumnPosition = function (docRow, docColumn) {\n var screenRow = this.documentToScreenRow(docRow, docColumn);\n return this.screenToDocumentPosition(screenRow, Number.MAX_VALUE / 10);\n };\n EditSession.prototype.getRowSplitData = function (row) {\n if (!this.$useWrapMode) {\n return undefined;\n }\n else {\n return this.$wrapData[row];\n }\n };\n EditSession.prototype.getScreenTabSize = function (screenColumn) {\n return this.$tabSize - (screenColumn % this.$tabSize | 0);\n };\n EditSession.prototype.screenToDocumentRow = function (screenRow, screenColumn) {\n return this.screenToDocumentPosition(screenRow, screenColumn).row;\n };\n EditSession.prototype.screenToDocumentColumn = function (screenRow, screenColumn) {\n return this.screenToDocumentPosition(screenRow, screenColumn).column;\n };\n EditSession.prototype.screenToDocumentPosition = function (screenRow, screenColumn, offsetX) {\n if (screenRow < 0)\n return { row: 0, column: 0 };\n var line;\n var docRow = 0;\n var docColumn = 0;\n var column;\n var row = 0;\n var rowLength = 0;\n var rowCache = this.$screenRowCache;\n var i = this.$getRowCacheIndex(rowCache, screenRow);\n var l = rowCache.length;\n if (l && i >= 0) {\n var row = rowCache[i];\n var docRow = this.$docRowCache[i];\n var doCache = screenRow > rowCache[l - 1];\n }\n else {\n var doCache = !l;\n }\n var maxRow = this.getLength() - 1;\n var foldLine = this.getNextFoldLine(docRow);\n var foldStart = foldLine ? foldLine.start.row : Infinity;\n while (row <= screenRow) {\n rowLength = this.getRowLength(docRow);\n if (row + rowLength > screenRow || docRow >= maxRow) {\n break;\n }\n else {\n row += rowLength;\n docRow++;\n if (docRow > foldStart) {\n docRow = foldLine.end.row + 1;\n foldLine = this.getNextFoldLine(docRow, foldLine);\n foldStart = foldLine ? foldLine.start.row : Infinity;\n }\n }\n if (doCache) {\n this.$docRowCache.push(docRow);\n this.$screenRowCache.push(row);\n }\n }\n if (foldLine && foldLine.start.row <= docRow) {\n line = this.getFoldDisplayLine(foldLine);\n docRow = foldLine.start.row;\n }\n else if (row + rowLength <= screenRow || docRow > maxRow) {\n return {\n row: maxRow,\n column: this.getLine(maxRow).length\n };\n }\n else {\n line = this.getLine(docRow);\n foldLine = null;\n }\n var wrapIndent = 0, splitIndex = Math.floor(screenRow - row);\n if (this.$useWrapMode) {\n var splits = this.$wrapData[docRow];\n if (splits) {\n column = splits[splitIndex];\n if (splitIndex > 0 && splits.length) {\n wrapIndent = splits.indent;\n docColumn = splits[splitIndex - 1] || splits[splits.length - 1];\n line = line.substring(docColumn);\n }\n }\n }\n if (offsetX !== undefined && this.$bidiHandler.isBidiRow(row + splitIndex, docRow, splitIndex))\n screenColumn = this.$bidiHandler.offsetToCol(offsetX);\n docColumn += this.$getStringScreenWidth(line, screenColumn - wrapIndent)[1];\n if (this.$useWrapMode && docColumn >= column)\n docColumn = column - 1;\n if (foldLine)\n return foldLine.idxToPosition(docColumn);\n return { row: docRow, column: docColumn };\n };\n EditSession.prototype.documentToScreenPosition = function (docRow, docColumn) {\n if (typeof docColumn === \"undefined\")\n var pos = this.$clipPositionToDocument(/**@type{Point}*/ (docRow).row, /**@type{Point}*/ (docRow).column);\n else\n pos = this.$clipPositionToDocument(/**@type{number}*/ (docRow), docColumn);\n docRow = pos.row;\n docColumn = pos.column;\n var screenRow = 0;\n var foldStartRow = null;\n var fold = null;\n fold = this.getFoldAt(docRow, docColumn, 1);\n if (fold) {\n docRow = fold.start.row;\n docColumn = fold.start.column;\n }\n var rowEnd, row = 0;\n var rowCache = this.$docRowCache;\n var i = this.$getRowCacheIndex(rowCache, docRow);\n var l = rowCache.length;\n if (l && i >= 0) {\n var row = rowCache[i];\n var screenRow = this.$screenRowCache[i];\n var doCache = docRow > rowCache[l - 1];\n }\n else {\n var doCache = !l;\n }\n var foldLine = this.getNextFoldLine(row);\n var foldStart = foldLine ? foldLine.start.row : Infinity;\n while (row < docRow) {\n if (row >= foldStart) {\n rowEnd = foldLine.end.row + 1;\n if (rowEnd > docRow)\n break;\n foldLine = this.getNextFoldLine(rowEnd, foldLine);\n foldStart = foldLine ? foldLine.start.row : Infinity;\n }\n else {\n rowEnd = row + 1;\n }\n screenRow += this.getRowLength(row);\n row = rowEnd;\n if (doCache) {\n this.$docRowCache.push(row);\n this.$screenRowCache.push(screenRow);\n }\n }\n var textLine = \"\";\n if (foldLine && row >= foldStart) {\n textLine = this.getFoldDisplayLine(foldLine, docRow, docColumn);\n foldStartRow = foldLine.start.row;\n }\n else {\n textLine = this.getLine(docRow).substring(0, docColumn);\n foldStartRow = docRow;\n }\n var wrapIndent = 0;\n if (this.$useWrapMode) {\n var wrapRow = this.$wrapData[foldStartRow];\n if (wrapRow) {\n var screenRowOffset = 0;\n while (textLine.length >= wrapRow[screenRowOffset]) {\n screenRow++;\n screenRowOffset++;\n }\n textLine = textLine.substring(wrapRow[screenRowOffset - 1] || 0, textLine.length);\n wrapIndent = screenRowOffset > 0 ? wrapRow.indent : 0;\n }\n }\n if (this.lineWidgets && this.lineWidgets[row] && this.lineWidgets[row].rowsAbove)\n screenRow += this.lineWidgets[row].rowsAbove;\n return {\n row: screenRow,\n column: wrapIndent + this.$getStringScreenWidth(textLine)[0]\n };\n };\n EditSession.prototype.documentToScreenColumn = function (row, docColumn) {\n return this.documentToScreenPosition(row, docColumn).column;\n };\n EditSession.prototype.documentToScreenRow = function (docRow, docColumn) {\n return this.documentToScreenPosition(docRow, docColumn).row;\n };\n EditSession.prototype.getScreenLength = function () {\n var screenRows = 0;\n var fold = null;\n if (!this.$useWrapMode) {\n screenRows = this.getLength();\n var foldData = this.$foldData;\n for (var i = 0; i < foldData.length; i++) {\n fold = foldData[i];\n screenRows -= fold.end.row - fold.start.row;\n }\n }\n else {\n var lastRow = this.$wrapData.length;\n var row = 0, i = 0;\n var fold = this.$foldData[i++];\n var foldStart = fold ? fold.start.row : Infinity;\n while (row < lastRow) {\n var splits = this.$wrapData[row];\n screenRows += splits ? splits.length + 1 : 1;\n row++;\n if (row > foldStart) {\n row = fold.end.row + 1;\n fold = this.$foldData[i++];\n foldStart = fold ? fold.start.row : Infinity;\n }\n }\n }\n if (this.lineWidgets)\n screenRows += this.$getWidgetScreenLength();\n return screenRows;\n };\n EditSession.prototype.$setFontMetrics = function (fm) {\n if (!this.$enableVarChar)\n return;\n this.$getStringScreenWidth = function (str, maxScreenColumn, screenColumn) {\n if (maxScreenColumn === 0)\n return [0, 0];\n if (!maxScreenColumn)\n maxScreenColumn = Infinity;\n screenColumn = screenColumn || 0;\n var c, column;\n for (column = 0; column < str.length; column++) {\n c = str.charAt(column);\n if (c === \"\\t\") {\n screenColumn += this.getScreenTabSize(screenColumn);\n }\n else {\n screenColumn += fm.getCharacterWidth(c);\n }\n if (screenColumn > maxScreenColumn) {\n break;\n }\n }\n return [screenColumn, column];\n };\n };\n EditSession.prototype.getPrecedingCharacter = function () {\n var pos = this.selection.getCursor();\n if (pos.column === 0) {\n return pos.row === 0 ? \"\" : this.doc.getNewLineCharacter();\n }\n var currentLine = this.getLine(pos.row);\n return currentLine[pos.column - 1];\n };\n EditSession.prototype.destroy = function () {\n if (!this.destroyed) {\n this.bgTokenizer.setDocument(null);\n this.bgTokenizer.cleanup();\n this.destroyed = true;\n }\n this.endOperation();\n this.$stopWorker();\n this.removeAllListeners();\n if (this.doc) {\n this.doc.off(\"change\", this.$onChange);\n }\n if (this.selection) {\n this.selection.off(\"changeCursor\", this.$onSelectionChange);\n this.selection.off(\"changeSelection\", this.$onSelectionChange);\n }\n this.selection.detach();\n };\n return EditSession;\n}());\nEditSession.$uid = 0;\nEditSession.prototype.$modes = config.$modes;\nEditSession.prototype.getValue = EditSession.prototype.toString;\nEditSession.prototype.$defaultUndoManager = {\n undo: function () { },\n redo: function () { },\n hasUndo: function () { },\n hasRedo: function () { },\n reset: function () { },\n add: function () { },\n addSelection: function () { },\n startNewGroup: function () { },\n addSession: function () { }\n};\nEditSession.prototype.$overwrite = false;\nEditSession.prototype.$mode = null;\nEditSession.prototype.$modeId = null;\nEditSession.prototype.$scrollTop = 0;\nEditSession.prototype.$scrollLeft = 0;\nEditSession.prototype.$wrapLimit = 80;\nEditSession.prototype.$useWrapMode = false;\nEditSession.prototype.$wrapLimitRange = {\n min: null,\n max: null\n};\nEditSession.prototype.lineWidgets = null;\nEditSession.prototype.isFullWidth = isFullWidth;\noop.implement(EditSession.prototype, EventEmitter);\nvar CHAR = 1, CHAR_EXT = 2, PLACEHOLDER_START = 3, PLACEHOLDER_BODY = 4, PUNCTUATION = 9, SPACE = 10, TAB = 11, TAB_SPACE = 12;\nfunction isFullWidth(c) {\n if (c < 0x1100)\n return false;\n return c >= 0x1100 && c <= 0x115F ||\n c >= 0x11A3 && c <= 0x11A7 ||\n c >= 0x11FA && c <= 0x11FF ||\n c >= 0x2329 && c <= 0x232A ||\n c >= 0x2E80 && c <= 0x2E99 ||\n c >= 0x2E9B && c <= 0x2EF3 ||\n c >= 0x2F00 && c <= 0x2FD5 ||\n c >= 0x2FF0 && c <= 0x2FFB ||\n c >= 0x3000 && c <= 0x303E ||\n c >= 0x3041 && c <= 0x3096 ||\n c >= 0x3099 && c <= 0x30FF ||\n c >= 0x3105 && c <= 0x312D ||\n c >= 0x3131 && c <= 0x318E ||\n c >= 0x3190 && c <= 0x31BA ||\n c >= 0x31C0 && c <= 0x31E3 ||\n c >= 0x31F0 && c <= 0x321E ||\n c >= 0x3220 && c <= 0x3247 ||\n c >= 0x3250 && c <= 0x32FE ||\n c >= 0x3300 && c <= 0x4DBF ||\n c >= 0x4E00 && c <= 0xA48C ||\n c >= 0xA490 && c <= 0xA4C6 ||\n c >= 0xA960 && c <= 0xA97C ||\n c >= 0xAC00 && c <= 0xD7A3 ||\n c >= 0xD7B0 && c <= 0xD7C6 ||\n c >= 0xD7CB && c <= 0xD7FB ||\n c >= 0xF900 && c <= 0xFAFF ||\n c >= 0xFE10 && c <= 0xFE19 ||\n c >= 0xFE30 && c <= 0xFE52 ||\n c >= 0xFE54 && c <= 0xFE66 ||\n c >= 0xFE68 && c <= 0xFE6B ||\n c >= 0xFF01 && c <= 0xFF60 ||\n c >= 0xFFE0 && c <= 0xFFE6;\n}\nrequire(\"./edit_session/folding\").Folding.call(EditSession.prototype);\nrequire(\"./edit_session/bracket_match\").BracketMatch.call(EditSession.prototype);\nconfig.defineOptions(EditSession.prototype, \"session\", {\n wrap: {\n set: function (value) {\n if (!value || value == \"off\")\n value = false;\n else if (value == \"free\")\n value = true;\n else if (value == \"printMargin\")\n value = -1;\n else if (typeof value == \"string\")\n value = parseInt(value, 10) || false;\n if (this.$wrap == value)\n return;\n this.$wrap = value;\n if (!value) {\n this.setUseWrapMode(false);\n }\n else {\n var col = typeof value == \"number\" ? value : null;\n this.setWrapLimitRange(col, col);\n this.setUseWrapMode(true);\n }\n },\n get: function () {\n if (this.getUseWrapMode()) {\n if (this.$wrap == -1)\n return \"printMargin\";\n if (!this.getWrapLimitRange().min)\n return \"free\";\n return this.$wrap;\n }\n return \"off\";\n },\n handlesSet: true\n },\n wrapMethod: {\n set: function (val) {\n val = val == \"auto\"\n ? this.$mode.type != \"text\"\n : val != \"text\";\n if (val != this.$wrapAsCode) {\n this.$wrapAsCode = val;\n if (this.$useWrapMode) {\n this.$useWrapMode = false;\n this.setUseWrapMode(true);\n }\n }\n },\n initialValue: \"auto\"\n },\n indentedSoftWrap: {\n set: function () {\n if (this.$useWrapMode) {\n this.$useWrapMode = false;\n this.setUseWrapMode(true);\n }\n },\n initialValue: true\n },\n firstLineNumber: {\n set: function () { this._signal(\"changeBreakpoint\"); },\n initialValue: 1\n },\n useWorker: {\n set: function (useWorker) {\n this.$useWorker = useWorker;\n this.$stopWorker();\n if (useWorker)\n this.$startWorker();\n },\n initialValue: true\n },\n useSoftTabs: { initialValue: true },\n tabSize: {\n set: function (tabSize) {\n tabSize = parseInt(tabSize);\n if (tabSize > 0 && this.$tabSize !== tabSize) {\n this.$modified = true;\n this.$rowLengthCache = [];\n this.$tabSize = tabSize;\n this._signal(\"changeTabSize\");\n }\n },\n initialValue: 4,\n handlesSet: true\n },\n navigateWithinSoftTabs: { initialValue: false },\n foldStyle: {\n set: function (val) { this.setFoldStyle(val); },\n handlesSet: true\n },\n overwrite: {\n set: function (val) { this._signal(\"changeOverwrite\"); },\n initialValue: false\n },\n newLineMode: {\n set: function (val) { this.doc.setNewLineMode(val); },\n get: function () { return this.doc.getNewLineMode(); },\n handlesSet: true\n },\n mode: {\n set: function (val) { this.setMode(val); },\n get: function () { return this.$modeId; },\n handlesSet: true\n }\n});\nexports.EditSession = EditSession;\n\n});\n\nace.define(\"ace/search\",[\"require\",\"exports\",\"module\",\"ace/lib/lang\",\"ace/lib/oop\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar lang = require(\"./lib/lang\");\nvar oop = require(\"./lib/oop\");\nvar Range = require(\"./range\").Range;\nvar Search = /** @class */ (function () {\n function Search() {\n this.$options = {};\n }\n Search.prototype.set = function (options) {\n oop.mixin(this.$options, options);\n return this;\n };\n Search.prototype.getOptions = function () {\n return lang.copyObject(this.$options);\n };\n Search.prototype.setOptions = function (options) {\n this.$options = options;\n };\n Search.prototype.find = function (session) {\n var options = this.$options;\n var iterator = this.$matchIterator(session, options);\n if (!iterator)\n return false;\n var firstRange = null;\n iterator.forEach(function (sr, sc, er, ec) {\n firstRange = new Range(sr, sc, er, ec);\n if (sc == ec && options.start && /**@type{Range}*/ (options.start).start\n && options.skipCurrent != false && firstRange.isEqual(/**@type{Range}*/ (options.start))) {\n firstRange = null;\n return false;\n }\n return true;\n });\n return firstRange;\n };\n Search.prototype.findAll = function (session) {\n var options = this.$options;\n if (!options.needle)\n return [];\n this.$assembleRegExp(options);\n var range = options.range;\n var lines = range\n ? session.getLines(range.start.row, range.end.row)\n : session.doc.getAllLines();\n var ranges = [];\n var re = options.re;\n if (options.$isMultiLine) {\n var len = re.length;\n var maxRow = lines.length - len;\n var prevRange;\n outer: for (var row = re.offset || 0; row <= maxRow; row++) {\n for (var j = 0; j < len; j++)\n if (lines[row + j].search(re[j]) == -1)\n continue outer;\n var startLine = lines[row];\n var line = lines[row + len - 1];\n var startIndex = startLine.length - startLine.match(re[0])[0].length;\n var endIndex = line.match(re[len - 1])[0].length;\n if (prevRange && prevRange.end.row === row &&\n prevRange.end.column > startIndex) {\n continue;\n }\n ranges.push(prevRange = new Range(row, startIndex, row + len - 1, endIndex));\n if (len > 2)\n row = row + len - 2;\n }\n }\n else {\n for (var i = 0; i < lines.length; i++) {\n var matches = lang.getMatchOffsets(lines[i], re);\n for (var j = 0; j < matches.length; j++) {\n var match = matches[j];\n ranges.push(new Range(i, match.offset, i, match.offset + match.length));\n }\n }\n }\n if (range) {\n var startColumn = range.start.column;\n var endColumn = range.end.column;\n var i = 0, j = ranges.length - 1;\n while (i < j && ranges[i].start.column < startColumn && ranges[i].start.row == 0)\n i++;\n var endRow = range.end.row - range.start.row;\n while (i < j && ranges[j].end.column > endColumn && ranges[j].end.row == endRow)\n j--;\n ranges = ranges.slice(i, j + 1);\n for (i = 0, j = ranges.length; i < j; i++) {\n ranges[i].start.row += range.start.row;\n ranges[i].end.row += range.start.row;\n }\n }\n return ranges;\n };\n Search.prototype.replace = function (input, replacement) {\n var options = this.$options;\n var re = this.$assembleRegExp(options);\n if (options.$isMultiLine)\n return replacement;\n if (!re)\n return;\n var match = re.exec(input);\n if (!match || match[0].length != input.length)\n return null;\n if (!options.regExp) {\n replacement = replacement.replace(/\\$/g, \"$$$$\");\n }\n replacement = input.replace(re, replacement);\n if (options.preserveCase) {\n replacement = replacement.split(\"\");\n for (var i = Math.min(input.length, input.length); i--;) {\n var ch = input[i];\n if (ch && ch.toLowerCase() != ch)\n replacement[i] = replacement[i].toUpperCase();\n else\n replacement[i] = replacement[i].toLowerCase();\n }\n replacement = replacement.join(\"\");\n }\n return replacement;\n };\n Search.prototype.$assembleRegExp = function (options, $disableFakeMultiline) {\n if (options.needle instanceof RegExp)\n return options.re = options.needle;\n var needle = options.needle;\n if (!options.needle)\n return options.re = false;\n if (!options.regExp)\n needle = lang.escapeRegExp(needle);\n var modifier = options.caseSensitive ? \"gm\" : \"gmi\";\n try {\n new RegExp(needle, \"u\");\n options.$supportsUnicodeFlag = true;\n modifier += \"u\";\n }\n catch (e) {\n options.$supportsUnicodeFlag = false; //left for backward compatibility with previous versions for cases like /ab\\{2}/gu\n }\n if (options.wholeWord)\n needle = addWordBoundary(needle, options);\n options.$isMultiLine = !$disableFakeMultiline && /[\\n\\r]/.test(needle);\n if (options.$isMultiLine)\n return options.re = this.$assembleMultilineRegExp(needle, modifier);\n try {\n var re = new RegExp(needle, modifier);\n }\n catch (e) {\n re = false;\n }\n return options.re = re;\n };\n Search.prototype.$assembleMultilineRegExp = function (needle, modifier) {\n var parts = needle.replace(/\\r\\n|\\r|\\n/g, \"$\\n^\").split(\"\\n\");\n var re = [];\n for (var i = 0; i < parts.length; i++)\n try {\n re.push(new RegExp(parts[i], modifier));\n }\n catch (e) {\n return false;\n }\n return re;\n };\n Search.prototype.$matchIterator = function (session, options) {\n var re = this.$assembleRegExp(options);\n if (!re)\n return false;\n var backwards = options.backwards == true;\n var skipCurrent = options.skipCurrent != false;\n var supportsUnicodeFlag = re.unicode;\n var range = options.range;\n var start = options.start;\n if (!start)\n start = range ? range[backwards ? \"end\" : \"start\"] : session.selection.getRange();\n if (start.start)\n start = start[skipCurrent != backwards ? \"end\" : \"start\"];\n var firstRow = range ? range.start.row : 0;\n var lastRow = range ? range.end.row : session.getLength() - 1;\n if (backwards) {\n var forEach = function (callback) {\n var row = start.row;\n if (forEachInLine(row, start.column, callback))\n return;\n for (row--; row >= firstRow; row--)\n if (forEachInLine(row, Number.MAX_VALUE, callback))\n return;\n if (options.wrap == false)\n return;\n for (row = lastRow, firstRow = start.row; row >= firstRow; row--)\n if (forEachInLine(row, Number.MAX_VALUE, callback))\n return;\n };\n }\n else {\n var forEach = function (callback) {\n var row = start.row;\n if (forEachInLine(row, start.column, callback))\n return;\n for (row = row + 1; row <= lastRow; row++)\n if (forEachInLine(row, 0, callback))\n return;\n if (options.wrap == false)\n return;\n for (row = firstRow, lastRow = start.row; row <= lastRow; row++)\n if (forEachInLine(row, 0, callback))\n return;\n };\n }\n if (options.$isMultiLine) {\n var len = re.length;\n var forEachInLine = function (row, offset, callback) {\n var startRow = backwards ? row - len + 1 : row;\n if (startRow < 0 || startRow + len > session.getLength())\n return;\n var line = session.getLine(startRow);\n var startIndex = line.search(re[0]);\n if (!backwards && startIndex < offset || startIndex === -1)\n return;\n for (var i = 1; i < len; i++) {\n line = session.getLine(startRow + i);\n if (line.search(re[i]) == -1)\n return;\n }\n var endIndex = line.match(re[len - 1])[0].length;\n if (backwards && endIndex > offset)\n return;\n if (callback(startRow, startIndex, startRow + len - 1, endIndex))\n return true;\n };\n }\n else if (backwards) {\n var forEachInLine = function (row, endIndex, callback) {\n var line = session.getLine(row);\n var matches = [];\n var m, last = 0;\n re.lastIndex = 0;\n while ((m = re.exec(line))) {\n var length = m[0].length;\n last = m.index;\n if (!length) {\n if (last >= line.length)\n break;\n re.lastIndex = last += lang.skipEmptyMatch(line, last, supportsUnicodeFlag);\n }\n if (m.index + length > endIndex)\n break;\n matches.push(m.index, length);\n }\n for (var i = matches.length - 1; i >= 0; i -= 2) {\n var column = matches[i - 1];\n var length = matches[i];\n if (callback(row, column, row, column + length))\n return true;\n }\n };\n }\n else {\n var forEachInLine = function (row, startIndex, callback) {\n var line = session.getLine(row);\n var last;\n var m;\n re.lastIndex = startIndex;\n while ((m = re.exec(line))) {\n var length = m[0].length;\n last = m.index;\n if (callback(row, last, row, last + length))\n return true;\n if (!length) {\n re.lastIndex = last += lang.skipEmptyMatch(line, last, supportsUnicodeFlag);\n if (last >= line.length)\n return false;\n }\n }\n };\n }\n return { forEach: forEach };\n };\n return Search;\n}());\nfunction addWordBoundary(needle, options) {\n var supportsLookbehind = lang.supportsLookbehind();\n function wordBoundary(c, firstChar) {\n if (firstChar === void 0) { firstChar = true; }\n var wordRegExp = supportsLookbehind && options.$supportsUnicodeFlag ? new RegExp(\"[\\\\p{L}\\\\p{N}_]\", \"u\") : new RegExp(\"\\\\w\");\n if (wordRegExp.test(c) || options.regExp) {\n if (supportsLookbehind && options.$supportsUnicodeFlag) {\n if (firstChar)\n return \"(?<=^|[^\\\\p{L}\\\\p{N}_])\";\n return \"(?=[^\\\\p{L}\\\\p{N}_]|$)\";\n }\n return \"\\\\b\";\n }\n return \"\";\n }\n var needleArray = Array.from(needle);\n var firstChar = needleArray[0];\n var lastChar = needleArray[needleArray.length - 1];\n return wordBoundary(firstChar) + needle + wordBoundary(lastChar, false);\n}\nexports.Search = Search;\n\n});\n\nace.define(\"ace/keyboard/hash_handler\",[\"require\",\"exports\",\"module\",\"ace/lib/keys\",\"ace/lib/useragent\"], function(require, exports, module){\"use strict\";\nvar __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})(); var keyUtil = require(\"../lib/keys\");\nvar useragent = require(\"../lib/useragent\");\nvar KEY_MODS = keyUtil.KEY_MODS;\nvar MultiHashHandler = /** @class */ (function () {\n function MultiHashHandler(config, platform) {\n this.$init(config, platform, false);\n }\n MultiHashHandler.prototype.$init = function (config, platform, $singleCommand) {\n this.platform = platform || (useragent.isMac ? \"mac\" : \"win\");\n this.commands = {};\n this.commandKeyBinding = {};\n this.addCommands(config);\n this.$singleCommand = $singleCommand;\n };\n MultiHashHandler.prototype.addCommand = function (command) {\n if (this.commands[command.name])\n this.removeCommand(command);\n this.commands[command.name] = command;\n if (command.bindKey)\n this._buildKeyHash(command);\n };\n MultiHashHandler.prototype.removeCommand = function (command, keepCommand) {\n var name = command && (typeof command === 'string' ? command : command.name);\n command = this.commands[name];\n if (!keepCommand)\n delete this.commands[name];\n var ckb = this.commandKeyBinding;\n for (var keyId in ckb) {\n var cmdGroup = ckb[keyId];\n if (cmdGroup == command) {\n delete ckb[keyId];\n }\n else if (Array.isArray(cmdGroup)) {\n var i = cmdGroup.indexOf(command);\n if (i != -1) {\n cmdGroup.splice(i, 1);\n if (cmdGroup.length == 1)\n ckb[keyId] = cmdGroup[0];\n }\n }\n }\n };\n MultiHashHandler.prototype.bindKey = function (key, command, position) {\n if (typeof key == \"object\" && key) {\n if (position == undefined)\n position = key.position;\n key = key[this.platform];\n }\n if (!key)\n return;\n if (typeof command == \"function\")\n return this.addCommand({ exec: command, bindKey: key, name: command.name || /**@type{string}*/ (key) }); (key).split(\"|\").forEach(function (keyPart) {\n var chain = \"\";\n if (keyPart.indexOf(\" \") != -1) {\n var parts = keyPart.split(/\\s+/);\n keyPart = parts.pop();\n parts.forEach(function (keyPart) {\n var binding = this.parseKeys(keyPart);\n var id = KEY_MODS[binding.hashId] + binding.key;\n chain += (chain ? \" \" : \"\") + id;\n this._addCommandToBinding(chain, \"chainKeys\");\n }, this);\n chain += \" \";\n }\n var binding = this.parseKeys(keyPart);\n var id = KEY_MODS[binding.hashId] + binding.key;\n this._addCommandToBinding(chain + id, command, position);\n }, this);\n };\n MultiHashHandler.prototype._addCommandToBinding = function (keyId, command, position) {\n var ckb = this.commandKeyBinding, i;\n if (!command) {\n delete ckb[keyId];\n }\n else if (!ckb[keyId] || this.$singleCommand) {\n ckb[keyId] = command;\n }\n else {\n if (!Array.isArray(ckb[keyId])) {\n ckb[keyId] = [ckb[keyId]];\n }\n else if ((i = ckb[keyId].indexOf(command)) != -1) {\n ckb[keyId].splice(i, 1);\n }\n if (typeof position != \"number\") {\n position = getPosition(command);\n }\n var commands = ckb[keyId];\n for (i = 0; i < commands.length; i++) {\n var other = commands[i];\n var otherPos = getPosition(other);\n if (otherPos > position)\n break;\n }\n commands.splice(i, 0, command);\n }\n };\n MultiHashHandler.prototype.addCommands = function (commands) {\n commands && Object.keys(commands).forEach(function (name) {\n var command = commands[name];\n if (!command)\n return;\n if (typeof command === \"string\")\n return this.bindKey(command, name);\n if (typeof command === \"function\")\n command = { exec: command };\n if (typeof command !== \"object\")\n return;\n if (!command.name)\n command.name = name;\n this.addCommand(command);\n }, this);\n };\n MultiHashHandler.prototype.removeCommands = function (commands) {\n Object.keys(commands).forEach(function (name) {\n this.removeCommand(commands[name]);\n }, this);\n };\n MultiHashHandler.prototype.bindKeys = function (keyList) {\n Object.keys(keyList).forEach(function (key) {\n this.bindKey(key, keyList[key]);\n }, this);\n };\n MultiHashHandler.prototype._buildKeyHash = function (command) {\n this.bindKey(command.bindKey, command);\n };\n MultiHashHandler.prototype.parseKeys = function (keys) {\n var parts = keys.toLowerCase().split(/[\\-\\+]([\\-\\+])?/).filter(function (x) { return x; });\n var key = parts.pop();\n var keyCode = keyUtil[key];\n if (keyUtil.FUNCTION_KEYS[keyCode])\n key = keyUtil.FUNCTION_KEYS[keyCode].toLowerCase();\n else if (!parts.length)\n return { key: key, hashId: -1 };\n else if (parts.length == 1 && parts[0] == \"shift\")\n return { key: key.toUpperCase(), hashId: -1 };\n var hashId = 0;\n for (var i = parts.length; i--;) {\n var modifier = keyUtil.KEY_MODS[parts[i]];\n if (modifier == null) {\n if (typeof console != \"undefined\")\n console.error(\"invalid modifier \" + parts[i] + \" in \" + keys);\n return false;\n }\n hashId |= modifier;\n }\n return { key: key, hashId: hashId };\n };\n MultiHashHandler.prototype.findKeyCommand = function (hashId, keyString) {\n var key = KEY_MODS[hashId] + keyString;\n return this.commandKeyBinding[key];\n };\n MultiHashHandler.prototype.handleKeyboard = function (data, hashId, keyString, keyCode) {\n if (keyCode < 0)\n return;\n var key = KEY_MODS[hashId] + keyString;\n var command = this.commandKeyBinding[key];\n if (data.$keyChain) {\n data.$keyChain += \" \" + key;\n command = this.commandKeyBinding[data.$keyChain] || command;\n }\n if (command) {\n if (command == \"chainKeys\" || command[command.length - 1] == \"chainKeys\") {\n data.$keyChain = data.$keyChain || key;\n return { command: \"null\" };\n }\n }\n if (data.$keyChain) {\n if ((!hashId || hashId == 4) && keyString.length == 1)\n data.$keyChain = data.$keyChain.slice(0, -key.length - 1); // wait for input\n else if (hashId == -1 || keyCode > 0)\n data.$keyChain = \"\"; // reset keyChain\n }\n return { command: command };\n };\n MultiHashHandler.prototype.getStatusText = function (editor, data) {\n return data.$keyChain || \"\";\n };\n return MultiHashHandler;\n}());\nfunction getPosition(command) {\n return typeof command == \"object\" && command.bindKey\n && command.bindKey.position\n || (command.isDefault ? -100 : 0);\n}\nvar HashHandler = /** @class */ (function (_super) {\n __extends(HashHandler, _super);\n function HashHandler(config, platform) {\n var _this = _super.call(this, config, platform) || this;\n _this.$singleCommand = true;\n return _this;\n }\n return HashHandler;\n}(MultiHashHandler));\nHashHandler.call = function (thisArg, config, platform) {\n MultiHashHandler.prototype.$init.call(thisArg, config, platform, true);\n};\nMultiHashHandler.call = function (thisArg, config, platform) {\n MultiHashHandler.prototype.$init.call(thisArg, config, platform, false);\n};\nexports.HashHandler = HashHandler;\nexports.MultiHashHandler = MultiHashHandler;\n\n});\n\nace.define(\"ace/commands/command_manager\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/keyboard/hash_handler\",\"ace/lib/event_emitter\"], function(require, exports, module){\"use strict\";\nvar __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar oop = require(\"../lib/oop\");\nvar MultiHashHandler = require(\"../keyboard/hash_handler\").MultiHashHandler;\nvar EventEmitter = require(\"../lib/event_emitter\").EventEmitter;\nvar CommandManager = /** @class */ (function (_super) {\n __extends(CommandManager, _super);\n function CommandManager(platform, commands) {\n var _this = _super.call(this, commands, platform) || this;\n _this.byName = _this.commands;\n _this.setDefaultHandler(\"exec\", function (e) {\n if (!e.args) {\n return e.command.exec(e.editor, {}, e.event, true);\n }\n return e.command.exec(e.editor, e.args, e.event, false);\n });\n return _this;\n }\n CommandManager.prototype.exec = function (command, editor, args) {\n if (Array.isArray(command)) {\n for (var i = command.length; i--;) {\n if (this.exec(command[i], editor, args))\n return true;\n }\n return false;\n }\n if (typeof command === \"string\")\n command = this.commands[command];\n if (!this.canExecute(command, editor)) {\n return false;\n }\n var e = { editor: editor, command: command, args: args };\n e.returnValue = this._emit(\"exec\", e);\n this._signal(\"afterExec\", e);\n return e.returnValue === false ? false : true;\n };\n CommandManager.prototype.canExecute = function (command, editor) {\n if (typeof command === \"string\")\n command = this.commands[command];\n if (!command)\n return false;\n if (editor && editor.$readOnly && !command.readOnly)\n return false;\n if (this.$checkCommandState != false && command.isAvailable && !command.isAvailable(editor))\n return false;\n return true;\n };\n CommandManager.prototype.toggleRecording = function (editor) {\n if (this.$inReplay)\n return;\n editor && editor._emit(\"changeStatus\");\n if (this.recording) {\n this.macro.pop();\n this.off(\"exec\", this.$addCommandToMacro);\n if (!this.macro.length)\n this.macro = this.oldMacro;\n return this.recording = false;\n }\n if (!this.$addCommandToMacro) {\n this.$addCommandToMacro = function (e) {\n this.macro.push([e.command, e.args]);\n }.bind(this);\n }\n this.oldMacro = this.macro;\n this.macro = [];\n this.on(\"exec\", this.$addCommandToMacro);\n return this.recording = true;\n };\n CommandManager.prototype.replay = function (editor) {\n if (this.$inReplay || !this.macro)\n return;\n if (this.recording)\n return this.toggleRecording(editor);\n try {\n this.$inReplay = true;\n this.macro.forEach(function (x) {\n if (typeof x == \"string\")\n this.exec(x, editor);\n else\n this.exec(x[0], editor, x[1]);\n }, this);\n }\n finally {\n this.$inReplay = false;\n }\n };\n CommandManager.prototype.trimMacro = function (m) {\n return m.map(function (x) {\n if (typeof x[0] != \"string\")\n x[0] = x[0].name;\n if (!x[1])\n x = x[0];\n return x;\n });\n };\n return CommandManager;\n}(MultiHashHandler));\noop.implement(CommandManager.prototype, EventEmitter);\nexports.CommandManager = CommandManager;\n\n});\n\nace.define(\"ace/commands/default_commands\",[\"require\",\"exports\",\"module\",\"ace/lib/lang\",\"ace/config\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar lang = require(\"../lib/lang\");\nvar config = require(\"../config\");\nvar Range = require(\"../range\").Range;\nfunction bindKey(win, mac) {\n return { win: win, mac: mac };\n}\nexports.commands = [{\n name: \"showSettingsMenu\",\n description: \"Show settings menu\",\n bindKey: bindKey(\"Ctrl-,\", \"Command-,\"),\n exec: function (editor) {\n config.loadModule(\"ace/ext/settings_menu\", function (module) {\n module.init(editor);\n editor.showSettingsMenu();\n });\n },\n readOnly: true\n }, {\n name: \"goToNextError\",\n description: \"Go to next error\",\n bindKey: bindKey(\"Alt-E\", \"F4\"),\n exec: function (editor) {\n config.loadModule(\"ace/ext/error_marker\", function (module) {\n module.showErrorMarker(editor, 1);\n });\n },\n scrollIntoView: \"animate\",\n readOnly: true\n }, {\n name: \"goToPreviousError\",\n description: \"Go to previous error\",\n bindKey: bindKey(\"Alt-Shift-E\", \"Shift-F4\"),\n exec: function (editor) {\n config.loadModule(\"ace/ext/error_marker\", function (module) {\n module.showErrorMarker(editor, -1);\n });\n },\n scrollIntoView: \"animate\",\n readOnly: true\n }, {\n name: \"selectall\",\n description: \"Select all\",\n bindKey: bindKey(\"Ctrl-A\", \"Command-A\"),\n exec: function (editor) { editor.selectAll(); },\n readOnly: true\n }, {\n name: \"centerselection\",\n description: \"Center selection\",\n bindKey: bindKey(null, \"Ctrl-L\"),\n exec: function (editor) { editor.centerSelection(); },\n readOnly: true\n }, {\n name: \"gotoline\",\n description: \"Go to line...\",\n bindKey: bindKey(\"Ctrl-L\", \"Command-L\"),\n exec: function (editor, line) {\n if (typeof line === \"number\" && !isNaN(line))\n editor.gotoLine(line);\n editor.prompt({ $type: \"gotoLine\" });\n },\n readOnly: true\n }, {\n name: \"fold\",\n bindKey: bindKey(\"Alt-L|Ctrl-F1\", \"Command-Alt-L|Command-F1\"),\n exec: function (editor) { editor.session.toggleFold(false); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"center\",\n readOnly: true\n }, {\n name: \"unfold\",\n bindKey: bindKey(\"Alt-Shift-L|Ctrl-Shift-F1\", \"Command-Alt-Shift-L|Command-Shift-F1\"),\n exec: function (editor) { editor.session.toggleFold(true); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"center\",\n readOnly: true\n }, {\n name: \"toggleFoldWidget\",\n description: \"Toggle fold widget\",\n bindKey: bindKey(\"F2\", \"F2\"),\n exec: function (editor) { editor.session.toggleFoldWidget(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"center\",\n readOnly: true\n }, {\n name: \"toggleParentFoldWidget\",\n description: \"Toggle parent fold widget\",\n bindKey: bindKey(\"Alt-F2\", \"Alt-F2\"),\n exec: function (editor) { editor.session.toggleFoldWidget(true); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"center\",\n readOnly: true\n }, {\n name: \"foldall\",\n description: \"Fold all\",\n bindKey: bindKey(null, \"Ctrl-Command-Option-0\"),\n exec: function (editor) { editor.session.foldAll(); },\n scrollIntoView: \"center\",\n readOnly: true\n }, {\n name: \"foldAllComments\",\n description: \"Fold all comments\",\n bindKey: bindKey(null, \"Ctrl-Command-Option-0\"),\n exec: function (editor) { editor.session.foldAllComments(); },\n scrollIntoView: \"center\",\n readOnly: true\n }, {\n name: \"foldOther\",\n description: \"Fold other\",\n bindKey: bindKey(\"Alt-0\", \"Command-Option-0\"),\n exec: function (editor) {\n editor.session.foldAll();\n editor.session.unfold(editor.selection.getAllRanges());\n },\n scrollIntoView: \"center\",\n readOnly: true\n }, {\n name: \"unfoldall\",\n description: \"Unfold all\",\n bindKey: bindKey(\"Alt-Shift-0\", \"Command-Option-Shift-0\"),\n exec: function (editor) { editor.session.unfold(); },\n scrollIntoView: \"center\",\n readOnly: true\n }, {\n name: \"findnext\",\n description: \"Find next\",\n bindKey: bindKey(\"Ctrl-K\", \"Command-G\"),\n exec: function (editor) { editor.findNext(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"center\",\n readOnly: true\n }, {\n name: \"findprevious\",\n description: \"Find previous\",\n bindKey: bindKey(\"Ctrl-Shift-K\", \"Command-Shift-G\"),\n exec: function (editor) { editor.findPrevious(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"center\",\n readOnly: true\n }, {\n name: \"selectOrFindNext\",\n description: \"Select or find next\",\n bindKey: bindKey(\"Alt-K\", \"Ctrl-G\"),\n exec: function (editor) {\n if (editor.selection.isEmpty())\n editor.selection.selectWord();\n else\n editor.findNext();\n },\n readOnly: true\n }, {\n name: \"selectOrFindPrevious\",\n description: \"Select or find previous\",\n bindKey: bindKey(\"Alt-Shift-K\", \"Ctrl-Shift-G\"),\n exec: function (editor) {\n if (editor.selection.isEmpty())\n editor.selection.selectWord();\n else\n editor.findPrevious();\n },\n readOnly: true\n }, {\n name: \"find\",\n description: \"Find\",\n bindKey: bindKey(\"Ctrl-F\", \"Command-F\"),\n exec: function (editor) {\n config.loadModule(\"ace/ext/searchbox\", function (e) { e.Search(editor); });\n },\n readOnly: true\n }, {\n name: \"overwrite\",\n description: \"Overwrite\",\n bindKey: \"Insert\",\n exec: function (editor) { editor.toggleOverwrite(); },\n readOnly: true\n }, {\n name: \"selecttostart\",\n description: \"Select to start\",\n bindKey: bindKey(\"Ctrl-Shift-Home\", \"Command-Shift-Home|Command-Shift-Up\"),\n exec: function (editor) { editor.getSelection().selectFileStart(); },\n multiSelectAction: \"forEach\",\n readOnly: true,\n scrollIntoView: \"animate\",\n aceCommandGroup: \"fileJump\"\n }, {\n name: \"gotostart\",\n description: \"Go to start\",\n bindKey: bindKey(\"Ctrl-Home\", \"Command-Home|Command-Up\"),\n exec: function (editor) { editor.navigateFileStart(); },\n multiSelectAction: \"forEach\",\n readOnly: true,\n scrollIntoView: \"animate\",\n aceCommandGroup: \"fileJump\"\n }, {\n name: \"selectup\",\n description: \"Select up\",\n bindKey: bindKey(\"Shift-Up\", \"Shift-Up|Ctrl-Shift-P\"),\n exec: function (editor) { editor.getSelection().selectUp(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"golineup\",\n description: \"Go line up\",\n bindKey: bindKey(\"Up\", \"Up|Ctrl-P\"),\n exec: function (editor, args) { editor.navigateUp(args.times); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selecttoend\",\n description: \"Select to end\",\n bindKey: bindKey(\"Ctrl-Shift-End\", \"Command-Shift-End|Command-Shift-Down\"),\n exec: function (editor) { editor.getSelection().selectFileEnd(); },\n multiSelectAction: \"forEach\",\n readOnly: true,\n scrollIntoView: \"animate\",\n aceCommandGroup: \"fileJump\"\n }, {\n name: \"gotoend\",\n description: \"Go to end\",\n bindKey: bindKey(\"Ctrl-End\", \"Command-End|Command-Down\"),\n exec: function (editor) { editor.navigateFileEnd(); },\n multiSelectAction: \"forEach\",\n readOnly: true,\n scrollIntoView: \"animate\",\n aceCommandGroup: \"fileJump\"\n }, {\n name: \"selectdown\",\n description: \"Select down\",\n bindKey: bindKey(\"Shift-Down\", \"Shift-Down|Ctrl-Shift-N\"),\n exec: function (editor) { editor.getSelection().selectDown(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"golinedown\",\n description: \"Go line down\",\n bindKey: bindKey(\"Down\", \"Down|Ctrl-N\"),\n exec: function (editor, args) { editor.navigateDown(args.times); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selectwordleft\",\n description: \"Select word left\",\n bindKey: bindKey(\"Ctrl-Shift-Left\", \"Option-Shift-Left\"),\n exec: function (editor) { editor.getSelection().selectWordLeft(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"gotowordleft\",\n description: \"Go to word left\",\n bindKey: bindKey(\"Ctrl-Left\", \"Option-Left\"),\n exec: function (editor) { editor.navigateWordLeft(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selecttolinestart\",\n description: \"Select to line start\",\n bindKey: bindKey(\"Alt-Shift-Left\", \"Command-Shift-Left|Ctrl-Shift-A\"),\n exec: function (editor) { editor.getSelection().selectLineStart(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"gotolinestart\",\n description: \"Go to line start\",\n bindKey: bindKey(\"Alt-Left|Home\", \"Command-Left|Home|Ctrl-A\"),\n exec: function (editor) { editor.navigateLineStart(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selectleft\",\n description: \"Select left\",\n bindKey: bindKey(\"Shift-Left\", \"Shift-Left|Ctrl-Shift-B\"),\n exec: function (editor) { editor.getSelection().selectLeft(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"gotoleft\",\n description: \"Go to left\",\n bindKey: bindKey(\"Left\", \"Left|Ctrl-B\"),\n exec: function (editor, args) { editor.navigateLeft(args.times); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selectwordright\",\n description: \"Select word right\",\n bindKey: bindKey(\"Ctrl-Shift-Right\", \"Option-Shift-Right\"),\n exec: function (editor) { editor.getSelection().selectWordRight(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"gotowordright\",\n description: \"Go to word right\",\n bindKey: bindKey(\"Ctrl-Right\", \"Option-Right\"),\n exec: function (editor) { editor.navigateWordRight(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selecttolineend\",\n description: \"Select to line end\",\n bindKey: bindKey(\"Alt-Shift-Right\", \"Command-Shift-Right|Shift-End|Ctrl-Shift-E\"),\n exec: function (editor) { editor.getSelection().selectLineEnd(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"gotolineend\",\n description: \"Go to line end\",\n bindKey: bindKey(\"Alt-Right|End\", \"Command-Right|End|Ctrl-E\"),\n exec: function (editor) { editor.navigateLineEnd(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selectright\",\n description: \"Select right\",\n bindKey: bindKey(\"Shift-Right\", \"Shift-Right\"),\n exec: function (editor) { editor.getSelection().selectRight(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"gotoright\",\n description: \"Go to right\",\n bindKey: bindKey(\"Right\", \"Right|Ctrl-F\"),\n exec: function (editor, args) { editor.navigateRight(args.times); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selectpagedown\",\n description: \"Select page down\",\n bindKey: \"Shift-PageDown\",\n exec: function (editor) { editor.selectPageDown(); },\n readOnly: true\n }, {\n name: \"pagedown\",\n description: \"Page down\",\n bindKey: bindKey(null, \"Option-PageDown\"),\n exec: function (editor) { editor.scrollPageDown(); },\n readOnly: true\n }, {\n name: \"gotopagedown\",\n description: \"Go to page down\",\n bindKey: bindKey(\"PageDown\", \"PageDown|Ctrl-V\"),\n exec: function (editor) { editor.gotoPageDown(); },\n readOnly: true\n }, {\n name: \"selectpageup\",\n description: \"Select page up\",\n bindKey: \"Shift-PageUp\",\n exec: function (editor) { editor.selectPageUp(); },\n readOnly: true\n }, {\n name: \"pageup\",\n description: \"Page up\",\n bindKey: bindKey(null, \"Option-PageUp\"),\n exec: function (editor) { editor.scrollPageUp(); },\n readOnly: true\n }, {\n name: \"gotopageup\",\n description: \"Go to page up\",\n bindKey: \"PageUp\",\n exec: function (editor) { editor.gotoPageUp(); },\n readOnly: true\n }, {\n name: \"scrollup\",\n description: \"Scroll up\",\n bindKey: bindKey(\"Ctrl-Up\", null),\n exec: function (e) { e.renderer.scrollBy(0, -2 * e.renderer.layerConfig.lineHeight); },\n readOnly: true\n }, {\n name: \"scrolldown\",\n description: \"Scroll down\",\n bindKey: bindKey(\"Ctrl-Down\", null),\n exec: function (e) { e.renderer.scrollBy(0, 2 * e.renderer.layerConfig.lineHeight); },\n readOnly: true\n }, {\n name: \"selectlinestart\",\n description: \"Select line start\",\n bindKey: \"Shift-Home\",\n exec: function (editor) { editor.getSelection().selectLineStart(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selectlineend\",\n description: \"Select line end\",\n bindKey: \"Shift-End\",\n exec: function (editor) { editor.getSelection().selectLineEnd(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"togglerecording\",\n description: \"Toggle recording\",\n bindKey: bindKey(\"Ctrl-Alt-E\", \"Command-Option-E\"),\n exec: function (editor) { editor.commands.toggleRecording(editor); },\n readOnly: true\n }, {\n name: \"replaymacro\",\n description: \"Replay macro\",\n bindKey: bindKey(\"Ctrl-Shift-E\", \"Command-Shift-E\"),\n exec: function (editor) { editor.commands.replay(editor); },\n readOnly: true\n }, {\n name: \"jumptomatching\",\n description: \"Jump to matching\",\n bindKey: bindKey(\"Ctrl-\\\\|Ctrl-P\", \"Command-\\\\\"),\n exec: function (editor) { editor.jumpToMatching(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"animate\",\n readOnly: true\n }, {\n name: \"selecttomatching\",\n description: \"Select to matching\",\n bindKey: bindKey(\"Ctrl-Shift-\\\\|Ctrl-Shift-P\", \"Command-Shift-\\\\\"),\n exec: function (editor) { editor.jumpToMatching(true); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"animate\",\n readOnly: true\n }, {\n name: \"expandToMatching\",\n description: \"Expand to matching\",\n bindKey: bindKey(\"Ctrl-Shift-M\", \"Ctrl-Shift-M\"),\n exec: function (editor) { editor.jumpToMatching(true, true); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"animate\",\n readOnly: true\n }, {\n name: \"passKeysToBrowser\",\n description: \"Pass keys to browser\",\n bindKey: bindKey(null, null),\n exec: function () { },\n passEvent: true,\n readOnly: true\n }, {\n name: \"copy\",\n description: \"Copy\",\n exec: function (editor) {\n },\n readOnly: true\n },\n {\n name: \"cut\",\n description: \"Cut\",\n exec: function (editor) {\n var cutLine = editor.$copyWithEmptySelection && editor.selection.isEmpty();\n var range = cutLine ? editor.selection.getLineRange() : editor.selection.getRange();\n editor._emit(\"cut\", range);\n if (!range.isEmpty())\n editor.session.remove(range);\n editor.clearSelection();\n },\n scrollIntoView: \"cursor\",\n multiSelectAction: \"forEach\"\n }, {\n name: \"paste\",\n description: \"Paste\",\n exec: function (editor, args) {\n editor.$handlePaste(args);\n },\n scrollIntoView: \"cursor\"\n }, {\n name: \"removeline\",\n description: \"Remove line\",\n bindKey: bindKey(\"Ctrl-D\", \"Command-D\"),\n exec: function (editor) { editor.removeLines(); },\n scrollIntoView: \"cursor\",\n multiSelectAction: \"forEachLine\"\n }, {\n name: \"duplicateSelection\",\n description: \"Duplicate selection\",\n bindKey: bindKey(\"Ctrl-Shift-D\", \"Command-Shift-D\"),\n exec: function (editor) { editor.duplicateSelection(); },\n scrollIntoView: \"cursor\",\n multiSelectAction: \"forEach\"\n }, {\n name: \"sortlines\",\n description: \"Sort lines\",\n bindKey: bindKey(\"Ctrl-Alt-S\", \"Command-Alt-S\"),\n exec: function (editor) { editor.sortLines(); },\n scrollIntoView: \"selection\",\n multiSelectAction: \"forEachLine\"\n }, {\n name: \"togglecomment\",\n description: \"Toggle comment\",\n bindKey: bindKey(\"Ctrl-/\", \"Command-/\"),\n exec: function (editor) { editor.toggleCommentLines(); },\n multiSelectAction: \"forEachLine\",\n scrollIntoView: \"selectionPart\"\n }, {\n name: \"toggleBlockComment\",\n description: \"Toggle block comment\",\n bindKey: bindKey(\"Ctrl-Shift-/\", \"Command-Shift-/\"),\n exec: function (editor) { editor.toggleBlockComment(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"selectionPart\"\n }, {\n name: \"modifyNumberUp\",\n description: \"Modify number up\",\n bindKey: bindKey(\"Ctrl-Shift-Up\", \"Alt-Shift-Up\"),\n exec: function (editor) { editor.modifyNumber(1); },\n scrollIntoView: \"cursor\",\n multiSelectAction: \"forEach\"\n }, {\n name: \"modifyNumberDown\",\n description: \"Modify number down\",\n bindKey: bindKey(\"Ctrl-Shift-Down\", \"Alt-Shift-Down\"),\n exec: function (editor) { editor.modifyNumber(-1); },\n scrollIntoView: \"cursor\",\n multiSelectAction: \"forEach\"\n }, {\n name: \"replace\",\n description: \"Replace\",\n bindKey: bindKey(\"Ctrl-H\", \"Command-Option-F\"),\n exec: function (editor) {\n config.loadModule(\"ace/ext/searchbox\", function (e) { e.Search(editor, true); });\n }\n }, {\n name: \"undo\",\n description: \"Undo\",\n bindKey: bindKey(\"Ctrl-Z\", \"Command-Z\"),\n exec: function (editor) { editor.undo(); }\n }, {\n name: \"redo\",\n description: \"Redo\",\n bindKey: bindKey(\"Ctrl-Shift-Z|Ctrl-Y\", \"Command-Shift-Z|Command-Y\"),\n exec: function (editor) { editor.redo(); }\n }, {\n name: \"copylinesup\",\n description: \"Copy lines up\",\n bindKey: bindKey(\"Alt-Shift-Up\", \"Command-Option-Up\"),\n exec: function (editor) { editor.copyLinesUp(); },\n scrollIntoView: \"cursor\"\n }, {\n name: \"movelinesup\",\n description: \"Move lines up\",\n bindKey: bindKey(\"Alt-Up\", \"Option-Up\"),\n exec: function (editor) { editor.moveLinesUp(); },\n scrollIntoView: \"cursor\"\n }, {\n name: \"copylinesdown\",\n description: \"Copy lines down\",\n bindKey: bindKey(\"Alt-Shift-Down\", \"Command-Option-Down\"),\n exec: function (editor) { editor.copyLinesDown(); },\n scrollIntoView: \"cursor\"\n }, {\n name: \"movelinesdown\",\n description: \"Move lines down\",\n bindKey: bindKey(\"Alt-Down\", \"Option-Down\"),\n exec: function (editor) { editor.moveLinesDown(); },\n scrollIntoView: \"cursor\"\n }, {\n name: \"del\",\n description: \"Delete\",\n bindKey: bindKey(\"Delete\", \"Delete|Ctrl-D|Shift-Delete\"),\n exec: function (editor) { editor.remove(\"right\"); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"backspace\",\n description: \"Backspace\",\n bindKey: bindKey(\"Shift-Backspace|Backspace\", \"Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H\"),\n exec: function (editor) { editor.remove(\"left\"); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"cut_or_delete\",\n description: \"Cut or delete\",\n bindKey: bindKey(\"Shift-Delete\", null),\n exec: function (editor) {\n if (editor.selection.isEmpty()) {\n editor.remove(\"left\");\n }\n else {\n return false;\n }\n },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"removetolinestart\",\n description: \"Remove to line start\",\n bindKey: bindKey(\"Alt-Backspace\", \"Command-Backspace\"),\n exec: function (editor) { editor.removeToLineStart(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"removetolineend\",\n description: \"Remove to line end\",\n bindKey: bindKey(\"Alt-Delete\", \"Ctrl-K|Command-Delete\"),\n exec: function (editor) { editor.removeToLineEnd(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"removetolinestarthard\",\n description: \"Remove to line start hard\",\n bindKey: bindKey(\"Ctrl-Shift-Backspace\", null),\n exec: function (editor) {\n var range = editor.selection.getRange();\n range.start.column = 0;\n editor.session.remove(range);\n },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"removetolineendhard\",\n description: \"Remove to line end hard\",\n bindKey: bindKey(\"Ctrl-Shift-Delete\", null),\n exec: function (editor) {\n var range = editor.selection.getRange();\n range.end.column = Number.MAX_VALUE;\n editor.session.remove(range);\n },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"removewordleft\",\n description: \"Remove word left\",\n bindKey: bindKey(\"Ctrl-Backspace\", \"Alt-Backspace|Ctrl-Alt-Backspace\"),\n exec: function (editor) { editor.removeWordLeft(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"removewordright\",\n description: \"Remove word right\",\n bindKey: bindKey(\"Ctrl-Delete\", \"Alt-Delete\"),\n exec: function (editor) { editor.removeWordRight(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"outdent\",\n description: \"Outdent\",\n bindKey: bindKey(\"Shift-Tab\", \"Shift-Tab\"),\n exec: function (editor) { editor.blockOutdent(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"selectionPart\"\n }, {\n name: \"indent\",\n description: \"Indent\",\n bindKey: bindKey(\"Tab\", \"Tab\"),\n exec: function (editor) { editor.indent(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"selectionPart\"\n }, {\n name: \"blockoutdent\",\n description: \"Block outdent\",\n bindKey: bindKey(\"Ctrl-[\", \"Ctrl-[\"),\n exec: function (editor) { editor.blockOutdent(); },\n multiSelectAction: \"forEachLine\",\n scrollIntoView: \"selectionPart\"\n }, {\n name: \"blockindent\",\n description: \"Block indent\",\n bindKey: bindKey(\"Ctrl-]\", \"Ctrl-]\"),\n exec: function (editor) { editor.blockIndent(); },\n multiSelectAction: \"forEachLine\",\n scrollIntoView: \"selectionPart\"\n }, {\n name: \"insertstring\",\n description: \"Insert string\",\n exec: function (editor, str) { editor.insert(str); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"inserttext\",\n description: \"Insert text\",\n exec: function (editor, args) {\n editor.insert(lang.stringRepeat(args.text || \"\", args.times || 1));\n },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"splitline\",\n description: \"Split line\",\n bindKey: bindKey(null, \"Ctrl-O\"),\n exec: function (editor) { editor.splitLine(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"transposeletters\",\n description: \"Transpose letters\",\n bindKey: bindKey(\"Alt-Shift-X\", \"Ctrl-T\"),\n exec: function (editor) { editor.transposeLetters(); },\n multiSelectAction: function (editor) { editor.transposeSelections(1); },\n scrollIntoView: \"cursor\"\n }, {\n name: \"touppercase\",\n description: \"To uppercase\",\n bindKey: bindKey(\"Ctrl-U\", \"Ctrl-U\"),\n exec: function (editor) { editor.toUpperCase(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"tolowercase\",\n description: \"To lowercase\",\n bindKey: bindKey(\"Ctrl-Shift-U\", \"Ctrl-Shift-U\"),\n exec: function (editor) { editor.toLowerCase(); },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"autoindent\",\n description: \"Auto Indent\",\n bindKey: bindKey(null, null),\n exec: function (editor) { editor.autoIndent(); },\n scrollIntoView: \"animate\"\n }, {\n name: \"expandtoline\",\n description: \"Expand to line\",\n bindKey: bindKey(\"Ctrl-Shift-L\", \"Command-Shift-L\"),\n exec: function (editor) {\n var range = editor.selection.getRange();\n range.start.column = range.end.column = 0;\n range.end.row++;\n editor.selection.setRange(range, false);\n },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"openlink\",\n bindKey: bindKey(\"Ctrl+F3\", \"F3\"),\n exec: function (editor) { editor.openLink(); }\n }, {\n name: \"joinlines\",\n description: \"Join lines\",\n bindKey: bindKey(null, null),\n exec: function (editor) {\n var isBackwards = editor.selection.isBackwards();\n var selectionStart = isBackwards ? editor.selection.getSelectionLead() : editor.selection.getSelectionAnchor();\n var selectionEnd = isBackwards ? editor.selection.getSelectionAnchor() : editor.selection.getSelectionLead();\n var firstLineEndCol = editor.session.doc.getLine(selectionStart.row).length;\n var selectedText = editor.session.doc.getTextRange(editor.selection.getRange());\n var selectedCount = selectedText.replace(/\\n\\s*/, \" \").length;\n var insertLine = editor.session.doc.getLine(selectionStart.row);\n for (var i = selectionStart.row + 1; i <= selectionEnd.row + 1; i++) {\n var curLine = lang.stringTrimLeft(lang.stringTrimRight(editor.session.doc.getLine(i)));\n if (curLine.length !== 0) {\n curLine = \" \" + curLine;\n }\n insertLine += curLine;\n }\n if (selectionEnd.row + 1 < (editor.session.doc.getLength() - 1)) {\n insertLine += editor.session.doc.getNewLineCharacter();\n }\n editor.clearSelection();\n editor.session.doc.replace(new Range(selectionStart.row, 0, selectionEnd.row + 2, 0), insertLine);\n if (selectedCount > 0) {\n editor.selection.moveCursorTo(selectionStart.row, selectionStart.column);\n editor.selection.selectTo(selectionStart.row, selectionStart.column + selectedCount);\n }\n else {\n firstLineEndCol = editor.session.doc.getLine(selectionStart.row).length > firstLineEndCol ? (firstLineEndCol + 1) : firstLineEndCol;\n editor.selection.moveCursorTo(selectionStart.row, firstLineEndCol);\n }\n },\n multiSelectAction: \"forEach\",\n readOnly: true\n }, {\n name: \"invertSelection\",\n description: \"Invert selection\",\n bindKey: bindKey(null, null),\n exec: function (editor) {\n var endRow = editor.session.doc.getLength() - 1;\n var endCol = editor.session.doc.getLine(endRow).length;\n var ranges = editor.selection.rangeList.ranges;\n var newRanges = [];\n if (ranges.length < 1) {\n ranges = [editor.selection.getRange()];\n }\n for (var i = 0; i < ranges.length; i++) {\n if (i == (ranges.length - 1)) {\n if (!(ranges[i].end.row === endRow && ranges[i].end.column === endCol)) {\n newRanges.push(new Range(ranges[i].end.row, ranges[i].end.column, endRow, endCol));\n }\n }\n if (i === 0) {\n if (!(ranges[i].start.row === 0 && ranges[i].start.column === 0)) {\n newRanges.push(new Range(0, 0, ranges[i].start.row, ranges[i].start.column));\n }\n }\n else {\n newRanges.push(new Range(ranges[i - 1].end.row, ranges[i - 1].end.column, ranges[i].start.row, ranges[i].start.column));\n }\n }\n editor.exitMultiSelectMode();\n editor.clearSelection();\n for (var i = 0; i < newRanges.length; i++) {\n editor.selection.addRange(newRanges[i], false);\n }\n },\n readOnly: true,\n scrollIntoView: \"none\"\n }, {\n name: \"addLineAfter\",\n description: \"Add new line after the current line\",\n exec: function (editor) {\n editor.selection.clearSelection();\n editor.navigateLineEnd();\n editor.insert(\"\\n\");\n },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"addLineBefore\",\n description: \"Add new line before the current line\",\n exec: function (editor) {\n editor.selection.clearSelection();\n var cursor = editor.getCursorPosition();\n editor.selection.moveTo(cursor.row - 1, Number.MAX_VALUE);\n editor.insert(\"\\n\");\n if (cursor.row === 0)\n editor.navigateUp();\n },\n multiSelectAction: \"forEach\",\n scrollIntoView: \"cursor\"\n }, {\n name: \"openCommandPallete\",\n exec: function (editor) {\n console.warn(\"This is an obsolete command. Please use `openCommandPalette` instead.\");\n editor.prompt({ $type: \"commands\" });\n },\n readOnly: true\n }, {\n name: \"openCommandPalette\",\n description: \"Open command palette\",\n bindKey: bindKey(\"F1\", \"F1\"),\n exec: function (editor) {\n editor.prompt({ $type: \"commands\" });\n },\n readOnly: true\n }, {\n name: \"modeSelect\",\n description: \"Change language mode...\",\n bindKey: bindKey(null, null),\n exec: function (editor) {\n editor.prompt({ $type: \"modes\" });\n },\n readOnly: true\n }];\nfor (var i = 1; i < 9; i++) {\n exports.commands.push({\n name: \"foldToLevel\" + i,\n description: \"Fold To Level \" + i,\n level: i,\n exec: function (editor) { editor.session.foldToLevel(this.level); },\n scrollIntoView: \"center\",\n readOnly: true\n });\n}\n\n});\n\nace.define(\"ace/keyboard/gutter_handler\",[\"require\",\"exports\",\"module\",\"ace/lib/keys\",\"ace/mouse/default_gutter_handler\"], function(require, exports, module){\"use strict\";\nvar keys = require('../lib/keys');\nvar GutterTooltip = require(\"../mouse/default_gutter_handler\").GutterTooltip;\nvar GutterKeyboardHandler = /** @class */ (function () {\n function GutterKeyboardHandler(editor) {\n this.editor = editor;\n this.gutterLayer = editor.renderer.$gutterLayer;\n this.element = editor.renderer.$gutter;\n this.lines = editor.renderer.$gutterLayer.$lines;\n this.activeRowIndex = null;\n this.activeLane = null;\n this.annotationTooltip = new GutterTooltip(this.editor);\n }\n GutterKeyboardHandler.prototype.addListener = function () {\n this.element.addEventListener(\"keydown\", this.$onGutterKeyDown.bind(this));\n this.element.addEventListener(\"focusout\", this.$blurGutter.bind(this));\n this.editor.on(\"mousewheel\", this.$blurGutter.bind(this));\n };\n GutterKeyboardHandler.prototype.removeListener = function () {\n this.element.removeEventListener(\"keydown\", this.$onGutterKeyDown.bind(this));\n this.element.removeEventListener(\"focusout\", this.$blurGutter.bind(this));\n this.editor.off(\"mousewheel\", this.$blurGutter.bind(this));\n };\n GutterKeyboardHandler.prototype.$onGutterKeyDown = function (e) {\n if (this.annotationTooltip.isOpen) {\n e.preventDefault();\n if (e.keyCode === keys[\"escape\"])\n this.annotationTooltip.hideTooltip();\n return;\n }\n if (e.target === this.element) {\n if (e.keyCode != keys[\"enter\"]) {\n return;\n }\n e.preventDefault();\n var row = this.editor.getCursorPosition().row;\n if (!this.editor.isRowVisible(row))\n this.editor.scrollToLine(row, true, true);\n setTimeout(\n function () {\n var index = this.$rowToRowIndex(this.gutterLayer.$cursorCell.row);\n var nearestFoldIndex = this.$findNearestFoldWidget(index);\n var nearestAnnotationIndex = this.$findNearestAnnotation(index);\n if (nearestFoldIndex === null && nearestAnnotationIndex === null)\n return;\n if (nearestFoldIndex === null && nearestAnnotationIndex !== null) {\n this.activeRowIndex = nearestAnnotationIndex;\n this.activeLane = \"annotation\";\n this.$focusAnnotation(this.activeRowIndex);\n return;\n }\n if (nearestFoldIndex !== null && nearestAnnotationIndex === null) {\n this.activeRowIndex = nearestFoldIndex;\n this.activeLane = \"fold\";\n this.$focusFoldWidget(this.activeRowIndex);\n return;\n }\n if (Math.abs(nearestAnnotationIndex - index) < Math.abs(nearestFoldIndex - index)) {\n this.activeRowIndex = nearestAnnotationIndex;\n this.activeLane = \"annotation\";\n this.$focusAnnotation(this.activeRowIndex);\n return;\n }\n else {\n this.activeRowIndex = nearestFoldIndex;\n this.activeLane = \"fold\";\n this.$focusFoldWidget(this.activeRowIndex);\n return;\n }\n }.bind(this), 10);\n return;\n }\n this.$handleGutterKeyboardInteraction(e);\n setTimeout(function () {\n this.editor._signal(\"gutterkeydown\", new GutterKeyboardEvent(e, this));\n }.bind(this), 10);\n };\n GutterKeyboardHandler.prototype.$handleGutterKeyboardInteraction = function (e) {\n if (e.keyCode === keys[\"tab\"]) {\n e.preventDefault();\n return;\n }\n if (e.keyCode === keys[\"escape\"]) {\n e.preventDefault();\n this.$blurGutter();\n this.element.focus();\n this.lane = null;\n return;\n }\n if (e.keyCode === keys[\"up\"]) {\n e.preventDefault();\n switch (this.activeLane) {\n case \"fold\":\n this.$moveFoldWidgetUp();\n break;\n case \"annotation\":\n this.$moveAnnotationUp();\n break;\n }\n return;\n }\n if (e.keyCode === keys[\"down\"]) {\n e.preventDefault();\n switch (this.activeLane) {\n case \"fold\":\n this.$moveFoldWidgetDown();\n break;\n case \"annotation\":\n this.$moveAnnotationDown();\n break;\n }\n return;\n }\n if (e.keyCode === keys[\"left\"]) {\n e.preventDefault();\n this.$switchLane(\"annotation\");\n return;\n }\n if (e.keyCode === keys[\"right\"]) {\n e.preventDefault();\n this.$switchLane(\"fold\");\n return;\n }\n if (e.keyCode === keys[\"enter\"] || e.keyCode === keys[\"space\"]) {\n e.preventDefault();\n switch (this.activeLane) {\n case \"fold\":\n if (this.gutterLayer.session.foldWidgets[this.$rowIndexToRow(this.activeRowIndex)] === 'start') {\n var rowFoldingWidget = this.$rowIndexToRow(this.activeRowIndex);\n this.editor.session.onFoldWidgetClick(this.$rowIndexToRow(this.activeRowIndex), e);\n setTimeout(\n function () {\n if (this.$rowIndexToRow(this.activeRowIndex) !== rowFoldingWidget) {\n this.$blurFoldWidget(this.activeRowIndex);\n this.activeRowIndex = this.$rowToRowIndex(rowFoldingWidget);\n this.$focusFoldWidget(this.activeRowIndex);\n }\n }.bind(this), 10);\n break;\n }\n else if (this.gutterLayer.session.foldWidgets[this.$rowIndexToRow(this.activeRowIndex)] === 'end') {\n break;\n }\n return;\n case \"annotation\":\n var gutterElement = this.lines.cells[this.activeRowIndex].element.childNodes[2];\n var rect = gutterElement.getBoundingClientRect();\n var style = this.annotationTooltip.getElement().style;\n style.left = rect.right + \"px\";\n style.top = rect.bottom + \"px\";\n this.annotationTooltip.showTooltip(this.$rowIndexToRow(this.activeRowIndex));\n break;\n }\n return;\n }\n };\n GutterKeyboardHandler.prototype.$blurGutter = function () {\n if (this.activeRowIndex !== null) {\n switch (this.activeLane) {\n case \"fold\":\n this.$blurFoldWidget(this.activeRowIndex);\n break;\n case \"annotation\":\n this.$blurAnnotation(this.activeRowIndex);\n break;\n }\n }\n if (this.annotationTooltip.isOpen)\n this.annotationTooltip.hideTooltip();\n return;\n };\n GutterKeyboardHandler.prototype.$isFoldWidgetVisible = function (index) {\n var isRowFullyVisible = this.editor.isRowFullyVisible(this.$rowIndexToRow(index));\n var isIconVisible = this.$getFoldWidget(index).style.display !== \"none\";\n return isRowFullyVisible && isIconVisible;\n };\n GutterKeyboardHandler.prototype.$isAnnotationVisible = function (index) {\n var isRowFullyVisible = this.editor.isRowFullyVisible(this.$rowIndexToRow(index));\n var isIconVisible = this.$getAnnotation(index).style.display !== \"none\";\n return isRowFullyVisible && isIconVisible;\n };\n GutterKeyboardHandler.prototype.$getFoldWidget = function (index) {\n var cell = this.lines.get(index);\n var element = cell.element;\n return element.childNodes[1];\n };\n GutterKeyboardHandler.prototype.$getAnnotation = function (index) {\n var cell = this.lines.get(index);\n var element = cell.element;\n return element.childNodes[2];\n };\n GutterKeyboardHandler.prototype.$findNearestFoldWidget = function (index) {\n if (this.$isFoldWidgetVisible(index))\n return index;\n var i = 0;\n while (index - i > 0 || index + i < this.lines.getLength() - 1) {\n i++;\n if (index - i >= 0 && this.$isFoldWidgetVisible(index - i))\n return index - i;\n if (index + i <= this.lines.getLength() - 1 && this.$isFoldWidgetVisible(index + i))\n return index + i;\n }\n return null;\n };\n GutterKeyboardHandler.prototype.$findNearestAnnotation = function (index) {\n if (this.$isAnnotationVisible(index))\n return index;\n var i = 0;\n while (index - i > 0 || index + i < this.lines.getLength() - 1) {\n i++;\n if (index - i >= 0 && this.$isAnnotationVisible(index - i))\n return index - i;\n if (index + i <= this.lines.getLength() - 1 && this.$isAnnotationVisible(index + i))\n return index + i;\n }\n return null;\n };\n GutterKeyboardHandler.prototype.$focusFoldWidget = function (index) {\n if (index == null)\n return;\n var foldWidget = this.$getFoldWidget(index);\n foldWidget.classList.add(this.editor.renderer.keyboardFocusClassName);\n foldWidget.focus();\n };\n GutterKeyboardHandler.prototype.$focusAnnotation = function (index) {\n if (index == null)\n return;\n var annotation = this.$getAnnotation(index);\n annotation.classList.add(this.editor.renderer.keyboardFocusClassName);\n annotation.focus();\n };\n GutterKeyboardHandler.prototype.$blurFoldWidget = function (index) {\n var foldWidget = this.$getFoldWidget(index);\n foldWidget.classList.remove(this.editor.renderer.keyboardFocusClassName);\n foldWidget.blur();\n };\n GutterKeyboardHandler.prototype.$blurAnnotation = function (index) {\n var annotation = this.$getAnnotation(index);\n annotation.classList.remove(this.editor.renderer.keyboardFocusClassName);\n annotation.blur();\n };\n GutterKeyboardHandler.prototype.$moveFoldWidgetUp = function () {\n var index = this.activeRowIndex;\n while (index > 0) {\n index--;\n if (this.$isFoldWidgetVisible(index)) {\n this.$blurFoldWidget(this.activeRowIndex);\n this.activeRowIndex = index;\n this.$focusFoldWidget(this.activeRowIndex);\n return;\n }\n }\n return;\n };\n GutterKeyboardHandler.prototype.$moveFoldWidgetDown = function () {\n var index = this.activeRowIndex;\n while (index < this.lines.getLength() - 1) {\n index++;\n if (this.$isFoldWidgetVisible(index)) {\n this.$blurFoldWidget(this.activeRowIndex);\n this.activeRowIndex = index;\n this.$focusFoldWidget(this.activeRowIndex);\n return;\n }\n }\n return;\n };\n GutterKeyboardHandler.prototype.$moveAnnotationUp = function () {\n var index = this.activeRowIndex;\n while (index > 0) {\n index--;\n if (this.$isAnnotationVisible(index)) {\n this.$blurAnnotation(this.activeRowIndex);\n this.activeRowIndex = index;\n this.$focusAnnotation(this.activeRowIndex);\n return;\n }\n }\n return;\n };\n GutterKeyboardHandler.prototype.$moveAnnotationDown = function () {\n var index = this.activeRowIndex;\n while (index < this.lines.getLength() - 1) {\n index++;\n if (this.$isAnnotationVisible(index)) {\n this.$blurAnnotation(this.activeRowIndex);\n this.activeRowIndex = index;\n this.$focusAnnotation(this.activeRowIndex);\n return;\n }\n }\n return;\n };\n GutterKeyboardHandler.prototype.$switchLane = function (desinationLane) {\n switch (desinationLane) {\n case \"annotation\":\n if (this.activeLane === \"annotation\") {\n break;\n }\n var annotationIndex = this.$findNearestAnnotation(this.activeRowIndex);\n if (annotationIndex == null) {\n break;\n }\n this.activeLane = \"annotation\";\n this.$blurFoldWidget(this.activeRowIndex);\n this.activeRowIndex = annotationIndex;\n this.$focusAnnotation(this.activeRowIndex);\n break;\n case \"fold\":\n if (this.activeLane === \"fold\") {\n break;\n }\n var foldWidgetIndex = this.$findNearestFoldWidget(this.activeRowIndex);\n if (foldWidgetIndex == null) {\n break;\n }\n this.activeLane = \"fold\";\n this.$blurAnnotation(this.activeRowIndex);\n this.activeRowIndex = foldWidgetIndex;\n this.$focusFoldWidget(this.activeRowIndex);\n break;\n }\n return;\n };\n GutterKeyboardHandler.prototype.$rowIndexToRow = function (index) {\n var cell = this.lines.get(index);\n if (cell)\n return cell.row;\n return null;\n };\n GutterKeyboardHandler.prototype.$rowToRowIndex = function (row) {\n for (var i = 0; i < this.lines.getLength(); i++) {\n var cell = this.lines.get(i);\n if (cell.row == row)\n return i;\n }\n return null;\n };\n return GutterKeyboardHandler;\n}());\nexports.GutterKeyboardHandler = GutterKeyboardHandler;\nvar GutterKeyboardEvent = /** @class */ (function () {\n function GutterKeyboardEvent(domEvent, gutterKeyboardHandler) {\n this.gutterKeyboardHandler = gutterKeyboardHandler;\n this.domEvent = domEvent;\n }\n GutterKeyboardEvent.prototype.getKey = function () {\n return keys.keyCodeToString(this.domEvent.keyCode);\n };\n GutterKeyboardEvent.prototype.getRow = function () {\n return this.gutterKeyboardHandler.$rowIndexToRow(this.gutterKeyboardHandler.activeRowIndex);\n };\n GutterKeyboardEvent.prototype.isInAnnotationLane = function () {\n return this.gutterKeyboardHandler.activeLane === \"annotation\";\n };\n GutterKeyboardEvent.prototype.isInFoldLane = function () {\n return this.gutterKeyboardHandler.activeLane === \"fold\";\n };\n return GutterKeyboardEvent;\n}());\nexports.GutterKeyboardEvent = GutterKeyboardEvent;\n\n});\n\nace.define(\"ace/editor\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/dom\",\"ace/lib/lang\",\"ace/lib/useragent\",\"ace/keyboard/textinput\",\"ace/mouse/mouse_handler\",\"ace/mouse/fold_handler\",\"ace/keyboard/keybinding\",\"ace/edit_session\",\"ace/search\",\"ace/range\",\"ace/lib/event_emitter\",\"ace/commands/command_manager\",\"ace/commands/default_commands\",\"ace/config\",\"ace/token_iterator\",\"ace/keyboard/gutter_handler\",\"ace/config\",\"ace/clipboard\",\"ace/lib/keys\"], function(require, exports, module){\"use strict\";\nvar __values = (this && this.__values) || function(o) {\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\n if (m) return m.call(o);\n if (o && typeof o.length === \"number\") return {\n next: function () {\n if (o && i >= o.length) o = void 0;\n return { value: o && o[i++], done: !o };\n }\n };\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\n};\nvar oop = require(\"./lib/oop\");\nvar dom = require(\"./lib/dom\");\nvar lang = require(\"./lib/lang\");\nvar useragent = require(\"./lib/useragent\");\nvar TextInput = require(\"./keyboard/textinput\").TextInput;\nvar MouseHandler = require(\"./mouse/mouse_handler\").MouseHandler;\nvar FoldHandler = require(\"./mouse/fold_handler\").FoldHandler;\nvar KeyBinding = require(\"./keyboard/keybinding\").KeyBinding;\nvar EditSession = require(\"./edit_session\").EditSession;\nvar Search = require(\"./search\").Search;\nvar Range = require(\"./range\").Range;\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar CommandManager = require(\"./commands/command_manager\").CommandManager;\nvar defaultCommands = require(\"./commands/default_commands\").commands;\nvar config = require(\"./config\");\nvar TokenIterator = require(\"./token_iterator\").TokenIterator;\nvar GutterKeyboardHandler = require(\"./keyboard/gutter_handler\").GutterKeyboardHandler;\nvar nls = require(\"./config\").nls;\nvar clipboard = require(\"./clipboard\");\nvar keys = require('./lib/keys');\nvar Editor = /** @class */ (function () {\n function Editor(renderer, session, options) { this.session;\n this.$toDestroy = [];\n var container = renderer.getContainerElement();\n this.container = container;\n this.renderer = renderer;\n this.id = \"editor\" + (++Editor.$uid);\n this.commands = new CommandManager(useragent.isMac ? \"mac\" : \"win\", defaultCommands);\n if (typeof document == \"object\") {\n this.textInput = new TextInput(renderer.getTextAreaContainer(), this);\n this.renderer.textarea = this.textInput.getElement();\n this.$mouseHandler = new MouseHandler(this);\n new FoldHandler(this);\n }\n this.keyBinding = new KeyBinding(this);\n this.$search = new Search().set({\n wrap: true\n });\n this.$historyTracker = this.$historyTracker.bind(this);\n this.commands.on(\"exec\", this.$historyTracker);\n this.$initOperationListeners();\n this._$emitInputEvent = lang.delayedCall(function () {\n this._signal(\"input\", {});\n if (this.session && !this.session.destroyed)\n this.session.bgTokenizer.scheduleStart();\n }.bind(this));\n this.on(\"change\", function (_, _self) {\n _self._$emitInputEvent.schedule(31);\n });\n this.setSession(session || options && options.session || new EditSession(\"\"));\n config.resetOptions(this);\n if (options)\n this.setOptions(options);\n config._signal(\"editor\", this);\n }\n Editor.prototype.$initOperationListeners = function () {\n this.commands.on(\"exec\", this.startOperation.bind(this), true);\n this.commands.on(\"afterExec\", this.endOperation.bind(this), true);\n };\n Editor.prototype.startOperation = function (commandEvent) {\n this.session.startOperation(commandEvent);\n };\n Editor.prototype.endOperation = function (e) {\n this.session.endOperation(e);\n };\n Editor.prototype.onStartOperation = function (commandEvent) {\n this.curOp = this.session.curOp;\n this.curOp.scrollTop = this.renderer.scrollTop;\n this.prevOp = this.session.prevOp;\n if (!commandEvent) {\n this.previousCommand = null;\n }\n };\n Editor.prototype.onEndOperation = function (e) {\n if (this.curOp && this.session) {\n if (e && e.returnValue === false) {\n this.curOp = null;\n return;\n }\n this._signal(\"beforeEndOperation\");\n if (!this.curOp)\n return;\n var command = this.curOp.command;\n var scrollIntoView = command && command.scrollIntoView;\n if (scrollIntoView) {\n switch (scrollIntoView) {\n case \"center-animate\":\n scrollIntoView = \"animate\";\n case \"center\":\n this.renderer.scrollCursorIntoView(null, 0.5);\n break;\n case \"animate\":\n case \"cursor\":\n this.renderer.scrollCursorIntoView();\n break;\n case \"selectionPart\":\n var range = this.selection.getRange();\n var config = this.renderer.layerConfig;\n if (range.start.row >= config.lastRow || range.end.row <= config.firstRow) {\n this.renderer.scrollSelectionIntoView(this.selection.anchor, this.selection.lead);\n }\n break;\n default:\n break;\n }\n if (scrollIntoView == \"animate\")\n this.renderer.animateScrolling(this.curOp.scrollTop);\n }\n this.$lastSel = this.session.selection.toJSON();\n this.prevOp = this.curOp;\n this.curOp = null;\n }\n };\n Editor.prototype.$historyTracker = function (e) {\n if (!this.$mergeUndoDeltas)\n return;\n var prev = this.prevOp;\n var mergeableCommands = this.$mergeableCommands;\n var shouldMerge = prev.command && (e.command.name == prev.command.name);\n if (e.command.name == \"insertstring\") {\n var text = e.args;\n if (this.mergeNextCommand === undefined)\n this.mergeNextCommand = true;\n shouldMerge = shouldMerge\n && this.mergeNextCommand // previous command allows to coalesce with\n && (!/\\s/.test(text) || /\\s/.test(prev.args)); // previous insertion was of same type\n this.mergeNextCommand = true;\n }\n else {\n shouldMerge = shouldMerge\n && mergeableCommands.indexOf(e.command.name) !== -1; // the command is mergeable\n }\n if (this.$mergeUndoDeltas != \"always\"\n && Date.now() - this.sequenceStartTime > 2000) {\n shouldMerge = false; // the sequence is too long\n }\n if (shouldMerge)\n this.session.mergeUndoDeltas = true;\n else if (mergeableCommands.indexOf(e.command.name) !== -1)\n this.sequenceStartTime = Date.now();\n };\n Editor.prototype.setKeyboardHandler = function (keyboardHandler, cb) {\n if (keyboardHandler && typeof keyboardHandler === \"string\" && keyboardHandler != \"ace\") {\n this.$keybindingId = keyboardHandler;\n var _self = this;\n config.loadModule([\"keybinding\", keyboardHandler], function (module) {\n if (_self.$keybindingId == keyboardHandler)\n _self.keyBinding.setKeyboardHandler(module && module.handler);\n cb && cb();\n });\n }\n else {\n this.$keybindingId = null;\n this.keyBinding.setKeyboardHandler(keyboardHandler);\n cb && cb();\n }\n };\n Editor.prototype.getKeyboardHandler = function () {\n return this.keyBinding.getKeyboardHandler();\n };\n Editor.prototype.setSession = function (session) {\n if (this.session == session)\n return;\n if (this.curOp)\n this.endOperation();\n this.curOp = {};\n var oldSession = this.session;\n if (oldSession) {\n this.session.off(\"change\", this.$onDocumentChange);\n this.session.off(\"changeMode\", this.$onChangeMode);\n this.session.off(\"tokenizerUpdate\", this.$onTokenizerUpdate);\n this.session.off(\"changeTabSize\", this.$onChangeTabSize);\n this.session.off(\"changeWrapLimit\", this.$onChangeWrapLimit);\n this.session.off(\"changeWrapMode\", this.$onChangeWrapMode);\n this.session.off(\"changeFold\", this.$onChangeFold);\n this.session.off(\"changeFrontMarker\", this.$onChangeFrontMarker);\n this.session.off(\"changeBackMarker\", this.$onChangeBackMarker);\n this.session.off(\"changeBreakpoint\", this.$onChangeBreakpoint);\n this.session.off(\"changeAnnotation\", this.$onChangeAnnotation);\n this.session.off(\"changeOverwrite\", this.$onCursorChange);\n this.session.off(\"changeScrollTop\", this.$onScrollTopChange);\n this.session.off(\"changeScrollLeft\", this.$onScrollLeftChange);\n this.session.off(\"startOperation\", this.$onStartOperation);\n this.session.off(\"endOperation\", this.$onEndOperation);\n var selection = this.session.getSelection();\n selection.off(\"changeCursor\", this.$onCursorChange);\n selection.off(\"changeSelection\", this.$onSelectionChange);\n }\n this.session = session;\n if (session) {\n this.$onDocumentChange = this.onDocumentChange.bind(this);\n session.on(\"change\", this.$onDocumentChange);\n this.renderer.setSession(session);\n this.$onChangeMode = this.onChangeMode.bind(this);\n session.on(\"changeMode\", this.$onChangeMode);\n this.$onTokenizerUpdate = this.onTokenizerUpdate.bind(this);\n session.on(\"tokenizerUpdate\", this.$onTokenizerUpdate);\n this.$onChangeTabSize = this.renderer.onChangeTabSize.bind(this.renderer);\n session.on(\"changeTabSize\", this.$onChangeTabSize);\n this.$onChangeWrapLimit = this.onChangeWrapLimit.bind(this);\n session.on(\"changeWrapLimit\", this.$onChangeWrapLimit);\n this.$onChangeWrapMode = this.onChangeWrapMode.bind(this);\n session.on(\"changeWrapMode\", this.$onChangeWrapMode);\n this.$onChangeFold = this.onChangeFold.bind(this);\n session.on(\"changeFold\", this.$onChangeFold);\n this.$onChangeFrontMarker = this.onChangeFrontMarker.bind(this);\n this.session.on(\"changeFrontMarker\", this.$onChangeFrontMarker);\n this.$onChangeBackMarker = this.onChangeBackMarker.bind(this);\n this.session.on(\"changeBackMarker\", this.$onChangeBackMarker);\n this.$onChangeBreakpoint = this.onChangeBreakpoint.bind(this);\n this.session.on(\"changeBreakpoint\", this.$onChangeBreakpoint);\n this.$onChangeAnnotation = this.onChangeAnnotation.bind(this);\n this.session.on(\"changeAnnotation\", this.$onChangeAnnotation);\n this.$onCursorChange = this.onCursorChange.bind(this);\n this.session.on(\"changeOverwrite\", this.$onCursorChange);\n this.$onScrollTopChange = this.onScrollTopChange.bind(this);\n this.session.on(\"changeScrollTop\", this.$onScrollTopChange);\n this.$onScrollLeftChange = this.onScrollLeftChange.bind(this);\n this.session.on(\"changeScrollLeft\", this.$onScrollLeftChange);\n this.selection = session.getSelection();\n this.selection.on(\"changeCursor\", this.$onCursorChange);\n this.$onSelectionChange = this.onSelectionChange.bind(this);\n this.selection.on(\"changeSelection\", this.$onSelectionChange);\n this.$onStartOperation = this.onStartOperation.bind(this);\n this.session.on(\"startOperation\", this.$onStartOperation);\n this.$onEndOperation = this.onEndOperation.bind(this);\n this.session.on(\"endOperation\", this.$onEndOperation);\n this.onChangeMode();\n this.onCursorChange();\n this.onScrollTopChange();\n this.onScrollLeftChange();\n this.onSelectionChange();\n this.onChangeFrontMarker();\n this.onChangeBackMarker();\n this.onChangeBreakpoint();\n this.onChangeAnnotation();\n this.session.getUseWrapMode() && this.renderer.adjustWrapLimit();\n this.renderer.updateFull();\n }\n else {\n this.selection = null;\n this.renderer.setSession(session);\n }\n this._signal(\"changeSession\", {\n session: session,\n oldSession: oldSession\n });\n this.curOp = null;\n oldSession && oldSession._signal(\"changeEditor\", { oldEditor: this });\n if (oldSession)\n oldSession.$editor = null;\n session && session._signal(\"changeEditor\", { editor: this });\n if (session)\n session.$editor = this;\n if (session && !session.destroyed)\n session.bgTokenizer.scheduleStart();\n };\n Editor.prototype.getSession = function () {\n return this.session;\n };\n Editor.prototype.setValue = function (val, cursorPos) {\n this.session.doc.setValue(val);\n if (!cursorPos)\n this.selectAll();\n else if (cursorPos == 1)\n this.navigateFileEnd();\n else if (cursorPos == -1)\n this.navigateFileStart();\n return val;\n };\n Editor.prototype.getValue = function () {\n return this.session.getValue();\n };\n Editor.prototype.getSelection = function () {\n return this.selection;\n };\n Editor.prototype.resize = function (force) {\n this.renderer.onResize(force);\n };\n Editor.prototype.setTheme = function (theme, cb) {\n this.renderer.setTheme(theme, cb);\n };\n Editor.prototype.getTheme = function () {\n return this.renderer.getTheme();\n };\n Editor.prototype.setStyle = function (style) {\n this.renderer.setStyle(style);\n };\n Editor.prototype.unsetStyle = function (style) {\n this.renderer.unsetStyle(style);\n };\n Editor.prototype.getFontSize = function () {\n return this.getOption(\"fontSize\") ||\n dom.computedStyle(this.container).fontSize;\n };\n Editor.prototype.setFontSize = function (size) {\n this.setOption(\"fontSize\", size);\n };\n Editor.prototype.$highlightBrackets = function () {\n if (this.$highlightPending) {\n return;\n }\n var self = this;\n this.$highlightPending = true;\n setTimeout(function () {\n self.$highlightPending = false;\n var session = self.session;\n if (!session || session.destroyed)\n return;\n if (session.$bracketHighlight) {\n session.$bracketHighlight.markerIds.forEach(function (id) {\n session.removeMarker(id);\n });\n session.$bracketHighlight = null;\n }\n var pos = self.getCursorPosition();\n var handler = self.getKeyboardHandler();\n var isBackwards = handler && handler.$getDirectionForHighlight && handler.$getDirectionForHighlight(self);\n var ranges = session.getMatchingBracketRanges(pos, isBackwards);\n if (!ranges) {\n var iterator = new TokenIterator(session, pos.row, pos.column);\n var token = iterator.getCurrentToken();\n if (token && /\\b(?:tag-open|tag-name)/.test(token.type)) {\n var tagNamesRanges = session.getMatchingTags(pos);\n if (tagNamesRanges) {\n ranges = [\n tagNamesRanges.openTagName.isEmpty() ? tagNamesRanges.openTag : tagNamesRanges.openTagName,\n tagNamesRanges.closeTagName.isEmpty() ? tagNamesRanges.closeTag : tagNamesRanges.closeTagName\n ];\n }\n }\n }\n if (!ranges && session.$mode.getMatching)\n ranges = session.$mode.getMatching(self.session);\n if (!ranges) {\n if (self.getHighlightIndentGuides())\n self.renderer.$textLayer.$highlightIndentGuide();\n return;\n }\n var markerType = \"ace_bracket\";\n if (!Array.isArray(ranges)) {\n ranges = [ranges];\n }\n else if (ranges.length == 1) {\n markerType = \"ace_error_bracket\";\n }\n if (ranges.length == 2) {\n if (Range.comparePoints(ranges[0].end, ranges[1].start) == 0)\n ranges = [Range.fromPoints(ranges[0].start, ranges[1].end)];\n else if (Range.comparePoints(ranges[0].start, ranges[1].end) == 0)\n ranges = [Range.fromPoints(ranges[1].start, ranges[0].end)];\n }\n session.$bracketHighlight = {\n ranges: ranges,\n markerIds: ranges.map(function (range) {\n return session.addMarker(range, markerType, \"text\");\n })\n };\n if (self.getHighlightIndentGuides())\n self.renderer.$textLayer.$highlightIndentGuide();\n }, 50);\n };\n Editor.prototype.focus = function () {\n this.textInput.focus();\n };\n Editor.prototype.isFocused = function () {\n return this.textInput.isFocused();\n };\n Editor.prototype.blur = function () {\n this.textInput.blur();\n };\n Editor.prototype.onFocus = function (e) {\n if (this.$isFocused)\n return;\n this.$isFocused = true;\n this.renderer.showCursor();\n this.renderer.visualizeFocus();\n this._emit(\"focus\", e);\n };\n Editor.prototype.onBlur = function (e) {\n if (!this.$isFocused)\n return;\n this.$isFocused = false;\n this.renderer.hideCursor();\n this.renderer.visualizeBlur();\n this._emit(\"blur\", e);\n };\n Editor.prototype.$cursorChange = function () {\n this.renderer.updateCursor();\n this.$highlightBrackets();\n this.$updateHighlightActiveLine();\n };\n Editor.prototype.onDocumentChange = function (delta) {\n var wrap = this.session.$useWrapMode;\n var lastRow = (delta.start.row == delta.end.row ? delta.end.row : Infinity);\n this.renderer.updateLines(delta.start.row, lastRow, wrap);\n this._signal(\"change\", delta);\n this.$cursorChange();\n };\n Editor.prototype.onTokenizerUpdate = function (e) {\n var rows = e.data;\n this.renderer.updateLines(rows.first, rows.last);\n };\n Editor.prototype.onScrollTopChange = function () {\n this.renderer.scrollToY(this.session.getScrollTop());\n };\n Editor.prototype.onScrollLeftChange = function () {\n this.renderer.scrollToX(this.session.getScrollLeft());\n };\n Editor.prototype.onCursorChange = function () {\n this.$cursorChange();\n this._signal(\"changeSelection\");\n };\n Editor.prototype.$updateHighlightActiveLine = function () {\n var session = this.getSession();\n var highlight;\n if (this.$highlightActiveLine) {\n if (this.$selectionStyle != \"line\" || !this.selection.isMultiLine())\n highlight = this.getCursorPosition();\n if (this.renderer.theme && this.renderer.theme.$selectionColorConflict && !this.selection.isEmpty())\n highlight = false;\n if (this.renderer.$maxLines && this.session.getLength() === 1 && !(this.renderer.$minLines > 1))\n highlight = false;\n }\n if (session.$highlightLineMarker && !highlight) {\n session.removeMarker(session.$highlightLineMarker.id);\n session.$highlightLineMarker = null;\n }\n else if (!session.$highlightLineMarker && highlight) {\n var range = new Range(highlight.row, highlight.column, highlight.row, Infinity);\n range.id = session.addMarker(range, \"ace_active-line\", \"screenLine\");\n session.$highlightLineMarker = range;\n }\n else if (highlight) {\n session.$highlightLineMarker.start.row = highlight.row;\n session.$highlightLineMarker.end.row = highlight.row;\n session.$highlightLineMarker.start.column = highlight.column;\n session._signal(\"changeBackMarker\");\n }\n };\n Editor.prototype.onSelectionChange = function (e) {\n var session = this.session;\n if (session.$selectionMarker) {\n session.removeMarker(session.$selectionMarker);\n }\n session.$selectionMarker = null;\n if (!this.selection.isEmpty()) {\n var range = this.selection.getRange();\n var style = this.getSelectionStyle();\n session.$selectionMarker = session.addMarker(range, \"ace_selection\", style);\n }\n else {\n this.$updateHighlightActiveLine();\n }\n var re = this.$highlightSelectedWord && this.$getSelectionHighLightRegexp();\n this.session.highlight(re);\n this._signal(\"changeSelection\");\n };\n Editor.prototype.$getSelectionHighLightRegexp = function () {\n var session = this.session;\n var selection = this.getSelectionRange();\n if (selection.isEmpty() || selection.isMultiLine())\n return;\n var startColumn = selection.start.column;\n var endColumn = selection.end.column;\n var line = session.getLine(selection.start.row);\n var needle = line.substring(startColumn, endColumn);\n if (needle.length > 5000 || !/[\\w\\d]/.test(needle))\n return;\n var re = this.$search.$assembleRegExp({\n wholeWord: true,\n caseSensitive: true,\n needle: needle\n });\n var wordWithBoundary = line.substring(startColumn - 1, endColumn + 1);\n if (!re.test(wordWithBoundary))\n return;\n return re;\n };\n Editor.prototype.onChangeFrontMarker = function () {\n this.renderer.updateFrontMarkers();\n };\n Editor.prototype.onChangeBackMarker = function () {\n this.renderer.updateBackMarkers();\n };\n Editor.prototype.onChangeBreakpoint = function () {\n this.renderer.updateBreakpoints();\n };\n Editor.prototype.onChangeAnnotation = function () {\n this.renderer.setAnnotations(this.session.getAnnotations());\n };\n Editor.prototype.onChangeMode = function (e) {\n this.renderer.updateText();\n this._emit(\"changeMode\", e);\n };\n Editor.prototype.onChangeWrapLimit = function () {\n this.renderer.updateFull();\n };\n Editor.prototype.onChangeWrapMode = function () {\n this.renderer.onResize(true);\n };\n Editor.prototype.onChangeFold = function () {\n this.$updateHighlightActiveLine();\n this.renderer.updateFull();\n };\n Editor.prototype.getSelectedText = function () {\n return this.session.getTextRange(this.getSelectionRange());\n };\n Editor.prototype.getCopyText = function () {\n var text = this.getSelectedText();\n var nl = this.session.doc.getNewLineCharacter();\n var copyLine = false;\n if (!text && this.$copyWithEmptySelection) {\n copyLine = true;\n var ranges = this.selection.getAllRanges();\n for (var i = 0; i < ranges.length; i++) {\n var range = ranges[i];\n if (i && ranges[i - 1].start.row == range.start.row)\n continue;\n text += this.session.getLine(range.start.row) + nl;\n }\n }\n var e = { text: text };\n this._signal(\"copy\", e);\n clipboard.lineMode = copyLine ? e.text : false;\n return e.text;\n };\n Editor.prototype.onCopy = function () {\n this.commands.exec(\"copy\", this);\n };\n Editor.prototype.onCut = function () {\n this.commands.exec(\"cut\", this);\n };\n Editor.prototype.onPaste = function (text, event) {\n var e = { text: text, event: event };\n this.commands.exec(\"paste\", this, e);\n };\n Editor.prototype.$handlePaste = function (e) {\n if (typeof e == \"string\")\n e = { text: e };\n this._signal(\"paste\", e);\n var text = e.text;\n var lineMode = text === clipboard.lineMode;\n var session = this.session;\n if (!this.inMultiSelectMode || this.inVirtualSelectionMode) {\n if (lineMode)\n session.insert({ row: this.selection.lead.row, column: 0 }, text);\n else\n this.insert(text);\n }\n else if (lineMode) {\n this.selection.rangeList.ranges.forEach(function (range) {\n session.insert({ row: range.start.row, column: 0 }, text);\n });\n }\n else {\n var lines = text.split(/\\r\\n|\\r|\\n/);\n var ranges = this.selection.rangeList.ranges;\n var isFullLine = lines.length == 2 && (!lines[0] || !lines[1]);\n if (lines.length != ranges.length || isFullLine)\n return this.commands.exec(\"insertstring\", this, text);\n for (var i = ranges.length; i--;) {\n var range = ranges[i];\n if (!range.isEmpty())\n session.remove(range);\n session.insert(range.start, lines[i]);\n }\n }\n };\n Editor.prototype.execCommand = function (command, args) {\n return this.commands.exec(command, this, args);\n };\n Editor.prototype.insert = function (text, pasted) {\n var session = this.session;\n var mode = session.getMode();\n var cursor = this.getCursorPosition();\n if (this.getBehavioursEnabled() && !pasted) {\n var transform = mode.transformAction(session.getState(cursor.row), 'insertion', this, session, text);\n if (transform) {\n if (text !== transform.text) {\n if (!this.inVirtualSelectionMode) {\n this.session.mergeUndoDeltas = false;\n this.mergeNextCommand = false;\n }\n }\n text = transform.text;\n }\n }\n if (text == \"\\t\")\n text = this.session.getTabString();\n if (!this.selection.isEmpty()) {\n var range = this.getSelectionRange();\n cursor = this.session.remove(range);\n this.clearSelection();\n }\n else if (this.session.getOverwrite() && text.indexOf(\"\\n\") == -1) {\n var range = Range.fromPoints(cursor, cursor);\n range.end.column += text.length;\n this.session.remove(range);\n }\n if (text == \"\\n\" || text == \"\\r\\n\") {\n var line = session.getLine(cursor.row);\n if (cursor.column > line.search(/\\S|$/)) {\n var d = line.substr(cursor.column).search(/\\S|$/);\n session.doc.removeInLine(cursor.row, cursor.column, cursor.column + d);\n }\n }\n this.clearSelection();\n var start = cursor.column;\n var lineState = session.getState(cursor.row);\n var line = session.getLine(cursor.row);\n var shouldOutdent = mode.checkOutdent(lineState, line, text);\n session.insert(cursor, text);\n if (transform && transform.selection) {\n if (transform.selection.length == 2) { // Transform relative to the current column\n this.selection.setSelectionRange(new Range(cursor.row, start + transform.selection[0], cursor.row, start + transform.selection[1]));\n }\n else { // Transform relative to the current row.\n this.selection.setSelectionRange(new Range(cursor.row + transform.selection[0], transform.selection[1], cursor.row + transform.selection[2], transform.selection[3]));\n }\n }\n if (this.$enableAutoIndent) {\n if (session.getDocument().isNewLine(text)) {\n var lineIndent = mode.getNextLineIndent(lineState, line.slice(0, cursor.column), session.getTabString());\n session.insert({ row: cursor.row + 1, column: 0 }, lineIndent);\n }\n if (shouldOutdent)\n mode.autoOutdent(lineState, session, cursor.row);\n }\n };\n Editor.prototype.autoIndent = function () {\n var session = this.session;\n var mode = session.getMode();\n var ranges = this.selection.isEmpty()\n ? [new Range(0, 0, session.doc.getLength() - 1, 0)]\n : this.selection.getAllRanges();\n var prevLineState = \"\";\n var prevLine = \"\";\n var lineIndent = \"\";\n var tab = session.getTabString();\n for (var i = 0; i < ranges.length; i++) {\n var startRow = ranges[i].start.row;\n var endRow = ranges[i].end.row;\n for (var row = startRow; row <= endRow; row++) {\n if (row > 0) {\n prevLineState = session.getState(row - 1);\n prevLine = session.getLine(row - 1);\n lineIndent = mode.getNextLineIndent(prevLineState, prevLine, tab);\n }\n var line = session.getLine(row);\n var currIndent = mode.$getIndent(line);\n if (lineIndent !== currIndent) {\n if (currIndent.length > 0) {\n var range = new Range(row, 0, row, currIndent.length);\n session.remove(range);\n }\n if (lineIndent.length > 0) {\n session.insert({ row: row, column: 0 }, lineIndent);\n }\n }\n mode.autoOutdent(prevLineState, session, row);\n }\n }\n };\n Editor.prototype.onTextInput = function (text, composition) {\n if (!composition)\n return this.keyBinding.onTextInput(text);\n this.startOperation({ command: { name: \"insertstring\" } });\n var applyComposition = this.applyComposition.bind(this, text, composition);\n if (this.selection.rangeCount)\n this.forEachSelection(applyComposition);\n else\n applyComposition();\n this.endOperation();\n };\n Editor.prototype.applyComposition = function (text, composition) {\n if (composition.extendLeft || composition.extendRight) {\n var r = this.selection.getRange();\n r.start.column -= composition.extendLeft;\n r.end.column += composition.extendRight;\n if (r.start.column < 0) {\n r.start.row--;\n r.start.column += this.session.getLine(r.start.row).length + 1;\n }\n this.selection.setRange(r);\n if (!text && !r.isEmpty())\n this.remove();\n }\n if (text || !this.selection.isEmpty())\n this.insert(text, true);\n if (composition.restoreStart || composition.restoreEnd) {\n var r = this.selection.getRange();\n r.start.column -= composition.restoreStart;\n r.end.column -= composition.restoreEnd;\n this.selection.setRange(r);\n }\n };\n Editor.prototype.onCommandKey = function (e, hashId, keyCode) {\n return this.keyBinding.onCommandKey(e, hashId, keyCode);\n };\n Editor.prototype.setOverwrite = function (overwrite) {\n this.session.setOverwrite(overwrite);\n };\n Editor.prototype.getOverwrite = function () {\n return this.session.getOverwrite();\n };\n Editor.prototype.toggleOverwrite = function () {\n this.session.toggleOverwrite();\n };\n Editor.prototype.setScrollSpeed = function (speed) {\n this.setOption(\"scrollSpeed\", speed);\n };\n Editor.prototype.getScrollSpeed = function () {\n return this.getOption(\"scrollSpeed\");\n };\n Editor.prototype.setDragDelay = function (dragDelay) {\n this.setOption(\"dragDelay\", dragDelay);\n };\n Editor.prototype.getDragDelay = function () {\n return this.getOption(\"dragDelay\");\n };\n Editor.prototype.setSelectionStyle = function (val) {\n this.setOption(\"selectionStyle\", val);\n };\n Editor.prototype.getSelectionStyle = function () {\n return this.getOption(\"selectionStyle\");\n };\n Editor.prototype.setHighlightActiveLine = function (shouldHighlight) {\n this.setOption(\"highlightActiveLine\", shouldHighlight);\n };\n Editor.prototype.getHighlightActiveLine = function () {\n return this.getOption(\"highlightActiveLine\");\n };\n Editor.prototype.setHighlightGutterLine = function (shouldHighlight) {\n this.setOption(\"highlightGutterLine\", shouldHighlight);\n };\n Editor.prototype.getHighlightGutterLine = function () {\n return this.getOption(\"highlightGutterLine\");\n };\n Editor.prototype.setHighlightSelectedWord = function (shouldHighlight) {\n this.setOption(\"highlightSelectedWord\", shouldHighlight);\n };\n Editor.prototype.getHighlightSelectedWord = function () {\n return this.$highlightSelectedWord;\n };\n Editor.prototype.setAnimatedScroll = function (shouldAnimate) {\n this.renderer.setAnimatedScroll(shouldAnimate);\n };\n Editor.prototype.getAnimatedScroll = function () {\n return this.renderer.getAnimatedScroll();\n };\n Editor.prototype.setShowInvisibles = function (showInvisibles) {\n this.renderer.setShowInvisibles(showInvisibles);\n };\n Editor.prototype.getShowInvisibles = function () {\n return this.renderer.getShowInvisibles();\n };\n Editor.prototype.setDisplayIndentGuides = function (display) {\n this.renderer.setDisplayIndentGuides(display);\n };\n Editor.prototype.getDisplayIndentGuides = function () {\n return this.renderer.getDisplayIndentGuides();\n };\n Editor.prototype.setHighlightIndentGuides = function (highlight) {\n this.renderer.setHighlightIndentGuides(highlight);\n };\n Editor.prototype.getHighlightIndentGuides = function () {\n return this.renderer.getHighlightIndentGuides();\n };\n Editor.prototype.setShowPrintMargin = function (showPrintMargin) {\n this.renderer.setShowPrintMargin(showPrintMargin);\n };\n Editor.prototype.getShowPrintMargin = function () {\n return this.renderer.getShowPrintMargin();\n };\n Editor.prototype.setPrintMarginColumn = function (showPrintMargin) {\n this.renderer.setPrintMarginColumn(showPrintMargin);\n };\n Editor.prototype.getPrintMarginColumn = function () {\n return this.renderer.getPrintMarginColumn();\n };\n Editor.prototype.setReadOnly = function (readOnly) {\n this.setOption(\"readOnly\", readOnly);\n };\n Editor.prototype.getReadOnly = function () {\n return this.getOption(\"readOnly\");\n };\n Editor.prototype.setBehavioursEnabled = function (enabled) {\n this.setOption(\"behavioursEnabled\", enabled);\n };\n Editor.prototype.getBehavioursEnabled = function () {\n return this.getOption(\"behavioursEnabled\");\n };\n Editor.prototype.setWrapBehavioursEnabled = function (enabled) {\n this.setOption(\"wrapBehavioursEnabled\", enabled);\n };\n Editor.prototype.getWrapBehavioursEnabled = function () {\n return this.getOption(\"wrapBehavioursEnabled\");\n };\n Editor.prototype.setShowFoldWidgets = function (show) {\n this.setOption(\"showFoldWidgets\", show);\n };\n Editor.prototype.getShowFoldWidgets = function () {\n return this.getOption(\"showFoldWidgets\");\n };\n Editor.prototype.setFadeFoldWidgets = function (fade) {\n this.setOption(\"fadeFoldWidgets\", fade);\n };\n Editor.prototype.getFadeFoldWidgets = function () {\n return this.getOption(\"fadeFoldWidgets\");\n };\n Editor.prototype.remove = function (dir) {\n if (this.selection.isEmpty()) {\n if (dir == \"left\")\n this.selection.selectLeft();\n else\n this.selection.selectRight();\n }\n var range = this.getSelectionRange();\n if (this.getBehavioursEnabled()) {\n var session = this.session;\n var state = session.getState(range.start.row);\n var new_range = session.getMode().transformAction(state, 'deletion', this, session, range);\n if (range.end.column === 0) {\n var text = session.getTextRange(range);\n if (text[text.length - 1] == \"\\n\") {\n var line = session.getLine(range.end.row);\n if (/^\\s+$/.test(line)) {\n range.end.column = line.length;\n }\n }\n }\n if (new_range)\n range = new_range;\n }\n this.session.remove(range);\n this.clearSelection();\n };\n Editor.prototype.removeWordRight = function () {\n if (this.selection.isEmpty())\n this.selection.selectWordRight();\n this.session.remove(this.getSelectionRange());\n this.clearSelection();\n };\n Editor.prototype.removeWordLeft = function () {\n if (this.selection.isEmpty())\n this.selection.selectWordLeft();\n this.session.remove(this.getSelectionRange());\n this.clearSelection();\n };\n Editor.prototype.removeToLineStart = function () {\n if (this.selection.isEmpty())\n this.selection.selectLineStart();\n if (this.selection.isEmpty())\n this.selection.selectLeft();\n this.session.remove(this.getSelectionRange());\n this.clearSelection();\n };\n Editor.prototype.removeToLineEnd = function () {\n if (this.selection.isEmpty())\n this.selection.selectLineEnd();\n var range = this.getSelectionRange();\n if (range.start.column == range.end.column && range.start.row == range.end.row) {\n range.end.column = 0;\n range.end.row++;\n }\n this.session.remove(range);\n this.clearSelection();\n };\n Editor.prototype.splitLine = function () {\n if (!this.selection.isEmpty()) {\n this.session.remove(this.getSelectionRange());\n this.clearSelection();\n }\n var cursor = this.getCursorPosition();\n this.insert(\"\\n\");\n this.moveCursorToPosition(cursor);\n };\n Editor.prototype.setGhostText = function (text, position) {\n this.renderer.setGhostText(text, position);\n };\n Editor.prototype.removeGhostText = function () {\n this.renderer.removeGhostText();\n };\n Editor.prototype.transposeLetters = function () {\n if (!this.selection.isEmpty()) {\n return;\n }\n var cursor = this.getCursorPosition();\n var column = cursor.column;\n if (column === 0)\n return;\n var line = this.session.getLine(cursor.row);\n var swap, range;\n if (column < line.length) {\n swap = line.charAt(column) + line.charAt(column - 1);\n range = new Range(cursor.row, column - 1, cursor.row, column + 1);\n }\n else {\n swap = line.charAt(column - 1) + line.charAt(column - 2);\n range = new Range(cursor.row, column - 2, cursor.row, column);\n }\n this.session.replace(range, swap);\n this.session.selection.moveToPosition(range.end);\n };\n Editor.prototype.toLowerCase = function () {\n var originalRange = this.getSelectionRange();\n if (this.selection.isEmpty()) {\n this.selection.selectWord();\n }\n var range = this.getSelectionRange();\n var text = this.session.getTextRange(range);\n this.session.replace(range, text.toLowerCase());\n this.selection.setSelectionRange(originalRange);\n };\n Editor.prototype.toUpperCase = function () {\n var originalRange = this.getSelectionRange();\n if (this.selection.isEmpty()) {\n this.selection.selectWord();\n }\n var range = this.getSelectionRange();\n var text = this.session.getTextRange(range);\n this.session.replace(range, text.toUpperCase());\n this.selection.setSelectionRange(originalRange);\n };\n Editor.prototype.indent = function () {\n var session = this.session;\n var range = this.getSelectionRange();\n if (range.start.row < range.end.row) {\n var rows = this.$getSelectedRows();\n session.indentRows(rows.first, rows.last, \"\\t\");\n return;\n }\n else if (range.start.column < range.end.column) {\n var text = session.getTextRange(range);\n if (!/^\\s+$/.test(text)) {\n var rows = this.$getSelectedRows();\n session.indentRows(rows.first, rows.last, \"\\t\");\n return;\n }\n }\n var line = session.getLine(range.start.row);\n var position = range.start;\n var size = session.getTabSize();\n var column = session.documentToScreenColumn(position.row, position.column);\n if (this.session.getUseSoftTabs()) {\n var count = (size - column % size);\n var indentString = lang.stringRepeat(\" \", count);\n }\n else {\n var count = column % size;\n while (line[range.start.column - 1] == \" \" && count) {\n range.start.column--;\n count--;\n }\n this.selection.setSelectionRange(range);\n indentString = \"\\t\";\n }\n return this.insert(indentString);\n };\n Editor.prototype.blockIndent = function () {\n var rows = this.$getSelectedRows();\n this.session.indentRows(rows.first, rows.last, \"\\t\");\n };\n Editor.prototype.blockOutdent = function () {\n var selection = this.session.getSelection();\n this.session.outdentRows(selection.getRange());\n };\n Editor.prototype.sortLines = function () {\n var rows = this.$getSelectedRows();\n var session = this.session;\n var lines = [];\n for (var i = rows.first; i <= rows.last; i++)\n lines.push(session.getLine(i));\n lines.sort(function (a, b) {\n if (a.toLowerCase() < b.toLowerCase())\n return -1;\n if (a.toLowerCase() > b.toLowerCase())\n return 1;\n return 0;\n });\n var deleteRange = new Range(0, 0, 0, 0);\n for (var i = rows.first; i <= rows.last; i++) {\n var line = session.getLine(i);\n deleteRange.start.row = i;\n deleteRange.end.row = i;\n deleteRange.end.column = line.length;\n session.replace(deleteRange, lines[i - rows.first]);\n }\n };\n Editor.prototype.toggleCommentLines = function () {\n var state = this.session.getState(this.getCursorPosition().row);\n var rows = this.$getSelectedRows();\n this.session.getMode().toggleCommentLines(state, this.session, rows.first, rows.last);\n };\n Editor.prototype.toggleBlockComment = function () {\n var cursor = this.getCursorPosition();\n var state = this.session.getState(cursor.row);\n var range = this.getSelectionRange();\n this.session.getMode().toggleBlockComment(state, this.session, range, cursor);\n };\n Editor.prototype.getNumberAt = function (row, column) {\n var _numberRx = /[\\-]?[0-9]+(?:\\.[0-9]+)?/g;\n _numberRx.lastIndex = 0;\n var s = this.session.getLine(row);\n while (_numberRx.lastIndex < column) {\n var m = _numberRx.exec(s);\n if (m.index <= column && m.index + m[0].length >= column) {\n var number = {\n value: m[0],\n start: m.index,\n end: m.index + m[0].length\n };\n return number;\n }\n }\n return null;\n };\n Editor.prototype.modifyNumber = function (amount) {\n var row = this.selection.getCursor().row;\n var column = this.selection.getCursor().column;\n var charRange = new Range(row, column - 1, row, column);\n var c = this.session.getTextRange(charRange);\n if (!isNaN(parseFloat(c)) && isFinite(c)) {\n var nr = this.getNumberAt(row, column);\n if (nr) {\n var fp = nr.value.indexOf(\".\") >= 0 ? nr.start + nr.value.indexOf(\".\") + 1 : nr.end;\n var decimals = nr.start + nr.value.length - fp;\n var t = parseFloat(nr.value);\n t *= Math.pow(10, decimals);\n if (fp !== nr.end && column < fp) {\n amount *= Math.pow(10, nr.end - column - 1);\n }\n else {\n amount *= Math.pow(10, nr.end - column);\n }\n t += amount;\n t /= Math.pow(10, decimals);\n var nnr = t.toFixed(decimals);\n var replaceRange = new Range(row, nr.start, row, nr.end);\n this.session.replace(replaceRange, nnr);\n this.moveCursorTo(row, Math.max(nr.start + 1, column + nnr.length - nr.value.length));\n }\n }\n else {\n this.toggleWord();\n }\n };\n Editor.prototype.toggleWord = function () {\n var row = this.selection.getCursor().row;\n var column = this.selection.getCursor().column;\n this.selection.selectWord();\n var currentState = this.getSelectedText();\n var currWordStart = this.selection.getWordRange().start.column;\n var wordParts = currentState.replace(/([a-z]+|[A-Z]+)(?=[A-Z_]|$)/g, '$1 ').split(/\\s/);\n var delta = column - currWordStart - 1;\n if (delta < 0)\n delta = 0;\n var curLength = 0, itLength = 0;\n var that = this;\n if (currentState.match(/[A-Za-z0-9_]+/)) {\n wordParts.forEach(function (item, i) {\n itLength = curLength + item.length;\n if (delta >= curLength && delta <= itLength) {\n currentState = item;\n that.selection.clearSelection();\n that.moveCursorTo(row, curLength + currWordStart);\n that.selection.selectTo(row, itLength + currWordStart);\n }\n curLength = itLength;\n });\n }\n var wordPairs = this.$toggleWordPairs;\n var reg;\n for (var i = 0; i < wordPairs.length; i++) {\n var item = wordPairs[i];\n for (var j = 0; j <= 1; j++) {\n var negate = +!j;\n var firstCondition = currentState.match(new RegExp('^\\\\s?_?(' + lang.escapeRegExp(item[j]) + ')\\\\s?$', 'i'));\n if (firstCondition) {\n var secondCondition = currentState.match(new RegExp('([_]|^|\\\\s)(' + lang.escapeRegExp(firstCondition[1]) + ')($|\\\\s)', 'g'));\n if (secondCondition) {\n reg = currentState.replace(new RegExp(lang.escapeRegExp(item[j]), 'i'), function (result) {\n var res = item[negate];\n if (result.toUpperCase() == result) {\n res = res.toUpperCase();\n }\n else if (result.charAt(0).toUpperCase() == result.charAt(0)) {\n res = res.substr(0, 0) + item[negate].charAt(0).toUpperCase() + res.substr(1);\n }\n return res;\n });\n this.insert(reg);\n reg = \"\";\n }\n }\n }\n }\n };\n Editor.prototype.findLinkAt = function (row, column) {\n var e_1, _a;\n var line = this.session.getLine(row);\n var wordParts = line.split(/((?:https?|ftp):\\/\\/[\\S]+)/);\n var columnPosition = column;\n if (columnPosition < 0)\n columnPosition = 0;\n var previousPosition = 0, currentPosition = 0, match;\n try {\n for (var wordParts_1 = __values(wordParts), wordParts_1_1 = wordParts_1.next(); !wordParts_1_1.done; wordParts_1_1 = wordParts_1.next()) {\n var item = wordParts_1_1.value;\n currentPosition = previousPosition + item.length;\n if (columnPosition >= previousPosition && columnPosition <= currentPosition) {\n if (item.match(/((?:https?|ftp):\\/\\/[\\S]+)/)) {\n match = item.replace(/[\\s:.,'\";}\\]]+$/, \"\");\n break;\n }\n }\n previousPosition = currentPosition;\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (wordParts_1_1 && !wordParts_1_1.done && (_a = wordParts_1.return)) _a.call(wordParts_1);\n }\n finally { if (e_1) throw e_1.error; }\n }\n return match;\n };\n Editor.prototype.openLink = function () {\n var cursor = this.selection.getCursor();\n var url = this.findLinkAt(cursor.row, cursor.column);\n if (url)\n window.open(url, '_blank');\n return url != null;\n };\n Editor.prototype.removeLines = function () {\n var rows = this.$getSelectedRows();\n this.session.removeFullLines(rows.first, rows.last);\n this.clearSelection();\n };\n Editor.prototype.duplicateSelection = function () {\n var sel = this.selection;\n var doc = this.session;\n var range = sel.getRange();\n var reverse = sel.isBackwards();\n if (range.isEmpty()) {\n var row = range.start.row;\n doc.duplicateLines(row, row);\n }\n else {\n var point = reverse ? range.start : range.end;\n var endPoint = doc.insert(point, doc.getTextRange(range));\n range.start = point;\n range.end = endPoint;\n sel.setSelectionRange(range, reverse);\n }\n };\n Editor.prototype.moveLinesDown = function () {\n this.$moveLines(1, false);\n };\n Editor.prototype.moveLinesUp = function () {\n this.$moveLines(-1, false);\n };\n Editor.prototype.moveText = function (range, toPosition, copy) {\n return this.session.moveText(range, toPosition, copy);\n };\n Editor.prototype.copyLinesUp = function () {\n this.$moveLines(-1, true);\n };\n Editor.prototype.copyLinesDown = function () {\n this.$moveLines(1, true);\n };\n Editor.prototype.$moveLines = function (dir, copy) {\n var rows, moved;\n var selection = this.selection;\n if (!selection.inMultiSelectMode || this.inVirtualSelectionMode) {\n var range = selection.toOrientedRange();\n rows = this.$getSelectedRows(range);\n moved = this.session.$moveLines(rows.first, rows.last, copy ? 0 : dir);\n if (copy && dir == -1)\n moved = 0;\n range.moveBy(moved, 0);\n selection.fromOrientedRange(range);\n }\n else {\n var ranges = selection.rangeList.ranges;\n selection.rangeList.detach(this.session);\n this.inVirtualSelectionMode = true;\n var diff = 0;\n var totalDiff = 0;\n var l = ranges.length;\n for (var i = 0; i < l; i++) {\n var rangeIndex = i;\n ranges[i].moveBy(diff, 0);\n rows = this.$getSelectedRows(ranges[i]);\n var first = rows.first;\n var last = rows.last;\n while (++i < l) {\n if (totalDiff)\n ranges[i].moveBy(totalDiff, 0);\n var subRows = this.$getSelectedRows(ranges[i]);\n if (copy && subRows.first != last)\n break;\n else if (!copy && subRows.first > last + 1)\n break;\n last = subRows.last;\n }\n i--;\n diff = this.session.$moveLines(first, last, copy ? 0 : dir);\n if (copy && dir == -1)\n rangeIndex = i + 1;\n while (rangeIndex <= i) {\n ranges[rangeIndex].moveBy(diff, 0);\n rangeIndex++;\n }\n if (!copy)\n diff = 0;\n totalDiff += diff;\n }\n selection.fromOrientedRange(selection.ranges[0]);\n selection.rangeList.attach(this.session);\n this.inVirtualSelectionMode = false;\n }\n };\n Editor.prototype.$getSelectedRows = function (range) {\n range = (range || this.getSelectionRange()).collapseRows();\n return {\n first: this.session.getRowFoldStart(range.start.row),\n last: this.session.getRowFoldEnd(range.end.row)\n };\n };\n Editor.prototype.onCompositionStart = function (compositionState) {\n this.renderer.showComposition(compositionState);\n };\n Editor.prototype.onCompositionUpdate = function (text) {\n this.renderer.setCompositionText(text);\n };\n Editor.prototype.onCompositionEnd = function () {\n this.renderer.hideComposition();\n };\n Editor.prototype.getFirstVisibleRow = function () {\n return this.renderer.getFirstVisibleRow();\n };\n Editor.prototype.getLastVisibleRow = function () {\n return this.renderer.getLastVisibleRow();\n };\n Editor.prototype.isRowVisible = function (row) {\n return (row >= this.getFirstVisibleRow() && row <= this.getLastVisibleRow());\n };\n Editor.prototype.isRowFullyVisible = function (row) {\n return (row >= this.renderer.getFirstFullyVisibleRow() && row <= this.renderer.getLastFullyVisibleRow());\n };\n Editor.prototype.$getVisibleRowCount = function () {\n return this.renderer.getScrollBottomRow() - this.renderer.getScrollTopRow() + 1;\n };\n Editor.prototype.$moveByPage = function (dir, select) {\n var renderer = this.renderer;\n var config = this.renderer.layerConfig;\n var rows = dir * Math.floor(config.height / config.lineHeight);\n if (select === true) {\n this.selection.$moveSelection(function () {\n this.moveCursorBy(rows, 0);\n });\n }\n else if (select === false) {\n this.selection.moveCursorBy(rows, 0);\n this.selection.clearSelection();\n }\n var scrollTop = renderer.scrollTop;\n renderer.scrollBy(0, rows * config.lineHeight);\n if (select != null)\n renderer.scrollCursorIntoView(null, 0.5);\n renderer.animateScrolling(scrollTop);\n };\n Editor.prototype.selectPageDown = function () {\n this.$moveByPage(1, true);\n };\n Editor.prototype.selectPageUp = function () {\n this.$moveByPage(-1, true);\n };\n Editor.prototype.gotoPageDown = function () {\n this.$moveByPage(1, false);\n };\n Editor.prototype.gotoPageUp = function () {\n this.$moveByPage(-1, false);\n };\n Editor.prototype.scrollPageDown = function () {\n this.$moveByPage(1);\n };\n Editor.prototype.scrollPageUp = function () {\n this.$moveByPage(-1);\n };\n Editor.prototype.scrollToRow = function (row) {\n this.renderer.scrollToRow(row);\n };\n Editor.prototype.scrollToLine = function (line, center, animate, callback) {\n this.renderer.scrollToLine(line, center, animate, callback);\n };\n Editor.prototype.centerSelection = function () {\n var range = this.getSelectionRange();\n var pos = {\n row: Math.floor(range.start.row + (range.end.row - range.start.row) / 2),\n column: Math.floor(range.start.column + (range.end.column - range.start.column) / 2)\n };\n this.renderer.alignCursor(pos, 0.5);\n };\n Editor.prototype.getCursorPosition = function () {\n return this.selection.getCursor();\n };\n Editor.prototype.getCursorPositionScreen = function () {\n return this.session.documentToScreenPosition(this.getCursorPosition());\n };\n Editor.prototype.getSelectionRange = function () {\n return this.selection.getRange();\n };\n Editor.prototype.selectAll = function () {\n this.selection.selectAll();\n };\n Editor.prototype.clearSelection = function () {\n this.selection.clearSelection();\n };\n Editor.prototype.moveCursorTo = function (row, column) {\n this.selection.moveCursorTo(row, column);\n };\n Editor.prototype.moveCursorToPosition = function (pos) {\n this.selection.moveCursorToPosition(pos);\n };\n Editor.prototype.jumpToMatching = function (select, expand) {\n var cursor = this.getCursorPosition();\n var iterator = new TokenIterator(this.session, cursor.row, cursor.column);\n var prevToken = iterator.getCurrentToken();\n var tokenCount = 0;\n if (prevToken && prevToken.type.indexOf('tag-name') !== -1) {\n prevToken = iterator.stepBackward();\n }\n var token = prevToken || iterator.stepForward();\n if (!token)\n return;\n var matchType;\n var found = false;\n var depth = {};\n var i = cursor.column - token.start;\n var bracketType;\n var brackets = {\n \")\": \"(\",\n \"(\": \"(\",\n \"]\": \"[\",\n \"[\": \"[\",\n \"{\": \"{\",\n \"}\": \"{\"\n };\n do {\n if (token.value.match(/[{}()\\[\\]]/g)) {\n for (; i < token.value.length && !found; i++) {\n if (!brackets[token.value[i]]) {\n continue;\n }\n bracketType = brackets[token.value[i]] + '.' + token.type.replace(\"rparen\", \"lparen\");\n if (isNaN(depth[bracketType])) {\n depth[bracketType] = 0;\n }\n switch (token.value[i]) {\n case '(':\n case '[':\n case '{':\n depth[bracketType]++;\n break;\n case ')':\n case ']':\n case '}':\n depth[bracketType]--;\n if (depth[bracketType] === -1) {\n matchType = 'bracket';\n found = true;\n }\n break;\n }\n }\n }\n else if (token.type.indexOf('tag-name') !== -1) {\n if (isNaN(depth[token.value])) {\n depth[token.value] = 0;\n }\n if (prevToken.value === '<' && tokenCount > 1) {\n depth[token.value]++;\n }\n else if (prevToken.value === '= 0; --i) {\n if (this.$tryReplace(ranges[i], replacement)) {\n replaced++;\n }\n }\n this.selection.setSelectionRange(selection);\n return replaced;\n };\n Editor.prototype.$tryReplace = function (range, replacement) {\n var input = this.session.getTextRange(range);\n replacement = this.$search.replace(input, replacement);\n if (replacement !== null) {\n range.end = this.session.replace(range, replacement);\n return range;\n }\n else {\n return null;\n }\n };\n Editor.prototype.getLastSearchOptions = function () {\n return this.$search.getOptions();\n };\n Editor.prototype.find = function (needle, options, animate) {\n if (!options)\n options = {};\n if (typeof needle == \"string\" || needle instanceof RegExp)\n options.needle = needle;\n else if (typeof needle == \"object\")\n oop.mixin(options, needle);\n var range = this.selection.getRange();\n if (options.needle == null) {\n needle = this.session.getTextRange(range)\n || this.$search.$options.needle;\n if (!needle) {\n range = this.session.getWordRange(range.start.row, range.start.column);\n needle = this.session.getTextRange(range);\n }\n this.$search.set({ needle: needle });\n }\n this.$search.set(options);\n if (!options.start)\n this.$search.set({ start: range });\n var newRange = this.$search.find(this.session);\n if (options.preventScroll)\n return newRange;\n if (newRange) {\n this.revealRange(newRange, animate);\n return newRange;\n }\n if (options.backwards)\n range.start = range.end;\n else\n range.end = range.start;\n this.selection.setRange(range);\n };\n Editor.prototype.findNext = function (options, animate) {\n this.find({ skipCurrent: true, backwards: false }, options, animate);\n };\n Editor.prototype.findPrevious = function (options, animate) {\n this.find(options, { skipCurrent: true, backwards: true }, animate);\n };\n Editor.prototype.revealRange = function (range, animate) {\n this.session.unfold(range);\n this.selection.setSelectionRange(range);\n var scrollTop = this.renderer.scrollTop;\n this.renderer.scrollSelectionIntoView(range.start, range.end, 0.5);\n if (animate !== false)\n this.renderer.animateScrolling(scrollTop);\n };\n Editor.prototype.undo = function () {\n this.session.getUndoManager().undo(this.session);\n this.renderer.scrollCursorIntoView(null, 0.5);\n };\n Editor.prototype.redo = function () {\n this.session.getUndoManager().redo(this.session);\n this.renderer.scrollCursorIntoView(null, 0.5);\n };\n Editor.prototype.destroy = function () {\n if (this.$toDestroy) {\n this.$toDestroy.forEach(function (el) {\n el.destroy();\n });\n this.$toDestroy = null;\n }\n if (this.$mouseHandler)\n this.$mouseHandler.destroy();\n this.renderer.destroy();\n this._signal(\"destroy\", this);\n if (this.session)\n this.session.destroy();\n if (this._$emitInputEvent)\n this._$emitInputEvent.cancel();\n this.removeAllListeners();\n };\n Editor.prototype.setAutoScrollEditorIntoView = function (enable) {\n if (!enable)\n return;\n var rect;\n var self = this;\n var shouldScroll = false;\n if (!this.$scrollAnchor)\n this.$scrollAnchor = document.createElement(\"div\");\n var scrollAnchor = this.$scrollAnchor;\n scrollAnchor.style.cssText = \"position:absolute\";\n this.container.insertBefore(scrollAnchor, this.container.firstChild);\n var onChangeSelection = this.on(\"changeSelection\", function () {\n shouldScroll = true;\n });\n var onBeforeRender = this.renderer.on(\"beforeRender\", function () {\n if (shouldScroll)\n rect = self.renderer.container.getBoundingClientRect();\n });\n var onAfterRender = this.renderer.on(\"afterRender\", function () {\n if (shouldScroll && rect && (self.isFocused()\n || self.searchBox && self.searchBox.isFocused())) {\n var renderer = self.renderer;\n var pos = renderer.$cursorLayer.$pixelPos;\n var config = renderer.layerConfig;\n var top = pos.top - config.offset;\n if (pos.top >= 0 && top + rect.top < 0) {\n shouldScroll = true;\n }\n else if (pos.top < config.height &&\n pos.top + rect.top + config.lineHeight > window.innerHeight) {\n shouldScroll = false;\n }\n else {\n shouldScroll = null;\n }\n if (shouldScroll != null) {\n scrollAnchor.style.top = top + \"px\";\n scrollAnchor.style.left = pos.left + \"px\";\n scrollAnchor.style.height = config.lineHeight + \"px\";\n scrollAnchor.scrollIntoView(shouldScroll);\n }\n shouldScroll = rect = null;\n }\n });\n this.setAutoScrollEditorIntoView = function (enable) {\n if (enable)\n return;\n delete this.setAutoScrollEditorIntoView;\n this.off(\"changeSelection\", onChangeSelection);\n this.renderer.off(\"afterRender\", onAfterRender);\n this.renderer.off(\"beforeRender\", onBeforeRender);\n };\n };\n Editor.prototype.$resetCursorStyle = function () {\n var style = this.$cursorStyle || \"ace\";\n var cursorLayer = this.renderer.$cursorLayer;\n if (!cursorLayer)\n return;\n cursorLayer.setSmoothBlinking(/smooth/.test(style));\n cursorLayer.isBlinking = !this.$readOnly && style != \"wide\";\n dom.setCssClass(cursorLayer.element, \"ace_slim-cursors\", /slim/.test(style));\n };\n Editor.prototype.prompt = function (message, options, callback) {\n var editor = this;\n config.loadModule(\"ace/ext/prompt\", function (module) {\n module.prompt(editor, message, options, callback);\n });\n };\n return Editor;\n}());\nEditor.$uid = 0;\nEditor.prototype.curOp = null;\nEditor.prototype.prevOp = {};\nEditor.prototype.$mergeableCommands = [\"backspace\", \"del\", \"insertstring\"];\nEditor.prototype.$toggleWordPairs = [\n [\"first\", \"last\"],\n [\"true\", \"false\"],\n [\"yes\", \"no\"],\n [\"width\", \"height\"],\n [\"top\", \"bottom\"],\n [\"right\", \"left\"],\n [\"on\", \"off\"],\n [\"x\", \"y\"],\n [\"get\", \"set\"],\n [\"max\", \"min\"],\n [\"horizontal\", \"vertical\"],\n [\"show\", \"hide\"],\n [\"add\", \"remove\"],\n [\"up\", \"down\"],\n [\"before\", \"after\"],\n [\"even\", \"odd\"],\n [\"in\", \"out\"],\n [\"inside\", \"outside\"],\n [\"next\", \"previous\"],\n [\"increase\", \"decrease\"],\n [\"attach\", \"detach\"],\n [\"&&\", \"||\"],\n [\"==\", \"!=\"]\n];\noop.implement(Editor.prototype, EventEmitter);\nconfig.defineOptions(Editor.prototype, \"editor\", {\n selectionStyle: {\n set: function (style) {\n this.onSelectionChange();\n this._signal(\"changeSelectionStyle\", { data: style });\n },\n initialValue: \"line\"\n },\n highlightActiveLine: {\n set: function () { this.$updateHighlightActiveLine(); },\n initialValue: true\n },\n highlightSelectedWord: {\n set: function (shouldHighlight) { this.$onSelectionChange(); },\n initialValue: true\n },\n readOnly: {\n set: function (readOnly) {\n this.textInput.setReadOnly(readOnly);\n this.$resetCursorStyle();\n },\n initialValue: false\n },\n copyWithEmptySelection: {\n set: function (value) {\n this.textInput.setCopyWithEmptySelection(value);\n },\n initialValue: false\n },\n cursorStyle: {\n set: function (val) { this.$resetCursorStyle(); },\n values: [\"ace\", \"slim\", \"smooth\", \"wide\"],\n initialValue: \"ace\"\n },\n mergeUndoDeltas: {\n values: [false, true, \"always\"],\n initialValue: true\n },\n behavioursEnabled: { initialValue: true },\n wrapBehavioursEnabled: { initialValue: true },\n enableAutoIndent: { initialValue: true },\n autoScrollEditorIntoView: {\n set: function (val) { this.setAutoScrollEditorIntoView(val); }\n },\n keyboardHandler: {\n set: function (val) { this.setKeyboardHandler(val); },\n get: function () { return this.$keybindingId; },\n handlesSet: true\n },\n value: {\n set: function (val) { this.session.setValue(val); },\n get: function () { return this.getValue(); },\n handlesSet: true,\n hidden: true\n },\n session: {\n set: function (val) { this.setSession(val); },\n get: function () { return this.session; },\n handlesSet: true,\n hidden: true\n },\n showLineNumbers: {\n set: function (show) {\n this.renderer.$gutterLayer.setShowLineNumbers(show);\n this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER);\n if (show && this.$relativeLineNumbers)\n relativeNumberRenderer.attach(this);\n else\n relativeNumberRenderer.detach(this);\n },\n initialValue: true\n },\n relativeLineNumbers: {\n set: function (value) {\n if (this.$showLineNumbers && value)\n relativeNumberRenderer.attach(this);\n else\n relativeNumberRenderer.detach(this);\n }\n },\n placeholder: {\n set: function (message) {\n if (!this.$updatePlaceholder) {\n this.$updatePlaceholder = function () {\n var hasValue = this.session && (this.renderer.$composition ||\n this.session.getLength() > 1 || this.session.getLine(0).length > 0);\n if (hasValue && this.renderer.placeholderNode) {\n this.renderer.off(\"afterRender\", this.$updatePlaceholder);\n dom.removeCssClass(this.container, \"ace_hasPlaceholder\");\n this.renderer.placeholderNode.remove();\n this.renderer.placeholderNode = null;\n }\n else if (!hasValue && !this.renderer.placeholderNode) {\n this.renderer.on(\"afterRender\", this.$updatePlaceholder);\n dom.addCssClass(this.container, \"ace_hasPlaceholder\");\n var el = dom.createElement(\"div\");\n el.className = \"ace_placeholder\";\n el.textContent = this.$placeholder || \"\";\n this.renderer.placeholderNode = el;\n this.renderer.content.appendChild(this.renderer.placeholderNode);\n }\n else if (!hasValue && this.renderer.placeholderNode) {\n this.renderer.placeholderNode.textContent = this.$placeholder || \"\";\n }\n }.bind(this);\n this.on(\"input\", this.$updatePlaceholder);\n }\n this.$updatePlaceholder();\n }\n },\n enableKeyboardAccessibility: {\n set: function (value) {\n var blurCommand = {\n name: \"blurTextInput\",\n description: \"Set focus to the editor content div to allow tabbing through the page\",\n bindKey: \"Esc\",\n exec: function (editor) {\n editor.blur();\n editor.renderer.scroller.focus();\n },\n readOnly: true\n };\n var focusOnEnterKeyup = function (e) {\n if (e.target == this.renderer.scroller && e.keyCode === keys['enter']) {\n e.preventDefault();\n var row = this.getCursorPosition().row;\n if (!this.isRowVisible(row))\n this.scrollToLine(row, true, true);\n this.focus();\n }\n };\n var gutterKeyboardHandler;\n if (value) {\n this.renderer.enableKeyboardAccessibility = true;\n this.renderer.keyboardFocusClassName = \"ace_keyboard-focus\";\n this.textInput.getElement().setAttribute(\"tabindex\", -1);\n this.textInput.setNumberOfExtraLines(useragent.isWin ? 3 : 0);\n this.renderer.scroller.setAttribute(\"tabindex\", 0);\n this.renderer.scroller.setAttribute(\"role\", \"group\");\n this.renderer.scroller.setAttribute(\"aria-roledescription\", nls(\"editor.scroller.aria-roledescription\", \"editor\"));\n this.renderer.scroller.classList.add(this.renderer.keyboardFocusClassName);\n this.renderer.scroller.setAttribute(\"aria-label\", nls(\"editor.scroller.aria-label\", \"Editor content, press Enter to start editing, press Escape to exit\"));\n this.renderer.scroller.addEventListener(\"keyup\", focusOnEnterKeyup.bind(this));\n this.commands.addCommand(blurCommand);\n this.renderer.$gutter.setAttribute(\"tabindex\", 0);\n this.renderer.$gutter.setAttribute(\"aria-hidden\", false);\n this.renderer.$gutter.setAttribute(\"role\", \"group\");\n this.renderer.$gutter.setAttribute(\"aria-roledescription\", nls(\"editor.gutter.aria-roledescription\", \"editor\"));\n this.renderer.$gutter.setAttribute(\"aria-label\", nls(\"editor.gutter.aria-label\", \"Editor gutter, press Enter to interact with controls using arrow keys, press Escape to exit\"));\n this.renderer.$gutter.classList.add(this.renderer.keyboardFocusClassName);\n this.renderer.content.setAttribute(\"aria-hidden\", true);\n if (!gutterKeyboardHandler)\n gutterKeyboardHandler = new GutterKeyboardHandler(this);\n gutterKeyboardHandler.addListener();\n this.textInput.setAriaOptions({\n setLabel: true\n });\n }\n else {\n this.renderer.enableKeyboardAccessibility = false;\n this.textInput.getElement().setAttribute(\"tabindex\", 0);\n this.textInput.setNumberOfExtraLines(0);\n this.renderer.scroller.setAttribute(\"tabindex\", -1);\n this.renderer.scroller.removeAttribute(\"role\");\n this.renderer.scroller.removeAttribute(\"aria-roledescription\");\n this.renderer.scroller.classList.remove(this.renderer.keyboardFocusClassName);\n this.renderer.scroller.removeAttribute(\"aria-label\");\n this.renderer.scroller.removeEventListener(\"keyup\", focusOnEnterKeyup.bind(this));\n this.commands.removeCommand(blurCommand);\n this.renderer.content.removeAttribute(\"aria-hidden\");\n this.renderer.$gutter.setAttribute(\"tabindex\", -1);\n this.renderer.$gutter.setAttribute(\"aria-hidden\", true);\n this.renderer.$gutter.removeAttribute(\"role\");\n this.renderer.$gutter.removeAttribute(\"aria-roledescription\");\n this.renderer.$gutter.removeAttribute(\"aria-label\");\n this.renderer.$gutter.classList.remove(this.renderer.keyboardFocusClassName);\n if (gutterKeyboardHandler)\n gutterKeyboardHandler.removeListener();\n }\n },\n initialValue: false\n },\n textInputAriaLabel: {\n set: function (val) { this.$textInputAriaLabel = val; },\n initialValue: \"\"\n },\n enableMobileMenu: {\n set: function (val) { this.$enableMobileMenu = val; },\n initialValue: true\n },\n customScrollbar: \"renderer\",\n hScrollBarAlwaysVisible: \"renderer\",\n vScrollBarAlwaysVisible: \"renderer\",\n highlightGutterLine: \"renderer\",\n animatedScroll: \"renderer\",\n showInvisibles: \"renderer\",\n showPrintMargin: \"renderer\",\n printMarginColumn: \"renderer\",\n printMargin: \"renderer\",\n fadeFoldWidgets: \"renderer\",\n showFoldWidgets: \"renderer\",\n displayIndentGuides: \"renderer\",\n highlightIndentGuides: \"renderer\",\n showGutter: \"renderer\",\n fontSize: \"renderer\",\n fontFamily: \"renderer\",\n maxLines: \"renderer\",\n minLines: \"renderer\",\n scrollPastEnd: \"renderer\",\n fixedWidthGutter: \"renderer\",\n theme: \"renderer\",\n hasCssTransforms: \"renderer\",\n maxPixelHeight: \"renderer\",\n useTextareaForIME: \"renderer\",\n useResizeObserver: \"renderer\",\n useSvgGutterIcons: \"renderer\",\n showFoldedAnnotations: \"renderer\",\n scrollSpeed: \"$mouseHandler\",\n dragDelay: \"$mouseHandler\",\n dragEnabled: \"$mouseHandler\",\n focusTimeout: \"$mouseHandler\",\n tooltipFollowsMouse: \"$mouseHandler\",\n firstLineNumber: \"session\",\n overwrite: \"session\",\n newLineMode: \"session\",\n useWorker: \"session\",\n useSoftTabs: \"session\",\n navigateWithinSoftTabs: \"session\",\n tabSize: \"session\",\n wrap: \"session\",\n indentedSoftWrap: \"session\",\n foldStyle: \"session\",\n mode: \"session\"\n});\nvar relativeNumberRenderer = {\n getText: function (/**@type{EditSession}*/ session, /**@type{number}*/ row) {\n return (Math.abs(session.selection.lead.row - row) || (row + 1 + (row < 9 ? \"\\xb7\" : \"\"))) + \"\";\n },\n getWidth: function (session, /**@type{number}*/ lastLineNumber, config) {\n return Math.max(lastLineNumber.toString().length, (config.lastRow + 1).toString().length, 2) * config.characterWidth;\n },\n update: function (e, /**@type{Editor}*/ editor) {\n editor.renderer.$loop.schedule(editor.renderer.CHANGE_GUTTER);\n },\n attach: function (/**@type{Editor}*/ editor) {\n editor.renderer.$gutterLayer.$renderer = this;\n editor.on(\"changeSelection\", this.update);\n this.update(null, editor);\n },\n detach: function (/**@type{Editor}*/ editor) {\n if (editor.renderer.$gutterLayer.$renderer == this)\n editor.renderer.$gutterLayer.$renderer = null;\n editor.off(\"changeSelection\", this.update);\n this.update(null, editor);\n }\n};\nexports.Editor = Editor;\n\n});\n\nace.define(\"ace/layer/lines\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\"], function(require, exports, module){\"use strict\";\nvar dom = require(\"../lib/dom\");\nvar Lines = /** @class */ (function () {\n function Lines(element, canvasHeight) {\n this.element = element;\n this.canvasHeight = canvasHeight || 500000;\n this.element.style.height = (this.canvasHeight * 2) + \"px\";\n this.cells = [];\n this.cellCache = [];\n this.$offsetCoefficient = 0;\n }\n Lines.prototype.moveContainer = function (config) {\n dom.translate(this.element, 0, -((config.firstRowScreen * config.lineHeight) % this.canvasHeight) - config.offset * this.$offsetCoefficient);\n };\n Lines.prototype.pageChanged = function (oldConfig, newConfig) {\n return (Math.floor((oldConfig.firstRowScreen * oldConfig.lineHeight) / this.canvasHeight) !==\n Math.floor((newConfig.firstRowScreen * newConfig.lineHeight) / this.canvasHeight));\n };\n Lines.prototype.computeLineTop = function (row, config, session) {\n var screenTop = config.firstRowScreen * config.lineHeight;\n var screenPage = Math.floor(screenTop / this.canvasHeight);\n var lineTop = session.documentToScreenRow(row, 0) * config.lineHeight;\n return lineTop - (screenPage * this.canvasHeight);\n };\n Lines.prototype.computeLineHeight = function (row, config, session) {\n return config.lineHeight * session.getRowLineCount(row);\n };\n Lines.prototype.getLength = function () {\n return this.cells.length;\n };\n Lines.prototype.get = function (index) {\n return this.cells[index];\n };\n Lines.prototype.shift = function () {\n this.$cacheCell(this.cells.shift());\n };\n Lines.prototype.pop = function () {\n this.$cacheCell(this.cells.pop());\n };\n Lines.prototype.push = function (cell) {\n if (Array.isArray(cell)) {\n this.cells.push.apply(this.cells, cell);\n var fragment = dom.createFragment(this.element);\n for (var i = 0; i < cell.length; i++) {\n fragment.appendChild(cell[i].element);\n }\n this.element.appendChild(fragment);\n }\n else {\n this.cells.push(cell);\n this.element.appendChild(cell.element);\n }\n };\n Lines.prototype.unshift = function (cell) {\n if (Array.isArray(cell)) {\n this.cells.unshift.apply(this.cells, cell);\n var fragment = dom.createFragment(this.element);\n for (var i = 0; i < cell.length; i++) {\n fragment.appendChild(cell[i].element);\n }\n if (this.element.firstChild)\n this.element.insertBefore(fragment, this.element.firstChild);\n else\n this.element.appendChild(fragment);\n }\n else {\n this.cells.unshift(cell);\n this.element.insertAdjacentElement(\"afterbegin\", cell.element);\n }\n };\n Lines.prototype.last = function () {\n if (this.cells.length)\n return this.cells[this.cells.length - 1];\n else\n return null;\n };\n Lines.prototype.$cacheCell = function (cell) {\n if (!cell)\n return;\n cell.element.remove();\n this.cellCache.push(cell);\n };\n Lines.prototype.createCell = function (row, config, session, initElement) {\n var cell = this.cellCache.pop();\n if (!cell) {\n var element = dom.createElement(\"div\");\n if (initElement)\n initElement(element);\n this.element.appendChild(element);\n cell = {\n element: element,\n text: \"\",\n row: row\n };\n }\n cell.row = row;\n return cell;\n };\n return Lines;\n}());\nexports.Lines = Lines;\n\n});\n\nace.define(\"ace/layer/gutter\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\",\"ace/lib/oop\",\"ace/lib/lang\",\"ace/lib/event_emitter\",\"ace/layer/lines\",\"ace/config\"], function(require, exports, module){\"use strict\";\nvar dom = require(\"../lib/dom\");\nvar oop = require(\"../lib/oop\");\nvar lang = require(\"../lib/lang\");\nvar EventEmitter = require(\"../lib/event_emitter\").EventEmitter;\nvar Lines = require(\"./lines\").Lines;\nvar nls = require(\"../config\").nls;\nvar Gutter = /** @class */ (function () {\n function Gutter(parentEl) {\n this.element = dom.createElement(\"div\");\n this.element.className = \"ace_layer ace_gutter-layer\";\n parentEl.appendChild(this.element);\n this.setShowFoldWidgets(this.$showFoldWidgets);\n this.gutterWidth = 0;\n this.$annotations = [];\n this.$updateAnnotations = this.$updateAnnotations.bind(this);\n this.$lines = new Lines(this.element);\n this.$lines.$offsetCoefficient = 1;\n }\n Gutter.prototype.setSession = function (session) {\n if (this.session)\n this.session.off(\"change\", this.$updateAnnotations);\n this.session = session;\n if (session)\n session.on(\"change\", this.$updateAnnotations);\n };\n Gutter.prototype.addGutterDecoration = function (row, className) {\n if (window.console)\n console.warn && console.warn(\"deprecated use session.addGutterDecoration\");\n this.session.addGutterDecoration(row, className);\n };\n Gutter.prototype.removeGutterDecoration = function (row, className) {\n if (window.console)\n console.warn && console.warn(\"deprecated use session.removeGutterDecoration\");\n this.session.removeGutterDecoration(row, className);\n };\n Gutter.prototype.setAnnotations = function (annotations) {\n this.$annotations = [];\n for (var i = 0; i < annotations.length; i++) {\n var annotation = annotations[i];\n var row = annotation.row;\n var rowInfo = this.$annotations[row];\n if (!rowInfo)\n rowInfo = this.$annotations[row] = { text: [], type: [], displayText: [] };\n var annoText = annotation.text;\n var displayAnnoText = annotation.text;\n var annoType = annotation.type;\n annoText = annoText ? lang.escapeHTML(annoText) : annotation.html || \"\";\n displayAnnoText = displayAnnoText ? displayAnnoText : annotation.html || \"\";\n if (rowInfo.text.indexOf(annoText) === -1) {\n rowInfo.text.push(annoText);\n rowInfo.type.push(annoType);\n rowInfo.displayText.push(displayAnnoText);\n }\n var className = annotation.className;\n if (className) {\n rowInfo.className = className;\n }\n else if (annoType === \"error\") {\n rowInfo.className = \" ace_error\";\n }\n else if (annoType === \"security\" && !/\\bace_error\\b/.test(rowInfo.className)) {\n rowInfo.className = \" ace_security\";\n }\n else if (annoType === \"warning\" && !/\\bace_(error|security)\\b/.test(rowInfo.className)) {\n rowInfo.className = \" ace_warning\";\n }\n else if (annoType === \"info\" && !rowInfo.className) {\n rowInfo.className = \" ace_info\";\n }\n else if (annoType === \"hint\" && !rowInfo.className) {\n rowInfo.className = \" ace_hint\";\n }\n }\n };\n Gutter.prototype.$updateAnnotations = function (delta) {\n if (!this.$annotations.length)\n return;\n var firstRow = delta.start.row;\n var len = delta.end.row - firstRow;\n if (len === 0) {\n }\n else if (delta.action == 'remove') {\n this.$annotations.splice(firstRow, len + 1, null);\n }\n else {\n var args = new Array(len + 1);\n args.unshift(firstRow, 1);\n this.$annotations.splice.apply(this.$annotations, args);\n }\n };\n Gutter.prototype.update = function (config) {\n this.config = config;\n var session = this.session;\n var firstRow = config.firstRow;\n var lastRow = Math.min(config.lastRow + config.gutterOffset, // needed to compensate for hor scollbar\n session.getLength() - 1);\n this.oldLastRow = lastRow;\n this.config = config;\n this.$lines.moveContainer(config);\n this.$updateCursorRow();\n var fold = session.getNextFoldLine(firstRow);\n var foldStart = fold ? fold.start.row : Infinity;\n var cell = null;\n var index = -1;\n var row = firstRow;\n while (true) {\n if (row > foldStart) {\n row = fold.end.row + 1;\n fold = session.getNextFoldLine(row, fold);\n foldStart = fold ? fold.start.row : Infinity;\n }\n if (row > lastRow) {\n while (this.$lines.getLength() > index + 1)\n this.$lines.pop();\n break;\n }\n cell = this.$lines.get(++index);\n if (cell) {\n cell.row = row;\n }\n else {\n cell = this.$lines.createCell(row, config, this.session, onCreateCell);\n this.$lines.push(cell);\n }\n this.$renderCell(cell, config, fold, row);\n row++;\n }\n this._signal(\"afterRender\");\n this.$updateGutterWidth(config);\n };\n Gutter.prototype.$updateGutterWidth = function (config) {\n var session = this.session;\n var gutterRenderer = session.gutterRenderer || this.$renderer;\n var firstLineNumber = session.$firstLineNumber;\n var lastLineText = this.$lines.last() ? this.$lines.last().text : \"\";\n if (this.$fixedWidth || session.$useWrapMode)\n lastLineText = session.getLength() + firstLineNumber - 1;\n var gutterWidth = gutterRenderer\n ? gutterRenderer.getWidth(session, lastLineText, config)\n : lastLineText.toString().length * config.characterWidth;\n var padding = this.$padding || this.$computePadding();\n gutterWidth += padding.left + padding.right;\n if (gutterWidth !== this.gutterWidth && !isNaN(gutterWidth)) {\n this.gutterWidth = gutterWidth; (this.element.parentNode).style.width =\n this.element.style.width = Math.ceil(this.gutterWidth) + \"px\";\n this._signal(\"changeGutterWidth\", gutterWidth);\n }\n };\n Gutter.prototype.$updateCursorRow = function () {\n if (!this.$highlightGutterLine)\n return;\n var position = this.session.selection.getCursor();\n if (this.$cursorRow === position.row)\n return;\n this.$cursorRow = position.row;\n };\n Gutter.prototype.updateLineHighlight = function () {\n if (!this.$highlightGutterLine)\n return;\n var row = this.session.selection.cursor.row;\n this.$cursorRow = row;\n if (this.$cursorCell && this.$cursorCell.row == row)\n return;\n if (this.$cursorCell)\n this.$cursorCell.element.className = this.$cursorCell.element.className.replace(\"ace_gutter-active-line \", \"\");\n var cells = this.$lines.cells;\n this.$cursorCell = null;\n for (var i = 0; i < cells.length; i++) {\n var cell = cells[i];\n if (cell.row >= this.$cursorRow) {\n if (cell.row > this.$cursorRow) {\n var fold = this.session.getFoldLine(this.$cursorRow);\n if (i > 0 && fold && fold.start.row == cells[i - 1].row)\n cell = cells[i - 1];\n else\n break;\n }\n cell.element.className = \"ace_gutter-active-line \" + cell.element.className;\n this.$cursorCell = cell;\n break;\n }\n }\n };\n Gutter.prototype.scrollLines = function (config) {\n var oldConfig = this.config;\n this.config = config;\n this.$updateCursorRow();\n if (this.$lines.pageChanged(oldConfig, config))\n return this.update(config);\n this.$lines.moveContainer(config);\n var lastRow = Math.min(config.lastRow + config.gutterOffset, // needed to compensate for hor scollbar\n this.session.getLength() - 1);\n var oldLastRow = this.oldLastRow;\n this.oldLastRow = lastRow;\n if (!oldConfig || oldLastRow < config.firstRow)\n return this.update(config);\n if (lastRow < oldConfig.firstRow)\n return this.update(config);\n if (oldConfig.firstRow < config.firstRow)\n for (var row = this.session.getFoldedRowCount(oldConfig.firstRow, config.firstRow - 1); row > 0; row--)\n this.$lines.shift();\n if (oldLastRow > lastRow)\n for (var row = this.session.getFoldedRowCount(lastRow + 1, oldLastRow); row > 0; row--)\n this.$lines.pop();\n if (config.firstRow < oldConfig.firstRow) {\n this.$lines.unshift(this.$renderLines(config, config.firstRow, oldConfig.firstRow - 1));\n }\n if (lastRow > oldLastRow) {\n this.$lines.push(this.$renderLines(config, oldLastRow + 1, lastRow));\n }\n this.updateLineHighlight();\n this._signal(\"afterRender\");\n this.$updateGutterWidth(config);\n };\n Gutter.prototype.$renderLines = function (config, firstRow, lastRow) {\n var fragment = [];\n var row = firstRow;\n var foldLine = this.session.getNextFoldLine(row);\n var foldStart = foldLine ? foldLine.start.row : Infinity;\n while (true) {\n if (row > foldStart) {\n row = foldLine.end.row + 1;\n foldLine = this.session.getNextFoldLine(row, foldLine);\n foldStart = foldLine ? foldLine.start.row : Infinity;\n }\n if (row > lastRow)\n break;\n var cell = this.$lines.createCell(row, config, this.session, onCreateCell);\n this.$renderCell(cell, config, foldLine, row);\n fragment.push(cell);\n row++;\n }\n return fragment;\n };\n Gutter.prototype.$renderCell = function (cell, config, fold, row) {\n var element = cell.element;\n var session = this.session;\n var textNode = element.childNodes[0];\n var foldWidget = element.childNodes[1];\n var annotationNode = element.childNodes[2];\n var annotationIconNode = annotationNode.firstChild;\n var firstLineNumber = session.$firstLineNumber;\n var breakpoints = session.$breakpoints;\n var decorations = session.$decorations;\n var gutterRenderer = session.gutterRenderer || this.$renderer;\n var foldWidgets = this.$showFoldWidgets && session.foldWidgets;\n var foldStart = fold ? fold.start.row : Number.MAX_VALUE;\n var lineHeight = config.lineHeight + \"px\";\n var className = this.$useSvgGutterIcons ? \"ace_gutter-cell_svg-icons \" : \"ace_gutter-cell \";\n var iconClassName = this.$useSvgGutterIcons ? \"ace_icon_svg\" : \"ace_icon\";\n var rowText = (gutterRenderer\n ? gutterRenderer.getText(session, row)\n : row + firstLineNumber).toString();\n if (this.$highlightGutterLine) {\n if (row == this.$cursorRow || (fold && row < this.$cursorRow && row >= foldStart && this.$cursorRow <= fold.end.row)) {\n className += \"ace_gutter-active-line \";\n if (this.$cursorCell != cell) {\n if (this.$cursorCell)\n this.$cursorCell.element.className = this.$cursorCell.element.className.replace(\"ace_gutter-active-line \", \"\");\n this.$cursorCell = cell;\n }\n }\n }\n if (breakpoints[row])\n className += breakpoints[row];\n if (decorations[row])\n className += decorations[row];\n if (this.$annotations[row] && row !== foldStart)\n className += this.$annotations[row].className;\n if (foldWidgets) {\n var c = foldWidgets[row];\n if (c == null)\n c = foldWidgets[row] = session.getFoldWidget(row);\n }\n if (c) {\n var foldClass = \"ace_fold-widget ace_\" + c;\n var isClosedFold = c == \"start\" && row == foldStart && row < fold.end.row;\n if (isClosedFold) {\n foldClass += \" ace_closed\";\n var foldAnnotationClass = \"\";\n var annotationInFold = false;\n for (var i = row + 1; i <= fold.end.row; i++) {\n if (!this.$annotations[i])\n continue;\n if (this.$annotations[i].className === \" ace_error\") {\n annotationInFold = true;\n foldAnnotationClass = \" ace_error_fold\";\n break;\n }\n if (this.$annotations[i].className === \" ace_security\") {\n annotationInFold = true;\n foldAnnotationClass = \" ace_security_fold\";\n }\n else if (this.$annotations[i].className === \" ace_warning\" &&\n foldAnnotationClass !== \" ace_security_fold\") {\n annotationInFold = true;\n foldAnnotationClass = \" ace_warning_fold\";\n }\n }\n className += foldAnnotationClass;\n }\n else\n foldClass += \" ace_open\";\n if (foldWidget.className != foldClass)\n foldWidget.className = foldClass;\n dom.setStyle(foldWidget.style, \"height\", lineHeight);\n dom.setStyle(foldWidget.style, \"display\", \"inline-block\");\n foldWidget.setAttribute(\"role\", \"button\");\n foldWidget.setAttribute(\"tabindex\", \"-1\");\n var foldRange = session.getFoldWidgetRange(row);\n if (foldRange)\n foldWidget.setAttribute(\"aria-label\", nls(\"gutter.code-folding.range.aria-label\", \"Toggle code folding, rows $0 through $1\", [\n foldRange.start.row + 1,\n foldRange.end.row + 1\n ]));\n else {\n if (fold)\n foldWidget.setAttribute(\"aria-label\", nls(\"gutter.code-folding.closed.aria-label\", \"Toggle code folding, rows $0 through $1\", [\n fold.start.row + 1,\n fold.end.row + 1\n ]));\n else\n foldWidget.setAttribute(\"aria-label\", nls(\"gutter.code-folding.open.aria-label\", \"Toggle code folding, row $0\", [row + 1]));\n }\n if (isClosedFold) {\n foldWidget.setAttribute(\"aria-expanded\", \"false\");\n foldWidget.setAttribute(\"title\", nls(\"gutter.code-folding.closed.title\", \"Unfold code\"));\n }\n else {\n foldWidget.setAttribute(\"aria-expanded\", \"true\");\n foldWidget.setAttribute(\"title\", nls(\"gutter.code-folding.open.title\", \"Fold code\"));\n }\n }\n else {\n if (foldWidget) {\n dom.setStyle(foldWidget.style, \"display\", \"none\");\n foldWidget.setAttribute(\"tabindex\", \"0\");\n foldWidget.removeAttribute(\"role\");\n foldWidget.removeAttribute(\"aria-label\");\n }\n }\n if (annotationInFold && this.$showFoldedAnnotations) {\n annotationNode.className = \"ace_gutter_annotation\";\n annotationIconNode.className = iconClassName;\n annotationIconNode.className += foldAnnotationClass;\n dom.setStyle(annotationIconNode.style, \"height\", lineHeight);\n dom.setStyle(annotationNode.style, \"display\", \"block\");\n dom.setStyle(annotationNode.style, \"height\", lineHeight);\n var ariaLabel;\n switch (foldAnnotationClass) {\n case \" ace_error_fold\":\n ariaLabel = nls(\"gutter.annotation.aria-label.error\", \"Error, read annotations row $0\", [rowText]);\n break;\n case \" ace_security_fold\":\n ariaLabel = nls(\"gutter.annotation.aria-label.security\", \"Security finding, read annotations row $0\", [rowText]);\n break;\n case \" ace_warning_fold\":\n ariaLabel = nls(\"gutter.annotation.aria-label.warning\", \"Warning, read annotations row $0\", [rowText]);\n break;\n }\n annotationNode.setAttribute(\"aria-label\", ariaLabel);\n annotationNode.setAttribute(\"tabindex\", \"-1\");\n annotationNode.setAttribute(\"role\", \"button\");\n }\n else if (this.$annotations[row]) {\n annotationNode.className = \"ace_gutter_annotation\";\n annotationIconNode.className = iconClassName;\n if (this.$useSvgGutterIcons)\n annotationIconNode.className += this.$annotations[row].className;\n else\n element.classList.add(this.$annotations[row].className.replace(\" \", \"\"));\n dom.setStyle(annotationIconNode.style, \"height\", lineHeight);\n dom.setStyle(annotationNode.style, \"display\", \"block\");\n dom.setStyle(annotationNode.style, \"height\", lineHeight);\n var ariaLabel;\n switch (this.$annotations[row].className) {\n case \" ace_error\":\n ariaLabel = nls(\"gutter.annotation.aria-label.error\", \"Error, read annotations row $0\", [rowText]);\n break;\n case \" ace_security\":\n ariaLabel = nls(\"gutter.annotation.aria-label.security\", \"Security finding, read annotations row $0\", [rowText]);\n break;\n case \" ace_warning\":\n ariaLabel = nls(\"gutter.annotation.aria-label.warning\", \"Warning, read annotations row $0\", [rowText]);\n break;\n case \" ace_info\":\n ariaLabel = nls(\"gutter.annotation.aria-label.info\", \"Info, read annotations row $0\", [rowText]);\n break;\n case \" ace_hint\":\n ariaLabel = nls(\"gutter.annotation.aria-label.hint\", \"Suggestion, read annotations row $0\", [rowText]);\n break;\n }\n annotationNode.setAttribute(\"aria-label\", ariaLabel);\n annotationNode.setAttribute(\"tabindex\", \"-1\");\n annotationNode.setAttribute(\"role\", \"button\");\n }\n else {\n dom.setStyle(annotationNode.style, \"display\", \"none\");\n annotationNode.removeAttribute(\"aria-label\");\n annotationNode.removeAttribute(\"role\");\n annotationNode.setAttribute(\"tabindex\", \"0\");\n }\n if (rowText !== textNode.data) {\n textNode.data = rowText;\n }\n if (element.className != className)\n element.className = className;\n dom.setStyle(cell.element.style, \"height\", this.$lines.computeLineHeight(row, config, session) + \"px\");\n dom.setStyle(cell.element.style, \"top\", this.$lines.computeLineTop(row, config, session) + \"px\");\n cell.text = rowText;\n if (annotationNode.style.display === \"none\" && foldWidget.style.display === \"none\")\n cell.element.setAttribute(\"aria-hidden\", true);\n else\n cell.element.setAttribute(\"aria-hidden\", false);\n return cell;\n };\n Gutter.prototype.setHighlightGutterLine = function (highlightGutterLine) {\n this.$highlightGutterLine = highlightGutterLine;\n };\n Gutter.prototype.setShowLineNumbers = function (show) {\n this.$renderer = !show && {\n getWidth: function () { return 0; },\n getText: function () { return \"\"; }\n };\n };\n Gutter.prototype.getShowLineNumbers = function () {\n return this.$showLineNumbers;\n };\n Gutter.prototype.setShowFoldWidgets = function (show) {\n if (show)\n dom.addCssClass(this.element, \"ace_folding-enabled\");\n else\n dom.removeCssClass(this.element, \"ace_folding-enabled\");\n this.$showFoldWidgets = show;\n this.$padding = null;\n };\n Gutter.prototype.getShowFoldWidgets = function () {\n return this.$showFoldWidgets;\n };\n Gutter.prototype.$computePadding = function () {\n if (!this.element.firstChild)\n return { left: 0, right: 0 };\n var style = dom.computedStyle(/**@type{Element}*/ (this.element.firstChild));\n this.$padding = {};\n this.$padding.left = (parseInt(style.borderLeftWidth) || 0)\n + (parseInt(style.paddingLeft) || 0) + 1;\n this.$padding.right = (parseInt(style.borderRightWidth) || 0)\n + (parseInt(style.paddingRight) || 0);\n return this.$padding;\n };\n Gutter.prototype.getRegion = function (point) {\n var padding = this.$padding || this.$computePadding();\n var rect = this.element.getBoundingClientRect();\n if (point.x < padding.left + rect.left)\n return \"markers\";\n if (this.$showFoldWidgets && point.x > rect.right - padding.right)\n return \"foldWidgets\";\n };\n return Gutter;\n}());\nGutter.prototype.$fixedWidth = false;\nGutter.prototype.$highlightGutterLine = true;\nGutter.prototype.$renderer = \"\";\nGutter.prototype.$showLineNumbers = true;\nGutter.prototype.$showFoldWidgets = true;\noop.implement(Gutter.prototype, EventEmitter);\nfunction onCreateCell(element) {\n var textNode = document.createTextNode('');\n element.appendChild(textNode);\n var foldWidget = dom.createElement(\"span\");\n element.appendChild(foldWidget);\n var annotationNode = dom.createElement(\"span\");\n element.appendChild(annotationNode);\n var annotationIconNode = dom.createElement(\"span\");\n annotationNode.appendChild(annotationIconNode);\n return element;\n}\nexports.Gutter = Gutter;\n\n});\n\nace.define(\"ace/layer/marker\",[\"require\",\"exports\",\"module\",\"ace/range\",\"ace/lib/dom\"], function(require, exports, module){\"use strict\";\nvar Range = require(\"../range\").Range;\nvar dom = require(\"../lib/dom\");\nvar Marker = /** @class */ (function () {\n function Marker(parentEl) {\n this.element = dom.createElement(\"div\");\n this.element.className = \"ace_layer ace_marker-layer\";\n parentEl.appendChild(this.element);\n }\n Marker.prototype.setPadding = function (padding) {\n this.$padding = padding;\n };\n Marker.prototype.setSession = function (session) {\n this.session = session;\n };\n Marker.prototype.setMarkers = function (markers) {\n this.markers = markers;\n };\n Marker.prototype.elt = function (className, css) {\n var x = this.i != -1 && this.element.childNodes[this.i];\n if (!x) {\n x = document.createElement(\"div\");\n this.element.appendChild(x);\n this.i = -1;\n }\n else {\n this.i++;\n }\n x.style.cssText = css;\n x.className = className;\n };\n Marker.prototype.update = function (config) {\n if (!config)\n return;\n this.config = config;\n this.i = 0;\n var html;\n for (var key in this.markers) {\n var marker = this.markers[key];\n if (!marker.range) {\n marker.update(html, this, this.session, config);\n continue;\n }\n var range = marker.range.clipRows(config.firstRow, config.lastRow);\n if (range.isEmpty())\n continue;\n range = range.toScreenRange(this.session);\n if (marker.renderer) {\n var top = this.$getTop(range.start.row, config);\n var left = this.$padding + range.start.column * config.characterWidth;\n marker.renderer(html, range, left, top, config);\n }\n else if (marker.type == \"fullLine\") {\n this.drawFullLineMarker(html, range, marker.clazz, config);\n }\n else if (marker.type == \"screenLine\") {\n this.drawScreenLineMarker(html, range, marker.clazz, config);\n }\n else if (range.isMultiLine()) {\n if (marker.type == \"text\")\n this.drawTextMarker(html, range, marker.clazz, config);\n else\n this.drawMultiLineMarker(html, range, marker.clazz, config);\n }\n else {\n this.drawSingleLineMarker(html, range, marker.clazz + \" ace_start\" + \" ace_br15\", config);\n }\n }\n if (this.i != -1) {\n while (this.i < this.element.childElementCount)\n this.element.removeChild(this.element.lastChild);\n }\n };\n Marker.prototype.$getTop = function (row, layerConfig) {\n return (row - layerConfig.firstRowScreen) * layerConfig.lineHeight;\n };\n Marker.prototype.drawTextMarker = function (stringBuilder, range, clazz, layerConfig, extraStyle) {\n var session = this.session;\n var start = range.start.row;\n var end = range.end.row;\n var row = start;\n var prev = 0;\n var curr = 0;\n var next = session.getScreenLastRowColumn(row);\n var lineRange = new Range(row, range.start.column, row, curr);\n for (; row <= end; row++) {\n lineRange.start.row = lineRange.end.row = row;\n lineRange.start.column = row == start ? range.start.column : session.getRowWrapIndent(row);\n lineRange.end.column = next;\n prev = curr;\n curr = next;\n next = row + 1 < end ? session.getScreenLastRowColumn(row + 1) : row == end ? 0 : range.end.column;\n this.drawSingleLineMarker(stringBuilder, lineRange, clazz + (row == start ? \" ace_start\" : \"\") + \" ace_br\"\n + getBorderClass(row == start || row == start + 1 && range.start.column, prev < curr, curr > next, row == end), layerConfig, row == end ? 0 : 1, extraStyle);\n }\n };\n Marker.prototype.drawMultiLineMarker = function (stringBuilder, range, clazz, config, extraStyle) {\n var padding = this.$padding;\n var height = config.lineHeight;\n var top = this.$getTop(range.start.row, config);\n var left = padding + range.start.column * config.characterWidth;\n extraStyle = extraStyle || \"\";\n if (this.session.$bidiHandler.isBidiRow(range.start.row)) {\n var range1 = range.clone();\n range1.end.row = range1.start.row;\n range1.end.column = this.session.getLine(range1.start.row).length;\n this.drawBidiSingleLineMarker(stringBuilder, range1, clazz + \" ace_br1 ace_start\", config, null, extraStyle);\n }\n else {\n this.elt(clazz + \" ace_br1 ace_start\", \"height:\" + height + \"px;\" + \"right:\" + padding + \"px;\" + \"top:\" + top + \"px;left:\" + left + \"px;\" + (extraStyle || \"\"));\n }\n if (this.session.$bidiHandler.isBidiRow(range.end.row)) {\n var range1 = range.clone();\n range1.start.row = range1.end.row;\n range1.start.column = 0;\n this.drawBidiSingleLineMarker(stringBuilder, range1, clazz + \" ace_br12\", config, null, extraStyle);\n }\n else {\n top = this.$getTop(range.end.row, config);\n var width = range.end.column * config.characterWidth;\n this.elt(clazz + \" ace_br12\", \"height:\" + height + \"px;\" +\n \"width:\" + width + \"px;\" +\n \"top:\" + top + \"px;\" +\n \"left:\" + padding + \"px;\" + (extraStyle || \"\"));\n }\n height = (range.end.row - range.start.row - 1) * config.lineHeight;\n if (height <= 0)\n return;\n top = this.$getTop(range.start.row + 1, config);\n var radiusClass = (range.start.column ? 1 : 0) | (range.end.column ? 0 : 8);\n this.elt(clazz + (radiusClass ? \" ace_br\" + radiusClass : \"\"), \"height:\" + height + \"px;\" +\n \"right:\" + padding + \"px;\" +\n \"top:\" + top + \"px;\" +\n \"left:\" + padding + \"px;\" + (extraStyle || \"\"));\n };\n Marker.prototype.drawSingleLineMarker = function (stringBuilder, range, clazz, config, extraLength, extraStyle) {\n if (this.session.$bidiHandler.isBidiRow(range.start.row))\n return this.drawBidiSingleLineMarker(stringBuilder, range, clazz, config, extraLength, extraStyle);\n var height = config.lineHeight;\n var width = (range.end.column + (extraLength || 0) - range.start.column) * config.characterWidth;\n var top = this.$getTop(range.start.row, config);\n var left = this.$padding + range.start.column * config.characterWidth;\n this.elt(clazz, \"height:\" + height + \"px;\" +\n \"width:\" + width + \"px;\" +\n \"top:\" + top + \"px;\" +\n \"left:\" + left + \"px;\" + (extraStyle || \"\"));\n };\n Marker.prototype.drawBidiSingleLineMarker = function (stringBuilder, range, clazz, config, extraLength, extraStyle) {\n var height = config.lineHeight, top = this.$getTop(range.start.row, config), padding = this.$padding;\n var selections = this.session.$bidiHandler.getSelections(range.start.column, range.end.column);\n selections.forEach(function (selection) {\n this.elt(clazz, \"height:\" + height + \"px;\" +\n \"width:\" + (selection.width + (extraLength || 0)) + \"px;\" +\n \"top:\" + top + \"px;\" +\n \"left:\" + (padding + selection.left) + \"px;\" + (extraStyle || \"\"));\n }, this);\n };\n Marker.prototype.drawFullLineMarker = function (stringBuilder, range, clazz, config, extraStyle) {\n var top = this.$getTop(range.start.row, config);\n var height = config.lineHeight;\n if (range.start.row != range.end.row)\n height += this.$getTop(range.end.row, config) - top;\n this.elt(clazz, \"height:\" + height + \"px;\" +\n \"top:\" + top + \"px;\" +\n \"left:0;right:0;\" + (extraStyle || \"\"));\n };\n Marker.prototype.drawScreenLineMarker = function (stringBuilder, range, clazz, config, extraStyle) {\n var top = this.$getTop(range.start.row, config);\n var height = config.lineHeight;\n this.elt(clazz, \"height:\" + height + \"px;\" +\n \"top:\" + top + \"px;\" +\n \"left:0;right:0;\" + (extraStyle || \"\"));\n };\n return Marker;\n}());\nMarker.prototype.$padding = 0;\nfunction getBorderClass(tl, tr, br, bl) {\n return (tl ? 1 : 0) | (tr ? 2 : 0) | (br ? 4 : 0) | (bl ? 8 : 0);\n}\nexports.Marker = Marker;\n\n});\n\nace.define(\"ace/layer/text_util\",[\"require\",\"exports\",\"module\"], function(require, exports, module){// Tokens for which Ace just uses a simple TextNode and does not add any special className.\nvar textTokens = new Set([\"text\", \"rparen\", \"lparen\"]);\nexports.isTextToken = function (tokenType) {\n return textTokens.has(tokenType);\n};\n\n});\n\nace.define(\"ace/layer/text\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/dom\",\"ace/lib/lang\",\"ace/layer/lines\",\"ace/lib/event_emitter\",\"ace/config\",\"ace/layer/text_util\"], function(require, exports, module){\"use strict\";\nvar oop = require(\"../lib/oop\");\nvar dom = require(\"../lib/dom\");\nvar lang = require(\"../lib/lang\");\nvar Lines = require(\"./lines\").Lines;\nvar EventEmitter = require(\"../lib/event_emitter\").EventEmitter;\nvar nls = require(\"../config\").nls;\nvar isTextToken = require(\"./text_util\").isTextToken;\nvar Text = /** @class */ (function () {\n function Text(parentEl) {\n this.dom = dom;\n this.element = this.dom.createElement(\"div\");\n this.element.className = \"ace_layer ace_text-layer\";\n parentEl.appendChild(this.element);\n this.$updateEolChar = this.$updateEolChar.bind(this);\n this.$lines = new Lines(this.element);\n }\n Text.prototype.$updateEolChar = function () {\n var doc = this.session.doc;\n var unixMode = doc.getNewLineCharacter() == \"\\n\" && doc.getNewLineMode() != \"windows\";\n var EOL_CHAR = unixMode ? this.EOL_CHAR_LF : this.EOL_CHAR_CRLF;\n if (this.EOL_CHAR != EOL_CHAR) {\n this.EOL_CHAR = EOL_CHAR;\n return true;\n }\n };\n Text.prototype.setPadding = function (padding) {\n this.$padding = padding;\n this.element.style.margin = \"0 \" + padding + \"px\";\n };\n Text.prototype.getLineHeight = function () {\n return this.$fontMetrics.$characterSize.height || 0;\n };\n Text.prototype.getCharacterWidth = function () {\n return this.$fontMetrics.$characterSize.width || 0;\n };\n Text.prototype.$setFontMetrics = function (measure) {\n this.$fontMetrics = measure;\n this.$fontMetrics.on(\"changeCharacterSize\", \n function (e) {\n this._signal(\"changeCharacterSize\", e);\n }.bind(this));\n this.$pollSizeChanges();\n };\n Text.prototype.checkForSizeChanges = function () {\n this.$fontMetrics.checkForSizeChanges();\n };\n Text.prototype.$pollSizeChanges = function () {\n return this.$pollSizeChangesTimer = this.$fontMetrics.$pollSizeChanges();\n };\n Text.prototype.setSession = function (session) {\n this.session = session;\n if (session)\n this.$computeTabString();\n };\n Text.prototype.setShowInvisibles = function (showInvisibles) {\n if (this.showInvisibles == showInvisibles)\n return false;\n this.showInvisibles = showInvisibles;\n if (typeof showInvisibles == \"string\") {\n this.showSpaces = /tab/i.test(showInvisibles);\n this.showTabs = /space/i.test(showInvisibles);\n this.showEOL = /eol/i.test(showInvisibles);\n }\n else {\n this.showSpaces = this.showTabs = this.showEOL = showInvisibles;\n }\n this.$computeTabString();\n return true;\n };\n Text.prototype.setDisplayIndentGuides = function (display) {\n if (this.displayIndentGuides == display)\n return false;\n this.displayIndentGuides = display;\n this.$computeTabString();\n return true;\n };\n Text.prototype.setHighlightIndentGuides = function (highlight) {\n if (this.$highlightIndentGuides === highlight)\n return false;\n this.$highlightIndentGuides = highlight;\n return highlight;\n };\n Text.prototype.$computeTabString = function () {\n var tabSize = this.session.getTabSize();\n this.tabSize = tabSize; var tabStr = this.$tabStrings = [0];\n for (var i = 1; i < tabSize + 1; i++) {\n if (this.showTabs) {\n var span = this.dom.createElement(\"span\");\n span.className = \"ace_invisible ace_invisible_tab\";\n span.textContent = lang.stringRepeat(this.TAB_CHAR, i);\n tabStr.push(span);\n }\n else {\n tabStr.push(this.dom.createTextNode(lang.stringRepeat(\" \", i), this.element));\n }\n }\n if (this.displayIndentGuides) {\n this.$indentGuideRe = /\\s\\S| \\t|\\t |\\s$/;\n var className = \"ace_indent-guide\";\n var spaceClass = this.showSpaces ? \" ace_invisible ace_invisible_space\" : \"\";\n var spaceContent = this.showSpaces\n ? lang.stringRepeat(this.SPACE_CHAR, this.tabSize)\n : lang.stringRepeat(\" \", this.tabSize);\n var tabClass = this.showTabs ? \" ace_invisible ace_invisible_tab\" : \"\";\n var tabContent = this.showTabs\n ? lang.stringRepeat(this.TAB_CHAR, this.tabSize)\n : spaceContent;\n var span = this.dom.createElement(\"span\");\n span.className = className + spaceClass;\n span.textContent = spaceContent;\n this.$tabStrings[\" \"] = span;\n var span = this.dom.createElement(\"span\");\n span.className = className + tabClass;\n span.textContent = tabContent;\n this.$tabStrings[\"\\t\"] = span;\n }\n };\n Text.prototype.updateLines = function (config, firstRow, lastRow) {\n if (this.config.lastRow != config.lastRow ||\n this.config.firstRow != config.firstRow) {\n return this.update(config);\n }\n this.config = config;\n var first = Math.max(firstRow, config.firstRow);\n var last = Math.min(lastRow, config.lastRow);\n var lineElements = this.element.childNodes;\n var lineElementsIdx = 0;\n for (var row = config.firstRow; row < first; row++) {\n var foldLine = this.session.getFoldLine(row);\n if (foldLine) {\n if (foldLine.containsRow(first)) {\n first = foldLine.start.row;\n break;\n }\n else {\n row = foldLine.end.row;\n }\n }\n lineElementsIdx++;\n }\n var heightChanged = false;\n var row = first;\n var foldLine = this.session.getNextFoldLine(row);\n var foldStart = foldLine ? foldLine.start.row : Infinity;\n while (true) {\n if (row > foldStart) {\n row = foldLine.end.row + 1;\n foldLine = this.session.getNextFoldLine(row, foldLine);\n foldStart = foldLine ? foldLine.start.row : Infinity;\n }\n if (row > last)\n break; var lineElement = lineElements[lineElementsIdx++];\n if (lineElement) {\n this.dom.removeChildren(lineElement);\n this.$renderLine(lineElement, row, row == foldStart ? foldLine : false);\n if (heightChanged)\n lineElement.style.top = this.$lines.computeLineTop(row, config, this.session) + \"px\";\n var height = (config.lineHeight * this.session.getRowLength(row)) + \"px\";\n if (lineElement.style.height != height) {\n heightChanged = true;\n lineElement.style.height = height;\n }\n }\n row++;\n }\n if (heightChanged) {\n while (lineElementsIdx < this.$lines.cells.length) {\n var cell = this.$lines.cells[lineElementsIdx++];\n cell.element.style.top = this.$lines.computeLineTop(cell.row, config, this.session) + \"px\";\n }\n }\n };\n Text.prototype.scrollLines = function (config) {\n var oldConfig = this.config;\n this.config = config;\n if (this.$lines.pageChanged(oldConfig, config))\n return this.update(config);\n this.$lines.moveContainer(config);\n var lastRow = config.lastRow;\n var oldLastRow = oldConfig ? oldConfig.lastRow : -1;\n if (!oldConfig || oldLastRow < config.firstRow)\n return this.update(config);\n if (lastRow < oldConfig.firstRow)\n return this.update(config);\n if (!oldConfig || oldConfig.lastRow < config.firstRow)\n return this.update(config);\n if (config.lastRow < oldConfig.firstRow)\n return this.update(config);\n if (oldConfig.firstRow < config.firstRow)\n for (var row = this.session.getFoldedRowCount(oldConfig.firstRow, config.firstRow - 1); row > 0; row--)\n this.$lines.shift();\n if (oldConfig.lastRow > config.lastRow)\n for (var row = this.session.getFoldedRowCount(config.lastRow + 1, oldConfig.lastRow); row > 0; row--)\n this.$lines.pop();\n if (config.firstRow < oldConfig.firstRow) {\n this.$lines.unshift(this.$renderLinesFragment(config, config.firstRow, oldConfig.firstRow - 1));\n }\n if (config.lastRow > oldConfig.lastRow) {\n this.$lines.push(this.$renderLinesFragment(config, oldConfig.lastRow + 1, config.lastRow));\n }\n this.$highlightIndentGuide();\n };\n Text.prototype.$renderLinesFragment = function (config, firstRow, lastRow) {\n var fragment = [];\n var row = firstRow;\n var foldLine = this.session.getNextFoldLine(row);\n var foldStart = foldLine ? foldLine.start.row : Infinity;\n while (true) {\n if (row > foldStart) {\n row = foldLine.end.row + 1;\n foldLine = this.session.getNextFoldLine(row, foldLine);\n foldStart = foldLine ? foldLine.start.row : Infinity;\n }\n if (row > lastRow)\n break;\n var line = this.$lines.createCell(row, config, this.session);\n var lineEl = line.element;\n this.dom.removeChildren(lineEl);\n dom.setStyle(lineEl.style, \"height\", this.$lines.computeLineHeight(row, config, this.session) + \"px\");\n dom.setStyle(lineEl.style, \"top\", this.$lines.computeLineTop(row, config, this.session) + \"px\");\n this.$renderLine(lineEl, row, row == foldStart ? foldLine : false);\n if (this.$useLineGroups()) {\n lineEl.className = \"ace_line_group\";\n }\n else {\n lineEl.className = \"ace_line\";\n }\n fragment.push(line);\n row++;\n }\n return fragment;\n };\n Text.prototype.update = function (config) {\n this.$lines.moveContainer(config);\n this.config = config;\n var firstRow = config.firstRow;\n var lastRow = config.lastRow;\n var lines = this.$lines;\n while (lines.getLength())\n lines.pop();\n lines.push(this.$renderLinesFragment(config, firstRow, lastRow));\n };\n Text.prototype.$renderToken = function (parent, screenColumn, token, value) {\n var self = this;\n var re = /(\\t)|( +)|([\\x00-\\x1f\\x80-\\xa0\\xad\\u1680\\u180E\\u2000-\\u200f\\u2028\\u2029\\u202F\\u205F\\uFEFF\\uFFF9-\\uFFFC\\u2066\\u2067\\u2068\\u202A\\u202B\\u202D\\u202E\\u202C\\u2069\\u2060\\u2061\\u2062\\u2063\\u2064\\u206A\\u206B\\u206B\\u206C\\u206D\\u206E\\u206F]+)|(\\u3000)|([\\u1100-\\u115F\\u11A3-\\u11A7\\u11FA-\\u11FF\\u2329-\\u232A\\u2E80-\\u2E99\\u2E9B-\\u2EF3\\u2F00-\\u2FD5\\u2FF0-\\u2FFB\\u3001-\\u303E\\u3041-\\u3096\\u3099-\\u30FF\\u3105-\\u312D\\u3131-\\u318E\\u3190-\\u31BA\\u31C0-\\u31E3\\u31F0-\\u321E\\u3220-\\u3247\\u3250-\\u32FE\\u3300-\\u4DBF\\u4E00-\\uA48C\\uA490-\\uA4C6\\uA960-\\uA97C\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFAFF\\uFE10-\\uFE19\\uFE30-\\uFE52\\uFE54-\\uFE66\\uFE68-\\uFE6B\\uFF01-\\uFF60\\uFFE0-\\uFFE6]|[\\uD800-\\uDBFF][\\uDC00-\\uDFFF])/g;\n var valueFragment = this.dom.createFragment(this.element);\n var m;\n var i = 0;\n while (m = re.exec(value)) {\n var tab = m[1];\n var simpleSpace = m[2];\n var controlCharacter = m[3];\n var cjkSpace = m[4];\n var cjk = m[5];\n if (!self.showSpaces && simpleSpace)\n continue;\n var before = i != m.index ? value.slice(i, m.index) : \"\";\n i = m.index + m[0].length;\n if (before) {\n valueFragment.appendChild(this.dom.createTextNode(before, this.element));\n }\n if (tab) {\n var tabSize = self.session.getScreenTabSize(screenColumn + m.index);\n valueFragment.appendChild(self.$tabStrings[tabSize].cloneNode(true));\n screenColumn += tabSize - 1;\n }\n else if (simpleSpace) {\n if (self.showSpaces) {\n var span = this.dom.createElement(\"span\");\n span.className = \"ace_invisible ace_invisible_space\";\n span.textContent = lang.stringRepeat(self.SPACE_CHAR, simpleSpace.length);\n valueFragment.appendChild(span);\n }\n else {\n valueFragment.appendChild(this.dom.createTextNode(simpleSpace, this.element));\n }\n }\n else if (controlCharacter) {\n var span = this.dom.createElement(\"span\");\n span.className = \"ace_invisible ace_invisible_space ace_invalid\";\n span.textContent = lang.stringRepeat(self.SPACE_CHAR, controlCharacter.length);\n valueFragment.appendChild(span);\n }\n else if (cjkSpace) {\n screenColumn += 1;\n var span = this.dom.createElement(\"span\");\n span.style.width = (self.config.characterWidth * 2) + \"px\";\n span.className = self.showSpaces ? \"ace_cjk ace_invisible ace_invisible_space\" : \"ace_cjk\";\n span.textContent = self.showSpaces ? self.SPACE_CHAR : cjkSpace;\n valueFragment.appendChild(span);\n }\n else if (cjk) {\n screenColumn += 1;\n var span = this.dom.createElement(\"span\");\n span.style.width = (self.config.characterWidth * 2) + \"px\";\n span.className = \"ace_cjk\";\n span.textContent = cjk;\n valueFragment.appendChild(span);\n }\n }\n valueFragment.appendChild(this.dom.createTextNode(i ? value.slice(i) : value, this.element));\n if (!isTextToken(token.type)) {\n var classes = \"ace_\" + token.type.replace(/\\./g, \" ace_\");\n var span = this.dom.createElement(\"span\");\n if (token.type == \"fold\") {\n span.style.width = (token.value.length * this.config.characterWidth) + \"px\";\n span.setAttribute(\"title\", nls(\"inline-fold.closed.title\", \"Unfold code\"));\n }\n span.className = classes;\n span.appendChild(valueFragment);\n parent.appendChild(span);\n }\n else {\n parent.appendChild(valueFragment);\n }\n return screenColumn + value.length;\n };\n Text.prototype.renderIndentGuide = function (parent, value, max) {\n var cols = value.search(this.$indentGuideRe);\n if (cols <= 0 || cols >= max)\n return value;\n if (value[0] == \" \") {\n cols -= cols % this.tabSize;\n var count = cols / this.tabSize;\n for (var i = 0; i < count; i++) {\n parent.appendChild(this.$tabStrings[\" \"].cloneNode(true));\n }\n this.$highlightIndentGuide();\n return value.substr(cols);\n }\n else if (value[0] == \"\\t\") {\n for (var i = 0; i < cols; i++) {\n parent.appendChild(this.$tabStrings[\"\\t\"].cloneNode(true));\n }\n this.$highlightIndentGuide();\n return value.substr(cols);\n }\n this.$highlightIndentGuide();\n return value;\n };\n Text.prototype.$highlightIndentGuide = function () {\n if (!this.$highlightIndentGuides || !this.displayIndentGuides)\n return;\n this.$highlightIndentGuideMarker = {\n indentLevel: undefined,\n start: undefined,\n end: undefined,\n dir: undefined\n };\n var lines = this.session.doc.$lines;\n if (!lines)\n return;\n var cursor = this.session.selection.getCursor();\n var initialIndent = /^\\s*/.exec(this.session.doc.getLine(cursor.row))[0].length;\n var elementIndentLevel = Math.floor(initialIndent / this.tabSize);\n this.$highlightIndentGuideMarker = {\n indentLevel: elementIndentLevel,\n start: cursor.row\n };\n var bracketHighlight = this.session.$bracketHighlight;\n if (bracketHighlight) {\n var ranges = this.session.$bracketHighlight.ranges;\n for (var i = 0; i < ranges.length; i++) {\n if (cursor.row !== ranges[i].start.row) {\n this.$highlightIndentGuideMarker.end = ranges[i].start.row;\n if (cursor.row > ranges[i].start.row) {\n this.$highlightIndentGuideMarker.dir = -1;\n }\n else {\n this.$highlightIndentGuideMarker.dir = 1;\n }\n break;\n }\n }\n }\n if (!this.$highlightIndentGuideMarker.end) {\n if (lines[cursor.row] !== '' && cursor.column === lines[cursor.row].length) {\n this.$highlightIndentGuideMarker.dir = 1;\n for (var i = cursor.row + 1; i < lines.length; i++) {\n var line = lines[i];\n var currentIndent = /^\\s*/.exec(line)[0].length;\n if (line !== '') {\n this.$highlightIndentGuideMarker.end = i;\n if (currentIndent <= initialIndent)\n break;\n }\n }\n }\n }\n this.$renderHighlightIndentGuide();\n };\n Text.prototype.$clearActiveIndentGuide = function () {\n var cells = this.$lines.cells;\n for (var i = 0; i < cells.length; i++) {\n var cell = cells[i];\n var childNodes = cell.element.childNodes;\n if (childNodes.length > 0) {\n for (var j = 0; j < childNodes.length; j++) {\n if (childNodes[j].classList && childNodes[j].classList.contains(\"ace_indent-guide-active\")) {\n childNodes[j].classList.remove(\"ace_indent-guide-active\");\n break;\n }\n }\n }\n }\n };\n Text.prototype.$setIndentGuideActive = function (cell, indentLevel) {\n var line = this.session.doc.getLine(cell.row);\n if (line !== \"\") {\n var childNodes = cell.element.childNodes;\n if (childNodes) {\n var node = childNodes[indentLevel - 1];\n if (node && node.classList && node.classList.contains(\"ace_indent-guide\"))\n node.classList.add(\"ace_indent-guide-active\");\n }\n }\n };\n Text.prototype.$renderHighlightIndentGuide = function () {\n if (!this.$lines)\n return;\n var cells = this.$lines.cells;\n this.$clearActiveIndentGuide();\n var indentLevel = this.$highlightIndentGuideMarker.indentLevel;\n if (indentLevel !== 0) {\n if (this.$highlightIndentGuideMarker.dir === 1) {\n for (var i = 0; i < cells.length; i++) {\n var cell = cells[i];\n if (this.$highlightIndentGuideMarker.end && cell.row >= this.$highlightIndentGuideMarker.start\n + 1) {\n if (cell.row >= this.$highlightIndentGuideMarker.end)\n break;\n this.$setIndentGuideActive(cell, indentLevel);\n }\n }\n }\n else {\n for (var i = cells.length - 1; i >= 0; i--) {\n var cell = cells[i];\n if (this.$highlightIndentGuideMarker.end && cell.row < this.$highlightIndentGuideMarker.start) {\n if (cell.row <= this.$highlightIndentGuideMarker.end)\n break;\n this.$setIndentGuideActive(cell, indentLevel);\n }\n }\n }\n }\n };\n Text.prototype.$createLineElement = function (parent) {\n var lineEl = this.dom.createElement(\"div\");\n lineEl.className = \"ace_line\";\n lineEl.style.height = this.config.lineHeight + \"px\";\n return lineEl;\n };\n Text.prototype.$renderWrappedLine = function (parent, tokens, splits) {\n var chars = 0;\n var split = 0;\n var splitChars = splits[0];\n var screenColumn = 0;\n var lineEl = this.$createLineElement();\n parent.appendChild(lineEl);\n for (var i = 0; i < tokens.length; i++) {\n var token = tokens[i];\n var value = token.value;\n if (i == 0 && this.displayIndentGuides) {\n chars = value.length;\n value = this.renderIndentGuide(lineEl, value, splitChars);\n if (!value)\n continue;\n chars -= value.length;\n }\n if (chars + value.length < splitChars) {\n screenColumn = this.$renderToken(lineEl, screenColumn, token, value);\n chars += value.length;\n }\n else {\n while (chars + value.length >= splitChars) {\n screenColumn = this.$renderToken(lineEl, screenColumn, token, value.substring(0, splitChars - chars));\n value = value.substring(splitChars - chars);\n chars = splitChars;\n lineEl = this.$createLineElement();\n parent.appendChild(lineEl);\n lineEl.appendChild(this.dom.createTextNode(lang.stringRepeat(\"\\xa0\", splits.indent), this.element));\n split++;\n screenColumn = 0;\n splitChars = splits[split] || Number.MAX_VALUE;\n }\n if (value.length != 0) {\n chars += value.length;\n screenColumn = this.$renderToken(lineEl, screenColumn, token, value);\n }\n }\n }\n if (splits[splits.length - 1] > this.MAX_LINE_LENGTH)\n this.$renderOverflowMessage(lineEl, screenColumn, null, \"\", true);\n };\n Text.prototype.$renderSimpleLine = function (parent, tokens) {\n var screenColumn = 0;\n for (var i = 0; i < tokens.length; i++) {\n var token = tokens[i];\n var value = token.value;\n if (i == 0 && this.displayIndentGuides) {\n value = this.renderIndentGuide(parent, value);\n if (!value)\n continue;\n }\n if (screenColumn + value.length > this.MAX_LINE_LENGTH)\n return this.$renderOverflowMessage(parent, screenColumn, token, value);\n screenColumn = this.$renderToken(parent, screenColumn, token, value);\n }\n };\n Text.prototype.$renderOverflowMessage = function (parent, screenColumn, token, value, hide) {\n token && this.$renderToken(parent, screenColumn, token, value.slice(0, this.MAX_LINE_LENGTH - screenColumn));\n var overflowEl = this.dom.createElement(\"span\");\n overflowEl.className = \"ace_inline_button ace_keyword ace_toggle_wrap\";\n overflowEl.textContent = hide ? \"\" : \"\";\n parent.appendChild(overflowEl);\n };\n Text.prototype.$renderLine = function (parent, row, foldLine) {\n if (!foldLine && foldLine != false)\n foldLine = this.session.getFoldLine(row);\n if (foldLine)\n var tokens = this.$getFoldLineTokens(row, foldLine);\n else\n var tokens = this.session.getTokens(row);\n var lastLineEl = parent;\n if (tokens.length) {\n var splits = this.session.getRowSplitData(row);\n if (splits && splits.length) {\n this.$renderWrappedLine(parent, tokens, splits);\n var lastLineEl = parent.lastChild;\n }\n else {\n var lastLineEl = parent;\n if (this.$useLineGroups()) {\n lastLineEl = this.$createLineElement();\n parent.appendChild(lastLineEl);\n }\n this.$renderSimpleLine(lastLineEl, tokens);\n }\n }\n else if (this.$useLineGroups()) {\n lastLineEl = this.$createLineElement();\n parent.appendChild(lastLineEl);\n }\n if (this.showEOL && lastLineEl) {\n if (foldLine)\n row = foldLine.end.row;\n var invisibleEl = this.dom.createElement(\"span\");\n invisibleEl.className = \"ace_invisible ace_invisible_eol\";\n invisibleEl.textContent = row == this.session.getLength() - 1 ? this.EOF_CHAR : this.EOL_CHAR;\n lastLineEl.appendChild(invisibleEl);\n }\n };\n Text.prototype.$getFoldLineTokens = function (row, foldLine) {\n var session = this.session;\n var renderTokens = [];\n function addTokens(tokens, from, to) {\n var idx = 0, col = 0;\n while ((col + tokens[idx].value.length) < from) {\n col += tokens[idx].value.length;\n idx++;\n if (idx == tokens.length)\n return;\n }\n if (col != from) {\n var value = tokens[idx].value.substring(from - col);\n if (value.length > (to - from))\n value = value.substring(0, to - from);\n renderTokens.push({\n type: tokens[idx].type,\n value: value\n });\n col = from + value.length;\n idx += 1;\n }\n while (col < to && idx < tokens.length) {\n var value = tokens[idx].value;\n if (value.length + col > to) {\n renderTokens.push({\n type: tokens[idx].type,\n value: value.substring(0, to - col)\n });\n }\n else\n renderTokens.push(tokens[idx]);\n col += value.length;\n idx += 1;\n }\n }\n var tokens = session.getTokens(row);\n foldLine.walk(function (placeholder, row, column, lastColumn, isNewRow) {\n if (placeholder != null) {\n renderTokens.push({\n type: \"fold\",\n value: placeholder\n });\n }\n else {\n if (isNewRow)\n tokens = session.getTokens(row);\n if (tokens.length)\n addTokens(tokens, lastColumn, column);\n }\n }, foldLine.end.row, this.session.getLine(foldLine.end.row).length);\n return renderTokens;\n };\n Text.prototype.$useLineGroups = function () {\n return this.session.getUseWrapMode();\n };\n return Text;\n}());\nText.prototype.EOF_CHAR = \"\\xB6\";\nText.prototype.EOL_CHAR_LF = \"\\xAC\";\nText.prototype.EOL_CHAR_CRLF = \"\\xa4\";\nText.prototype.EOL_CHAR = Text.prototype.EOL_CHAR_LF;\nText.prototype.TAB_CHAR = \"\\u2014\"; //\"\\u21E5\";\nText.prototype.SPACE_CHAR = \"\\xB7\";\nText.prototype.$padding = 0;\nText.prototype.MAX_LINE_LENGTH = 10000;\nText.prototype.showInvisibles = false;\nText.prototype.showSpaces = false;\nText.prototype.showTabs = false;\nText.prototype.showEOL = false;\nText.prototype.displayIndentGuides = true;\nText.prototype.$highlightIndentGuides = true;\nText.prototype.$tabStrings = [];\nText.prototype.destroy = {};\nText.prototype.onChangeTabSize = Text.prototype.$computeTabString;\noop.implement(Text.prototype, EventEmitter);\nexports.Text = Text;\n\n});\n\nace.define(\"ace/layer/cursor\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\"], function(require, exports, module){\"use strict\";\nvar dom = require(\"../lib/dom\");\nvar Cursor = /** @class */ (function () {\n function Cursor(parentEl) {\n this.element = dom.createElement(\"div\");\n this.element.className = \"ace_layer ace_cursor-layer\";\n parentEl.appendChild(this.element);\n this.isVisible = false;\n this.isBlinking = true;\n this.blinkInterval = 1000;\n this.smoothBlinking = false;\n this.cursors = [];\n this.cursor = this.addCursor();\n dom.addCssClass(this.element, \"ace_hidden-cursors\");\n this.$updateCursors = this.$updateOpacity.bind(this);\n }\n Cursor.prototype.$updateOpacity = function (val) {\n var cursors = this.cursors;\n for (var i = cursors.length; i--;)\n dom.setStyle(cursors[i].style, \"opacity\", val ? \"\" : \"0\");\n };\n Cursor.prototype.$startCssAnimation = function () {\n var cursors = this.cursors;\n for (var i = cursors.length; i--;)\n cursors[i].style.animationDuration = this.blinkInterval + \"ms\";\n this.$isAnimating = true;\n setTimeout(function () {\n if (this.$isAnimating) {\n dom.addCssClass(this.element, \"ace_animate-blinking\");\n }\n }.bind(this));\n };\n Cursor.prototype.$stopCssAnimation = function () {\n this.$isAnimating = false;\n dom.removeCssClass(this.element, \"ace_animate-blinking\");\n };\n Cursor.prototype.setPadding = function (padding) {\n this.$padding = padding;\n };\n Cursor.prototype.setSession = function (session) {\n this.session = session;\n };\n Cursor.prototype.setBlinking = function (blinking) {\n if (blinking != this.isBlinking) {\n this.isBlinking = blinking;\n this.restartTimer();\n }\n };\n Cursor.prototype.setBlinkInterval = function (blinkInterval) {\n if (blinkInterval != this.blinkInterval) {\n this.blinkInterval = blinkInterval;\n this.restartTimer();\n }\n };\n Cursor.prototype.setSmoothBlinking = function (smoothBlinking) {\n if (smoothBlinking != this.smoothBlinking) {\n this.smoothBlinking = smoothBlinking;\n dom.setCssClass(this.element, \"ace_smooth-blinking\", smoothBlinking);\n this.$updateCursors(true);\n this.restartTimer();\n }\n };\n Cursor.prototype.addCursor = function () {\n var el = dom.createElement(\"div\");\n el.className = \"ace_cursor\";\n this.element.appendChild(el);\n this.cursors.push(el);\n return el;\n };\n Cursor.prototype.removeCursor = function () {\n if (this.cursors.length > 1) {\n var el = this.cursors.pop();\n el.parentNode.removeChild(el);\n return el;\n }\n };\n Cursor.prototype.hideCursor = function () {\n this.isVisible = false;\n dom.addCssClass(this.element, \"ace_hidden-cursors\");\n this.restartTimer();\n };\n Cursor.prototype.showCursor = function () {\n this.isVisible = true;\n dom.removeCssClass(this.element, \"ace_hidden-cursors\");\n this.restartTimer();\n };\n Cursor.prototype.restartTimer = function () {\n var update = this.$updateCursors;\n clearInterval(this.intervalId);\n clearTimeout(this.timeoutId);\n this.$stopCssAnimation();\n if (this.smoothBlinking) {\n this.$isSmoothBlinking = false;\n dom.removeCssClass(this.element, \"ace_smooth-blinking\");\n }\n update(true);\n if (!this.isBlinking || !this.blinkInterval || !this.isVisible) {\n this.$stopCssAnimation();\n return;\n }\n if (this.smoothBlinking) {\n this.$isSmoothBlinking = true;\n setTimeout(function () {\n if (this.$isSmoothBlinking) {\n dom.addCssClass(this.element, \"ace_smooth-blinking\");\n }\n }.bind(this));\n }\n if (dom.HAS_CSS_ANIMATION) {\n this.$startCssAnimation();\n }\n else {\n var blink = /**@this{Cursor}*/ function () {\n this.timeoutId = setTimeout(function () {\n update(false);\n }, 0.6 * this.blinkInterval);\n }.bind(this);\n this.intervalId = setInterval(function () {\n update(true);\n blink();\n }, this.blinkInterval);\n blink();\n }\n };\n Cursor.prototype.getPixelPosition = function (position, onScreen) {\n if (!this.config || !this.session)\n return { left: 0, top: 0 };\n if (!position)\n position = this.session.selection.getCursor();\n var pos = this.session.documentToScreenPosition(position);\n var cursorLeft = this.$padding + (this.session.$bidiHandler.isBidiRow(pos.row, position.row)\n ? this.session.$bidiHandler.getPosLeft(pos.column)\n : pos.column * this.config.characterWidth);\n var cursorTop = (pos.row - (onScreen ? this.config.firstRowScreen : 0)) *\n this.config.lineHeight;\n return { left: cursorLeft, top: cursorTop };\n };\n Cursor.prototype.isCursorInView = function (pixelPos, config) {\n return pixelPos.top >= 0 && pixelPos.top < config.maxHeight;\n };\n Cursor.prototype.update = function (config) {\n this.config = config;\n var selections = this.session.$selectionMarkers;\n var i = 0, cursorIndex = 0;\n if (selections === undefined || selections.length === 0) {\n selections = [{ cursor: null }];\n }\n for (var i = 0, n = selections.length; i < n; i++) {\n var pixelPos = this.getPixelPosition(selections[i].cursor, true);\n if ((pixelPos.top > config.height + config.offset ||\n pixelPos.top < 0) && i > 1) {\n continue;\n }\n var element = this.cursors[cursorIndex++] || this.addCursor();\n var style = element.style;\n if (!this.drawCursor) {\n if (!this.isCursorInView(pixelPos, config)) {\n dom.setStyle(style, \"display\", \"none\");\n }\n else {\n dom.setStyle(style, \"display\", \"block\");\n dom.translate(element, pixelPos.left, pixelPos.top);\n dom.setStyle(style, \"width\", Math.round(config.characterWidth) + \"px\");\n dom.setStyle(style, \"height\", config.lineHeight + \"px\");\n }\n }\n else {\n this.drawCursor(element, pixelPos, config, selections[i], this.session);\n }\n }\n while (this.cursors.length > cursorIndex)\n this.removeCursor();\n var overwrite = this.session.getOverwrite();\n this.$setOverwrite(overwrite);\n this.$pixelPos = pixelPos;\n this.restartTimer();\n };\n Cursor.prototype.$setOverwrite = function (overwrite) {\n if (overwrite != this.overwrite) {\n this.overwrite = overwrite;\n if (overwrite)\n dom.addCssClass(this.element, \"ace_overwrite-cursors\");\n else\n dom.removeCssClass(this.element, \"ace_overwrite-cursors\");\n }\n };\n Cursor.prototype.destroy = function () {\n clearInterval(this.intervalId);\n clearTimeout(this.timeoutId);\n };\n return Cursor;\n}());\nCursor.prototype.$padding = 0;\nCursor.prototype.drawCursor = null;\nexports.Cursor = Cursor;\n\n});\n\nace.define(\"ace/scrollbar\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/dom\",\"ace/lib/event\",\"ace/lib/event_emitter\"], function(require, exports, module){\"use strict\";\nvar __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar oop = require(\"./lib/oop\");\nvar dom = require(\"./lib/dom\");\nvar event = require(\"./lib/event\");\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar MAX_SCROLL_H = 0x8000;\nvar Scrollbar = /** @class */ (function () {\n function Scrollbar(parent, classSuffix) {\n this.element = dom.createElement(\"div\");\n this.element.className = \"ace_scrollbar ace_scrollbar\" + classSuffix;\n this.inner = dom.createElement(\"div\");\n this.inner.className = \"ace_scrollbar-inner\";\n this.inner.textContent = \"\\xa0\";\n this.element.appendChild(this.inner);\n parent.appendChild(this.element);\n this.setVisible(false);\n this.skipEvent = false;\n event.addListener(this.element, \"scroll\", this.onScroll.bind(this));\n event.addListener(this.element, \"mousedown\", event.preventDefault);\n }\n Scrollbar.prototype.setVisible = function (isVisible) {\n this.element.style.display = isVisible ? \"\" : \"none\";\n this.isVisible = isVisible;\n this.coeff = 1;\n };\n return Scrollbar;\n}());\noop.implement(Scrollbar.prototype, EventEmitter);\nvar VScrollBar = /** @class */ (function (_super) {\n __extends(VScrollBar, _super);\n function VScrollBar(parent, renderer) {\n var _this = _super.call(this, parent, '-v') || this;\n _this.scrollTop = 0;\n _this.scrollHeight = 0;\n renderer.$scrollbarWidth =\n _this.width = dom.scrollbarWidth(parent.ownerDocument);\n _this.inner.style.width =\n _this.element.style.width = (_this.width || 15) + 5 + \"px\";\n _this.$minWidth = 0;\n return _this;\n }\n VScrollBar.prototype.onScroll = function () {\n if (!this.skipEvent) {\n this.scrollTop = this.element.scrollTop;\n if (this.coeff != 1) {\n var h = this.element.clientHeight / this.scrollHeight;\n this.scrollTop = this.scrollTop * (1 - h) / (this.coeff - h);\n }\n this._emit(\"scroll\", { data: this.scrollTop });\n }\n this.skipEvent = false;\n };\n VScrollBar.prototype.getWidth = function () {\n return Math.max(this.isVisible ? this.width : 0, this.$minWidth || 0);\n };\n VScrollBar.prototype.setHeight = function (height) {\n this.element.style.height = height + \"px\";\n };\n VScrollBar.prototype.setScrollHeight = function (height) {\n this.scrollHeight = height;\n if (height > MAX_SCROLL_H) {\n this.coeff = MAX_SCROLL_H / height;\n height = MAX_SCROLL_H;\n }\n else if (this.coeff != 1) {\n this.coeff = 1;\n }\n this.inner.style.height = height + \"px\";\n };\n VScrollBar.prototype.setScrollTop = function (scrollTop) {\n if (this.scrollTop != scrollTop) {\n this.skipEvent = true;\n this.scrollTop = scrollTop;\n this.element.scrollTop = scrollTop * this.coeff;\n }\n };\n return VScrollBar;\n}(Scrollbar));\nVScrollBar.prototype.setInnerHeight = VScrollBar.prototype.setScrollHeight;\nvar HScrollBar = /** @class */ (function (_super) {\n __extends(HScrollBar, _super);\n function HScrollBar(parent, renderer) {\n var _this = _super.call(this, parent, '-h') || this;\n _this.scrollLeft = 0;\n _this.height = renderer.$scrollbarWidth;\n _this.inner.style.height =\n _this.element.style.height = (_this.height || 15) + 5 + \"px\";\n return _this;\n }\n HScrollBar.prototype.onScroll = function () {\n if (!this.skipEvent) {\n this.scrollLeft = this.element.scrollLeft;\n this._emit(\"scroll\", { data: this.scrollLeft });\n }\n this.skipEvent = false;\n };\n HScrollBar.prototype.getHeight = function () {\n return this.isVisible ? this.height : 0;\n };\n HScrollBar.prototype.setWidth = function (width) {\n this.element.style.width = width + \"px\";\n };\n HScrollBar.prototype.setInnerWidth = function (width) {\n this.inner.style.width = width + \"px\";\n };\n HScrollBar.prototype.setScrollWidth = function (width) {\n this.inner.style.width = width + \"px\";\n };\n HScrollBar.prototype.setScrollLeft = function (scrollLeft) {\n if (this.scrollLeft != scrollLeft) {\n this.skipEvent = true;\n this.scrollLeft = this.element.scrollLeft = scrollLeft;\n }\n };\n return HScrollBar;\n}(Scrollbar));\nexports.ScrollBar = VScrollBar; // backward compatibility\nexports.ScrollBarV = VScrollBar; // backward compatibility\nexports.ScrollBarH = HScrollBar; // backward compatibility\nexports.VScrollBar = VScrollBar;\nexports.HScrollBar = HScrollBar;\n\n});\n\nace.define(\"ace/scrollbar_custom\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/dom\",\"ace/lib/event\",\"ace/lib/event_emitter\"], function(require, exports, module){\"use strict\";\nvar __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar oop = require(\"./lib/oop\");\nvar dom = require(\"./lib/dom\");\nvar event = require(\"./lib/event\");\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\ndom.importCssString(\".ace_editor>.ace_sb-v div, .ace_editor>.ace_sb-h div{\\n position: absolute;\\n background: rgba(128, 128, 128, 0.6);\\n -moz-box-sizing: border-box;\\n box-sizing: border-box;\\n border: 1px solid #bbb;\\n border-radius: 2px;\\n z-index: 8;\\n}\\n.ace_editor>.ace_sb-v, .ace_editor>.ace_sb-h {\\n position: absolute;\\n z-index: 6;\\n background: none;\\n overflow: hidden!important;\\n}\\n.ace_editor>.ace_sb-v {\\n z-index: 6;\\n right: 0;\\n top: 0;\\n width: 12px;\\n}\\n.ace_editor>.ace_sb-v div {\\n z-index: 8;\\n right: 0;\\n width: 100%;\\n}\\n.ace_editor>.ace_sb-h {\\n bottom: 0;\\n left: 0;\\n height: 12px;\\n}\\n.ace_editor>.ace_sb-h div {\\n bottom: 0;\\n height: 100%;\\n}\\n.ace_editor>.ace_sb_grabbed {\\n z-index: 8;\\n background: #000;\\n}\", \"ace_scrollbar.css\", false);\nvar ScrollBar = /** @class */ (function () {\n function ScrollBar(parent, classSuffix) {\n this.element = dom.createElement(\"div\");\n this.element.className = \"ace_sb\" + classSuffix;\n this.inner = dom.createElement(\"div\");\n this.inner.className = \"\";\n this.element.appendChild(this.inner);\n this.VScrollWidth = 12;\n this.HScrollHeight = 12;\n parent.appendChild(this.element);\n this.setVisible(false);\n this.skipEvent = false;\n event.addMultiMouseDownListener(this.element, [500, 300, 300], this, \"onMouseDown\");\n }\n ScrollBar.prototype.setVisible = function (isVisible) {\n this.element.style.display = isVisible ? \"\" : \"none\";\n this.isVisible = isVisible;\n this.coeff = 1;\n };\n return ScrollBar;\n}());\noop.implement(ScrollBar.prototype, EventEmitter);\nvar VScrollBar = /** @class */ (function (_super) {\n __extends(VScrollBar, _super);\n function VScrollBar(parent, renderer) {\n var _this = _super.call(this, parent, '-v') || this;\n _this.scrollTop = 0;\n _this.scrollHeight = 0;\n _this.parent = parent;\n _this.width = _this.VScrollWidth;\n _this.renderer = renderer;\n _this.inner.style.width = _this.element.style.width = (_this.width || 15) + \"px\";\n _this.$minWidth = 0;\n return _this;\n }\n VScrollBar.prototype.onMouseDown = function (eType, e) {\n if (eType !== \"mousedown\")\n return;\n if (event.getButton(e) !== 0 || e.detail === 2) {\n return;\n }\n if (e.target === this.inner) {\n var self = this;\n var mousePageY = e.clientY;\n var onMouseMove = function (e) {\n mousePageY = e.clientY;\n };\n var onMouseUp = function () {\n clearInterval(timerId);\n };\n var startY = e.clientY;\n var startTop = this.thumbTop;\n var onScrollInterval = function () {\n if (mousePageY === undefined)\n return;\n var scrollTop = self.scrollTopFromThumbTop(startTop + mousePageY - startY);\n if (scrollTop === self.scrollTop)\n return;\n self._emit(\"scroll\", { data: scrollTop });\n };\n event.capture(this.inner, onMouseMove, onMouseUp);\n var timerId = setInterval(onScrollInterval, 20);\n return event.preventDefault(e);\n }\n var top = e.clientY - this.element.getBoundingClientRect().top - this.thumbHeight / 2;\n this._emit(\"scroll\", { data: this.scrollTopFromThumbTop(top) });\n return event.preventDefault(e);\n };\n VScrollBar.prototype.getHeight = function () {\n return this.height;\n };\n VScrollBar.prototype.scrollTopFromThumbTop = function (thumbTop) {\n var scrollTop = thumbTop * (this.pageHeight - this.viewHeight) / (this.slideHeight - this.thumbHeight);\n scrollTop = scrollTop >> 0;\n if (scrollTop < 0) {\n scrollTop = 0;\n }\n else if (scrollTop > this.pageHeight - this.viewHeight) {\n scrollTop = this.pageHeight - this.viewHeight;\n }\n return scrollTop;\n };\n VScrollBar.prototype.getWidth = function () {\n return Math.max(this.isVisible ? this.width : 0, this.$minWidth || 0);\n };\n VScrollBar.prototype.setHeight = function (height) {\n this.height = Math.max(0, height);\n this.slideHeight = this.height;\n this.viewHeight = this.height;\n this.setScrollHeight(this.pageHeight, true);\n };\n VScrollBar.prototype.setScrollHeight = function (height, force) {\n if (this.pageHeight === height && !force)\n return;\n this.pageHeight = height;\n this.thumbHeight = this.slideHeight * this.viewHeight / this.pageHeight;\n if (this.thumbHeight > this.slideHeight)\n this.thumbHeight = this.slideHeight;\n if (this.thumbHeight < 15)\n this.thumbHeight = 15;\n this.inner.style.height = this.thumbHeight + \"px\";\n if (this.scrollTop > (this.pageHeight - this.viewHeight)) {\n this.scrollTop = (this.pageHeight - this.viewHeight);\n if (this.scrollTop < 0)\n this.scrollTop = 0;\n this._emit(\"scroll\", { data: this.scrollTop });\n }\n };\n VScrollBar.prototype.setScrollTop = function (scrollTop) {\n this.scrollTop = scrollTop;\n if (scrollTop < 0)\n scrollTop = 0;\n this.thumbTop = scrollTop * (this.slideHeight - this.thumbHeight) / (this.pageHeight - this.viewHeight);\n this.inner.style.top = this.thumbTop + \"px\";\n };\n return VScrollBar;\n}(ScrollBar));\nVScrollBar.prototype.setInnerHeight = VScrollBar.prototype.setScrollHeight;\nvar HScrollBar = /** @class */ (function (_super) {\n __extends(HScrollBar, _super);\n function HScrollBar(parent, renderer) {\n var _this = _super.call(this, parent, '-h') || this;\n _this.scrollLeft = 0;\n _this.scrollWidth = 0;\n _this.height = _this.HScrollHeight;\n _this.inner.style.height = _this.element.style.height = (_this.height || 12) + \"px\";\n _this.renderer = renderer;\n return _this;\n }\n HScrollBar.prototype.onMouseDown = function (eType, e) {\n if (eType !== \"mousedown\")\n return;\n if (event.getButton(e) !== 0 || e.detail === 2) {\n return;\n }\n if (e.target === this.inner) {\n var self = this;\n var mousePageX = e.clientX;\n var onMouseMove = function (e) {\n mousePageX = e.clientX;\n };\n var onMouseUp = function () {\n clearInterval(timerId);\n };\n var startX = e.clientX;\n var startLeft = this.thumbLeft;\n var onScrollInterval = function () {\n if (mousePageX === undefined)\n return;\n var scrollLeft = self.scrollLeftFromThumbLeft(startLeft + mousePageX - startX);\n if (scrollLeft === self.scrollLeft)\n return;\n self._emit(\"scroll\", { data: scrollLeft });\n };\n event.capture(this.inner, onMouseMove, onMouseUp);\n var timerId = setInterval(onScrollInterval, 20);\n return event.preventDefault(e);\n }\n var left = e.clientX - this.element.getBoundingClientRect().left - this.thumbWidth / 2;\n this._emit(\"scroll\", { data: this.scrollLeftFromThumbLeft(left) });\n return event.preventDefault(e);\n };\n HScrollBar.prototype.getHeight = function () {\n return this.isVisible ? this.height : 0;\n };\n HScrollBar.prototype.scrollLeftFromThumbLeft = function (thumbLeft) {\n var scrollLeft = thumbLeft * (this.pageWidth - this.viewWidth) / (this.slideWidth - this.thumbWidth);\n scrollLeft = scrollLeft >> 0;\n if (scrollLeft < 0) {\n scrollLeft = 0;\n }\n else if (scrollLeft > this.pageWidth - this.viewWidth) {\n scrollLeft = this.pageWidth - this.viewWidth;\n }\n return scrollLeft;\n };\n HScrollBar.prototype.setWidth = function (width) {\n this.width = Math.max(0, width);\n this.element.style.width = this.width + \"px\";\n this.slideWidth = this.width;\n this.viewWidth = this.width;\n this.setScrollWidth(this.pageWidth, true);\n };\n HScrollBar.prototype.setScrollWidth = function (width, force) {\n if (this.pageWidth === width && !force)\n return;\n this.pageWidth = width;\n this.thumbWidth = this.slideWidth * this.viewWidth / this.pageWidth;\n if (this.thumbWidth > this.slideWidth)\n this.thumbWidth = this.slideWidth;\n if (this.thumbWidth < 15)\n this.thumbWidth = 15;\n this.inner.style.width = this.thumbWidth + \"px\";\n if (this.scrollLeft > (this.pageWidth - this.viewWidth)) {\n this.scrollLeft = (this.pageWidth - this.viewWidth);\n if (this.scrollLeft < 0)\n this.scrollLeft = 0;\n this._emit(\"scroll\", { data: this.scrollLeft });\n }\n };\n HScrollBar.prototype.setScrollLeft = function (scrollLeft) {\n this.scrollLeft = scrollLeft;\n if (scrollLeft < 0)\n scrollLeft = 0;\n this.thumbLeft = scrollLeft * (this.slideWidth - this.thumbWidth) / (this.pageWidth - this.viewWidth);\n this.inner.style.left = (this.thumbLeft) + \"px\";\n };\n return HScrollBar;\n}(ScrollBar));\nHScrollBar.prototype.setInnerWidth = HScrollBar.prototype.setScrollWidth;\nexports.ScrollBar = VScrollBar; // backward compatibility\nexports.ScrollBarV = VScrollBar; // backward compatibility\nexports.ScrollBarH = HScrollBar; // backward compatibility\nexports.VScrollBar = VScrollBar;\nexports.HScrollBar = HScrollBar;\n\n});\n\nace.define(\"ace/renderloop\",[\"require\",\"exports\",\"module\",\"ace/lib/event\"], function(require, exports, module){\"use strict\";\nvar event = require(\"./lib/event\");\nvar RenderLoop = /** @class */ (function () {\n function RenderLoop(onRender, win) {\n this.onRender = onRender;\n this.pending = false;\n this.changes = 0;\n this.$recursionLimit = 2;\n this.window = win || window;\n var _self = this;\n this._flush = function (ts) {\n _self.pending = false;\n var changes = _self.changes;\n if (changes) {\n event.blockIdle(100);\n _self.changes = 0;\n _self.onRender(changes);\n }\n if (_self.changes) {\n if (_self.$recursionLimit-- < 0)\n return;\n _self.schedule();\n }\n else {\n _self.$recursionLimit = 2;\n }\n };\n }\n RenderLoop.prototype.schedule = function (change) {\n this.changes = this.changes | change;\n if (this.changes && !this.pending) {\n event.nextFrame(this._flush);\n this.pending = true;\n }\n };\n RenderLoop.prototype.clear = function (change) {\n var changes = this.changes;\n this.changes = 0;\n return changes;\n };\n return RenderLoop;\n}());\nexports.RenderLoop = RenderLoop;\n\n});\n\nace.define(\"ace/layer/font_metrics\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/dom\",\"ace/lib/lang\",\"ace/lib/event\",\"ace/lib/useragent\",\"ace/lib/event_emitter\"], function(require, exports, module){var oop = require(\"../lib/oop\");\nvar dom = require(\"../lib/dom\");\nvar lang = require(\"../lib/lang\");\nvar event = require(\"../lib/event\");\nvar useragent = require(\"../lib/useragent\");\nvar EventEmitter = require(\"../lib/event_emitter\").EventEmitter;\nvar CHAR_COUNT = 512;\nvar USE_OBSERVER = typeof ResizeObserver == \"function\";\nvar L = 200;\nvar FontMetrics = /** @class */ (function () {\n function FontMetrics(parentEl) {\n this.el = dom.createElement(\"div\");\n this.$setMeasureNodeStyles(this.el.style, true);\n this.$main = dom.createElement(\"div\");\n this.$setMeasureNodeStyles(this.$main.style);\n this.$measureNode = dom.createElement(\"div\");\n this.$setMeasureNodeStyles(this.$measureNode.style);\n this.el.appendChild(this.$main);\n this.el.appendChild(this.$measureNode);\n parentEl.appendChild(this.el);\n this.$measureNode.textContent = lang.stringRepeat(\"X\", CHAR_COUNT);\n this.$characterSize = { width: 0, height: 0 };\n if (USE_OBSERVER)\n this.$addObserver();\n else\n this.checkForSizeChanges();\n }\n FontMetrics.prototype.$setMeasureNodeStyles = function (style, isRoot) {\n style.width = style.height = \"auto\";\n style.left = style.top = \"0px\";\n style.visibility = \"hidden\";\n style.position = \"absolute\";\n style.whiteSpace = \"pre\";\n if (useragent.isIE < 8) {\n style[\"font-family\"] = \"inherit\";\n }\n else {\n style.font = \"inherit\";\n }\n style.overflow = isRoot ? \"hidden\" : \"visible\";\n };\n FontMetrics.prototype.checkForSizeChanges = function (size) {\n if (size === undefined)\n size = this.$measureSizes();\n if (size && (this.$characterSize.width !== size.width || this.$characterSize.height !== size.height)) {\n this.$measureNode.style.fontWeight = \"bold\";\n var boldSize = this.$measureSizes();\n this.$measureNode.style.fontWeight = \"\";\n this.$characterSize = size;\n this.charSizes = Object.create(null);\n this.allowBoldFonts = boldSize && boldSize.width === size.width && boldSize.height === size.height;\n this._emit(\"changeCharacterSize\", { data: size });\n }\n };\n FontMetrics.prototype.$addObserver = function () {\n var self = this;\n this.$observer = new window.ResizeObserver(function (e) {\n self.checkForSizeChanges();\n });\n this.$observer.observe(this.$measureNode);\n };\n FontMetrics.prototype.$pollSizeChanges = function () {\n if (this.$pollSizeChangesTimer || this.$observer)\n return this.$pollSizeChangesTimer;\n var self = this;\n return this.$pollSizeChangesTimer = event.onIdle(function cb() {\n self.checkForSizeChanges();\n event.onIdle(cb, 500);\n }, 500);\n };\n FontMetrics.prototype.setPolling = function (val) {\n if (val) {\n this.$pollSizeChanges();\n }\n else if (this.$pollSizeChangesTimer) {\n clearInterval(this.$pollSizeChangesTimer);\n this.$pollSizeChangesTimer = 0;\n }\n };\n FontMetrics.prototype.$measureSizes = function (node) {\n var size = {\n height: (node || this.$measureNode).clientHeight,\n width: (node || this.$measureNode).clientWidth / CHAR_COUNT\n };\n if (size.width === 0 || size.height === 0)\n return null;\n return size;\n };\n FontMetrics.prototype.$measureCharWidth = function (ch) {\n this.$main.textContent = lang.stringRepeat(ch, CHAR_COUNT);\n var rect = this.$main.getBoundingClientRect();\n return rect.width / CHAR_COUNT;\n };\n FontMetrics.prototype.getCharacterWidth = function (ch) {\n var w = this.charSizes[ch];\n if (w === undefined) {\n w = this.charSizes[ch] = this.$measureCharWidth(ch) / this.$characterSize.width;\n }\n return w;\n };\n FontMetrics.prototype.destroy = function () {\n clearInterval(this.$pollSizeChangesTimer);\n if (this.$observer)\n this.$observer.disconnect();\n if (this.el && this.el.parentNode)\n this.el.parentNode.removeChild(this.el);\n };\n FontMetrics.prototype.$getZoom = function (element) {\n if (!element || !element.parentElement)\n return 1;\n return (Number(window.getComputedStyle(element)[\"zoom\"]) || 1) * this.$getZoom(element.parentElement);\n };\n FontMetrics.prototype.$initTransformMeasureNodes = function () {\n var t = function (t, l) {\n return [\"div\", {\n style: \"position: absolute;top:\" + t + \"px;left:\" + l + \"px;\"\n }];\n };\n this.els = dom.buildDom([t(0, 0), t(L, 0), t(0, L), t(L, L)], this.el);\n };\n FontMetrics.prototype.transformCoordinates = function (clientPos, elPos) {\n if (clientPos) {\n var zoom = this.$getZoom(this.el);\n clientPos = mul(1 / zoom, clientPos);\n }\n function solve(l1, l2, r) {\n var det = l1[1] * l2[0] - l1[0] * l2[1];\n return [\n (-l2[1] * r[0] + l2[0] * r[1]) / det,\n (+l1[1] * r[0] - l1[0] * r[1]) / det\n ];\n }\n function sub(a, b) { return [a[0] - b[0], a[1] - b[1]]; }\n function add(a, b) { return [a[0] + b[0], a[1] + b[1]]; }\n function mul(a, b) { return [a * b[0], a * b[1]]; }\n if (!this.els)\n this.$initTransformMeasureNodes();\n function p(el) {\n var r = el.getBoundingClientRect();\n return [r.left, r.top];\n }\n var a = p(this.els[0]);\n var b = p(this.els[1]);\n var c = p(this.els[2]);\n var d = p(this.els[3]);\n var h = solve(sub(d, b), sub(d, c), sub(add(b, c), add(d, a)));\n var m1 = mul(1 + h[0], sub(b, a));\n var m2 = mul(1 + h[1], sub(c, a));\n if (elPos) {\n var x = elPos;\n var k = h[0] * x[0] / L + h[1] * x[1] / L + 1;\n var ut = add(mul(x[0], m1), mul(x[1], m2));\n return add(mul(1 / k / L, ut), a);\n }\n var u = sub(clientPos, a);\n var f = solve(sub(m1, mul(h[0], u)), sub(m2, mul(h[1], u)), u);\n return mul(L, f);\n };\n return FontMetrics;\n}());\nFontMetrics.prototype.$characterSize = { width: 0, height: 0 };\noop.implement(FontMetrics.prototype, EventEmitter);\nexports.FontMetrics = FontMetrics;\n\n});\n\nace.define(\"ace/css/editor-css\",[\"require\",\"exports\",\"module\"], function(require, exports, module){/*\nstyles = []\nfor (var i = 1; i < 16; i++) {\n styles.push(\".ace_br\" + i + \"{\" + (\n [\"top-left\", \"top-right\", \"bottom-right\", \"bottom-left\"]\n ).map(function(x, j) {\n return i & (1< .ace_line, .ace_text-layer > .ace_line_group {\\n contain: style size layout;\\n position: absolute;\\n top: 0;\\n left: 0;\\n right: 0;\\n}\\n\\n.ace_hidpi .ace_text-layer,\\n.ace_hidpi .ace_gutter-layer,\\n.ace_hidpi .ace_content,\\n.ace_hidpi .ace_gutter {\\n contain: strict;\\n}\\n.ace_hidpi .ace_text-layer > .ace_line, \\n.ace_hidpi .ace_text-layer > .ace_line_group {\\n contain: strict;\\n}\\n\\n.ace_cjk {\\n display: inline-block;\\n text-align: center;\\n}\\n\\n.ace_cursor-layer {\\n z-index: 4;\\n}\\n\\n.ace_cursor {\\n z-index: 4;\\n position: absolute;\\n box-sizing: border-box;\\n border-left: 2px solid;\\n /* workaround for smooth cursor repaintng whole screen in chrome */\\n transform: translatez(0);\\n}\\n\\n.ace_multiselect .ace_cursor {\\n border-left-width: 1px;\\n}\\n\\n.ace_slim-cursors .ace_cursor {\\n border-left-width: 1px;\\n}\\n\\n.ace_overwrite-cursors .ace_cursor {\\n border-left-width: 0;\\n border-bottom: 1px solid;\\n}\\n\\n.ace_hidden-cursors .ace_cursor {\\n opacity: 0.2;\\n}\\n\\n.ace_hasPlaceholder .ace_hidden-cursors .ace_cursor {\\n opacity: 0;\\n}\\n\\n.ace_smooth-blinking .ace_cursor {\\n transition: opacity 0.18s;\\n}\\n\\n.ace_animate-blinking .ace_cursor {\\n animation-duration: 1000ms;\\n animation-timing-function: step-end;\\n animation-name: blink-ace-animate;\\n animation-iteration-count: infinite;\\n}\\n\\n.ace_animate-blinking.ace_smooth-blinking .ace_cursor {\\n animation-duration: 1000ms;\\n animation-timing-function: ease-in-out;\\n animation-name: blink-ace-animate-smooth;\\n}\\n \\n@keyframes blink-ace-animate {\\n from, to { opacity: 1; }\\n 60% { opacity: 0; }\\n}\\n\\n@keyframes blink-ace-animate-smooth {\\n from, to { opacity: 1; }\\n 45% { opacity: 1; }\\n 60% { opacity: 0; }\\n 85% { opacity: 0; }\\n}\\n\\n.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {\\n position: absolute;\\n z-index: 3;\\n}\\n\\n.ace_marker-layer .ace_selection {\\n position: absolute;\\n z-index: 5;\\n}\\n\\n.ace_marker-layer .ace_bracket {\\n position: absolute;\\n z-index: 6;\\n}\\n\\n.ace_marker-layer .ace_error_bracket {\\n position: absolute;\\n border-bottom: 1px solid #DE5555;\\n border-radius: 0;\\n}\\n\\n.ace_marker-layer .ace_active-line {\\n position: absolute;\\n z-index: 2;\\n}\\n\\n.ace_marker-layer .ace_selected-word {\\n position: absolute;\\n z-index: 4;\\n box-sizing: border-box;\\n}\\n\\n.ace_line .ace_fold {\\n box-sizing: border-box;\\n\\n display: inline-block;\\n height: 11px;\\n margin-top: -2px;\\n vertical-align: middle;\\n\\n background-image:\\n url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII=\\\"),\\n url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=\\\");\\n background-repeat: no-repeat, repeat-x;\\n background-position: center center, top left;\\n color: transparent;\\n\\n border: 1px solid black;\\n border-radius: 2px;\\n\\n cursor: pointer;\\n pointer-events: auto;\\n}\\n\\n.ace_dark .ace_fold {\\n}\\n\\n.ace_fold:hover{\\n background-image:\\n url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII=\\\"),\\n url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC\\\");\\n}\\n\\n.ace_tooltip {\\n background-color: #f5f5f5;\\n border: 1px solid gray;\\n border-radius: 1px;\\n box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);\\n color: black;\\n max-width: 100%;\\n padding: 3px 4px;\\n position: fixed;\\n z-index: 999999;\\n box-sizing: border-box;\\n cursor: default;\\n white-space: pre-wrap;\\n word-wrap: break-word;\\n line-height: normal;\\n font-style: normal;\\n font-weight: normal;\\n letter-spacing: normal;\\n pointer-events: none;\\n overflow: auto;\\n max-width: min(60em, 66vw);\\n overscroll-behavior: contain;\\n}\\n.ace_tooltip pre {\\n white-space: pre-wrap;\\n}\\n\\n.ace_tooltip.ace_dark {\\n background-color: #636363;\\n color: #fff;\\n}\\n\\n.ace_tooltip:focus {\\n outline: 1px solid #5E9ED6;\\n}\\n\\n.ace_icon {\\n display: inline-block;\\n width: 18px;\\n vertical-align: top;\\n}\\n\\n.ace_icon_svg {\\n display: inline-block;\\n width: 12px;\\n vertical-align: top;\\n -webkit-mask-repeat: no-repeat;\\n -webkit-mask-size: 12px;\\n -webkit-mask-position: center;\\n}\\n\\n.ace_folding-enabled > .ace_gutter-cell, .ace_folding-enabled > .ace_gutter-cell_svg-icons {\\n padding-right: 13px;\\n}\\n\\n.ace_fold-widget {\\n box-sizing: border-box;\\n\\n margin: 0 -12px 0 1px;\\n display: none;\\n width: 11px;\\n vertical-align: top;\\n\\n background-image: url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==\\\");\\n background-repeat: no-repeat;\\n background-position: center;\\n\\n border-radius: 3px;\\n \\n border: 1px solid transparent;\\n cursor: pointer;\\n}\\n\\n.ace_folding-enabled .ace_fold-widget {\\n display: inline-block; \\n}\\n\\n.ace_fold-widget.ace_end {\\n background-image: url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==\\\");\\n}\\n\\n.ace_fold-widget.ace_closed {\\n background-image: url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==\\\");\\n}\\n\\n.ace_fold-widget:hover {\\n border: 1px solid rgba(0, 0, 0, 0.3);\\n background-color: rgba(255, 255, 255, 0.2);\\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);\\n}\\n\\n.ace_fold-widget:active {\\n border: 1px solid rgba(0, 0, 0, 0.4);\\n background-color: rgba(0, 0, 0, 0.05);\\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);\\n}\\n/**\\n * Dark version for fold widgets\\n */\\n.ace_dark .ace_fold-widget {\\n background-image: url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC\\\");\\n}\\n.ace_dark .ace_fold-widget.ace_end {\\n background-image: url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==\\\");\\n}\\n.ace_dark .ace_fold-widget.ace_closed {\\n background-image: url(\\\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==\\\");\\n}\\n.ace_dark .ace_fold-widget:hover {\\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);\\n background-color: rgba(255, 255, 255, 0.1);\\n}\\n.ace_dark .ace_fold-widget:active {\\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);\\n}\\n\\n.ace_inline_button {\\n border: 1px solid lightgray;\\n display: inline-block;\\n margin: -1px 8px;\\n padding: 0 5px;\\n pointer-events: auto;\\n cursor: pointer;\\n}\\n.ace_inline_button:hover {\\n border-color: gray;\\n background: rgba(200,200,200,0.2);\\n display: inline-block;\\n pointer-events: auto;\\n}\\n\\n.ace_fold-widget.ace_invalid {\\n background-color: #FFB4B4;\\n border-color: #DE5555;\\n}\\n\\n.ace_fade-fold-widgets .ace_fold-widget {\\n transition: opacity 0.4s ease 0.05s;\\n opacity: 0;\\n}\\n\\n.ace_fade-fold-widgets:hover .ace_fold-widget {\\n transition: opacity 0.05s ease 0.05s;\\n opacity:1;\\n}\\n\\n.ace_underline {\\n text-decoration: underline;\\n}\\n\\n.ace_bold {\\n font-weight: bold;\\n}\\n\\n.ace_nobold .ace_bold {\\n font-weight: normal;\\n}\\n\\n.ace_italic {\\n font-style: italic;\\n}\\n\\n\\n.ace_error-marker {\\n background-color: rgba(255, 0, 0,0.2);\\n position: absolute;\\n z-index: 9;\\n}\\n\\n.ace_highlight-marker {\\n background-color: rgba(255, 255, 0,0.2);\\n position: absolute;\\n z-index: 8;\\n}\\n\\n.ace_mobile-menu {\\n position: absolute;\\n line-height: 1.5;\\n border-radius: 4px;\\n -ms-user-select: none;\\n -moz-user-select: none;\\n -webkit-user-select: none;\\n user-select: none;\\n background: white;\\n box-shadow: 1px 3px 2px grey;\\n border: 1px solid #dcdcdc;\\n color: black;\\n}\\n.ace_dark > .ace_mobile-menu {\\n background: #333;\\n color: #ccc;\\n box-shadow: 1px 3px 2px grey;\\n border: 1px solid #444;\\n\\n}\\n.ace_mobile-button {\\n padding: 2px;\\n cursor: pointer;\\n overflow: hidden;\\n}\\n.ace_mobile-button:hover {\\n background-color: #eee;\\n opacity:1;\\n}\\n.ace_mobile-button:active {\\n background-color: #ddd;\\n}\\n\\n.ace_placeholder {\\n position: relative;\\n font-family: arial;\\n transform: scale(0.9);\\n transform-origin: left;\\n white-space: pre;\\n opacity: 0.7;\\n margin: 0 10px;\\n z-index: 1;\\n}\\n\\n.ace_ghost_text {\\n opacity: 0.5;\\n font-style: italic;\\n}\\n\\n.ace_ghost_text_container > div {\\n white-space: pre;\\n}\\n\\n.ghost_text_line_wrapped::after {\\n content: \\\"\\u21A9\\\";\\n position: absolute;\\n}\\n\\n.ace_lineWidgetContainer.ace_ghost_text {\\n margin: 0px 4px\\n}\\n\\n.ace_screenreader-only {\\n position:absolute;\\n left:-10000px;\\n top:auto;\\n width:1px;\\n height:1px;\\n overflow:hidden;\\n}\\n\\n.ace_hidden_token {\\n display: none;\\n}\";\n\n});\n\nace.define(\"ace/layer/decorators\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\",\"ace/lib/oop\",\"ace/lib/event_emitter\"], function(require, exports, module){\"use strict\";\nvar dom = require(\"../lib/dom\");\nvar oop = require(\"../lib/oop\");\nvar EventEmitter = require(\"../lib/event_emitter\").EventEmitter;\nvar Decorator = /** @class */ (function () {\n function Decorator(parent, renderer) {\n this.canvas = dom.createElement(\"canvas\");\n this.renderer = renderer;\n this.pixelRatio = 1;\n this.maxHeight = renderer.layerConfig.maxHeight;\n this.lineHeight = renderer.layerConfig.lineHeight;\n this.canvasHeight = parent.parent.scrollHeight;\n this.heightRatio = this.canvasHeight / this.maxHeight;\n this.canvasWidth = parent.width;\n this.minDecorationHeight = (2 * this.pixelRatio) | 0;\n this.halfMinDecorationHeight = (this.minDecorationHeight / 2) | 0;\n this.canvas.width = this.canvasWidth;\n this.canvas.height = this.canvasHeight;\n this.canvas.style.top = 0 + \"px\";\n this.canvas.style.right = 0 + \"px\";\n this.canvas.style.zIndex = 7 + \"px\";\n this.canvas.style.position = \"absolute\";\n this.colors = {};\n this.colors.dark = {\n \"error\": \"rgba(255, 18, 18, 1)\",\n \"warning\": \"rgba(18, 136, 18, 1)\",\n \"info\": \"rgba(18, 18, 136, 1)\"\n };\n this.colors.light = {\n \"error\": \"rgb(255,51,51)\",\n \"warning\": \"rgb(32,133,72)\",\n \"info\": \"rgb(35,68,138)\"\n };\n parent.element.appendChild(this.canvas);\n }\n Decorator.prototype.$updateDecorators = function (config) {\n var colors = (this.renderer.theme.isDark === true) ? this.colors.dark : this.colors.light;\n if (config) {\n this.maxHeight = config.maxHeight;\n this.lineHeight = config.lineHeight;\n this.canvasHeight = config.height;\n var allLineHeight = (config.lastRow + 1) * this.lineHeight;\n if (allLineHeight < this.canvasHeight) {\n this.heightRatio = 1;\n }\n else {\n this.heightRatio = this.canvasHeight / this.maxHeight;\n }\n }\n var ctx = this.canvas.getContext(\"2d\");\n function compare(a, b) {\n if (a.priority < b.priority)\n return -1;\n if (a.priority > b.priority)\n return 1;\n return 0;\n }\n var annotations = this.renderer.session.$annotations;\n ctx.clearRect(0, 0, this.canvas.width, this.canvas.height);\n if (annotations) {\n var priorities = {\n \"info\": 1,\n \"warning\": 2,\n \"error\": 3\n };\n annotations.forEach(function (item) {\n item.priority = priorities[item.type] || null;\n });\n annotations = annotations.sort(compare);\n var foldData = this.renderer.session.$foldData;\n for (var i = 0; i < annotations.length; i++) {\n var row = annotations[i].row;\n var compensateFold = this.compensateFoldRows(row, foldData);\n var currentY = Math.round((row - compensateFold) * this.lineHeight * this.heightRatio);\n var y1 = Math.round(((row - compensateFold) * this.lineHeight * this.heightRatio));\n var y2 = Math.round((((row - compensateFold) * this.lineHeight + this.lineHeight) * this.heightRatio));\n var height = y2 - y1;\n if (height < this.minDecorationHeight) {\n var yCenter = ((y1 + y2) / 2) | 0;\n if (yCenter < this.halfMinDecorationHeight) {\n yCenter = this.halfMinDecorationHeight;\n }\n else if (yCenter + this.halfMinDecorationHeight > this.canvasHeight) {\n yCenter = this.canvasHeight - this.halfMinDecorationHeight;\n }\n y1 = Math.round(yCenter - this.halfMinDecorationHeight);\n y2 = Math.round(yCenter + this.halfMinDecorationHeight);\n }\n ctx.fillStyle = colors[annotations[i].type] || null;\n ctx.fillRect(0, currentY, this.canvasWidth, y2 - y1);\n }\n }\n var cursor = this.renderer.session.selection.getCursor();\n if (cursor) {\n var compensateFold = this.compensateFoldRows(cursor.row, foldData);\n var currentY = Math.round((cursor.row - compensateFold) * this.lineHeight * this.heightRatio);\n ctx.fillStyle = \"rgba(0, 0, 0, 0.5)\";\n ctx.fillRect(0, currentY, this.canvasWidth, 2);\n }\n };\n Decorator.prototype.compensateFoldRows = function (row, foldData) {\n var compensateFold = 0;\n if (foldData && foldData.length > 0) {\n for (var j = 0; j < foldData.length; j++) {\n if (row > foldData[j].start.row && row < foldData[j].end.row) {\n compensateFold += row - foldData[j].start.row;\n }\n else if (row >= foldData[j].end.row) {\n compensateFold += foldData[j].end.row - foldData[j].start.row;\n }\n }\n }\n return compensateFold;\n };\n return Decorator;\n}());\noop.implement(Decorator.prototype, EventEmitter);\nexports.Decorator = Decorator;\n\n});\n\nace.define(\"ace/virtual_renderer\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/dom\",\"ace/lib/lang\",\"ace/config\",\"ace/layer/gutter\",\"ace/layer/marker\",\"ace/layer/text\",\"ace/layer/cursor\",\"ace/scrollbar\",\"ace/scrollbar\",\"ace/scrollbar_custom\",\"ace/scrollbar_custom\",\"ace/renderloop\",\"ace/layer/font_metrics\",\"ace/lib/event_emitter\",\"ace/css/editor-css\",\"ace/layer/decorators\",\"ace/lib/useragent\",\"ace/layer/text_util\"], function(require, exports, module){\"use strict\";\nvar oop = require(\"./lib/oop\");\nvar dom = require(\"./lib/dom\");\nvar lang = require(\"./lib/lang\");\nvar config = require(\"./config\");\nvar GutterLayer = require(\"./layer/gutter\").Gutter;\nvar MarkerLayer = require(\"./layer/marker\").Marker;\nvar TextLayer = require(\"./layer/text\").Text;\nvar CursorLayer = require(\"./layer/cursor\").Cursor;\nvar HScrollBar = require(\"./scrollbar\").HScrollBar;\nvar VScrollBar = require(\"./scrollbar\").VScrollBar;\nvar HScrollBarCustom = require(\"./scrollbar_custom\").HScrollBar;\nvar VScrollBarCustom = require(\"./scrollbar_custom\").VScrollBar;\nvar RenderLoop = require(\"./renderloop\").RenderLoop;\nvar FontMetrics = require(\"./layer/font_metrics\").FontMetrics;\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar editorCss = require(\"./css/editor-css\");\nvar Decorator = require(\"./layer/decorators\").Decorator;\nvar useragent = require(\"./lib/useragent\");\nvar isTextToken = require(\"./layer/text_util\").isTextToken;\ndom.importCssString(editorCss, \"ace_editor.css\", false);\nvar VirtualRenderer = /** @class */ (function () {\n function VirtualRenderer(container, theme) {\n var _self = this;\n this.container = container || dom.createElement(\"div\");\n dom.addCssClass(this.container, \"ace_editor\");\n if (dom.HI_DPI)\n dom.addCssClass(this.container, \"ace_hidpi\");\n this.setTheme(theme);\n if (config.get(\"useStrictCSP\") == null)\n config.set(\"useStrictCSP\", false);\n this.$gutter = dom.createElement(\"div\");\n this.$gutter.className = \"ace_gutter\";\n this.container.appendChild(this.$gutter);\n this.$gutter.setAttribute(\"aria-hidden\", \"true\");\n this.scroller = dom.createElement(\"div\");\n this.scroller.className = \"ace_scroller\";\n this.container.appendChild(this.scroller);\n this.content = dom.createElement(\"div\");\n this.content.className = \"ace_content\";\n this.scroller.appendChild(this.content);\n this.$gutterLayer = new GutterLayer(this.$gutter);\n this.$gutterLayer.on(\"changeGutterWidth\", this.onGutterResize.bind(this));\n this.$markerBack = new MarkerLayer(this.content);\n var textLayer = this.$textLayer = new TextLayer(this.content);\n this.canvas = textLayer.element;\n this.$markerFront = new MarkerLayer(this.content);\n this.$cursorLayer = new CursorLayer(this.content);\n this.$horizScroll = false;\n this.$vScroll = false;\n this.scrollBar =\n this.scrollBarV = new VScrollBar(this.container, this);\n this.scrollBarH = new HScrollBar(this.container, this);\n this.scrollBarV.on(\"scroll\", function (e) {\n if (!_self.$scrollAnimation)\n _self.session.setScrollTop(e.data - _self.scrollMargin.top);\n });\n this.scrollBarH.on(\"scroll\", function (e) {\n if (!_self.$scrollAnimation)\n _self.session.setScrollLeft(e.data - _self.scrollMargin.left);\n });\n this.scrollTop = 0;\n this.scrollLeft = 0;\n this.cursorPos = {\n row: 0,\n column: 0\n };\n this.$fontMetrics = new FontMetrics(this.container);\n this.$textLayer.$setFontMetrics(this.$fontMetrics);\n this.$textLayer.on(\"changeCharacterSize\", function (e) {\n _self.updateCharacterSize();\n _self.onResize(true, _self.gutterWidth, _self.$size.width, _self.$size.height);\n _self._signal(\"changeCharacterSize\", e);\n });\n this.$size = {\n width: 0,\n height: 0,\n scrollerHeight: 0,\n scrollerWidth: 0,\n $dirty: true\n };\n this.layerConfig = {\n width: 1,\n padding: 0,\n firstRow: 0,\n firstRowScreen: 0,\n lastRow: 0,\n lineHeight: 0,\n characterWidth: 0,\n minHeight: 1,\n maxHeight: 1,\n offset: 0,\n height: 1,\n gutterOffset: 1\n };\n this.scrollMargin = {\n left: 0,\n right: 0,\n top: 0,\n bottom: 0,\n v: 0,\n h: 0\n };\n this.margin = {\n left: 0,\n right: 0,\n top: 0,\n bottom: 0,\n v: 0,\n h: 0\n };\n this.$keepTextAreaAtCursor = !useragent.isIOS;\n this.$loop = new RenderLoop(this.$renderChanges.bind(this), this.container.ownerDocument.defaultView);\n this.$loop.schedule(this.CHANGE_FULL);\n this.updateCharacterSize();\n this.setPadding(4);\n this.$addResizeObserver();\n config.resetOptions(this);\n config._signal(\"renderer\", this);\n }\n VirtualRenderer.prototype.updateCharacterSize = function () {\n if (this.$textLayer.allowBoldFonts != this.$allowBoldFonts) {\n this.$allowBoldFonts = this.$textLayer.allowBoldFonts;\n this.setStyle(\"ace_nobold\", !this.$allowBoldFonts);\n }\n this.layerConfig.characterWidth =\n this.characterWidth = this.$textLayer.getCharacterWidth();\n this.layerConfig.lineHeight =\n this.lineHeight = this.$textLayer.getLineHeight();\n this.$updatePrintMargin();\n dom.setStyle(this.scroller.style, \"line-height\", this.lineHeight + \"px\");\n };\n VirtualRenderer.prototype.setSession = function (session) {\n if (this.session)\n this.session.doc.off(\"changeNewLineMode\", this.onChangeNewLineMode);\n this.session = session;\n if (session && this.scrollMargin.top && session.getScrollTop() <= 0)\n session.setScrollTop(-this.scrollMargin.top);\n this.$cursorLayer.setSession(session);\n this.$markerBack.setSession(session);\n this.$markerFront.setSession(session);\n this.$gutterLayer.setSession(session);\n this.$textLayer.setSession(session);\n if (!session)\n return;\n this.$loop.schedule(this.CHANGE_FULL);\n this.session.$setFontMetrics(this.$fontMetrics);\n this.scrollBarH.scrollLeft = this.scrollBarV.scrollTop = null;\n this.onChangeNewLineMode = this.onChangeNewLineMode.bind(this);\n this.onChangeNewLineMode();\n this.session.doc.on(\"changeNewLineMode\", this.onChangeNewLineMode);\n };\n VirtualRenderer.prototype.updateLines = function (firstRow, lastRow, force) {\n if (lastRow === undefined)\n lastRow = Infinity;\n if (!this.$changedLines) {\n this.$changedLines = {\n firstRow: firstRow,\n lastRow: lastRow\n };\n }\n else {\n if (this.$changedLines.firstRow > firstRow)\n this.$changedLines.firstRow = firstRow;\n if (this.$changedLines.lastRow < lastRow)\n this.$changedLines.lastRow = lastRow;\n }\n if (this.$changedLines.lastRow < this.layerConfig.firstRow) {\n if (force)\n this.$changedLines.lastRow = this.layerConfig.lastRow;\n else\n return;\n }\n if (this.$changedLines.firstRow > this.layerConfig.lastRow)\n return;\n this.$loop.schedule(this.CHANGE_LINES);\n };\n VirtualRenderer.prototype.onChangeNewLineMode = function () {\n this.$loop.schedule(this.CHANGE_TEXT);\n this.$textLayer.$updateEolChar();\n this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR);\n };\n VirtualRenderer.prototype.onChangeTabSize = function () {\n this.$loop.schedule(this.CHANGE_TEXT | this.CHANGE_MARKER);\n this.$textLayer.onChangeTabSize();\n };\n VirtualRenderer.prototype.updateText = function () {\n this.$loop.schedule(this.CHANGE_TEXT);\n };\n VirtualRenderer.prototype.updateFull = function (force) {\n if (force)\n this.$renderChanges(this.CHANGE_FULL, true);\n else\n this.$loop.schedule(this.CHANGE_FULL);\n };\n VirtualRenderer.prototype.updateFontSize = function () {\n this.$textLayer.checkForSizeChanges();\n };\n VirtualRenderer.prototype.$updateSizeAsync = function () {\n if (this.$loop.pending)\n this.$size.$dirty = true;\n else\n this.onResize();\n };\n VirtualRenderer.prototype.onResize = function (force, gutterWidth, width, height) {\n if (this.resizing > 2)\n return;\n else if (this.resizing > 0)\n this.resizing++;\n else\n this.resizing = force ? 1 : 0;\n var el = this.container;\n if (!height)\n height = el.clientHeight || el.scrollHeight;\n if (!height && this.$maxLines && this.lineHeight > 1) {\n if (!el.style.height || el.style.height == \"0px\") {\n el.style.height = \"1px\";\n height = el.clientHeight || el.scrollHeight;\n }\n }\n if (!width)\n width = el.clientWidth || el.scrollWidth;\n var changes = this.$updateCachedSize(force, gutterWidth, width, height);\n if (this.$resizeTimer)\n this.$resizeTimer.cancel();\n if (!this.$size.scrollerHeight || (!width && !height))\n return this.resizing = 0;\n if (force)\n this.$gutterLayer.$padding = null;\n if (force)\n this.$renderChanges(changes | this.$changes, true);\n else\n this.$loop.schedule(changes | this.$changes);\n if (this.resizing)\n this.resizing = 0;\n this.scrollBarH.scrollLeft = this.scrollBarV.scrollTop = null;\n if (this.$customScrollbar) {\n this.$updateCustomScrollbar(true);\n }\n };\n VirtualRenderer.prototype.$updateCachedSize = function (force, gutterWidth, width, height) {\n height -= (this.$extraHeight || 0);\n var changes = 0;\n var size = this.$size;\n var oldSize = {\n width: size.width,\n height: size.height,\n scrollerHeight: size.scrollerHeight,\n scrollerWidth: size.scrollerWidth\n };\n if (height && (force || size.height != height)) {\n size.height = height;\n changes |= this.CHANGE_SIZE;\n size.scrollerHeight = size.height;\n if (this.$horizScroll)\n size.scrollerHeight -= this.scrollBarH.getHeight();\n this.scrollBarV.setHeight(size.scrollerHeight);\n this.scrollBarV.element.style.bottom = this.scrollBarH.getHeight() + \"px\";\n changes = changes | this.CHANGE_SCROLL;\n }\n if (width && (force || size.width != width)) {\n changes |= this.CHANGE_SIZE;\n size.width = width;\n if (gutterWidth == null)\n gutterWidth = this.$showGutter ? this.$gutter.offsetWidth : 0;\n this.gutterWidth = gutterWidth;\n dom.setStyle(this.scrollBarH.element.style, \"left\", gutterWidth + \"px\");\n dom.setStyle(this.scroller.style, \"left\", gutterWidth + this.margin.left + \"px\");\n size.scrollerWidth = Math.max(0, width - gutterWidth - this.scrollBarV.getWidth() - this.margin.h);\n dom.setStyle(this.$gutter.style, \"left\", this.margin.left + \"px\");\n var right = this.scrollBarV.getWidth() + \"px\";\n dom.setStyle(this.scrollBarH.element.style, \"right\", right);\n dom.setStyle(this.scroller.style, \"right\", right);\n dom.setStyle(this.scroller.style, \"bottom\", this.scrollBarH.getHeight());\n this.scrollBarH.setWidth(size.scrollerWidth);\n if (this.session && this.session.getUseWrapMode() && this.adjustWrapLimit() || force) {\n changes |= this.CHANGE_FULL;\n }\n }\n size.$dirty = !width || !height;\n if (changes)\n this._signal(\"resize\", oldSize);\n return changes;\n };\n VirtualRenderer.prototype.onGutterResize = function (width) {\n var gutterWidth = this.$showGutter ? width : 0;\n if (gutterWidth != this.gutterWidth)\n this.$changes |= this.$updateCachedSize(true, gutterWidth, this.$size.width, this.$size.height);\n if (this.session.getUseWrapMode() && this.adjustWrapLimit()) {\n this.$loop.schedule(this.CHANGE_FULL);\n }\n else if (this.$size.$dirty) {\n this.$loop.schedule(this.CHANGE_FULL);\n }\n else {\n this.$computeLayerConfig();\n }\n };\n VirtualRenderer.prototype.adjustWrapLimit = function () {\n var availableWidth = this.$size.scrollerWidth - this.$padding * 2;\n var limit = Math.floor(availableWidth / this.characterWidth);\n return this.session.adjustWrapLimit(limit, this.$showPrintMargin && this.$printMarginColumn);\n };\n VirtualRenderer.prototype.setAnimatedScroll = function (shouldAnimate) {\n this.setOption(\"animatedScroll\", shouldAnimate);\n };\n VirtualRenderer.prototype.getAnimatedScroll = function () {\n return this.$animatedScroll;\n };\n VirtualRenderer.prototype.setShowInvisibles = function (showInvisibles) {\n this.setOption(\"showInvisibles\", showInvisibles);\n this.session.$bidiHandler.setShowInvisibles(showInvisibles);\n };\n VirtualRenderer.prototype.getShowInvisibles = function () {\n return this.getOption(\"showInvisibles\");\n };\n VirtualRenderer.prototype.getDisplayIndentGuides = function () {\n return this.getOption(\"displayIndentGuides\");\n };\n VirtualRenderer.prototype.setDisplayIndentGuides = function (display) {\n this.setOption(\"displayIndentGuides\", display);\n };\n VirtualRenderer.prototype.getHighlightIndentGuides = function () {\n return this.getOption(\"highlightIndentGuides\");\n };\n VirtualRenderer.prototype.setHighlightIndentGuides = function (highlight) {\n this.setOption(\"highlightIndentGuides\", highlight);\n };\n VirtualRenderer.prototype.setShowPrintMargin = function (showPrintMargin) {\n this.setOption(\"showPrintMargin\", showPrintMargin);\n };\n VirtualRenderer.prototype.getShowPrintMargin = function () {\n return this.getOption(\"showPrintMargin\");\n };\n VirtualRenderer.prototype.setPrintMarginColumn = function (printMarginColumn) {\n this.setOption(\"printMarginColumn\", printMarginColumn);\n };\n VirtualRenderer.prototype.getPrintMarginColumn = function () {\n return this.getOption(\"printMarginColumn\");\n };\n VirtualRenderer.prototype.getShowGutter = function () {\n return this.getOption(\"showGutter\");\n };\n VirtualRenderer.prototype.setShowGutter = function (show) {\n return this.setOption(\"showGutter\", show);\n };\n VirtualRenderer.prototype.getFadeFoldWidgets = function () {\n return this.getOption(\"fadeFoldWidgets\");\n };\n VirtualRenderer.prototype.setFadeFoldWidgets = function (show) {\n this.setOption(\"fadeFoldWidgets\", show);\n };\n VirtualRenderer.prototype.setHighlightGutterLine = function (shouldHighlight) {\n this.setOption(\"highlightGutterLine\", shouldHighlight);\n };\n VirtualRenderer.prototype.getHighlightGutterLine = function () {\n return this.getOption(\"highlightGutterLine\");\n };\n VirtualRenderer.prototype.$updatePrintMargin = function () {\n if (!this.$showPrintMargin && !this.$printMarginEl)\n return;\n if (!this.$printMarginEl) {\n var containerEl = dom.createElement(\"div\");\n containerEl.className = \"ace_layer ace_print-margin-layer\";\n this.$printMarginEl = dom.createElement(\"div\");\n this.$printMarginEl.className = \"ace_print-margin\";\n containerEl.appendChild(this.$printMarginEl);\n this.content.insertBefore(containerEl, this.content.firstChild);\n }\n var style = this.$printMarginEl.style;\n style.left = Math.round(this.characterWidth * this.$printMarginColumn + this.$padding) + \"px\";\n style.visibility = this.$showPrintMargin ? \"visible\" : \"hidden\";\n if (this.session && this.session.$wrap == -1)\n this.adjustWrapLimit();\n };\n VirtualRenderer.prototype.getContainerElement = function () {\n return this.container;\n };\n VirtualRenderer.prototype.getMouseEventTarget = function () {\n return this.scroller;\n };\n VirtualRenderer.prototype.getTextAreaContainer = function () {\n return this.container;\n };\n VirtualRenderer.prototype.$moveTextAreaToCursor = function () {\n if (this.$isMousePressed)\n return;\n var style = this.textarea.style;\n var composition = this.$composition;\n if (!this.$keepTextAreaAtCursor && !composition) {\n dom.translate(this.textarea, -100, 0);\n return;\n }\n var pixelPos = this.$cursorLayer.$pixelPos;\n if (!pixelPos)\n return;\n if (composition && composition.markerRange)\n pixelPos = this.$cursorLayer.getPixelPosition(composition.markerRange.start, true);\n var config = this.layerConfig;\n var posTop = pixelPos.top;\n var posLeft = pixelPos.left;\n posTop -= config.offset;\n var h = composition && composition.useTextareaForIME || useragent.isMobile ? this.lineHeight : 1;\n if (posTop < 0 || posTop > config.height - h) {\n dom.translate(this.textarea, 0, 0);\n return;\n }\n var w = 1;\n var maxTop = this.$size.height - h;\n if (!composition) {\n posTop += this.lineHeight;\n }\n else {\n if (composition.useTextareaForIME) {\n var val = this.textarea.value;\n w = this.characterWidth * (this.session.$getStringScreenWidth(val)[0]);\n }\n else {\n posTop += this.lineHeight + 2;\n }\n }\n posLeft -= this.scrollLeft;\n if (posLeft > this.$size.scrollerWidth - w)\n posLeft = this.$size.scrollerWidth - w;\n posLeft += this.gutterWidth + this.margin.left;\n dom.setStyle(style, \"height\", h + \"px\");\n dom.setStyle(style, \"width\", w + \"px\");\n dom.translate(this.textarea, Math.min(posLeft, this.$size.scrollerWidth - w), Math.min(posTop, maxTop));\n };\n VirtualRenderer.prototype.getFirstVisibleRow = function () {\n return this.layerConfig.firstRow;\n };\n VirtualRenderer.prototype.getFirstFullyVisibleRow = function () {\n return this.layerConfig.firstRow + (this.layerConfig.offset === 0 ? 0 : 1);\n };\n VirtualRenderer.prototype.getLastFullyVisibleRow = function () {\n var config = this.layerConfig;\n var lastRow = config.lastRow;\n var top = this.session.documentToScreenRow(lastRow, 0) * config.lineHeight;\n if (top - this.session.getScrollTop() > config.height - config.lineHeight)\n return lastRow - 1;\n return lastRow;\n };\n VirtualRenderer.prototype.getLastVisibleRow = function () {\n return this.layerConfig.lastRow;\n };\n VirtualRenderer.prototype.setPadding = function (padding) {\n this.$padding = padding;\n this.$textLayer.setPadding(padding);\n this.$cursorLayer.setPadding(padding);\n this.$markerFront.setPadding(padding);\n this.$markerBack.setPadding(padding);\n this.$loop.schedule(this.CHANGE_FULL);\n this.$updatePrintMargin();\n };\n VirtualRenderer.prototype.setScrollMargin = function (top, bottom, left, right) {\n var sm = this.scrollMargin;\n sm.top = top | 0;\n sm.bottom = bottom | 0;\n sm.right = right | 0;\n sm.left = left | 0;\n sm.v = sm.top + sm.bottom;\n sm.h = sm.left + sm.right;\n if (sm.top && this.scrollTop <= 0 && this.session)\n this.session.setScrollTop(-sm.top);\n this.updateFull();\n };\n VirtualRenderer.prototype.setMargin = function (top, bottom, left, right) {\n var sm = this.margin;\n sm.top = top | 0;\n sm.bottom = bottom | 0;\n sm.right = right | 0;\n sm.left = left | 0;\n sm.v = sm.top + sm.bottom;\n sm.h = sm.left + sm.right;\n this.$updateCachedSize(true, this.gutterWidth, this.$size.width, this.$size.height);\n this.updateFull();\n };\n VirtualRenderer.prototype.getHScrollBarAlwaysVisible = function () {\n return this.$hScrollBarAlwaysVisible;\n };\n VirtualRenderer.prototype.setHScrollBarAlwaysVisible = function (alwaysVisible) {\n this.setOption(\"hScrollBarAlwaysVisible\", alwaysVisible);\n };\n VirtualRenderer.prototype.getVScrollBarAlwaysVisible = function () {\n return this.$vScrollBarAlwaysVisible;\n };\n VirtualRenderer.prototype.setVScrollBarAlwaysVisible = function (alwaysVisible) {\n this.setOption(\"vScrollBarAlwaysVisible\", alwaysVisible);\n };\n VirtualRenderer.prototype.$updateScrollBarV = function () {\n var scrollHeight = this.layerConfig.maxHeight;\n var scrollerHeight = this.$size.scrollerHeight;\n if (!this.$maxLines && this.$scrollPastEnd) {\n scrollHeight -= (scrollerHeight - this.lineHeight) * this.$scrollPastEnd;\n if (this.scrollTop > scrollHeight - scrollerHeight) {\n scrollHeight = this.scrollTop + scrollerHeight;\n this.scrollBarV.scrollTop = null;\n }\n }\n this.scrollBarV.setScrollHeight(scrollHeight + this.scrollMargin.v);\n this.scrollBarV.setScrollTop(this.scrollTop + this.scrollMargin.top);\n };\n VirtualRenderer.prototype.$updateScrollBarH = function () {\n this.scrollBarH.setScrollWidth(this.layerConfig.width + 2 * this.$padding + this.scrollMargin.h);\n this.scrollBarH.setScrollLeft(this.scrollLeft + this.scrollMargin.left);\n };\n VirtualRenderer.prototype.freeze = function () {\n this.$frozen = true;\n };\n VirtualRenderer.prototype.unfreeze = function () {\n this.$frozen = false;\n };\n VirtualRenderer.prototype.$renderChanges = function (changes, force) {\n if (this.$changes) {\n changes |= this.$changes;\n this.$changes = 0;\n }\n if ((!this.session || !this.container.offsetWidth || this.$frozen) || (!changes && !force)) {\n this.$changes |= changes;\n return;\n }\n if (this.$size.$dirty) {\n this.$changes |= changes;\n return this.onResize(true);\n }\n if (!this.lineHeight) {\n this.$textLayer.checkForSizeChanges();\n }\n this._signal(\"beforeRender\", changes);\n if (this.session && this.session.$bidiHandler)\n this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);\n var config = this.layerConfig;\n if (changes & this.CHANGE_FULL ||\n changes & this.CHANGE_SIZE ||\n changes & this.CHANGE_TEXT ||\n changes & this.CHANGE_LINES ||\n changes & this.CHANGE_SCROLL ||\n changes & this.CHANGE_H_SCROLL) {\n changes |= this.$computeLayerConfig() | this.$loop.clear();\n if (config.firstRow != this.layerConfig.firstRow && config.firstRowScreen == this.layerConfig.firstRowScreen) {\n var st = this.scrollTop + (config.firstRow - Math.max(this.layerConfig.firstRow, 0)) * this.lineHeight;\n if (st > 0) {\n this.scrollTop = st;\n changes = changes | this.CHANGE_SCROLL;\n changes |= this.$computeLayerConfig() | this.$loop.clear();\n }\n }\n config = this.layerConfig;\n this.$updateScrollBarV();\n if (changes & this.CHANGE_H_SCROLL)\n this.$updateScrollBarH();\n dom.translate(this.content, -this.scrollLeft, -config.offset);\n var width = config.width + 2 * this.$padding + \"px\";\n var height = config.minHeight + \"px\";\n dom.setStyle(this.content.style, \"width\", width);\n dom.setStyle(this.content.style, \"height\", height);\n }\n if (changes & this.CHANGE_H_SCROLL) {\n dom.translate(this.content, -this.scrollLeft, -config.offset);\n this.scroller.className = this.scrollLeft <= 0 ? \"ace_scroller \" : \"ace_scroller ace_scroll-left \";\n if (this.enableKeyboardAccessibility)\n this.scroller.className += this.keyboardFocusClassName;\n }\n if (changes & this.CHANGE_FULL) {\n this.$changedLines = null;\n this.$textLayer.update(config);\n if (this.$showGutter)\n this.$gutterLayer.update(config);\n if (this.$customScrollbar) {\n this.$scrollDecorator.$updateDecorators(config);\n }\n this.$markerBack.update(config);\n this.$markerFront.update(config);\n this.$cursorLayer.update(config);\n this.$moveTextAreaToCursor();\n this._signal(\"afterRender\", changes);\n return;\n }\n if (changes & this.CHANGE_SCROLL) {\n this.$changedLines = null;\n if (changes & this.CHANGE_TEXT || changes & this.CHANGE_LINES)\n this.$textLayer.update(config);\n else\n this.$textLayer.scrollLines(config);\n if (this.$showGutter) {\n if (changes & this.CHANGE_GUTTER || changes & this.CHANGE_LINES)\n this.$gutterLayer.update(config);\n else\n this.$gutterLayer.scrollLines(config);\n }\n if (this.$customScrollbar) {\n this.$scrollDecorator.$updateDecorators(config);\n }\n this.$markerBack.update(config);\n this.$markerFront.update(config);\n this.$cursorLayer.update(config);\n this.$moveTextAreaToCursor();\n this._signal(\"afterRender\", changes);\n return;\n }\n if (changes & this.CHANGE_TEXT) {\n this.$changedLines = null;\n this.$textLayer.update(config);\n if (this.$showGutter)\n this.$gutterLayer.update(config);\n if (this.$customScrollbar) {\n this.$scrollDecorator.$updateDecorators(config);\n }\n }\n else if (changes & this.CHANGE_LINES) {\n if (this.$updateLines() || (changes & this.CHANGE_GUTTER) && this.$showGutter)\n this.$gutterLayer.update(config);\n if (this.$customScrollbar) {\n this.$scrollDecorator.$updateDecorators(config);\n }\n }\n else if (changes & this.CHANGE_TEXT || changes & this.CHANGE_GUTTER) {\n if (this.$showGutter)\n this.$gutterLayer.update(config);\n if (this.$customScrollbar) {\n this.$scrollDecorator.$updateDecorators(config);\n }\n }\n else if (changes & this.CHANGE_CURSOR) {\n if (this.$highlightGutterLine)\n this.$gutterLayer.updateLineHighlight(config);\n if (this.$customScrollbar) {\n this.$scrollDecorator.$updateDecorators(config);\n }\n }\n if (changes & this.CHANGE_CURSOR) {\n this.$cursorLayer.update(config);\n this.$moveTextAreaToCursor();\n }\n if (changes & (this.CHANGE_MARKER | this.CHANGE_MARKER_FRONT)) {\n this.$markerFront.update(config);\n }\n if (changes & (this.CHANGE_MARKER | this.CHANGE_MARKER_BACK)) {\n this.$markerBack.update(config);\n }\n this._signal(\"afterRender\", changes);\n };\n VirtualRenderer.prototype.$autosize = function () {\n var height = this.session.getScreenLength() * this.lineHeight;\n var maxHeight = this.$maxLines * this.lineHeight;\n var desiredHeight = Math.min(maxHeight, Math.max((this.$minLines || 1) * this.lineHeight, height)) + this.scrollMargin.v + (this.$extraHeight || 0);\n if (this.$horizScroll)\n desiredHeight += this.scrollBarH.getHeight();\n if (this.$maxPixelHeight && desiredHeight > this.$maxPixelHeight)\n desiredHeight = this.$maxPixelHeight;\n var hideScrollbars = desiredHeight <= 2 * this.lineHeight;\n var vScroll = !hideScrollbars && height > maxHeight;\n if (desiredHeight != this.desiredHeight ||\n this.$size.height != this.desiredHeight || vScroll != this.$vScroll) {\n if (vScroll != this.$vScroll) {\n this.$vScroll = vScroll;\n this.scrollBarV.setVisible(vScroll);\n }\n var w = this.container.clientWidth;\n this.container.style.height = desiredHeight + \"px\";\n this.$updateCachedSize(true, this.$gutterWidth, w, desiredHeight);\n this.desiredHeight = desiredHeight;\n this._signal(\"autosize\");\n }\n };\n VirtualRenderer.prototype.$computeLayerConfig = function () {\n var session = this.session;\n var size = this.$size;\n var hideScrollbars = size.height <= 2 * this.lineHeight;\n var screenLines = this.session.getScreenLength();\n var maxHeight = screenLines * this.lineHeight;\n var longestLine = this.$getLongestLine();\n var horizScroll = !hideScrollbars && (this.$hScrollBarAlwaysVisible ||\n size.scrollerWidth - longestLine - 2 * this.$padding < 0);\n var hScrollChanged = this.$horizScroll !== horizScroll;\n if (hScrollChanged) {\n this.$horizScroll = horizScroll;\n this.scrollBarH.setVisible(horizScroll);\n }\n var vScrollBefore = this.$vScroll; // autosize can change vscroll value in which case we need to update longestLine\n if (this.$maxLines && this.lineHeight > 1)\n this.$autosize();\n var minHeight = size.scrollerHeight + this.lineHeight;\n var scrollPastEnd = !this.$maxLines && this.$scrollPastEnd\n ? (size.scrollerHeight - this.lineHeight) * this.$scrollPastEnd\n : 0;\n maxHeight += scrollPastEnd;\n var sm = this.scrollMargin;\n this.session.setScrollTop(Math.max(-sm.top, Math.min(this.scrollTop, maxHeight - size.scrollerHeight + sm.bottom)));\n this.session.setScrollLeft(Math.max(-sm.left, Math.min(this.scrollLeft, longestLine + 2 * this.$padding - size.scrollerWidth + sm.right)));\n var vScroll = !hideScrollbars && (this.$vScrollBarAlwaysVisible ||\n size.scrollerHeight - maxHeight + scrollPastEnd < 0 || this.scrollTop > sm.top);\n var vScrollChanged = vScrollBefore !== vScroll;\n if (vScrollChanged) {\n this.$vScroll = vScroll;\n this.scrollBarV.setVisible(vScroll);\n }\n var offset = this.scrollTop % this.lineHeight;\n var lineCount = Math.ceil(minHeight / this.lineHeight) - 1;\n var firstRow = Math.max(0, Math.round((this.scrollTop - offset) / this.lineHeight));\n var lastRow = firstRow + lineCount;\n var firstRowScreen, firstRowHeight;\n var lineHeight = this.lineHeight;\n firstRow = session.screenToDocumentRow(firstRow, 0);\n var foldLine = session.getFoldLine(firstRow);\n if (foldLine) {\n firstRow = foldLine.start.row;\n }\n firstRowScreen = session.documentToScreenRow(firstRow, 0);\n firstRowHeight = session.getRowLength(firstRow) * lineHeight;\n lastRow = Math.min(session.screenToDocumentRow(lastRow, 0), session.getLength() - 1);\n minHeight = size.scrollerHeight + session.getRowLength(lastRow) * lineHeight +\n firstRowHeight;\n offset = this.scrollTop - firstRowScreen * lineHeight;\n var changes = 0;\n if (this.layerConfig.width != longestLine || hScrollChanged)\n changes = this.CHANGE_H_SCROLL;\n if (hScrollChanged || vScrollChanged) {\n changes |= this.$updateCachedSize(true, this.gutterWidth, size.width, size.height);\n this._signal(\"scrollbarVisibilityChanged\");\n if (vScrollChanged)\n longestLine = this.$getLongestLine();\n }\n this.layerConfig = {\n width: longestLine,\n padding: this.$padding,\n firstRow: firstRow,\n firstRowScreen: firstRowScreen,\n lastRow: lastRow,\n lineHeight: lineHeight,\n characterWidth: this.characterWidth,\n minHeight: minHeight,\n maxHeight: maxHeight,\n offset: offset,\n gutterOffset: lineHeight ? Math.max(0, Math.ceil((offset + size.height - size.scrollerHeight) / lineHeight)) : 0,\n height: this.$size.scrollerHeight\n };\n if (this.session.$bidiHandler)\n this.session.$bidiHandler.setContentWidth(longestLine - this.$padding);\n return changes;\n };\n VirtualRenderer.prototype.$updateLines = function () {\n if (!this.$changedLines)\n return;\n var firstRow = this.$changedLines.firstRow;\n var lastRow = this.$changedLines.lastRow;\n this.$changedLines = null;\n var layerConfig = this.layerConfig;\n if (firstRow > layerConfig.lastRow + 1) {\n return;\n }\n if (lastRow < layerConfig.firstRow) {\n return;\n }\n if (lastRow === Infinity) {\n if (this.$showGutter)\n this.$gutterLayer.update(layerConfig);\n this.$textLayer.update(layerConfig);\n return;\n }\n this.$textLayer.updateLines(layerConfig, firstRow, lastRow);\n return true;\n };\n VirtualRenderer.prototype.$getLongestLine = function () {\n var charCount = this.session.getScreenWidth();\n if (this.showInvisibles && !this.session.$useWrapMode)\n charCount += 1;\n if (this.$textLayer && charCount > this.$textLayer.MAX_LINE_LENGTH)\n charCount = this.$textLayer.MAX_LINE_LENGTH + 30;\n return Math.max(this.$size.scrollerWidth - 2 * this.$padding, Math.round(charCount * this.characterWidth));\n };\n VirtualRenderer.prototype.updateFrontMarkers = function () {\n this.$markerFront.setMarkers(this.session.getMarkers(true));\n this.$loop.schedule(this.CHANGE_MARKER_FRONT);\n };\n VirtualRenderer.prototype.updateBackMarkers = function () {\n this.$markerBack.setMarkers(this.session.getMarkers());\n this.$loop.schedule(this.CHANGE_MARKER_BACK);\n };\n VirtualRenderer.prototype.addGutterDecoration = function (row, className) {\n this.$gutterLayer.addGutterDecoration(row, className);\n };\n VirtualRenderer.prototype.removeGutterDecoration = function (row, className) {\n this.$gutterLayer.removeGutterDecoration(row, className);\n };\n VirtualRenderer.prototype.updateBreakpoints = function (rows) {\n this._rows = rows;\n this.$loop.schedule(this.CHANGE_GUTTER);\n };\n VirtualRenderer.prototype.setAnnotations = function (annotations) {\n this.$gutterLayer.setAnnotations(annotations);\n this.$loop.schedule(this.CHANGE_GUTTER);\n };\n VirtualRenderer.prototype.updateCursor = function () {\n this.$loop.schedule(this.CHANGE_CURSOR);\n };\n VirtualRenderer.prototype.hideCursor = function () {\n this.$cursorLayer.hideCursor();\n };\n VirtualRenderer.prototype.showCursor = function () {\n this.$cursorLayer.showCursor();\n };\n VirtualRenderer.prototype.scrollSelectionIntoView = function (anchor, lead, offset) {\n this.scrollCursorIntoView(anchor, offset);\n this.scrollCursorIntoView(lead, offset);\n };\n VirtualRenderer.prototype.scrollCursorIntoView = function (cursor, offset, $viewMargin) {\n if (this.$size.scrollerHeight === 0)\n return;\n var pos = this.$cursorLayer.getPixelPosition(cursor);\n var newLeft = pos.left;\n var newTop = pos.top;\n var topMargin = $viewMargin && $viewMargin.top || 0;\n var bottomMargin = $viewMargin && $viewMargin.bottom || 0;\n if (this.$scrollAnimation) {\n this.$stopAnimation = true;\n }\n var currentTop = this.$scrollAnimation ? this.session.getScrollTop() : this.scrollTop;\n if (currentTop + topMargin > newTop) {\n if (offset && currentTop + topMargin > newTop + this.lineHeight)\n newTop -= offset * this.$size.scrollerHeight;\n if (newTop === 0)\n newTop = -this.scrollMargin.top;\n this.session.setScrollTop(newTop);\n }\n else if (currentTop + this.$size.scrollerHeight - bottomMargin < newTop + this.lineHeight) {\n if (offset && currentTop + this.$size.scrollerHeight - bottomMargin < newTop - this.lineHeight)\n newTop += offset * this.$size.scrollerHeight;\n this.session.setScrollTop(newTop + this.lineHeight + bottomMargin - this.$size.scrollerHeight);\n }\n var currentLeft = this.scrollLeft;\n var twoCharsWidth = 2 * this.layerConfig.characterWidth;\n if (newLeft - twoCharsWidth < currentLeft) {\n newLeft -= twoCharsWidth;\n if (newLeft < this.$padding + twoCharsWidth) {\n newLeft = -this.scrollMargin.left;\n }\n this.session.setScrollLeft(newLeft);\n }\n else {\n newLeft += twoCharsWidth;\n if (currentLeft + this.$size.scrollerWidth < newLeft + this.characterWidth) {\n this.session.setScrollLeft(Math.round(newLeft + this.characterWidth - this.$size.scrollerWidth));\n }\n else if (currentLeft <= this.$padding && newLeft - currentLeft < this.characterWidth) {\n this.session.setScrollLeft(0);\n }\n }\n };\n VirtualRenderer.prototype.getScrollTop = function () {\n return this.session.getScrollTop();\n };\n VirtualRenderer.prototype.getScrollLeft = function () {\n return this.session.getScrollLeft();\n };\n VirtualRenderer.prototype.getScrollTopRow = function () {\n return this.scrollTop / this.lineHeight;\n };\n VirtualRenderer.prototype.getScrollBottomRow = function () {\n return Math.max(0, Math.floor((this.scrollTop + this.$size.scrollerHeight) / this.lineHeight) - 1);\n };\n VirtualRenderer.prototype.scrollToRow = function (row) {\n this.session.setScrollTop(row * this.lineHeight);\n };\n VirtualRenderer.prototype.alignCursor = function (cursor, alignment) {\n if (typeof cursor == \"number\")\n cursor = { row: cursor, column: 0 };\n var pos = this.$cursorLayer.getPixelPosition(cursor);\n var h = this.$size.scrollerHeight - this.lineHeight;\n var offset = pos.top - h * (alignment || 0);\n this.session.setScrollTop(offset);\n return offset;\n };\n VirtualRenderer.prototype.$calcSteps = function (fromValue, toValue) {\n var i = 0;\n var l = this.STEPS;\n var steps = [];\n var func = function (t, x_min, dx) {\n return dx * (Math.pow(t - 1, 3) + 1) + x_min;\n };\n for (i = 0; i < l; ++i)\n steps.push(func(i / this.STEPS, fromValue, toValue - fromValue));\n return steps;\n };\n VirtualRenderer.prototype.scrollToLine = function (line, center, animate, callback) {\n var pos = this.$cursorLayer.getPixelPosition({ row: line, column: 0 });\n var offset = pos.top;\n if (center)\n offset -= this.$size.scrollerHeight / 2;\n var initialScroll = this.scrollTop;\n this.session.setScrollTop(offset);\n if (animate !== false)\n this.animateScrolling(initialScroll, callback);\n };\n VirtualRenderer.prototype.animateScrolling = function (fromValue, callback) {\n var toValue = this.scrollTop;\n if (!this.$animatedScroll)\n return;\n var _self = this;\n if (fromValue == toValue)\n return;\n if (this.$scrollAnimation) {\n var oldSteps = this.$scrollAnimation.steps;\n if (oldSteps.length) {\n fromValue = oldSteps[0];\n if (fromValue == toValue)\n return;\n }\n }\n var steps = _self.$calcSteps(fromValue, toValue);\n this.$scrollAnimation = { from: fromValue, to: toValue, steps: steps };\n clearInterval(this.$timer);\n _self.session.setScrollTop(steps.shift());\n _self.session.$scrollTop = toValue;\n function endAnimation() {\n _self.$timer = clearInterval(_self.$timer);\n _self.$scrollAnimation = null;\n _self.$stopAnimation = false;\n callback && callback();\n }\n this.$timer = setInterval(function () {\n if (_self.$stopAnimation) {\n endAnimation();\n return;\n }\n if (!_self.session)\n return clearInterval(_self.$timer);\n if (steps.length) {\n _self.session.setScrollTop(steps.shift());\n _self.session.$scrollTop = toValue;\n }\n else if (toValue != null) {\n _self.session.$scrollTop = -1;\n _self.session.setScrollTop(toValue);\n toValue = null;\n }\n else {\n endAnimation();\n }\n }, 10);\n };\n VirtualRenderer.prototype.scrollToY = function (scrollTop) {\n if (this.scrollTop !== scrollTop) {\n this.$loop.schedule(this.CHANGE_SCROLL);\n this.scrollTop = scrollTop;\n }\n };\n VirtualRenderer.prototype.scrollToX = function (scrollLeft) {\n if (this.scrollLeft !== scrollLeft)\n this.scrollLeft = scrollLeft;\n this.$loop.schedule(this.CHANGE_H_SCROLL);\n };\n VirtualRenderer.prototype.scrollTo = function (x, y) {\n this.session.setScrollTop(y);\n this.session.setScrollLeft(x);\n };\n VirtualRenderer.prototype.scrollBy = function (deltaX, deltaY) {\n deltaY && this.session.setScrollTop(this.session.getScrollTop() + deltaY);\n deltaX && this.session.setScrollLeft(this.session.getScrollLeft() + deltaX);\n };\n VirtualRenderer.prototype.isScrollableBy = function (deltaX, deltaY) {\n if (deltaY < 0 && this.session.getScrollTop() >= 1 - this.scrollMargin.top)\n return true;\n if (deltaY > 0 && this.session.getScrollTop() + this.$size.scrollerHeight\n - this.layerConfig.maxHeight < -1 + this.scrollMargin.bottom)\n return true;\n if (deltaX < 0 && this.session.getScrollLeft() >= 1 - this.scrollMargin.left)\n return true;\n if (deltaX > 0 && this.session.getScrollLeft() + this.$size.scrollerWidth\n - this.layerConfig.width < -1 + this.scrollMargin.right)\n return true;\n };\n VirtualRenderer.prototype.pixelToScreenCoordinates = function (x, y) {\n var canvasPos;\n if (this.$hasCssTransforms) {\n canvasPos = { top: 0, left: 0 };\n var p = this.$fontMetrics.transformCoordinates([x, y]);\n x = p[1] - this.gutterWidth - this.margin.left;\n y = p[0];\n }\n else {\n canvasPos = this.scroller.getBoundingClientRect();\n }\n var offsetX = x + this.scrollLeft - canvasPos.left - this.$padding;\n var offset = offsetX / this.characterWidth;\n var row = Math.floor((y + this.scrollTop - canvasPos.top) / this.lineHeight);\n var col = this.$blockCursor ? Math.floor(offset) : Math.round(offset);\n return { row: row, column: col, side: offset - col > 0 ? 1 : -1, offsetX: offsetX };\n };\n VirtualRenderer.prototype.screenToTextCoordinates = function (x, y) {\n var canvasPos;\n if (this.$hasCssTransforms) {\n canvasPos = { top: 0, left: 0 };\n var p = this.$fontMetrics.transformCoordinates([x, y]);\n x = p[1] - this.gutterWidth - this.margin.left;\n y = p[0];\n }\n else {\n canvasPos = this.scroller.getBoundingClientRect();\n }\n var offsetX = x + this.scrollLeft - canvasPos.left - this.$padding;\n var offset = offsetX / this.characterWidth;\n var col = this.$blockCursor ? Math.floor(offset) : Math.round(offset);\n var row = Math.floor((y + this.scrollTop - canvasPos.top) / this.lineHeight);\n return this.session.screenToDocumentPosition(row, Math.max(col, 0), offsetX);\n };\n VirtualRenderer.prototype.textToScreenCoordinates = function (row, column) {\n var canvasPos = this.scroller.getBoundingClientRect();\n var pos = this.session.documentToScreenPosition(row, column);\n var x = this.$padding + (this.session.$bidiHandler.isBidiRow(pos.row, row)\n ? this.session.$bidiHandler.getPosLeft(pos.column)\n : Math.round(pos.column * this.characterWidth));\n var y = pos.row * this.lineHeight;\n return {\n pageX: canvasPos.left + x - this.scrollLeft,\n pageY: canvasPos.top + y - this.scrollTop\n };\n };\n VirtualRenderer.prototype.visualizeFocus = function () {\n dom.addCssClass(this.container, \"ace_focus\");\n };\n VirtualRenderer.prototype.visualizeBlur = function () {\n dom.removeCssClass(this.container, \"ace_focus\");\n };\n VirtualRenderer.prototype.showComposition = function (composition) {\n this.$composition = composition;\n if (!composition.cssText) {\n composition.cssText = this.textarea.style.cssText;\n }\n if (composition.useTextareaForIME == undefined)\n composition.useTextareaForIME = this.$useTextareaForIME;\n if (this.$useTextareaForIME) {\n dom.addCssClass(this.textarea, \"ace_composition\");\n this.textarea.style.cssText = \"\";\n this.$moveTextAreaToCursor();\n this.$cursorLayer.element.style.display = \"none\";\n }\n else {\n composition.markerId = this.session.addMarker(composition.markerRange, \"ace_composition_marker\", \"text\");\n }\n };\n VirtualRenderer.prototype.setCompositionText = function (text) {\n var cursor = this.session.selection.cursor;\n this.addToken(text, \"composition_placeholder\", cursor.row, cursor.column);\n this.$moveTextAreaToCursor();\n };\n VirtualRenderer.prototype.hideComposition = function () {\n if (!this.$composition)\n return;\n if (this.$composition.markerId)\n this.session.removeMarker(this.$composition.markerId);\n dom.removeCssClass(this.textarea, \"ace_composition\");\n this.textarea.style.cssText = this.$composition.cssText;\n var cursor = this.session.selection.cursor;\n this.removeExtraToken(cursor.row, cursor.column);\n this.$composition = null;\n this.$cursorLayer.element.style.display = \"\";\n };\n VirtualRenderer.prototype.setGhostText = function (text, position) {\n var cursor = this.session.selection.cursor;\n var insertPosition = position || { row: cursor.row, column: cursor.column };\n this.removeGhostText();\n var textChunks = this.$calculateWrappedTextChunks(text, insertPosition);\n this.addToken(textChunks[0].text, \"ghost_text\", insertPosition.row, insertPosition.column);\n this.$ghostText = {\n text: text,\n position: {\n row: insertPosition.row,\n column: insertPosition.column\n }\n };\n var widgetDiv = dom.createElement(\"div\");\n if (textChunks.length > 1) {\n var hiddenTokens = this.hideTokensAfterPosition(insertPosition.row, insertPosition.column);\n var lastLineDiv;\n textChunks.slice(1).forEach(function (el) {\n var chunkDiv = dom.createElement(\"div\");\n var chunkSpan = dom.createElement(\"span\");\n chunkSpan.className = \"ace_ghost_text\";\n if (el.wrapped)\n chunkDiv.className = \"ghost_text_line_wrapped\";\n if (el.text.length === 0)\n el.text = \" \";\n chunkSpan.appendChild(dom.createTextNode(el.text));\n chunkDiv.appendChild(chunkSpan);\n widgetDiv.appendChild(chunkDiv);\n lastLineDiv = chunkDiv;\n });\n hiddenTokens.forEach(function (token) {\n var element = dom.createElement(\"span\");\n if (!isTextToken(token.type))\n element.className = \"ace_\" + token.type.replace(/\\./g, \" ace_\");\n element.appendChild(dom.createTextNode(token.value));\n lastLineDiv.appendChild(element);\n });\n this.$ghostTextWidget = {\n el: widgetDiv,\n row: insertPosition.row,\n column: insertPosition.column,\n className: \"ace_ghost_text_container\"\n };\n this.session.widgetManager.addLineWidget(this.$ghostTextWidget);\n var pixelPosition = this.$cursorLayer.getPixelPosition(insertPosition, true);\n var el = this.container;\n var height = el.getBoundingClientRect().height;\n var ghostTextHeight = textChunks.length * this.lineHeight;\n var fitsY = ghostTextHeight < (height - pixelPosition.top);\n if (fitsY)\n return;\n if (ghostTextHeight < height) {\n this.scrollBy(0, (textChunks.length - 1) * this.lineHeight);\n }\n else {\n this.scrollToRow(insertPosition.row);\n }\n }\n };\n VirtualRenderer.prototype.$calculateWrappedTextChunks = function (text, position) {\n var availableWidth = this.$size.scrollerWidth - this.$padding * 2;\n var limit = Math.floor(availableWidth / this.characterWidth) - 2;\n limit = limit <= 0 ? 60 : limit; // this is a hack to prevent the editor from crashing when the window is too small\n var textLines = text.split(/\\r?\\n/);\n var textChunks = [];\n for (var i = 0; i < textLines.length; i++) {\n var displayTokens = this.session.$getDisplayTokens(textLines[i], position.column);\n var wrapSplits = this.session.$computeWrapSplits(displayTokens, limit, this.session.$tabSize);\n if (wrapSplits.length > 0) {\n var start = 0;\n wrapSplits.push(textLines[i].length);\n for (var j = 0; j < wrapSplits.length; j++) {\n var textSlice = textLines[i].slice(start, wrapSplits[j]);\n textChunks.push({ text: textSlice, wrapped: true });\n start = wrapSplits[j];\n }\n }\n else {\n textChunks.push({ text: textLines[i], wrapped: false });\n }\n }\n return textChunks;\n };\n VirtualRenderer.prototype.removeGhostText = function () {\n if (!this.$ghostText)\n return;\n var position = this.$ghostText.position;\n this.removeExtraToken(position.row, position.column);\n if (this.$ghostTextWidget) {\n this.session.widgetManager.removeLineWidget(this.$ghostTextWidget);\n this.$ghostTextWidget = null;\n }\n this.$ghostText = null;\n };\n VirtualRenderer.prototype.addToken = function (text, type, row, column) {\n var session = this.session;\n session.bgTokenizer.lines[row] = null;\n var newToken = { type: type, value: text };\n var tokens = session.getTokens(row);\n if (column == null || !tokens.length) {\n tokens.push(newToken);\n }\n else {\n var l = 0;\n for (var i = 0; i < tokens.length; i++) {\n var token = tokens[i];\n l += token.value.length;\n if (column <= l) {\n var diff = token.value.length - (l - column);\n var before = token.value.slice(0, diff);\n var after = token.value.slice(diff);\n tokens.splice(i, 1, { type: token.type, value: before }, newToken, { type: token.type, value: after });\n break;\n }\n }\n }\n this.updateLines(row, row);\n };\n VirtualRenderer.prototype.hideTokensAfterPosition = function (row, column) {\n var tokens = this.session.getTokens(row);\n var l = 0;\n var hasPassedCursor = false;\n var hiddenTokens = [];\n for (var i = 0; i < tokens.length; i++) {\n var token = tokens[i];\n l += token.value.length;\n if (token.type === \"ghost_text\")\n continue;\n if (hasPassedCursor) {\n hiddenTokens.push({ type: token.type, value: token.value });\n token.type = \"hidden_token\";\n continue;\n }\n if (l === column) {\n hasPassedCursor = true;\n }\n }\n this.updateLines(row, row);\n return hiddenTokens;\n };\n VirtualRenderer.prototype.removeExtraToken = function (row, column) {\n this.session.bgTokenizer.lines[row] = null;\n this.updateLines(row, row);\n };\n VirtualRenderer.prototype.setTheme = function (theme, cb) {\n var _self = this;\n this.$themeId = theme;\n _self._dispatchEvent('themeChange', { theme: theme });\n if (!theme || typeof theme == \"string\") {\n var moduleName = theme || this.$options.theme.initialValue;\n config.loadModule([\"theme\", moduleName], afterLoad);\n }\n else {\n afterLoad(theme);\n }\n function afterLoad(module) {\n if (_self.$themeId != theme)\n return cb && cb();\n if (!module || !module.cssClass)\n throw new Error(\"couldn't load module \" + theme + \" or it didn't call define\");\n if (module.$id)\n _self.$themeId = module.$id;\n dom.importCssString(module.cssText, module.cssClass, _self.container);\n if (_self.theme)\n dom.removeCssClass(_self.container, _self.theme.cssClass);\n var padding = \"padding\" in module ? module.padding\n : \"padding\" in (_self.theme || {}) ? 4 : _self.$padding;\n if (_self.$padding && padding != _self.$padding)\n _self.setPadding(padding);\n _self.$theme = module.cssClass;\n _self.theme = module;\n dom.addCssClass(_self.container, module.cssClass);\n dom.setCssClass(_self.container, \"ace_dark\", module.isDark);\n if (_self.$size) {\n _self.$size.width = 0;\n _self.$updateSizeAsync();\n }\n _self._dispatchEvent('themeLoaded', { theme: module });\n cb && cb();\n if (useragent.isSafari && _self.scroller) {\n _self.scroller.style.background = \"red\";\n _self.scroller.style.background = \"\";\n }\n }\n };\n VirtualRenderer.prototype.getTheme = function () {\n return this.$themeId;\n };\n VirtualRenderer.prototype.setStyle = function (style, include) {\n dom.setCssClass(this.container, style, include !== false);\n };\n VirtualRenderer.prototype.unsetStyle = function (style) {\n dom.removeCssClass(this.container, style);\n };\n VirtualRenderer.prototype.setCursorStyle = function (style) {\n dom.setStyle(this.scroller.style, \"cursor\", style);\n };\n VirtualRenderer.prototype.setMouseCursor = function (cursorStyle) {\n dom.setStyle(this.scroller.style, \"cursor\", cursorStyle);\n };\n VirtualRenderer.prototype.attachToShadowRoot = function () {\n dom.importCssString(editorCss, \"ace_editor.css\", this.container);\n };\n VirtualRenderer.prototype.destroy = function () {\n this.freeze();\n this.$fontMetrics.destroy();\n this.$cursorLayer.destroy();\n this.removeAllListeners();\n this.container.textContent = \"\";\n this.setOption(\"useResizeObserver\", false);\n };\n VirtualRenderer.prototype.$updateCustomScrollbar = function (val) {\n var _self = this;\n this.$horizScroll = this.$vScroll = null;\n this.scrollBarV.element.remove();\n this.scrollBarH.element.remove();\n if (this.$scrollDecorator) {\n delete this.$scrollDecorator;\n }\n if (val === true) {\n this.scrollBarV = new VScrollBarCustom(this.container, this);\n this.scrollBarH = new HScrollBarCustom(this.container, this);\n this.scrollBarV.setHeight(this.$size.scrollerHeight);\n this.scrollBarH.setWidth(this.$size.scrollerWidth);\n this.scrollBarV.addEventListener(\"scroll\", function (e) {\n if (!_self.$scrollAnimation)\n _self.session.setScrollTop(e.data - _self.scrollMargin.top);\n });\n this.scrollBarH.addEventListener(\"scroll\", function (e) {\n if (!_self.$scrollAnimation)\n _self.session.setScrollLeft(e.data - _self.scrollMargin.left);\n });\n this.$scrollDecorator = new Decorator(this.scrollBarV, this);\n this.$scrollDecorator.$updateDecorators();\n }\n else {\n this.scrollBarV = new VScrollBar(this.container, this);\n this.scrollBarH = new HScrollBar(this.container, this);\n this.scrollBarV.addEventListener(\"scroll\", function (e) {\n if (!_self.$scrollAnimation)\n _self.session.setScrollTop(e.data - _self.scrollMargin.top);\n });\n this.scrollBarH.addEventListener(\"scroll\", function (e) {\n if (!_self.$scrollAnimation)\n _self.session.setScrollLeft(e.data - _self.scrollMargin.left);\n });\n }\n };\n VirtualRenderer.prototype.$addResizeObserver = function () {\n if (!window.ResizeObserver || this.$resizeObserver)\n return;\n var self = this;\n this.$resizeTimer = lang.delayedCall(function () {\n if (!self.destroyed)\n self.onResize();\n }, 50);\n this.$resizeObserver = new window.ResizeObserver(function (e) {\n var w = e[0].contentRect.width;\n var h = e[0].contentRect.height;\n if (Math.abs(self.$size.width - w) > 1\n || Math.abs(self.$size.height - h) > 1) {\n self.$resizeTimer.delay();\n }\n else {\n self.$resizeTimer.cancel();\n }\n });\n this.$resizeObserver.observe(this.container);\n };\n return VirtualRenderer;\n}());\nVirtualRenderer.prototype.CHANGE_CURSOR = 1;\nVirtualRenderer.prototype.CHANGE_MARKER = 2;\nVirtualRenderer.prototype.CHANGE_GUTTER = 4;\nVirtualRenderer.prototype.CHANGE_SCROLL = 8;\nVirtualRenderer.prototype.CHANGE_LINES = 16;\nVirtualRenderer.prototype.CHANGE_TEXT = 32;\nVirtualRenderer.prototype.CHANGE_SIZE = 64;\nVirtualRenderer.prototype.CHANGE_MARKER_BACK = 128;\nVirtualRenderer.prototype.CHANGE_MARKER_FRONT = 256;\nVirtualRenderer.prototype.CHANGE_FULL = 512;\nVirtualRenderer.prototype.CHANGE_H_SCROLL = 1024;\nVirtualRenderer.prototype.$changes = 0;\nVirtualRenderer.prototype.$padding = null;\nVirtualRenderer.prototype.$frozen = false;\nVirtualRenderer.prototype.STEPS = 8;\noop.implement(VirtualRenderer.prototype, EventEmitter);\nconfig.defineOptions(VirtualRenderer.prototype, \"renderer\", {\n useResizeObserver: {\n set: function (value) {\n if (!value && this.$resizeObserver) {\n this.$resizeObserver.disconnect();\n this.$resizeTimer.cancel();\n this.$resizeTimer = this.$resizeObserver = null;\n }\n else if (value && !this.$resizeObserver) {\n this.$addResizeObserver();\n }\n }\n },\n animatedScroll: { initialValue: false },\n showInvisibles: {\n set: function (value) {\n if (this.$textLayer.setShowInvisibles(value))\n this.$loop.schedule(this.CHANGE_TEXT);\n },\n initialValue: false\n },\n showPrintMargin: {\n set: function () { this.$updatePrintMargin(); },\n initialValue: true\n },\n printMarginColumn: {\n set: function () { this.$updatePrintMargin(); },\n initialValue: 80\n },\n printMargin: {\n set: function (val) {\n if (typeof val == \"number\")\n this.$printMarginColumn = val;\n this.$showPrintMargin = !!val;\n this.$updatePrintMargin();\n },\n get: function () {\n return this.$showPrintMargin && this.$printMarginColumn;\n }\n },\n showGutter: {\n set: function (show) {\n this.$gutter.style.display = show ? \"block\" : \"none\";\n this.$loop.schedule(this.CHANGE_FULL);\n this.onGutterResize();\n },\n initialValue: true\n },\n useSvgGutterIcons: {\n set: function (value) {\n this.$gutterLayer.$useSvgGutterIcons = value;\n },\n initialValue: false\n },\n showFoldedAnnotations: {\n set: function (value) {\n this.$gutterLayer.$showFoldedAnnotations = value;\n },\n initialValue: false\n },\n fadeFoldWidgets: {\n set: function (show) {\n dom.setCssClass(this.$gutter, \"ace_fade-fold-widgets\", show);\n },\n initialValue: false\n },\n showFoldWidgets: {\n set: function (show) {\n this.$gutterLayer.setShowFoldWidgets(show);\n this.$loop.schedule(this.CHANGE_GUTTER);\n },\n initialValue: true\n },\n displayIndentGuides: {\n set: function (show) {\n if (this.$textLayer.setDisplayIndentGuides(show))\n this.$loop.schedule(this.CHANGE_TEXT);\n },\n initialValue: true\n },\n highlightIndentGuides: {\n set: function (show) {\n if (this.$textLayer.setHighlightIndentGuides(show) == true) {\n this.$textLayer.$highlightIndentGuide();\n }\n else {\n this.$textLayer.$clearActiveIndentGuide(this.$textLayer.$lines.cells);\n }\n },\n initialValue: true\n },\n highlightGutterLine: {\n set: function (shouldHighlight) {\n this.$gutterLayer.setHighlightGutterLine(shouldHighlight);\n this.$loop.schedule(this.CHANGE_GUTTER);\n },\n initialValue: true\n },\n hScrollBarAlwaysVisible: {\n set: function (val) {\n if (!this.$hScrollBarAlwaysVisible || !this.$horizScroll)\n this.$loop.schedule(this.CHANGE_SCROLL);\n },\n initialValue: false\n },\n vScrollBarAlwaysVisible: {\n set: function (val) {\n if (!this.$vScrollBarAlwaysVisible || !this.$vScroll)\n this.$loop.schedule(this.CHANGE_SCROLL);\n },\n initialValue: false\n },\n fontSize: {\n set: function (size) {\n if (typeof size == \"number\")\n size = size + \"px\";\n this.container.style.fontSize = size;\n this.updateFontSize();\n },\n initialValue: 12\n },\n fontFamily: {\n set: function (name) {\n this.container.style.fontFamily = name;\n this.updateFontSize();\n }\n },\n maxLines: {\n set: function (val) {\n this.updateFull();\n }\n },\n minLines: {\n set: function (val) {\n if (!(this.$minLines < 0x1ffffffffffff))\n this.$minLines = 0;\n this.updateFull();\n }\n },\n maxPixelHeight: {\n set: function (val) {\n this.updateFull();\n },\n initialValue: 0\n },\n scrollPastEnd: {\n set: function (val) {\n val = +val || 0;\n if (this.$scrollPastEnd == val)\n return;\n this.$scrollPastEnd = val;\n this.$loop.schedule(this.CHANGE_SCROLL);\n },\n initialValue: 0,\n handlesSet: true\n },\n fixedWidthGutter: {\n set: function (val) {\n this.$gutterLayer.$fixedWidth = !!val;\n this.$loop.schedule(this.CHANGE_GUTTER);\n }\n },\n customScrollbar: {\n set: function (val) {\n this.$updateCustomScrollbar(val);\n },\n initialValue: false\n },\n theme: {\n set: function (val) { this.setTheme(val); },\n get: function () { return this.$themeId || this.theme; },\n initialValue: \"./theme/textmate\",\n handlesSet: true\n },\n hasCssTransforms: {},\n useTextareaForIME: {\n initialValue: !useragent.isMobile && !useragent.isIE\n }\n});\nexports.VirtualRenderer = VirtualRenderer;\n\n});\n\nace.define(\"ace/worker/worker_client\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/net\",\"ace/lib/event_emitter\",\"ace/config\"], function(require, exports, module) {\n\"use strict\";\n\nvar oop = require(\"../lib/oop\");\nvar net = require(\"../lib/net\");\nvar EventEmitter = require(\"../lib/event_emitter\").EventEmitter;\nvar config = require(\"../config\");\n\nfunction $workerBlob(workerUrl) {\n var script = \"importScripts('\" + net.qualifyURL(workerUrl) + \"');\";\n try {\n return new Blob([script], {\"type\": \"application/javascript\"});\n } catch (e) { // Backwards-compatibility\n var BlobBuilder = window.BlobBuilder || window.WebKitBlobBuilder || window.MozBlobBuilder;\n var blobBuilder = new BlobBuilder();\n blobBuilder.append(script);\n return blobBuilder.getBlob(\"application/javascript\");\n }\n}\n\nfunction createWorker(workerUrl) {\n if (typeof Worker == \"undefined\")\n return { postMessage: function() {}, terminate: function() {} };\n if (config.get(\"loadWorkerFromBlob\")) {\n var blob = $workerBlob(workerUrl);\n var URL = window.URL || window.webkitURL;\n var blobURL = URL.createObjectURL(blob);\n return new Worker(blobURL);\n }\n return new Worker(workerUrl);\n}\n\nvar WorkerClient = function(worker) {\n if (!worker.postMessage)\n worker = this.$createWorkerFromOldConfig.apply(this, arguments);\n\n this.$worker = worker;\n this.$sendDeltaQueue = this.$sendDeltaQueue.bind(this);\n this.changeListener = this.changeListener.bind(this);\n this.onMessage = this.onMessage.bind(this);\n\n this.callbackId = 1;\n this.callbacks = {};\n\n this.$worker.onmessage = this.onMessage;\n};\n\n(function(){\n\n oop.implement(this, EventEmitter);\n\n this.$createWorkerFromOldConfig = function(topLevelNamespaces, mod, classname, workerUrl, importScripts) {\n if (require.nameToUrl && !require.toUrl)\n require.toUrl = require.nameToUrl;\n\n if (config.get(\"packaged\") || !require.toUrl) {\n workerUrl = workerUrl || config.moduleUrl(mod, \"worker\");\n } else {\n var normalizePath = this.$normalizePath;\n workerUrl = workerUrl || normalizePath(require.toUrl(\"ace/worker/worker.js\", null, \"_\"));\n\n var tlns = {};\n topLevelNamespaces.forEach(function(ns) {\n tlns[ns] = normalizePath(require.toUrl(ns, null, \"_\").replace(/(\\.js)?(\\?.*)?$/, \"\"));\n });\n }\n\n this.$worker = createWorker(workerUrl);\n if (importScripts) {\n this.send(\"importScripts\", importScripts);\n }\n this.$worker.postMessage({\n init : true,\n tlns : tlns,\n module : mod,\n classname : classname\n });\n return this.$worker;\n };\n\n this.onMessage = function(e) {\n var msg = e.data;\n switch (msg.type) {\n case \"event\":\n this._signal(msg.name, {data: msg.data});\n break;\n case \"call\":\n var callback = this.callbacks[msg.id];\n if (callback) {\n callback(msg.data);\n delete this.callbacks[msg.id];\n }\n break;\n case \"error\":\n this.reportError(msg.data);\n break;\n case \"log\":\n window.console && console.log && console.log.apply(console, msg.data);\n break;\n }\n };\n \n this.reportError = function(err) {\n window.console && console.error && console.error(err);\n };\n\n this.$normalizePath = function(path) {\n return net.qualifyURL(path);\n };\n\n this.terminate = function() {\n this._signal(\"terminate\", {});\n this.deltaQueue = null;\n this.$worker.terminate();\n this.$worker.onerror = function(e) {\n e.preventDefault();\n };\n this.$worker = null;\n if (this.$doc)\n this.$doc.off(\"change\", this.changeListener);\n this.$doc = null;\n };\n\n this.send = function(cmd, args) {\n this.$worker.postMessage({command: cmd, args: args});\n };\n\n this.call = function(cmd, args, callback) {\n if (callback) {\n var id = this.callbackId++;\n this.callbacks[id] = callback;\n args.push(id);\n }\n this.send(cmd, args);\n };\n\n this.emit = function(event, data) {\n try {\n if (data.data && data.data.err)\n data.data.err = {message: data.data.err.message, stack: data.data.err.stack, code: data.data.err.code};\n this.$worker && this.$worker.postMessage({event: event, data: {data: data.data}});\n }\n catch(ex) {\n console.error(ex.stack);\n }\n };\n\n this.attachToDocument = function(doc) {\n if (this.$doc)\n this.terminate();\n\n this.$doc = doc;\n this.call(\"setValue\", [doc.getValue()]);\n doc.on(\"change\", this.changeListener, true);\n };\n\n this.changeListener = function(delta) {\n if (!this.deltaQueue) {\n this.deltaQueue = [];\n setTimeout(this.$sendDeltaQueue, 0);\n }\n if (delta.action == \"insert\")\n this.deltaQueue.push(delta.start, delta.lines);\n else\n this.deltaQueue.push(delta.start, delta.end);\n };\n\n this.$sendDeltaQueue = function() {\n var q = this.deltaQueue;\n if (!q) return;\n this.deltaQueue = null;\n if (q.length > 50 && q.length > this.$doc.getLength() >> 1) {\n this.call(\"setValue\", [this.$doc.getValue()]);\n } else\n this.emit(\"change\", {data: q});\n };\n\n}).call(WorkerClient.prototype);\n\n\nvar UIWorkerClient = function(topLevelNamespaces, mod, classname) {\n var main = null;\n var emitSync = false;\n var sender = Object.create(EventEmitter);\n\n var messageBuffer = [];\n var workerClient = new WorkerClient({\n messageBuffer: messageBuffer,\n terminate: function() {},\n postMessage: function(e) {\n messageBuffer.push(e);\n if (!main) return;\n if (emitSync)\n setTimeout(processNext);\n else\n processNext();\n }\n });\n\n workerClient.setEmitSync = function(val) { emitSync = val; };\n\n var processNext = function() {\n var msg = messageBuffer.shift();\n if (msg.command)\n main[msg.command].apply(main, msg.args);\n else if (msg.event)\n sender._signal(msg.event, msg.data);\n };\n\n sender.postMessage = function(msg) {\n workerClient.onMessage({data: msg});\n };\n sender.callback = function(data, callbackId) {\n this.postMessage({type: \"call\", id: callbackId, data: data});\n };\n sender.emit = function(name, data) {\n this.postMessage({type: \"event\", name: name, data: data});\n };\n\n config.loadModule([\"worker\", mod], function(Main) {\n main = new Main[classname](sender);\n while (messageBuffer.length)\n processNext();\n });\n\n return workerClient;\n};\n\nexports.UIWorkerClient = UIWorkerClient;\nexports.WorkerClient = WorkerClient;\nexports.createWorker = createWorker;\n\n\n});\n\nace.define(\"ace/placeholder\",[\"require\",\"exports\",\"module\",\"ace/range\",\"ace/lib/event_emitter\",\"ace/lib/oop\"], function(require, exports, module){\"use strict\";\nvar Range = require(\"./range\").Range;\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar oop = require(\"./lib/oop\");\nvar PlaceHolder = /** @class */ (function () {\n function PlaceHolder(session, length, pos, others, mainClass, othersClass) {\n var _self = this;\n this.length = length;\n this.session = session;\n this.doc = session.getDocument();\n this.mainClass = mainClass;\n this.othersClass = othersClass;\n this.$onUpdate = this.onUpdate.bind(this);\n this.doc.on(\"change\", this.$onUpdate, true);\n this.$others = others;\n this.$onCursorChange = function () {\n setTimeout(function () {\n _self.onCursorChange();\n });\n };\n this.$pos = pos;\n var undoStack = session.getUndoManager().$undoStack || session.getUndoManager()[\"$undostack\"] || { length: -1 };\n this.$undoStackDepth = undoStack.length;\n this.setup();\n session.selection.on(\"changeCursor\", this.$onCursorChange);\n }\n PlaceHolder.prototype.setup = function () {\n var _self = this;\n var doc = this.doc;\n var session = this.session;\n this.selectionBefore = session.selection.toJSON();\n if (session.selection.inMultiSelectMode)\n session.selection.toSingleRange();\n this.pos = doc.createAnchor(this.$pos.row, this.$pos.column);\n var pos = this.pos;\n pos.$insertRight = true;\n pos.detach();\n pos.markerId = session.addMarker(new Range(pos.row, pos.column, pos.row, pos.column + this.length), this.mainClass, null, false);\n this.others = [];\n this.$others.forEach(function (other) {\n var anchor = doc.createAnchor(other.row, other.column);\n anchor.$insertRight = true;\n anchor.detach();\n _self.others.push(anchor);\n });\n session.setUndoSelect(false);\n };\n PlaceHolder.prototype.showOtherMarkers = function () {\n if (this.othersActive)\n return;\n var session = this.session;\n var _self = this;\n this.othersActive = true;\n this.others.forEach(function (anchor) {\n anchor.markerId = session.addMarker(new Range(anchor.row, anchor.column, anchor.row, anchor.column + _self.length), _self.othersClass, null, false);\n });\n };\n PlaceHolder.prototype.hideOtherMarkers = function () {\n if (!this.othersActive)\n return;\n this.othersActive = false;\n for (var i = 0; i < this.others.length; i++) {\n this.session.removeMarker(this.others[i].markerId);\n }\n };\n PlaceHolder.prototype.onUpdate = function (delta) {\n if (this.$updating)\n return this.updateAnchors(delta);\n var range = delta;\n if (range.start.row !== range.end.row)\n return;\n if (range.start.row !== this.pos.row)\n return;\n this.$updating = true;\n var lengthDiff = delta.action === \"insert\" ? range.end.column - range.start.column : range.start.column - range.end.column;\n var inMainRange = range.start.column >= this.pos.column && range.start.column <= this.pos.column + this.length + 1;\n var distanceFromStart = range.start.column - this.pos.column;\n this.updateAnchors(delta);\n if (inMainRange)\n this.length += lengthDiff;\n if (inMainRange && !this.session.$fromUndo) {\n if (delta.action === 'insert') {\n for (var i = this.others.length - 1; i >= 0; i--) {\n var otherPos = this.others[i];\n var newPos = { row: otherPos.row, column: otherPos.column + distanceFromStart };\n this.doc.insertMergedLines(newPos, delta.lines);\n }\n }\n else if (delta.action === 'remove') {\n for (var i = this.others.length - 1; i >= 0; i--) {\n var otherPos = this.others[i];\n var newPos = { row: otherPos.row, column: otherPos.column + distanceFromStart };\n this.doc.remove(new Range(newPos.row, newPos.column, newPos.row, newPos.column - lengthDiff));\n }\n }\n }\n this.$updating = false;\n this.updateMarkers();\n };\n PlaceHolder.prototype.updateAnchors = function (delta) {\n this.pos.onChange(delta);\n for (var i = this.others.length; i--;)\n this.others[i].onChange(delta);\n this.updateMarkers();\n };\n PlaceHolder.prototype.updateMarkers = function () {\n if (this.$updating)\n return;\n var _self = this;\n var session = this.session;\n var updateMarker = function (pos, className) {\n session.removeMarker(pos.markerId);\n pos.markerId = session.addMarker(new Range(pos.row, pos.column, pos.row, pos.column + _self.length), className, null, false);\n };\n updateMarker(this.pos, this.mainClass);\n for (var i = this.others.length; i--;)\n updateMarker(this.others[i], this.othersClass);\n };\n PlaceHolder.prototype.onCursorChange = function (event) {\n if (this.$updating || !this.session)\n return;\n var pos = this.session.selection.getCursor();\n if (pos.row === this.pos.row && pos.column >= this.pos.column && pos.column <= this.pos.column + this.length) {\n this.showOtherMarkers();\n this._emit(\"cursorEnter\", event);\n }\n else {\n this.hideOtherMarkers();\n this._emit(\"cursorLeave\", event);\n }\n };\n PlaceHolder.prototype.detach = function () {\n this.session.removeMarker(this.pos && this.pos.markerId);\n this.hideOtherMarkers();\n this.doc.off(\"change\", this.$onUpdate);\n this.session.selection.off(\"changeCursor\", this.$onCursorChange);\n this.session.setUndoSelect(true);\n this.session = null;\n };\n PlaceHolder.prototype.cancel = function () {\n if (this.$undoStackDepth === -1)\n return;\n var undoManager = this.session.getUndoManager();\n var undosRequired = (undoManager.$undoStack || undoManager[\"$undostack\"]).length - this.$undoStackDepth;\n for (var i = 0; i < undosRequired; i++) {\n undoManager.undo(this.session, true);\n }\n if (this.selectionBefore)\n this.session.selection.fromJSON(this.selectionBefore);\n };\n return PlaceHolder;\n}());\noop.implement(PlaceHolder.prototype, EventEmitter);\nexports.PlaceHolder = PlaceHolder;\n\n});\n\nace.define(\"ace/mouse/multi_select_handler\",[\"require\",\"exports\",\"module\",\"ace/lib/event\",\"ace/lib/useragent\"], function(require, exports, module){var event = require(\"../lib/event\");\nvar useragent = require(\"../lib/useragent\");\nfunction isSamePoint(p1, p2) {\n return p1.row == p2.row && p1.column == p2.column;\n}\nfunction onMouseDown(e) {\n var ev = e.domEvent;\n var alt = ev.altKey;\n var shift = ev.shiftKey;\n var ctrl = ev.ctrlKey;\n var accel = e.getAccelKey();\n var button = e.getButton();\n if (ctrl && useragent.isMac)\n button = ev.button;\n if (e.editor.inMultiSelectMode && button == 2) {\n e.editor.textInput.onContextMenu(e.domEvent);\n return;\n }\n if (!ctrl && !alt && !accel) {\n if (button === 0 && e.editor.inMultiSelectMode)\n e.editor.exitMultiSelectMode();\n return;\n }\n if (button !== 0)\n return;\n var editor = e.editor;\n var selection = editor.selection;\n var isMultiSelect = editor.inMultiSelectMode;\n var pos = e.getDocumentPosition();\n var cursor = selection.getCursor();\n var inSelection = e.inSelection() || (selection.isEmpty() && isSamePoint(pos, cursor));\n var mouseX = e.x, mouseY = e.y;\n var onMouseSelection = function (e) {\n mouseX = e.clientX;\n mouseY = e.clientY;\n };\n var session = editor.session;\n var screenAnchor = editor.renderer.pixelToScreenCoordinates(mouseX, mouseY);\n var screenCursor = screenAnchor;\n var selectionMode;\n if (editor.$mouseHandler.$enableJumpToDef) {\n if (ctrl && alt || accel && alt)\n selectionMode = shift ? \"block\" : \"add\";\n else if (alt && editor.$blockSelectEnabled)\n selectionMode = \"block\";\n }\n else {\n if (accel && !alt) {\n selectionMode = \"add\";\n if (!isMultiSelect && shift)\n return;\n }\n else if (alt && editor.$blockSelectEnabled) {\n selectionMode = \"block\";\n }\n }\n if (selectionMode && useragent.isMac && ev.ctrlKey) {\n editor.$mouseHandler.cancelContextMenu();\n }\n if (selectionMode == \"add\") {\n if (!isMultiSelect && inSelection)\n return; // dragging\n if (!isMultiSelect) {\n var range = selection.toOrientedRange();\n editor.addSelectionMarker(range);\n }\n var oldRange = selection.rangeList.rangeAtPoint(pos);\n editor.inVirtualSelectionMode = true;\n if (shift) {\n oldRange = null;\n range = selection.ranges[0] || range;\n editor.removeSelectionMarker(range);\n }\n editor.once(\"mouseup\", function () {\n var tmpSel = selection.toOrientedRange();\n if (oldRange && tmpSel.isEmpty() && isSamePoint(oldRange.cursor, tmpSel.cursor))\n selection.substractPoint(tmpSel.cursor);\n else {\n if (shift) {\n selection.substractPoint(range.cursor);\n }\n else if (range) {\n editor.removeSelectionMarker(range);\n selection.addRange(range);\n }\n selection.addRange(tmpSel);\n }\n editor.inVirtualSelectionMode = false;\n });\n }\n else if (selectionMode == \"block\") {\n e.stop();\n editor.inVirtualSelectionMode = true;\n var initialRange;\n var rectSel = [];\n var blockSelect = function () {\n var newCursor = editor.renderer.pixelToScreenCoordinates(mouseX, mouseY);\n var cursor = session.screenToDocumentPosition(newCursor.row, newCursor.column, newCursor.offsetX);\n if (isSamePoint(screenCursor, newCursor) && isSamePoint(cursor, selection.lead))\n return;\n screenCursor = newCursor;\n editor.selection.moveToPosition(cursor);\n editor.renderer.scrollCursorIntoView();\n editor.removeSelectionMarkers(rectSel);\n rectSel = selection.rectangularRangeBlock(screenCursor, screenAnchor);\n if (editor.$mouseHandler.$clickSelection && rectSel.length == 1 && rectSel[0].isEmpty())\n rectSel[0] = editor.$mouseHandler.$clickSelection.clone();\n rectSel.forEach(editor.addSelectionMarker, editor);\n editor.updateSelectionMarkers();\n };\n if (isMultiSelect && !accel) {\n selection.toSingleRange();\n }\n else if (!isMultiSelect && accel) {\n initialRange = selection.toOrientedRange();\n editor.addSelectionMarker(initialRange);\n }\n if (shift)\n screenAnchor = session.documentToScreenPosition(selection.lead);\n else\n selection.moveToPosition(pos);\n screenCursor = { row: -1, column: -1 };\n var onMouseSelectionEnd = function (e) {\n blockSelect();\n clearInterval(timerId);\n editor.removeSelectionMarkers(rectSel);\n if (!rectSel.length)\n rectSel = [selection.toOrientedRange()];\n if (initialRange) {\n editor.removeSelectionMarker(initialRange);\n selection.toSingleRange(initialRange);\n }\n for (var i = 0; i < rectSel.length; i++)\n selection.addRange(rectSel[i]);\n editor.inVirtualSelectionMode = false;\n editor.$mouseHandler.$clickSelection = null;\n };\n var onSelectionInterval = blockSelect;\n event.capture(editor.container, onMouseSelection, onMouseSelectionEnd);\n var timerId = setInterval(function () { onSelectionInterval(); }, 20);\n return e.preventDefault();\n }\n}\nexports.onMouseDown = onMouseDown;\n\n});\n\nace.define(\"ace/commands/multi_select_commands\",[\"require\",\"exports\",\"module\",\"ace/keyboard/hash_handler\"], function(require, exports, module){/**\n * commands to enter multiselect mode\n * @type {import(\"../../ace-internal\").Ace.Command[]}\n */\nexports.defaultCommands = [{\n name: \"addCursorAbove\",\n description: \"Add cursor above\",\n exec: function (editor) { editor.selectMoreLines(-1); },\n bindKey: { win: \"Ctrl-Alt-Up\", mac: \"Ctrl-Alt-Up\" },\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"addCursorBelow\",\n description: \"Add cursor below\",\n exec: function (editor) { editor.selectMoreLines(1); },\n bindKey: { win: \"Ctrl-Alt-Down\", mac: \"Ctrl-Alt-Down\" },\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"addCursorAboveSkipCurrent\",\n description: \"Add cursor above (skip current)\",\n exec: function (editor) { editor.selectMoreLines(-1, true); },\n bindKey: { win: \"Ctrl-Alt-Shift-Up\", mac: \"Ctrl-Alt-Shift-Up\" },\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"addCursorBelowSkipCurrent\",\n description: \"Add cursor below (skip current)\",\n exec: function (editor) { editor.selectMoreLines(1, true); },\n bindKey: { win: \"Ctrl-Alt-Shift-Down\", mac: \"Ctrl-Alt-Shift-Down\" },\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selectMoreBefore\",\n description: \"Select more before\",\n exec: function (editor) { editor.selectMore(-1); },\n bindKey: { win: \"Ctrl-Alt-Left\", mac: \"Ctrl-Alt-Left\" },\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selectMoreAfter\",\n description: \"Select more after\",\n exec: function (editor) { editor.selectMore(1); },\n bindKey: { win: \"Ctrl-Alt-Right\", mac: \"Ctrl-Alt-Right\" },\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selectNextBefore\",\n description: \"Select next before\",\n exec: function (editor) { editor.selectMore(-1, true); },\n bindKey: { win: \"Ctrl-Alt-Shift-Left\", mac: \"Ctrl-Alt-Shift-Left\" },\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"selectNextAfter\",\n description: \"Select next after\",\n exec: function (editor) { editor.selectMore(1, true); },\n bindKey: { win: \"Ctrl-Alt-Shift-Right\", mac: \"Ctrl-Alt-Shift-Right\" },\n scrollIntoView: \"cursor\",\n readOnly: true\n }, {\n name: \"toggleSplitSelectionIntoLines\",\n description: \"Split selection into lines\",\n exec: function (editor) {\n if (editor.multiSelect.rangeCount > 1)\n editor.multiSelect.joinSelections();\n else\n editor.multiSelect.splitIntoLines();\n },\n bindKey: { win: \"Ctrl-Alt-L\", mac: \"Ctrl-Alt-L\" },\n readOnly: true\n }, {\n name: \"splitSelectionIntoLines\",\n description: \"Split into lines\",\n exec: function (editor) { editor.multiSelect.splitIntoLines(); },\n readOnly: true\n }, {\n name: \"alignCursors\",\n description: \"Align cursors\",\n exec: function (editor) { editor.alignCursors(); },\n bindKey: { win: \"Ctrl-Alt-A\", mac: \"Ctrl-Alt-A\" },\n scrollIntoView: \"cursor\"\n }, {\n name: \"findAll\",\n description: \"Find all\",\n exec: function (editor) { editor.findAll(); },\n bindKey: { win: \"Ctrl-Alt-K\", mac: \"Ctrl-Alt-G\" },\n scrollIntoView: \"cursor\",\n readOnly: true\n }];\nexports.multiSelectCommands = [{\n name: \"singleSelection\",\n description: \"Single selection\",\n bindKey: \"esc\",\n exec: function (editor) { editor.exitMultiSelectMode(); },\n scrollIntoView: \"cursor\",\n readOnly: true,\n isAvailable: function (editor) { return editor && editor.inMultiSelectMode; }\n }];\nvar HashHandler = require(\"../keyboard/hash_handler\").HashHandler;\nexports.keyboardHandler = new HashHandler(exports.multiSelectCommands);\n\n});\n\nace.define(\"ace/multi_select\",[\"require\",\"exports\",\"module\",\"ace/range_list\",\"ace/range\",\"ace/selection\",\"ace/mouse/multi_select_handler\",\"ace/lib/event\",\"ace/lib/lang\",\"ace/commands/multi_select_commands\",\"ace/search\",\"ace/edit_session\",\"ace/editor\",\"ace/config\"], function(require, exports, module){/**\n * @typedef {import(\"./anchor\").Anchor} Anchor\n * @typedef {import(\"../ace-internal\").Ace.Point} Point\n * @typedef {import(\"../ace-internal\").Ace.ScreenCoordinates} ScreenCoordinates\n */\nvar RangeList = require(\"./range_list\").RangeList;\nvar Range = require(\"./range\").Range;\nvar Selection = require(\"./selection\").Selection;\nvar onMouseDown = require(\"./mouse/multi_select_handler\").onMouseDown;\nvar event = require(\"./lib/event\");\nvar lang = require(\"./lib/lang\");\nvar commands = require(\"./commands/multi_select_commands\");\nexports.commands = commands.defaultCommands.concat(commands.multiSelectCommands);\nvar Search = require(\"./search\").Search;\nvar search = new Search();\nfunction find(session, needle, dir) {\n search.$options.wrap = true;\n search.$options.needle = needle;\n search.$options.backwards = dir == -1;\n return search.find(session);\n}\nvar EditSession = require(\"./edit_session\").EditSession;\n(function () {\n this.getSelectionMarkers = function () {\n return this.$selectionMarkers;\n };\n}).call(EditSession.prototype);\n(function () {\n this.ranges = null;\n this.rangeList = null;\n this.addRange = function (range, $blockChangeEvents) {\n if (!range)\n return;\n if (!this.inMultiSelectMode && this.rangeCount === 0) {\n var oldRange = this.toOrientedRange();\n this.rangeList.add(oldRange);\n this.rangeList.add(range);\n if (this.rangeList.ranges.length != 2) {\n this.rangeList.removeAll();\n return $blockChangeEvents || this.fromOrientedRange(range);\n }\n this.rangeList.removeAll();\n this.rangeList.add(oldRange);\n this.$onAddRange(oldRange);\n }\n if (!range.cursor)\n range.cursor = range.end;\n var removed = this.rangeList.add(range);\n this.$onAddRange(range);\n if (removed.length)\n this.$onRemoveRange(removed);\n if (this.rangeCount > 1 && !this.inMultiSelectMode) {\n this._signal(\"multiSelect\");\n this.inMultiSelectMode = true;\n this.session.$undoSelect = false;\n this.rangeList.attach(this.session);\n }\n return $blockChangeEvents || this.fromOrientedRange(range);\n };\n this.toSingleRange = function (range) {\n range = range || this.ranges[0];\n var removed = this.rangeList.removeAll();\n if (removed.length)\n this.$onRemoveRange(removed);\n range && this.fromOrientedRange(range);\n };\n this.substractPoint = function (pos) {\n var removed = this.rangeList.substractPoint(pos);\n if (removed) {\n this.$onRemoveRange(removed);\n return removed[0];\n }\n };\n this.mergeOverlappingRanges = function () {\n var removed = this.rangeList.merge();\n if (removed.length)\n this.$onRemoveRange(removed);\n };\n this.$onAddRange = function (range) {\n this.rangeCount = this.rangeList.ranges.length;\n this.ranges.unshift(range);\n this._signal(\"addRange\", { range: range });\n };\n this.$onRemoveRange = function (removed) {\n this.rangeCount = this.rangeList.ranges.length;\n if (this.rangeCount == 1 && this.inMultiSelectMode) {\n var lastRange = this.rangeList.ranges.pop();\n removed.push(lastRange);\n this.rangeCount = 0;\n }\n for (var i = removed.length; i--;) {\n var index = this.ranges.indexOf(removed[i]);\n this.ranges.splice(index, 1);\n }\n this._signal(\"removeRange\", { ranges: removed });\n if (this.rangeCount === 0 && this.inMultiSelectMode) {\n this.inMultiSelectMode = false;\n this._signal(\"singleSelect\");\n this.session.$undoSelect = true;\n this.rangeList.detach(this.session);\n }\n lastRange = lastRange || this.ranges[0];\n if (lastRange && !lastRange.isEqual(this.getRange()))\n this.fromOrientedRange(lastRange);\n };\n this.$initRangeList = function () {\n if (this.rangeList)\n return;\n this.rangeList = new RangeList();\n this.ranges = [];\n this.rangeCount = 0;\n };\n this.getAllRanges = function () {\n return this.rangeCount ? this.rangeList.ranges.concat() : [this.getRange()];\n };\n this.splitIntoLines = function () {\n var ranges = this.ranges.length ? this.ranges : [this.getRange()];\n var newRanges = [];\n for (var i = 0; i < ranges.length; i++) {\n var range = ranges[i];\n var row = range.start.row;\n var endRow = range.end.row;\n if (row === endRow) {\n newRanges.push(range.clone());\n }\n else {\n newRanges.push(new Range(row, range.start.column, row, this.session.getLine(row).length));\n while (++row < endRow)\n newRanges.push(this.getLineRange(row, true));\n newRanges.push(new Range(endRow, 0, endRow, range.end.column));\n }\n if (i == 0 && !this.isBackwards())\n newRanges = newRanges.reverse();\n }\n this.toSingleRange();\n for (var i = newRanges.length; i--;)\n this.addRange(newRanges[i]);\n };\n this.joinSelections = function () {\n var ranges = this.rangeList.ranges;\n var lastRange = ranges[ranges.length - 1];\n var range = Range.fromPoints(ranges[0].start, lastRange.end);\n this.toSingleRange();\n this.setSelectionRange(range, lastRange.cursor == lastRange.start);\n };\n this.toggleBlockSelection = function () {\n if (this.rangeCount > 1) {\n var ranges = this.rangeList.ranges;\n var lastRange = ranges[ranges.length - 1];\n var range = Range.fromPoints(ranges[0].start, lastRange.end);\n this.toSingleRange();\n this.setSelectionRange(range, lastRange.cursor == lastRange.start);\n }\n else {\n var cursor = this.session.documentToScreenPosition(this.cursor);\n var anchor = this.session.documentToScreenPosition(this.anchor);\n var rectSel = this.rectangularRangeBlock(cursor, anchor);\n rectSel.forEach(this.addRange, this);\n }\n };\n this.rectangularRangeBlock = function (screenCursor, screenAnchor, includeEmptyLines) {\n var rectSel = [];\n var xBackwards = screenCursor.column < screenAnchor.column;\n if (xBackwards) {\n var startColumn = screenCursor.column;\n var endColumn = screenAnchor.column;\n var startOffsetX = screenCursor.offsetX;\n var endOffsetX = screenAnchor.offsetX;\n }\n else {\n var startColumn = screenAnchor.column;\n var endColumn = screenCursor.column;\n var startOffsetX = screenAnchor.offsetX;\n var endOffsetX = screenCursor.offsetX;\n }\n var yBackwards = screenCursor.row < screenAnchor.row;\n if (yBackwards) {\n var startRow = screenCursor.row;\n var endRow = screenAnchor.row;\n }\n else {\n var startRow = screenAnchor.row;\n var endRow = screenCursor.row;\n }\n if (startColumn < 0)\n startColumn = 0;\n if (startRow < 0)\n startRow = 0;\n if (startRow == endRow)\n includeEmptyLines = true;\n var docEnd;\n for (var row = startRow; row <= endRow; row++) {\n var range = Range.fromPoints(this.session.screenToDocumentPosition(row, startColumn, startOffsetX), this.session.screenToDocumentPosition(row, endColumn, endOffsetX));\n if (range.isEmpty()) {\n if (docEnd && isSamePoint(range.end, docEnd))\n break;\n docEnd = range.end;\n }\n range.cursor = xBackwards ? range.start : range.end;\n rectSel.push(range);\n }\n if (yBackwards)\n rectSel.reverse();\n if (!includeEmptyLines) {\n var end = rectSel.length - 1;\n while (rectSel[end].isEmpty() && end > 0)\n end--;\n if (end > 0) {\n var start = 0;\n while (rectSel[start].isEmpty())\n start++;\n }\n for (var i = end; i >= start; i--) {\n if (rectSel[i].isEmpty())\n rectSel.splice(i, 1);\n }\n }\n return rectSel;\n };\n}).call(Selection.prototype);\nvar Editor = require(\"./editor\").Editor;\n(function () {\n this.updateSelectionMarkers = function () {\n this.renderer.updateCursor();\n this.renderer.updateBackMarkers();\n };\n this.addSelectionMarker = function (orientedRange) {\n if (!orientedRange.cursor)\n orientedRange.cursor = orientedRange.end;\n var style = this.getSelectionStyle();\n orientedRange.marker = this.session.addMarker(orientedRange, \"ace_selection\", style);\n this.session.$selectionMarkers.push(orientedRange);\n this.session.selectionMarkerCount = this.session.$selectionMarkers.length;\n return orientedRange;\n };\n this.removeSelectionMarker = function (range) {\n if (!range.marker)\n return;\n this.session.removeMarker(range.marker);\n var index = this.session.$selectionMarkers.indexOf(range);\n if (index != -1)\n this.session.$selectionMarkers.splice(index, 1);\n this.session.selectionMarkerCount = this.session.$selectionMarkers.length;\n };\n this.removeSelectionMarkers = function (ranges) {\n var markerList = this.session.$selectionMarkers;\n for (var i = ranges.length; i--;) {\n var range = ranges[i];\n if (!range.marker)\n continue;\n this.session.removeMarker(range.marker);\n var index = markerList.indexOf(range);\n if (index != -1)\n markerList.splice(index, 1);\n }\n this.session.selectionMarkerCount = markerList.length;\n };\n this.$onAddRange = function (e) {\n this.addSelectionMarker(e.range);\n this.renderer.updateCursor();\n this.renderer.updateBackMarkers();\n };\n this.$onRemoveRange = function (e) {\n this.removeSelectionMarkers(e.ranges);\n this.renderer.updateCursor();\n this.renderer.updateBackMarkers();\n };\n this.$onMultiSelect = function (e) {\n if (this.inMultiSelectMode)\n return;\n this.inMultiSelectMode = true;\n this.setStyle(\"ace_multiselect\");\n this.keyBinding.addKeyboardHandler(commands.keyboardHandler);\n this.commands.setDefaultHandler(\"exec\", this.$onMultiSelectExec);\n this.renderer.updateCursor();\n this.renderer.updateBackMarkers();\n };\n this.$onSingleSelect = function (e) {\n if (this.session.multiSelect.inVirtualMode)\n return;\n this.inMultiSelectMode = false;\n this.unsetStyle(\"ace_multiselect\");\n this.keyBinding.removeKeyboardHandler(commands.keyboardHandler);\n this.commands.removeDefaultHandler(\"exec\", this.$onMultiSelectExec);\n this.renderer.updateCursor();\n this.renderer.updateBackMarkers();\n this._emit(\"changeSelection\");\n };\n this.$onMultiSelectExec = function (e) {\n var command = e.command;\n var editor = e.editor;\n if (!editor.multiSelect)\n return;\n if (!command.multiSelectAction) {\n var result = command.exec(editor, e.args || {});\n editor.multiSelect.addRange(editor.multiSelect.toOrientedRange());\n editor.multiSelect.mergeOverlappingRanges();\n }\n else if (command.multiSelectAction == \"forEach\") {\n result = editor.forEachSelection(command, e.args);\n }\n else if (command.multiSelectAction == \"forEachLine\") {\n result = editor.forEachSelection(command, e.args, true);\n }\n else if (command.multiSelectAction == \"single\") {\n editor.exitMultiSelectMode();\n result = command.exec(editor, e.args || {});\n }\n else {\n result = command.multiSelectAction(editor, e.args || {});\n }\n return result;\n };\n this.forEachSelection = function (cmd, args, options) {\n if (this.inVirtualSelectionMode)\n return;\n var keepOrder = options && options.keepOrder;\n var $byLines = options == true || options && options.$byLines;\n var session = this.session;\n var selection = this.selection;\n var rangeList = selection.rangeList;\n var ranges = (keepOrder ? selection : rangeList).ranges;\n var result;\n if (!ranges.length)\n return cmd.exec ? cmd.exec(this, args || {}) : cmd(this, args || {});\n var reg = selection._eventRegistry;\n selection._eventRegistry = {};\n var tmpSel = new Selection(session);\n this.inVirtualSelectionMode = true;\n for (var i = ranges.length; i--;) {\n if ($byLines) {\n while (i > 0 && ranges[i].start.row == ranges[i - 1].end.row)\n i--;\n }\n tmpSel.fromOrientedRange(ranges[i]);\n tmpSel.index = i;\n this.selection = session.selection = tmpSel;\n var cmdResult = cmd.exec ? cmd.exec(this, args || {}) : cmd(this, args || {});\n if (!result && cmdResult !== undefined)\n result = cmdResult;\n tmpSel.toOrientedRange(ranges[i]);\n }\n tmpSel.detach();\n this.selection = session.selection = selection;\n this.inVirtualSelectionMode = false;\n selection._eventRegistry = reg;\n selection.mergeOverlappingRanges();\n if (selection.ranges[0])\n selection.fromOrientedRange(selection.ranges[0]);\n var anim = this.renderer.$scrollAnimation;\n this.onCursorChange();\n this.onSelectionChange();\n if (anim && anim.from == anim.to)\n this.renderer.animateScrolling(anim.from);\n return result;\n };\n this.exitMultiSelectMode = function () {\n if (!this.inMultiSelectMode || this.inVirtualSelectionMode)\n return;\n this.multiSelect.toSingleRange();\n };\n this.getSelectedText = function () {\n var text = \"\";\n if (this.inMultiSelectMode && !this.inVirtualSelectionMode) {\n var ranges = this.multiSelect.rangeList.ranges;\n var buf = [];\n for (var i = 0; i < ranges.length; i++) {\n buf.push(this.session.getTextRange(ranges[i]));\n }\n var nl = this.session.getDocument().getNewLineCharacter();\n text = buf.join(nl);\n if (text.length == (buf.length - 1) * nl.length)\n text = \"\";\n }\n else if (!this.selection.isEmpty()) {\n text = this.session.getTextRange(this.getSelectionRange());\n }\n return text;\n };\n this.$checkMultiselectChange = function (e, anchor) {\n if (this.inMultiSelectMode && !this.inVirtualSelectionMode) {\n var range = this.multiSelect.ranges[0];\n if (this.multiSelect.isEmpty() && anchor == this.multiSelect.anchor)\n return;\n var pos = anchor == this.multiSelect.anchor\n ? range.cursor == range.start ? range.end : range.start\n : range.cursor;\n if (pos.row != anchor.row\n || this.session.$clipPositionToDocument(pos.row, pos.column).column != anchor.column)\n this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange());\n else\n this.multiSelect.mergeOverlappingRanges();\n }\n };\n this.findAll = function (needle, options, additive) {\n options = options || {};\n options.needle = needle || options.needle;\n if (options.needle == undefined) {\n var range = this.selection.isEmpty()\n ? this.selection.getWordRange()\n : this.selection.getRange();\n options.needle = this.session.getTextRange(range);\n }\n this.$search.set(options);\n var ranges = this.$search.findAll(this.session);\n if (!ranges.length)\n return 0;\n var selection = this.multiSelect;\n if (!additive)\n selection.toSingleRange(ranges[0]);\n for (var i = ranges.length; i--;)\n selection.addRange(ranges[i], true);\n if (range && selection.rangeList.rangeAtPoint(range.start))\n selection.addRange(range, true);\n return ranges.length;\n };\n this.selectMoreLines = function (dir, skip) {\n var range = this.selection.toOrientedRange();\n var isBackwards = range.cursor == range.end;\n var screenLead = this.session.documentToScreenPosition(range.cursor);\n if (this.selection.$desiredColumn)\n screenLead.column = this.selection.$desiredColumn;\n var lead = this.session.screenToDocumentPosition(screenLead.row + dir, screenLead.column);\n if (!range.isEmpty()) {\n var screenAnchor = this.session.documentToScreenPosition(isBackwards ? range.end : range.start);\n var anchor = this.session.screenToDocumentPosition(screenAnchor.row + dir, screenAnchor.column);\n }\n else {\n var anchor = lead;\n }\n if (isBackwards) {\n var newRange = Range.fromPoints(lead, anchor);\n newRange.cursor = newRange.start;\n }\n else {\n var newRange = Range.fromPoints(anchor, lead);\n newRange.cursor = newRange.end;\n }\n newRange.desiredColumn = screenLead.column;\n if (!this.selection.inMultiSelectMode) {\n this.selection.addRange(range);\n }\n else {\n if (skip)\n var toRemove = range.cursor;\n }\n this.selection.addRange(newRange);\n if (toRemove)\n this.selection.substractPoint(toRemove);\n };\n this.transposeSelections = function (dir) {\n var session = this.session;\n var sel = session.multiSelect;\n var all = sel.ranges;\n for (var i = all.length; i--;) {\n var range = all[i];\n if (range.isEmpty()) {\n var tmp_1 = session.getWordRange(range.start.row, range.start.column);\n range.start.row = tmp_1.start.row;\n range.start.column = tmp_1.start.column;\n range.end.row = tmp_1.end.row;\n range.end.column = tmp_1.end.column;\n }\n }\n sel.mergeOverlappingRanges();\n var words = [];\n for (var i = all.length; i--;) {\n var range = all[i];\n words.unshift(session.getTextRange(range));\n }\n if (dir < 0)\n words.unshift(words.pop());\n else\n words.push(words.shift());\n for (var i = all.length; i--;) {\n var range = all[i];\n var tmp = range.clone();\n session.replace(range, words[i]);\n range.start.row = tmp.start.row;\n range.start.column = tmp.start.column;\n }\n sel.fromOrientedRange(sel.ranges[0]);\n };\n this.selectMore = function (dir, skip, stopAtFirst) {\n var session = this.session;\n var sel = session.multiSelect;\n var range = sel.toOrientedRange();\n if (range.isEmpty()) {\n range = session.getWordRange(range.start.row, range.start.column);\n range.cursor = dir == -1 ? range.start : range.end;\n this.multiSelect.addRange(range);\n if (stopAtFirst)\n return;\n }\n var needle = session.getTextRange(range);\n var newRange = find(session, needle, dir);\n if (newRange) {\n newRange.cursor = dir == -1 ? newRange.start : newRange.end;\n this.session.unfold(newRange);\n this.multiSelect.addRange(newRange);\n this.renderer.scrollCursorIntoView(null, 0.5);\n }\n if (skip)\n this.multiSelect.substractPoint(range.cursor);\n };\n this.alignCursors = function () {\n var session = this.session;\n var sel = session.multiSelect;\n var ranges = sel.ranges;\n var row = -1;\n var sameRowRanges = ranges.filter(function (r) {\n if (r.cursor.row == row)\n return true;\n row = r.cursor.row;\n });\n if (!ranges.length || sameRowRanges.length == ranges.length - 1) {\n var range = this.selection.getRange();\n var fr = range.start.row, lr = range.end.row;\n var guessRange = fr == lr;\n if (guessRange) {\n var max = this.session.getLength();\n var line;\n do {\n line = this.session.getLine(lr);\n } while (/[=:]/.test(line) && ++lr < max);\n do {\n line = this.session.getLine(fr);\n } while (/[=:]/.test(line) && --fr > 0);\n if (fr < 0)\n fr = 0;\n if (lr >= max)\n lr = max - 1;\n }\n var lines = this.session.removeFullLines(fr, lr);\n lines = this.$reAlignText(lines, guessRange);\n this.session.insert({ row: fr, column: 0 }, lines.join(\"\\n\") + \"\\n\");\n if (!guessRange) {\n range.start.column = 0;\n range.end.column = lines[lines.length - 1].length;\n }\n this.selection.setRange(range);\n }\n else {\n sameRowRanges.forEach(function (r) {\n sel.substractPoint(r.cursor);\n });\n var maxCol = 0;\n var minSpace = Infinity;\n var spaceOffsets = ranges.map(function (r) {\n var p = r.cursor;\n var line = session.getLine(p.row);\n var spaceOffset = line.substr(p.column).search(/\\S/g);\n if (spaceOffset == -1)\n spaceOffset = 0;\n if (p.column > maxCol)\n maxCol = p.column;\n if (spaceOffset < minSpace)\n minSpace = spaceOffset;\n return spaceOffset;\n });\n ranges.forEach(function (r, i) {\n var p = r.cursor;\n var l = maxCol - p.column;\n var d = spaceOffsets[i] - minSpace;\n if (l > d)\n session.insert(p, lang.stringRepeat(\" \", l - d));\n else\n session.remove(new Range(p.row, p.column, p.row, p.column - l + d));\n r.start.column = r.end.column = maxCol;\n r.start.row = r.end.row = p.row;\n r.cursor = r.end;\n });\n sel.fromOrientedRange(ranges[0]);\n this.renderer.updateCursor();\n this.renderer.updateBackMarkers();\n }\n };\n this.$reAlignText = function (lines, forceLeft) {\n var isLeftAligned = true, isRightAligned = true;\n var startW, textW, endW;\n return lines.map(function (line) {\n var m = line.match(/(\\s*)(.*?)(\\s*)([=:].*)/);\n if (!m)\n return [line];\n if (startW == null) {\n startW = m[1].length;\n textW = m[2].length;\n endW = m[3].length;\n return m;\n }\n if (startW + textW + endW != m[1].length + m[2].length + m[3].length)\n isRightAligned = false;\n if (startW != m[1].length)\n isLeftAligned = false;\n if (startW > m[1].length)\n startW = m[1].length;\n if (textW < m[2].length)\n textW = m[2].length;\n if (endW > m[3].length)\n endW = m[3].length;\n return m;\n }).map(forceLeft ? alignLeft :\n isLeftAligned ? isRightAligned ? alignRight : alignLeft : unAlign);\n function spaces(n) {\n return lang.stringRepeat(\" \", n);\n }\n function alignLeft(m) {\n return !m[2] ? m[0] : spaces(startW) + m[2]\n + spaces(textW - m[2].length + endW)\n + m[4].replace(/^([=:])\\s+/, \"$1 \");\n }\n function alignRight(m) {\n return !m[2] ? m[0] : spaces(startW + textW - m[2].length) + m[2]\n + spaces(endW)\n + m[4].replace(/^([=:])\\s+/, \"$1 \");\n }\n function unAlign(m) {\n return !m[2] ? m[0] : spaces(startW) + m[2]\n + spaces(endW)\n + m[4].replace(/^([=:])\\s+/, \"$1 \");\n }\n };\n}).call(Editor.prototype);\nfunction isSamePoint(p1, p2) {\n return p1.row == p2.row && p1.column == p2.column;\n}\nexports.onSessionChange = function (e) {\n var session = e.session;\n if (session && !session.multiSelect) {\n session.$selectionMarkers = [];\n session.selection.$initRangeList();\n session.multiSelect = session.selection;\n }\n this.multiSelect = session && session.multiSelect;\n var oldSession = e.oldSession;\n if (oldSession) {\n oldSession.multiSelect.off(\"addRange\", this.$onAddRange);\n oldSession.multiSelect.off(\"removeRange\", this.$onRemoveRange);\n oldSession.multiSelect.off(\"multiSelect\", this.$onMultiSelect);\n oldSession.multiSelect.off(\"singleSelect\", this.$onSingleSelect);\n oldSession.multiSelect.lead.off(\"change\", this.$checkMultiselectChange);\n oldSession.multiSelect.anchor.off(\"change\", this.$checkMultiselectChange);\n }\n if (session) {\n session.multiSelect.on(\"addRange\", this.$onAddRange);\n session.multiSelect.on(\"removeRange\", this.$onRemoveRange);\n session.multiSelect.on(\"multiSelect\", this.$onMultiSelect);\n session.multiSelect.on(\"singleSelect\", this.$onSingleSelect);\n session.multiSelect.lead.on(\"change\", this.$checkMultiselectChange);\n session.multiSelect.anchor.on(\"change\", this.$checkMultiselectChange);\n }\n if (session && this.inMultiSelectMode != session.selection.inMultiSelectMode) {\n if (session.selection.inMultiSelectMode)\n this.$onMultiSelect();\n else\n this.$onSingleSelect();\n }\n};\nfunction MultiSelect(editor) {\n if (editor.$multiselectOnSessionChange)\n return;\n editor.$onAddRange = editor.$onAddRange.bind(editor);\n editor.$onRemoveRange = editor.$onRemoveRange.bind(editor);\n editor.$onMultiSelect = editor.$onMultiSelect.bind(editor);\n editor.$onSingleSelect = editor.$onSingleSelect.bind(editor);\n editor.$multiselectOnSessionChange = exports.onSessionChange.bind(editor);\n editor.$checkMultiselectChange = editor.$checkMultiselectChange.bind(editor);\n editor.$multiselectOnSessionChange(editor);\n editor.on(\"changeSession\", editor.$multiselectOnSessionChange);\n editor.on(\"mousedown\", onMouseDown);\n editor.commands.addCommands(commands.defaultCommands);\n addAltCursorListeners(editor);\n}\nfunction addAltCursorListeners(editor) {\n if (!editor.textInput)\n return;\n var el = editor.textInput.getElement();\n var altCursor = false;\n event.addListener(el, \"keydown\", function (e) {\n var altDown = e.keyCode == 18 && !(e.ctrlKey || e.shiftKey || e.metaKey);\n if (editor.$blockSelectEnabled && altDown) {\n if (!altCursor) {\n editor.renderer.setMouseCursor(\"crosshair\");\n altCursor = true;\n }\n }\n else if (altCursor) {\n reset();\n }\n }, editor);\n event.addListener(el, \"keyup\", reset, editor);\n event.addListener(el, \"blur\", reset, editor);\n function reset(e) {\n if (altCursor) {\n editor.renderer.setMouseCursor(\"\");\n altCursor = false;\n }\n }\n}\nexports.MultiSelect = MultiSelect;\nrequire(\"./config\").defineOptions(Editor.prototype, \"editor\", {\n enableMultiselect: {\n set: function (val) {\n MultiSelect(this);\n if (val) {\n this.on(\"mousedown\", onMouseDown);\n }\n else {\n this.off(\"mousedown\", onMouseDown);\n }\n },\n value: true\n },\n enableBlockSelect: {\n set: function (val) {\n this.$blockSelectEnabled = val;\n },\n value: true\n }\n});\n\n});\n\nace.define(\"ace/mode/folding/fold_mode\",[\"require\",\"exports\",\"module\",\"ace/range\"], function(require, exports, module){\"use strict\";\nvar Range = require(\"../../range\").Range;\nvar FoldMode = exports.FoldMode = function () { };\n(function () {\n this.foldingStartMarker = null;\n this.foldingStopMarker = null;\n this.getFoldWidget = function (session, foldStyle, row) {\n var line = session.getLine(row);\n if (this.foldingStartMarker.test(line))\n return \"start\";\n if (foldStyle == \"markbeginend\"\n && this.foldingStopMarker\n && this.foldingStopMarker.test(line))\n return \"end\";\n return \"\";\n };\n this.getFoldWidgetRange = function (session, foldStyle, row) {\n return null;\n };\n this.indentationBlock = function (session, row, column) {\n var re = /\\S/;\n var line = session.getLine(row);\n var startLevel = line.search(re);\n if (startLevel == -1)\n return;\n var startColumn = column || line.length;\n var maxRow = session.getLength();\n var startRow = row;\n var endRow = row;\n while (++row < maxRow) {\n var level = session.getLine(row).search(re);\n if (level == -1)\n continue;\n if (level <= startLevel) {\n var token = session.getTokenAt(row, 0);\n if (!token || token.type !== \"string\")\n break;\n }\n endRow = row;\n }\n if (endRow > startRow) {\n var endColumn = session.getLine(endRow).length;\n return new Range(startRow, startColumn, endRow, endColumn);\n }\n };\n this.openingBracketBlock = function (session, bracket, row, column, typeRe) {\n var start = { row: row, column: column + 1 };\n var end = session.$findClosingBracket(bracket, start, typeRe);\n if (!end)\n return;\n var fw = session.foldWidgets[end.row];\n if (fw == null)\n fw = session.getFoldWidget(end.row);\n if (fw == \"start\" && end.row > start.row) {\n end.row--;\n end.column = session.getLine(end.row).length;\n }\n return Range.fromPoints(start, end);\n };\n this.closingBracketBlock = function (session, bracket, row, column, typeRe) {\n var end = { row: row, column: column };\n var start = session.$findOpeningBracket(bracket, end);\n if (!start)\n return;\n start.column++;\n end.column--;\n return Range.fromPoints(start, end);\n };\n}).call(FoldMode.prototype);\n\n});\n\nace.define(\"ace/ext/error_marker\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\",\"ace/range\",\"ace/config\"], function(require, exports, module){\"use strict\";\nvar dom = require(\"../lib/dom\");\nvar Range = require(\"../range\").Range;\nvar nls = require(\"../config\").nls;\nfunction binarySearch(array, needle, comparator) {\n var first = 0;\n var last = array.length - 1;\n while (first <= last) {\n var mid = (first + last) >> 1;\n var c = comparator(needle, array[mid]);\n if (c > 0)\n first = mid + 1;\n else if (c < 0)\n last = mid - 1;\n else\n return mid;\n }\n return -(first + 1);\n}\nfunction findAnnotations(session, row, dir) {\n var annotations = session.getAnnotations().sort(Range.comparePoints);\n if (!annotations.length)\n return;\n var i = binarySearch(annotations, { row: row, column: -1 }, Range.comparePoints);\n if (i < 0)\n i = -i - 1;\n if (i >= annotations.length)\n i = dir > 0 ? 0 : annotations.length - 1;\n else if (i === 0 && dir < 0)\n i = annotations.length - 1;\n var annotation = annotations[i];\n if (!annotation || !dir)\n return;\n if (annotation.row === row) {\n do {\n annotation = annotations[i += dir];\n } while (annotation && annotation.row === row);\n if (!annotation)\n return annotations.slice();\n }\n var matched = [];\n row = annotation.row;\n do {\n matched[dir < 0 ? \"unshift\" : \"push\"](annotation);\n annotation = annotations[i += dir];\n } while (annotation && annotation.row == row);\n return matched.length && matched;\n}\nexports.showErrorMarker = function (editor, dir) {\n var session = editor.session;\n var pos = editor.getCursorPosition();\n var row = pos.row;\n var oldWidget = session.widgetManager.getWidgetsAtRow(row).filter(function (w) {\n return w.type == \"errorMarker\";\n })[0];\n if (oldWidget) {\n oldWidget.destroy();\n }\n else {\n row -= dir;\n }\n var annotations = findAnnotations(session, row, dir);\n var gutterAnno;\n if (annotations) {\n var annotation = annotations[0];\n pos.column = (annotation.pos && typeof annotation.column != \"number\"\n ? annotation.pos.sc\n : annotation.column) || 0;\n pos.row = annotation.row;\n gutterAnno = editor.renderer.$gutterLayer.$annotations[pos.row];\n }\n else if (oldWidget) {\n return;\n }\n else {\n gutterAnno = {\n displayText: [nls(\"error-marker.good-state\", \"Looks good!\")],\n className: \"ace_ok\"\n };\n }\n editor.session.unfold(pos.row);\n editor.selection.moveToPosition(pos);\n var w = {\n row: pos.row,\n fixedWidth: true,\n coverGutter: true,\n el: dom.createElement(\"div\"),\n type: \"errorMarker\"\n };\n var el = w.el.appendChild(dom.createElement(\"div\"));\n var arrow = w.el.appendChild(dom.createElement(\"div\"));\n arrow.className = \"error_widget_arrow \" + gutterAnno.className;\n var left = editor.renderer.$cursorLayer\n .getPixelPosition(pos).left;\n arrow.style.left = left + editor.renderer.gutterWidth - 5 + \"px\";\n w.el.className = \"error_widget_wrapper\";\n el.className = \"error_widget \" + gutterAnno.className;\n gutterAnno.displayText.forEach(function (annoTextLine, i) {\n el.appendChild(dom.createTextNode(annoTextLine));\n if (i < gutterAnno.displayText.length - 1) {\n el.appendChild(dom.createElement(\"br\"));\n }\n });\n el.appendChild(dom.createElement(\"div\"));\n var kb = function (_, hashId, keyString) {\n if (hashId === 0 && (keyString === \"esc\" || keyString === \"return\")) {\n w.destroy();\n return { command: \"null\" };\n }\n };\n w.destroy = function () {\n if (editor.$mouseHandler.isMousePressed)\n return;\n editor.keyBinding.removeKeyboardHandler(kb);\n session.widgetManager.removeLineWidget(w);\n editor.off(\"changeSelection\", w.destroy);\n editor.off(\"changeSession\", w.destroy);\n editor.off(\"mouseup\", w.destroy);\n editor.off(\"change\", w.destroy);\n };\n editor.keyBinding.addKeyboardHandler(kb);\n editor.on(\"changeSelection\", w.destroy);\n editor.on(\"changeSession\", w.destroy);\n editor.on(\"mouseup\", w.destroy);\n editor.on(\"change\", w.destroy);\n editor.session.widgetManager.addLineWidget(w);\n w.el.onmousedown = editor.focus.bind(editor);\n editor.renderer.scrollCursorIntoView(null, 0.5, { bottom: w.el.offsetHeight });\n};\ndom.importCssString(\"\\n .error_widget_wrapper {\\n background: inherit;\\n color: inherit;\\n border:none\\n }\\n .error_widget {\\n border-top: solid 2px;\\n border-bottom: solid 2px;\\n margin: 5px 0;\\n padding: 10px 40px;\\n white-space: pre-wrap;\\n }\\n .error_widget.ace_error, .error_widget_arrow.ace_error{\\n border-color: #ff5a5a\\n }\\n .error_widget.ace_warning, .error_widget_arrow.ace_warning{\\n border-color: #F1D817\\n }\\n .error_widget.ace_info, .error_widget_arrow.ace_info{\\n border-color: #5a5a5a\\n }\\n .error_widget.ace_ok, .error_widget_arrow.ace_ok{\\n border-color: #5aaa5a\\n }\\n .error_widget_arrow {\\n position: absolute;\\n border: solid 5px;\\n border-top-color: transparent!important;\\n border-right-color: transparent!important;\\n border-left-color: transparent!important;\\n top: -5px;\\n }\\n\", \"error_marker.css\", false);\n\n});\n\nace.define(\"ace/ace\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\",\"ace/range\",\"ace/editor\",\"ace/edit_session\",\"ace/undomanager\",\"ace/virtual_renderer\",\"ace/worker/worker_client\",\"ace/keyboard/hash_handler\",\"ace/placeholder\",\"ace/multi_select\",\"ace/mode/folding/fold_mode\",\"ace/theme/textmate\",\"ace/ext/error_marker\",\"ace/config\",\"ace/loader_build\"], function(require, exports, module){/**\n * The main class required to set up an Ace instance in the browser.\n *\n * @namespace Ace\n **/\n\"use strict\";\nrequire(\"./loader_build\")(exports)\nvar dom = require(\"./lib/dom\");\nvar Range = require(\"./range\").Range;\nvar Editor = require(\"./editor\").Editor;\nvar EditSession = require(\"./edit_session\").EditSession;\nvar UndoManager = require(\"./undomanager\").UndoManager;\nvar Renderer = require(\"./virtual_renderer\").VirtualRenderer;\nrequire(\"./worker/worker_client\");\nrequire(\"./keyboard/hash_handler\");\nrequire(\"./placeholder\");\nrequire(\"./multi_select\");\nrequire(\"./mode/folding/fold_mode\");\nrequire(\"./theme/textmate\");\nrequire(\"./ext/error_marker\");\nexports.config = require(\"./config\");\nexports.edit = function (el, options) {\n if (typeof el == \"string\") {\n var _id = el;\n el = document.getElementById(_id);\n if (!el)\n throw new Error(\"ace.edit can't find div #\" + _id);\n }\n if (el && el.env && el.env.editor instanceof Editor)\n return el.env.editor;\n var value = \"\";\n if (el && /input|textarea/i.test(el.tagName)) {\n var oldNode = el;\n value = oldNode.value;\n el = dom.createElement(\"pre\");\n oldNode.parentNode.replaceChild(el, oldNode);\n }\n else if (el) {\n value = el.textContent;\n el.innerHTML = \"\";\n }\n var doc = exports.createEditSession(value);\n var editor = new Editor(new Renderer(el), doc, options);\n var env = {\n document: doc,\n editor: editor,\n onResize: editor.resize.bind(editor, null)\n };\n if (oldNode)\n env.textarea = oldNode;\n editor.on(\"destroy\", function () {\n env.editor.container.env = null; // prevent memory leak on old ie\n });\n editor.container.env = editor.env = env;\n return editor;\n};\nexports.createEditSession = function (text, mode) {\n var doc = new EditSession(text, mode);\n doc.setUndoManager(new UndoManager());\n return doc;\n};\nexports.Range = Range;\nexports.Editor = Editor;\nexports.EditSession = EditSession;\nexports.UndoManager = UndoManager;\nexports.VirtualRenderer = Renderer;\nvar version = exports.config.version;\nexports.version = version;\n\n}); (function() {\n ace.require([\"ace/ace\"], function(a) {\n if (a) {\n a.config.init(true);\n a.define = ace.define;\n }\n var global = (function () {\n return this;\n })();\n if (!global && typeof window != \"undefined\") global = window; // can happen in strict mode\n if (!global && typeof self != \"undefined\") global = self; // can happen in webworker\n \n if (!global.ace)\n global.ace = a;\n for (var key in a) if (a.hasOwnProperty(key))\n global.ace[key] = a[key];\n global.ace[\"default\"] = global.ace;\n if (typeof module == \"object\" && typeof exports == \"object\" && module) {\n module.exports = global.ace;\n }\n });\n })();\n ","ace.define(\"ace/split\",[\"require\",\"exports\",\"module\",\"ace/lib/oop\",\"ace/lib/lang\",\"ace/lib/event_emitter\",\"ace/editor\",\"ace/virtual_renderer\",\"ace/edit_session\"], function(require, exports, module){\"use strict\";\nvar oop = require(\"./lib/oop\");\nvar lang = require(\"./lib/lang\");\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar Editor = require(\"./editor\").Editor;\nvar Renderer = require(\"./virtual_renderer\").VirtualRenderer;\nvar EditSession = require(\"./edit_session\").EditSession;\nvar Split;\nSplit = function (container, theme, splits) {\n this.BELOW = 1;\n this.BESIDE = 0;\n this.$container = container;\n this.$theme = theme;\n this.$splits = 0;\n this.$editorCSS = \"\";\n this.$editors = [];\n this.$orientation = this.BESIDE;\n this.setSplits(splits || 1);\n this.$cEditor = this.$editors[0];\n this.on(\"focus\", function (editor) {\n this.$cEditor = editor;\n }.bind(this));\n};\n(function () {\n oop.implement(this, EventEmitter);\n this.$createEditor = function () {\n var el = document.createElement(\"div\");\n el.className = this.$editorCSS;\n el.style.cssText = \"position: absolute; top:0px; bottom:0px\";\n this.$container.appendChild(el);\n var editor = new Editor(new Renderer(el, this.$theme));\n editor.on(\"focus\", function () {\n this._emit(\"focus\", editor);\n }.bind(this));\n this.$editors.push(editor);\n editor.setFontSize(this.$fontSize);\n return editor;\n };\n this.setSplits = function (splits) {\n var editor;\n if (splits < 1) {\n throw \"The number of splits have to be > 0!\";\n }\n if (splits == this.$splits) {\n return;\n }\n else if (splits > this.$splits) {\n while (this.$splits < this.$editors.length && this.$splits < splits) {\n editor = this.$editors[this.$splits];\n this.$container.appendChild(editor.container);\n editor.setFontSize(this.$fontSize);\n this.$splits++;\n }\n while (this.$splits < splits) {\n this.$createEditor();\n this.$splits++;\n }\n }\n else {\n while (this.$splits > splits) {\n editor = this.$editors[this.$splits - 1];\n this.$container.removeChild(editor.container);\n this.$splits--;\n }\n }\n this.resize();\n };\n this.getSplits = function () {\n return this.$splits;\n };\n this.getEditor = function (idx) {\n return this.$editors[idx];\n };\n this.getCurrentEditor = function () {\n return this.$cEditor;\n };\n this.focus = function () {\n this.$cEditor.focus();\n };\n this.blur = function () {\n this.$cEditor.blur();\n };\n this.setTheme = function (theme) {\n this.$editors.forEach(function (editor) {\n editor.setTheme(theme);\n });\n };\n this.setKeyboardHandler = function (keybinding) {\n this.$editors.forEach(function (editor) {\n editor.setKeyboardHandler(keybinding);\n });\n };\n this.forEach = function (callback, scope) {\n this.$editors.forEach(callback, scope);\n };\n this.$fontSize = \"\";\n this.setFontSize = function (size) {\n this.$fontSize = size;\n this.forEach(function (editor) {\n editor.setFontSize(size);\n });\n };\n this.$cloneSession = function (session) {\n var s = new EditSession(session.getDocument(), session.getMode());\n var undoManager = session.getUndoManager();\n s.setUndoManager(undoManager);\n s.setTabSize(session.getTabSize());\n s.setUseSoftTabs(session.getUseSoftTabs());\n s.setOverwrite(session.getOverwrite());\n s.setBreakpoints(session.getBreakpoints());\n s.setUseWrapMode(session.getUseWrapMode());\n s.setUseWorker(session.getUseWorker());\n s.setWrapLimitRange(session.$wrapLimitRange.min, session.$wrapLimitRange.max);\n s.$foldData = session.$cloneFoldData();\n return s;\n };\n this.setSession = function (session, idx) {\n var editor;\n if (idx == null) {\n editor = this.$cEditor;\n }\n else {\n editor = this.$editors[idx];\n }\n var isUsed = this.$editors.some(function (editor) {\n return editor.session === session;\n });\n if (isUsed) {\n session = this.$cloneSession(session);\n }\n editor.setSession(session);\n return session;\n };\n this.getOrientation = function () {\n return this.$orientation;\n };\n this.setOrientation = function (orientation) {\n if (this.$orientation == orientation) {\n return;\n }\n this.$orientation = orientation;\n this.resize();\n };\n this.resize = function () {\n var width = this.$container.clientWidth;\n var height = this.$container.clientHeight;\n var editor;\n if (this.$orientation == this.BESIDE) {\n var editorWidth = width / this.$splits;\n for (var i = 0; i < this.$splits; i++) {\n editor = this.$editors[i];\n editor.container.style.width = editorWidth + \"px\";\n editor.container.style.top = \"0px\";\n editor.container.style.left = i * editorWidth + \"px\";\n editor.container.style.height = height + \"px\";\n editor.resize();\n }\n }\n else {\n var editorHeight = height / this.$splits;\n for (var i = 0; i < this.$splits; i++) {\n editor = this.$editors[i];\n editor.container.style.width = width + \"px\";\n editor.container.style.top = i * editorHeight + \"px\";\n editor.container.style.left = \"0px\";\n editor.container.style.height = editorHeight + \"px\";\n editor.resize();\n }\n }\n };\n}).call(Split.prototype);\nexports.Split = Split;\n\n});\n\nace.define(\"ace/ext/split\",[\"require\",\"exports\",\"module\",\"ace/split\"], function(require, exports, module){\"use strict\";\nmodule.exports = require(\"../split\");\n\n}); (function() {\n ace.require([\"ace/ext/split\"], function(m) {\n if (typeof module == \"object\" && typeof exports == \"object\" && module) {\n module.exports = m;\n }\n });\n })();\n ","/**\n * Diff Match and Patch\n * Copyright 2018 The diff-match-patch Authors.\n * https://github.com/google/diff-match-patch\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Computes the difference between two texts to create a patch.\n * Applies the patch onto another text, allowing for errors.\n * @author fraser@google.com (Neil Fraser)\n */\n\n/**\n * Class containing the diff, match and patch methods.\n * @constructor\n */\nvar diff_match_patch = function() {\n\n // Defaults.\n // Redefine these in your program to override the defaults.\n\n // Number of seconds to map a diff before giving up (0 for infinity).\n this.Diff_Timeout = 1.0;\n // Cost of an empty edit operation in terms of edit characters.\n this.Diff_EditCost = 4;\n // At what point is no match declared (0.0 = perfection, 1.0 = very loose).\n this.Match_Threshold = 0.5;\n // How far to search for a match (0 = exact location, 1000+ = broad match).\n // A match this many characters away from the expected location will add\n // 1.0 to the score (0.0 is a perfect match).\n this.Match_Distance = 1000;\n // When deleting a large block of text (over ~64 characters), how close do\n // the contents have to be to match the expected contents. (0.0 = perfection,\n // 1.0 = very loose). Note that Match_Threshold controls how closely the\n // end points of a delete need to match.\n this.Patch_DeleteThreshold = 0.5;\n // Chunk size for context length.\n this.Patch_Margin = 4;\n\n // The number of bits in an int.\n this.Match_MaxBits = 32;\n};\n\n\n// DIFF FUNCTIONS\n\n\n/**\n * The data structure representing a diff is an array of tuples:\n * [[DIFF_DELETE, 'Hello'], [DIFF_INSERT, 'Goodbye'], [DIFF_EQUAL, ' world.']]\n * which means: delete 'Hello', add 'Goodbye' and keep ' world.'\n */\nvar DIFF_DELETE = -1;\nvar DIFF_INSERT = 1;\nvar DIFF_EQUAL = 0;\n\n/**\n * Class representing one diff tuple.\n * ~Attempts to look like a two-element array (which is what this used to be).~\n * Constructor returns an actual two-element array, to allow destructing @JackuB\n * See https://github.com/JackuB/diff-match-patch/issues/14 for details\n * @param {number} op Operation, one of: DIFF_DELETE, DIFF_INSERT, DIFF_EQUAL.\n * @param {string} text Text to be deleted, inserted, or retained.\n * @constructor\n */\ndiff_match_patch.Diff = function(op, text) {\n return [op, text];\n};\n\n/**\n * Find the differences between two texts. Simplifies the problem by stripping\n * any common prefix or suffix off the texts before diffing.\n * @param {string} text1 Old string to be diffed.\n * @param {string} text2 New string to be diffed.\n * @param {boolean=} opt_checklines Optional speedup flag. If present and false,\n * then don't run a line-level diff first to identify the changed areas.\n * Defaults to true, which does a faster, slightly less optimal diff.\n * @param {number=} opt_deadline Optional time when the diff should be complete\n * by. Used internally for recursive calls. Users should set DiffTimeout\n * instead.\n * @return {!Array.} Array of diff tuples.\n */\ndiff_match_patch.prototype.diff_main = function(text1, text2, opt_checklines,\n opt_deadline) {\n // Set a deadline by which time the diff must be complete.\n if (typeof opt_deadline == 'undefined') {\n if (this.Diff_Timeout <= 0) {\n opt_deadline = Number.MAX_VALUE;\n } else {\n opt_deadline = (new Date).getTime() + this.Diff_Timeout * 1000;\n }\n }\n var deadline = opt_deadline;\n\n // Check for null inputs.\n if (text1 == null || text2 == null) {\n throw new Error('Null input. (diff_main)');\n }\n\n // Check for equality (speedup).\n if (text1 == text2) {\n if (text1) {\n return [new diff_match_patch.Diff(DIFF_EQUAL, text1)];\n }\n return [];\n }\n\n if (typeof opt_checklines == 'undefined') {\n opt_checklines = true;\n }\n var checklines = opt_checklines;\n\n // Trim off common prefix (speedup).\n var commonlength = this.diff_commonPrefix(text1, text2);\n var commonprefix = text1.substring(0, commonlength);\n text1 = text1.substring(commonlength);\n text2 = text2.substring(commonlength);\n\n // Trim off common suffix (speedup).\n commonlength = this.diff_commonSuffix(text1, text2);\n var commonsuffix = text1.substring(text1.length - commonlength);\n text1 = text1.substring(0, text1.length - commonlength);\n text2 = text2.substring(0, text2.length - commonlength);\n\n // Compute the diff on the middle block.\n var diffs = this.diff_compute_(text1, text2, checklines, deadline);\n\n // Restore the prefix and suffix.\n if (commonprefix) {\n diffs.unshift(new diff_match_patch.Diff(DIFF_EQUAL, commonprefix));\n }\n if (commonsuffix) {\n diffs.push(new diff_match_patch.Diff(DIFF_EQUAL, commonsuffix));\n }\n this.diff_cleanupMerge(diffs);\n return diffs;\n};\n\n\n/**\n * Find the differences between two texts. Assumes that the texts do not\n * have any common prefix or suffix.\n * @param {string} text1 Old string to be diffed.\n * @param {string} text2 New string to be diffed.\n * @param {boolean} checklines Speedup flag. If false, then don't run a\n * line-level diff first to identify the changed areas.\n * If true, then run a faster, slightly less optimal diff.\n * @param {number} deadline Time when the diff should be complete by.\n * @return {!Array.} Array of diff tuples.\n * @private\n */\ndiff_match_patch.prototype.diff_compute_ = function(text1, text2, checklines,\n deadline) {\n var diffs;\n\n if (!text1) {\n // Just add some text (speedup).\n return [new diff_match_patch.Diff(DIFF_INSERT, text2)];\n }\n\n if (!text2) {\n // Just delete some text (speedup).\n return [new diff_match_patch.Diff(DIFF_DELETE, text1)];\n }\n\n var longtext = text1.length > text2.length ? text1 : text2;\n var shorttext = text1.length > text2.length ? text2 : text1;\n var i = longtext.indexOf(shorttext);\n if (i != -1) {\n // Shorter text is inside the longer text (speedup).\n diffs = [new diff_match_patch.Diff(DIFF_INSERT, longtext.substring(0, i)),\n new diff_match_patch.Diff(DIFF_EQUAL, shorttext),\n new diff_match_patch.Diff(DIFF_INSERT,\n longtext.substring(i + shorttext.length))];\n // Swap insertions for deletions if diff is reversed.\n if (text1.length > text2.length) {\n diffs[0][0] = diffs[2][0] = DIFF_DELETE;\n }\n return diffs;\n }\n\n if (shorttext.length == 1) {\n // Single character string.\n // After the previous speedup, the character can't be an equality.\n return [new diff_match_patch.Diff(DIFF_DELETE, text1),\n new diff_match_patch.Diff(DIFF_INSERT, text2)];\n }\n\n // Check to see if the problem can be split in two.\n var hm = this.diff_halfMatch_(text1, text2);\n if (hm) {\n // A half-match was found, sort out the return data.\n var text1_a = hm[0];\n var text1_b = hm[1];\n var text2_a = hm[2];\n var text2_b = hm[3];\n var mid_common = hm[4];\n // Send both pairs off for separate processing.\n var diffs_a = this.diff_main(text1_a, text2_a, checklines, deadline);\n var diffs_b = this.diff_main(text1_b, text2_b, checklines, deadline);\n // Merge the results.\n return diffs_a.concat([new diff_match_patch.Diff(DIFF_EQUAL, mid_common)],\n diffs_b);\n }\n\n if (checklines && text1.length > 100 && text2.length > 100) {\n return this.diff_lineMode_(text1, text2, deadline);\n }\n\n return this.diff_bisect_(text1, text2, deadline);\n};\n\n\n/**\n * Do a quick line-level diff on both strings, then rediff the parts for\n * greater accuracy.\n * This speedup can produce non-minimal diffs.\n * @param {string} text1 Old string to be diffed.\n * @param {string} text2 New string to be diffed.\n * @param {number} deadline Time when the diff should be complete by.\n * @return {!Array.} Array of diff tuples.\n * @private\n */\ndiff_match_patch.prototype.diff_lineMode_ = function(text1, text2, deadline) {\n // Scan the text on a line-by-line basis first.\n var a = this.diff_linesToChars_(text1, text2);\n text1 = a.chars1;\n text2 = a.chars2;\n var linearray = a.lineArray;\n\n var diffs = this.diff_main(text1, text2, false, deadline);\n\n // Convert the diff back to original text.\n this.diff_charsToLines_(diffs, linearray);\n // Eliminate freak matches (e.g. blank lines)\n this.diff_cleanupSemantic(diffs);\n\n // Rediff any replacement blocks, this time character-by-character.\n // Add a dummy entry at the end.\n diffs.push(new diff_match_patch.Diff(DIFF_EQUAL, ''));\n var pointer = 0;\n var count_delete = 0;\n var count_insert = 0;\n var text_delete = '';\n var text_insert = '';\n while (pointer < diffs.length) {\n switch (diffs[pointer][0]) {\n case DIFF_INSERT:\n count_insert++;\n text_insert += diffs[pointer][1];\n break;\n case DIFF_DELETE:\n count_delete++;\n text_delete += diffs[pointer][1];\n break;\n case DIFF_EQUAL:\n // Upon reaching an equality, check for prior redundancies.\n if (count_delete >= 1 && count_insert >= 1) {\n // Delete the offending records and add the merged ones.\n diffs.splice(pointer - count_delete - count_insert,\n count_delete + count_insert);\n pointer = pointer - count_delete - count_insert;\n var subDiff =\n this.diff_main(text_delete, text_insert, false, deadline);\n for (var j = subDiff.length - 1; j >= 0; j--) {\n diffs.splice(pointer, 0, subDiff[j]);\n }\n pointer = pointer + subDiff.length;\n }\n count_insert = 0;\n count_delete = 0;\n text_delete = '';\n text_insert = '';\n break;\n }\n pointer++;\n }\n diffs.pop(); // Remove the dummy entry at the end.\n\n return diffs;\n};\n\n\n/**\n * Find the 'middle snake' of a diff, split the problem in two\n * and return the recursively constructed diff.\n * See Myers 1986 paper: An O(ND) Difference Algorithm and Its Variations.\n * @param {string} text1 Old string to be diffed.\n * @param {string} text2 New string to be diffed.\n * @param {number} deadline Time at which to bail if not yet complete.\n * @return {!Array.} Array of diff tuples.\n * @private\n */\ndiff_match_patch.prototype.diff_bisect_ = function(text1, text2, deadline) {\n // Cache the text lengths to prevent multiple calls.\n var text1_length = text1.length;\n var text2_length = text2.length;\n var max_d = Math.ceil((text1_length + text2_length) / 2);\n var v_offset = max_d;\n var v_length = 2 * max_d;\n var v1 = new Array(v_length);\n var v2 = new Array(v_length);\n // Setting all elements to -1 is faster in Chrome & Firefox than mixing\n // integers and undefined.\n for (var x = 0; x < v_length; x++) {\n v1[x] = -1;\n v2[x] = -1;\n }\n v1[v_offset + 1] = 0;\n v2[v_offset + 1] = 0;\n var delta = text1_length - text2_length;\n // If the total number of characters is odd, then the front path will collide\n // with the reverse path.\n var front = (delta % 2 != 0);\n // Offsets for start and end of k loop.\n // Prevents mapping of space beyond the grid.\n var k1start = 0;\n var k1end = 0;\n var k2start = 0;\n var k2end = 0;\n for (var d = 0; d < max_d; d++) {\n // Bail out if deadline is reached.\n if ((new Date()).getTime() > deadline) {\n break;\n }\n\n // Walk the front path one step.\n for (var k1 = -d + k1start; k1 <= d - k1end; k1 += 2) {\n var k1_offset = v_offset + k1;\n var x1;\n if (k1 == -d || (k1 != d && v1[k1_offset - 1] < v1[k1_offset + 1])) {\n x1 = v1[k1_offset + 1];\n } else {\n x1 = v1[k1_offset - 1] + 1;\n }\n var y1 = x1 - k1;\n while (x1 < text1_length && y1 < text2_length &&\n text1.charAt(x1) == text2.charAt(y1)) {\n x1++;\n y1++;\n }\n v1[k1_offset] = x1;\n if (x1 > text1_length) {\n // Ran off the right of the graph.\n k1end += 2;\n } else if (y1 > text2_length) {\n // Ran off the bottom of the graph.\n k1start += 2;\n } else if (front) {\n var k2_offset = v_offset + delta - k1;\n if (k2_offset >= 0 && k2_offset < v_length && v2[k2_offset] != -1) {\n // Mirror x2 onto top-left coordinate system.\n var x2 = text1_length - v2[k2_offset];\n if (x1 >= x2) {\n // Overlap detected.\n return this.diff_bisectSplit_(text1, text2, x1, y1, deadline);\n }\n }\n }\n }\n\n // Walk the reverse path one step.\n for (var k2 = -d + k2start; k2 <= d - k2end; k2 += 2) {\n var k2_offset = v_offset + k2;\n var x2;\n if (k2 == -d || (k2 != d && v2[k2_offset - 1] < v2[k2_offset + 1])) {\n x2 = v2[k2_offset + 1];\n } else {\n x2 = v2[k2_offset - 1] + 1;\n }\n var y2 = x2 - k2;\n while (x2 < text1_length && y2 < text2_length &&\n text1.charAt(text1_length - x2 - 1) ==\n text2.charAt(text2_length - y2 - 1)) {\n x2++;\n y2++;\n }\n v2[k2_offset] = x2;\n if (x2 > text1_length) {\n // Ran off the left of the graph.\n k2end += 2;\n } else if (y2 > text2_length) {\n // Ran off the top of the graph.\n k2start += 2;\n } else if (!front) {\n var k1_offset = v_offset + delta - k2;\n if (k1_offset >= 0 && k1_offset < v_length && v1[k1_offset] != -1) {\n var x1 = v1[k1_offset];\n var y1 = v_offset + x1 - k1_offset;\n // Mirror x2 onto top-left coordinate system.\n x2 = text1_length - x2;\n if (x1 >= x2) {\n // Overlap detected.\n return this.diff_bisectSplit_(text1, text2, x1, y1, deadline);\n }\n }\n }\n }\n }\n // Diff took too long and hit the deadline or\n // number of diffs equals number of characters, no commonality at all.\n return [new diff_match_patch.Diff(DIFF_DELETE, text1),\n new diff_match_patch.Diff(DIFF_INSERT, text2)];\n};\n\n\n/**\n * Given the location of the 'middle snake', split the diff in two parts\n * and recurse.\n * @param {string} text1 Old string to be diffed.\n * @param {string} text2 New string to be diffed.\n * @param {number} x Index of split point in text1.\n * @param {number} y Index of split point in text2.\n * @param {number} deadline Time at which to bail if not yet complete.\n * @return {!Array.} Array of diff tuples.\n * @private\n */\ndiff_match_patch.prototype.diff_bisectSplit_ = function(text1, text2, x, y,\n deadline) {\n var text1a = text1.substring(0, x);\n var text2a = text2.substring(0, y);\n var text1b = text1.substring(x);\n var text2b = text2.substring(y);\n\n // Compute both diffs serially.\n var diffs = this.diff_main(text1a, text2a, false, deadline);\n var diffsb = this.diff_main(text1b, text2b, false, deadline);\n\n return diffs.concat(diffsb);\n};\n\n\n/**\n * Split two texts into an array of strings. Reduce the texts to a string of\n * hashes where each Unicode character represents one line.\n * @param {string} text1 First string.\n * @param {string} text2 Second string.\n * @return {{chars1: string, chars2: string, lineArray: !Array.}}\n * An object containing the encoded text1, the encoded text2 and\n * the array of unique strings.\n * The zeroth element of the array of unique strings is intentionally blank.\n * @private\n */\ndiff_match_patch.prototype.diff_linesToChars_ = function(text1, text2) {\n var lineArray = []; // e.g. lineArray[4] == 'Hello\\n'\n var lineHash = {}; // e.g. lineHash['Hello\\n'] == 4\n\n // '\\x00' is a valid character, but various debuggers don't like it.\n // So we'll insert a junk entry to avoid generating a null character.\n lineArray[0] = '';\n\n /**\n * Split a text into an array of strings. Reduce the texts to a string of\n * hashes where each Unicode character represents one line.\n * Modifies linearray and linehash through being a closure.\n * @param {string} text String to encode.\n * @return {string} Encoded string.\n * @private\n */\n function diff_linesToCharsMunge_(text) {\n var chars = '';\n // Walk the text, pulling out a substring for each line.\n // text.split('\\n') would would temporarily double our memory footprint.\n // Modifying text would create many large strings to garbage collect.\n var lineStart = 0;\n var lineEnd = -1;\n // Keeping our own length variable is faster than looking it up.\n var lineArrayLength = lineArray.length;\n while (lineEnd < text.length - 1) {\n lineEnd = text.indexOf('\\n', lineStart);\n if (lineEnd == -1) {\n lineEnd = text.length - 1;\n }\n var line = text.substring(lineStart, lineEnd + 1);\n\n if (lineHash.hasOwnProperty ? lineHash.hasOwnProperty(line) :\n (lineHash[line] !== undefined)) {\n chars += String.fromCharCode(lineHash[line]);\n } else {\n if (lineArrayLength == maxLines) {\n // Bail out at 65535 because\n // String.fromCharCode(65536) == String.fromCharCode(0)\n line = text.substring(lineStart);\n lineEnd = text.length;\n }\n chars += String.fromCharCode(lineArrayLength);\n lineHash[line] = lineArrayLength;\n lineArray[lineArrayLength++] = line;\n }\n lineStart = lineEnd + 1;\n }\n return chars;\n }\n // Allocate 2/3rds of the space for text1, the rest for text2.\n var maxLines = 40000;\n var chars1 = diff_linesToCharsMunge_(text1);\n maxLines = 65535;\n var chars2 = diff_linesToCharsMunge_(text2);\n return {chars1: chars1, chars2: chars2, lineArray: lineArray};\n};\n\n\n/**\n * Rehydrate the text in a diff from a string of line hashes to real lines of\n * text.\n * @param {!Array.} diffs Array of diff tuples.\n * @param {!Array.} lineArray Array of unique strings.\n * @private\n */\ndiff_match_patch.prototype.diff_charsToLines_ = function(diffs, lineArray) {\n for (var i = 0; i < diffs.length; i++) {\n var chars = diffs[i][1];\n var text = [];\n for (var j = 0; j < chars.length; j++) {\n text[j] = lineArray[chars.charCodeAt(j)];\n }\n diffs[i][1] = text.join('');\n }\n};\n\n\n/**\n * Determine the common prefix of two strings.\n * @param {string} text1 First string.\n * @param {string} text2 Second string.\n * @return {number} The number of characters common to the start of each\n * string.\n */\ndiff_match_patch.prototype.diff_commonPrefix = function(text1, text2) {\n // Quick check for common null cases.\n if (!text1 || !text2 || text1.charAt(0) != text2.charAt(0)) {\n return 0;\n }\n // Binary search.\n // Performance analysis: https://neil.fraser.name/news/2007/10/09/\n var pointermin = 0;\n var pointermax = Math.min(text1.length, text2.length);\n var pointermid = pointermax;\n var pointerstart = 0;\n while (pointermin < pointermid) {\n if (text1.substring(pointerstart, pointermid) ==\n text2.substring(pointerstart, pointermid)) {\n pointermin = pointermid;\n pointerstart = pointermin;\n } else {\n pointermax = pointermid;\n }\n pointermid = Math.floor((pointermax - pointermin) / 2 + pointermin);\n }\n return pointermid;\n};\n\n\n/**\n * Determine the common suffix of two strings.\n * @param {string} text1 First string.\n * @param {string} text2 Second string.\n * @return {number} The number of characters common to the end of each string.\n */\ndiff_match_patch.prototype.diff_commonSuffix = function(text1, text2) {\n // Quick check for common null cases.\n if (!text1 || !text2 ||\n text1.charAt(text1.length - 1) != text2.charAt(text2.length - 1)) {\n return 0;\n }\n // Binary search.\n // Performance analysis: https://neil.fraser.name/news/2007/10/09/\n var pointermin = 0;\n var pointermax = Math.min(text1.length, text2.length);\n var pointermid = pointermax;\n var pointerend = 0;\n while (pointermin < pointermid) {\n if (text1.substring(text1.length - pointermid, text1.length - pointerend) ==\n text2.substring(text2.length - pointermid, text2.length - pointerend)) {\n pointermin = pointermid;\n pointerend = pointermin;\n } else {\n pointermax = pointermid;\n }\n pointermid = Math.floor((pointermax - pointermin) / 2 + pointermin);\n }\n return pointermid;\n};\n\n\n/**\n * Determine if the suffix of one string is the prefix of another.\n * @param {string} text1 First string.\n * @param {string} text2 Second string.\n * @return {number} The number of characters common to the end of the first\n * string and the start of the second string.\n * @private\n */\ndiff_match_patch.prototype.diff_commonOverlap_ = function(text1, text2) {\n // Cache the text lengths to prevent multiple calls.\n var text1_length = text1.length;\n var text2_length = text2.length;\n // Eliminate the null case.\n if (text1_length == 0 || text2_length == 0) {\n return 0;\n }\n // Truncate the longer string.\n if (text1_length > text2_length) {\n text1 = text1.substring(text1_length - text2_length);\n } else if (text1_length < text2_length) {\n text2 = text2.substring(0, text1_length);\n }\n var text_length = Math.min(text1_length, text2_length);\n // Quick check for the worst case.\n if (text1 == text2) {\n return text_length;\n }\n\n // Start by looking for a single character match\n // and increase length until no match is found.\n // Performance analysis: https://neil.fraser.name/news/2010/11/04/\n var best = 0;\n var length = 1;\n while (true) {\n var pattern = text1.substring(text_length - length);\n var found = text2.indexOf(pattern);\n if (found == -1) {\n return best;\n }\n length += found;\n if (found == 0 || text1.substring(text_length - length) ==\n text2.substring(0, length)) {\n best = length;\n length++;\n }\n }\n};\n\n\n/**\n * Do the two texts share a substring which is at least half the length of the\n * longer text?\n * This speedup can produce non-minimal diffs.\n * @param {string} text1 First string.\n * @param {string} text2 Second string.\n * @return {Array.} Five element Array, containing the prefix of\n * text1, the suffix of text1, the prefix of text2, the suffix of\n * text2 and the common middle. Or null if there was no match.\n * @private\n */\ndiff_match_patch.prototype.diff_halfMatch_ = function(text1, text2) {\n if (this.Diff_Timeout <= 0) {\n // Don't risk returning a non-optimal diff if we have unlimited time.\n return null;\n }\n var longtext = text1.length > text2.length ? text1 : text2;\n var shorttext = text1.length > text2.length ? text2 : text1;\n if (longtext.length < 4 || shorttext.length * 2 < longtext.length) {\n return null; // Pointless.\n }\n var dmp = this; // 'this' becomes 'window' in a closure.\n\n /**\n * Does a substring of shorttext exist within longtext such that the substring\n * is at least half the length of longtext?\n * Closure, but does not reference any external variables.\n * @param {string} longtext Longer string.\n * @param {string} shorttext Shorter string.\n * @param {number} i Start index of quarter length substring within longtext.\n * @return {Array.} Five element Array, containing the prefix of\n * longtext, the suffix of longtext, the prefix of shorttext, the suffix\n * of shorttext and the common middle. Or null if there was no match.\n * @private\n */\n function diff_halfMatchI_(longtext, shorttext, i) {\n // Start with a 1/4 length substring at position i as a seed.\n var seed = longtext.substring(i, i + Math.floor(longtext.length / 4));\n var j = -1;\n var best_common = '';\n var best_longtext_a, best_longtext_b, best_shorttext_a, best_shorttext_b;\n while ((j = shorttext.indexOf(seed, j + 1)) != -1) {\n var prefixLength = dmp.diff_commonPrefix(longtext.substring(i),\n shorttext.substring(j));\n var suffixLength = dmp.diff_commonSuffix(longtext.substring(0, i),\n shorttext.substring(0, j));\n if (best_common.length < suffixLength + prefixLength) {\n best_common = shorttext.substring(j - suffixLength, j) +\n shorttext.substring(j, j + prefixLength);\n best_longtext_a = longtext.substring(0, i - suffixLength);\n best_longtext_b = longtext.substring(i + prefixLength);\n best_shorttext_a = shorttext.substring(0, j - suffixLength);\n best_shorttext_b = shorttext.substring(j + prefixLength);\n }\n }\n if (best_common.length * 2 >= longtext.length) {\n return [best_longtext_a, best_longtext_b,\n best_shorttext_a, best_shorttext_b, best_common];\n } else {\n return null;\n }\n }\n\n // First check if the second quarter is the seed for a half-match.\n var hm1 = diff_halfMatchI_(longtext, shorttext,\n Math.ceil(longtext.length / 4));\n // Check again based on the third quarter.\n var hm2 = diff_halfMatchI_(longtext, shorttext,\n Math.ceil(longtext.length / 2));\n var hm;\n if (!hm1 && !hm2) {\n return null;\n } else if (!hm2) {\n hm = hm1;\n } else if (!hm1) {\n hm = hm2;\n } else {\n // Both matched. Select the longest.\n hm = hm1[4].length > hm2[4].length ? hm1 : hm2;\n }\n\n // A half-match was found, sort out the return data.\n var text1_a, text1_b, text2_a, text2_b;\n if (text1.length > text2.length) {\n text1_a = hm[0];\n text1_b = hm[1];\n text2_a = hm[2];\n text2_b = hm[3];\n } else {\n text2_a = hm[0];\n text2_b = hm[1];\n text1_a = hm[2];\n text1_b = hm[3];\n }\n var mid_common = hm[4];\n return [text1_a, text1_b, text2_a, text2_b, mid_common];\n};\n\n\n/**\n * Reduce the number of edits by eliminating semantically trivial equalities.\n * @param {!Array.} diffs Array of diff tuples.\n */\ndiff_match_patch.prototype.diff_cleanupSemantic = function(diffs) {\n var changes = false;\n var equalities = []; // Stack of indices where equalities are found.\n var equalitiesLength = 0; // Keeping our own length var is faster in JS.\n /** @type {?string} */\n var lastEquality = null;\n // Always equal to diffs[equalities[equalitiesLength - 1]][1]\n var pointer = 0; // Index of current position.\n // Number of characters that changed prior to the equality.\n var length_insertions1 = 0;\n var length_deletions1 = 0;\n // Number of characters that changed after the equality.\n var length_insertions2 = 0;\n var length_deletions2 = 0;\n while (pointer < diffs.length) {\n if (diffs[pointer][0] == DIFF_EQUAL) { // Equality found.\n equalities[equalitiesLength++] = pointer;\n length_insertions1 = length_insertions2;\n length_deletions1 = length_deletions2;\n length_insertions2 = 0;\n length_deletions2 = 0;\n lastEquality = diffs[pointer][1];\n } else { // An insertion or deletion.\n if (diffs[pointer][0] == DIFF_INSERT) {\n length_insertions2 += diffs[pointer][1].length;\n } else {\n length_deletions2 += diffs[pointer][1].length;\n }\n // Eliminate an equality that is smaller or equal to the edits on both\n // sides of it.\n if (lastEquality && (lastEquality.length <=\n Math.max(length_insertions1, length_deletions1)) &&\n (lastEquality.length <= Math.max(length_insertions2,\n length_deletions2))) {\n // Duplicate record.\n diffs.splice(equalities[equalitiesLength - 1], 0,\n new diff_match_patch.Diff(DIFF_DELETE, lastEquality));\n // Change second copy to insert.\n diffs[equalities[equalitiesLength - 1] + 1][0] = DIFF_INSERT;\n // Throw away the equality we just deleted.\n equalitiesLength--;\n // Throw away the previous equality (it needs to be reevaluated).\n equalitiesLength--;\n pointer = equalitiesLength > 0 ? equalities[equalitiesLength - 1] : -1;\n length_insertions1 = 0; // Reset the counters.\n length_deletions1 = 0;\n length_insertions2 = 0;\n length_deletions2 = 0;\n lastEquality = null;\n changes = true;\n }\n }\n pointer++;\n }\n\n // Normalize the diff.\n if (changes) {\n this.diff_cleanupMerge(diffs);\n }\n this.diff_cleanupSemanticLossless(diffs);\n\n // Find any overlaps between deletions and insertions.\n // e.g: abcxxxxxxdef\n // -> abcxxxdef\n // e.g: xxxabcdefxxx\n // -> defxxxabc\n // Only extract an overlap if it is as big as the edit ahead or behind it.\n pointer = 1;\n while (pointer < diffs.length) {\n if (diffs[pointer - 1][0] == DIFF_DELETE &&\n diffs[pointer][0] == DIFF_INSERT) {\n var deletion = diffs[pointer - 1][1];\n var insertion = diffs[pointer][1];\n var overlap_length1 = this.diff_commonOverlap_(deletion, insertion);\n var overlap_length2 = this.diff_commonOverlap_(insertion, deletion);\n if (overlap_length1 >= overlap_length2) {\n if (overlap_length1 >= deletion.length / 2 ||\n overlap_length1 >= insertion.length / 2) {\n // Overlap found. Insert an equality and trim the surrounding edits.\n diffs.splice(pointer, 0, new diff_match_patch.Diff(DIFF_EQUAL,\n insertion.substring(0, overlap_length1)));\n diffs[pointer - 1][1] =\n deletion.substring(0, deletion.length - overlap_length1);\n diffs[pointer + 1][1] = insertion.substring(overlap_length1);\n pointer++;\n }\n } else {\n if (overlap_length2 >= deletion.length / 2 ||\n overlap_length2 >= insertion.length / 2) {\n // Reverse overlap found.\n // Insert an equality and swap and trim the surrounding edits.\n diffs.splice(pointer, 0, new diff_match_patch.Diff(DIFF_EQUAL,\n deletion.substring(0, overlap_length2)));\n diffs[pointer - 1][0] = DIFF_INSERT;\n diffs[pointer - 1][1] =\n insertion.substring(0, insertion.length - overlap_length2);\n diffs[pointer + 1][0] = DIFF_DELETE;\n diffs[pointer + 1][1] =\n deletion.substring(overlap_length2);\n pointer++;\n }\n }\n pointer++;\n }\n pointer++;\n }\n};\n\n\n/**\n * Look for single edits surrounded on both sides by equalities\n * which can be shifted sideways to align the edit to a word boundary.\n * e.g: The cat came. -> The cat came.\n * @param {!Array.} diffs Array of diff tuples.\n */\ndiff_match_patch.prototype.diff_cleanupSemanticLossless = function(diffs) {\n /**\n * Given two strings, compute a score representing whether the internal\n * boundary falls on logical boundaries.\n * Scores range from 6 (best) to 0 (worst).\n * Closure, but does not reference any external variables.\n * @param {string} one First string.\n * @param {string} two Second string.\n * @return {number} The score.\n * @private\n */\n function diff_cleanupSemanticScore_(one, two) {\n if (!one || !two) {\n // Edges are the best.\n return 6;\n }\n\n // Each port of this function behaves slightly differently due to\n // subtle differences in each language's definition of things like\n // 'whitespace'. Since this function's purpose is largely cosmetic,\n // the choice has been made to use each language's native features\n // rather than force total conformity.\n var char1 = one.charAt(one.length - 1);\n var char2 = two.charAt(0);\n var nonAlphaNumeric1 = char1.match(diff_match_patch.nonAlphaNumericRegex_);\n var nonAlphaNumeric2 = char2.match(diff_match_patch.nonAlphaNumericRegex_);\n var whitespace1 = nonAlphaNumeric1 &&\n char1.match(diff_match_patch.whitespaceRegex_);\n var whitespace2 = nonAlphaNumeric2 &&\n char2.match(diff_match_patch.whitespaceRegex_);\n var lineBreak1 = whitespace1 &&\n char1.match(diff_match_patch.linebreakRegex_);\n var lineBreak2 = whitespace2 &&\n char2.match(diff_match_patch.linebreakRegex_);\n var blankLine1 = lineBreak1 &&\n one.match(diff_match_patch.blanklineEndRegex_);\n var blankLine2 = lineBreak2 &&\n two.match(diff_match_patch.blanklineStartRegex_);\n\n if (blankLine1 || blankLine2) {\n // Five points for blank lines.\n return 5;\n } else if (lineBreak1 || lineBreak2) {\n // Four points for line breaks.\n return 4;\n } else if (nonAlphaNumeric1 && !whitespace1 && whitespace2) {\n // Three points for end of sentences.\n return 3;\n } else if (whitespace1 || whitespace2) {\n // Two points for whitespace.\n return 2;\n } else if (nonAlphaNumeric1 || nonAlphaNumeric2) {\n // One point for non-alphanumeric.\n return 1;\n }\n return 0;\n }\n\n var pointer = 1;\n // Intentionally ignore the first and last element (don't need checking).\n while (pointer < diffs.length - 1) {\n if (diffs[pointer - 1][0] == DIFF_EQUAL &&\n diffs[pointer + 1][0] == DIFF_EQUAL) {\n // This is a single edit surrounded by equalities.\n var equality1 = diffs[pointer - 1][1];\n var edit = diffs[pointer][1];\n var equality2 = diffs[pointer + 1][1];\n\n // First, shift the edit as far left as possible.\n var commonOffset = this.diff_commonSuffix(equality1, edit);\n if (commonOffset) {\n var commonString = edit.substring(edit.length - commonOffset);\n equality1 = equality1.substring(0, equality1.length - commonOffset);\n edit = commonString + edit.substring(0, edit.length - commonOffset);\n equality2 = commonString + equality2;\n }\n\n // Second, step character by character right, looking for the best fit.\n var bestEquality1 = equality1;\n var bestEdit = edit;\n var bestEquality2 = equality2;\n var bestScore = diff_cleanupSemanticScore_(equality1, edit) +\n diff_cleanupSemanticScore_(edit, equality2);\n while (edit.charAt(0) === equality2.charAt(0)) {\n equality1 += edit.charAt(0);\n edit = edit.substring(1) + equality2.charAt(0);\n equality2 = equality2.substring(1);\n var score = diff_cleanupSemanticScore_(equality1, edit) +\n diff_cleanupSemanticScore_(edit, equality2);\n // The >= encourages trailing rather than leading whitespace on edits.\n if (score >= bestScore) {\n bestScore = score;\n bestEquality1 = equality1;\n bestEdit = edit;\n bestEquality2 = equality2;\n }\n }\n\n if (diffs[pointer - 1][1] != bestEquality1) {\n // We have an improvement, save it back to the diff.\n if (bestEquality1) {\n diffs[pointer - 1][1] = bestEquality1;\n } else {\n diffs.splice(pointer - 1, 1);\n pointer--;\n }\n diffs[pointer][1] = bestEdit;\n if (bestEquality2) {\n diffs[pointer + 1][1] = bestEquality2;\n } else {\n diffs.splice(pointer + 1, 1);\n pointer--;\n }\n }\n }\n pointer++;\n }\n};\n\n// Define some regex patterns for matching boundaries.\ndiff_match_patch.nonAlphaNumericRegex_ = /[^a-zA-Z0-9]/;\ndiff_match_patch.whitespaceRegex_ = /\\s/;\ndiff_match_patch.linebreakRegex_ = /[\\r\\n]/;\ndiff_match_patch.blanklineEndRegex_ = /\\n\\r?\\n$/;\ndiff_match_patch.blanklineStartRegex_ = /^\\r?\\n\\r?\\n/;\n\n/**\n * Reduce the number of edits by eliminating operationally trivial equalities.\n * @param {!Array.} diffs Array of diff tuples.\n */\ndiff_match_patch.prototype.diff_cleanupEfficiency = function(diffs) {\n var changes = false;\n var equalities = []; // Stack of indices where equalities are found.\n var equalitiesLength = 0; // Keeping our own length var is faster in JS.\n /** @type {?string} */\n var lastEquality = null;\n // Always equal to diffs[equalities[equalitiesLength - 1]][1]\n var pointer = 0; // Index of current position.\n // Is there an insertion operation before the last equality.\n var pre_ins = false;\n // Is there a deletion operation before the last equality.\n var pre_del = false;\n // Is there an insertion operation after the last equality.\n var post_ins = false;\n // Is there a deletion operation after the last equality.\n var post_del = false;\n while (pointer < diffs.length) {\n if (diffs[pointer][0] == DIFF_EQUAL) { // Equality found.\n if (diffs[pointer][1].length < this.Diff_EditCost &&\n (post_ins || post_del)) {\n // Candidate found.\n equalities[equalitiesLength++] = pointer;\n pre_ins = post_ins;\n pre_del = post_del;\n lastEquality = diffs[pointer][1];\n } else {\n // Not a candidate, and can never become one.\n equalitiesLength = 0;\n lastEquality = null;\n }\n post_ins = post_del = false;\n } else { // An insertion or deletion.\n if (diffs[pointer][0] == DIFF_DELETE) {\n post_del = true;\n } else {\n post_ins = true;\n }\n /*\n * Five types to be split:\n * ABXYCD\n * AXCD\n * ABXC\n * AXCD\n * ABXC\n */\n if (lastEquality && ((pre_ins && pre_del && post_ins && post_del) ||\n ((lastEquality.length < this.Diff_EditCost / 2) &&\n (pre_ins + pre_del + post_ins + post_del) == 3))) {\n // Duplicate record.\n diffs.splice(equalities[equalitiesLength - 1], 0,\n new diff_match_patch.Diff(DIFF_DELETE, lastEquality));\n // Change second copy to insert.\n diffs[equalities[equalitiesLength - 1] + 1][0] = DIFF_INSERT;\n equalitiesLength--; // Throw away the equality we just deleted;\n lastEquality = null;\n if (pre_ins && pre_del) {\n // No changes made which could affect previous entry, keep going.\n post_ins = post_del = true;\n equalitiesLength = 0;\n } else {\n equalitiesLength--; // Throw away the previous equality.\n pointer = equalitiesLength > 0 ?\n equalities[equalitiesLength - 1] : -1;\n post_ins = post_del = false;\n }\n changes = true;\n }\n }\n pointer++;\n }\n\n if (changes) {\n this.diff_cleanupMerge(diffs);\n }\n};\n\n\n/**\n * Reorder and merge like edit sections. Merge equalities.\n * Any edit section can move as long as it doesn't cross an equality.\n * @param {!Array.} diffs Array of diff tuples.\n */\ndiff_match_patch.prototype.diff_cleanupMerge = function(diffs) {\n // Add a dummy entry at the end.\n diffs.push(new diff_match_patch.Diff(DIFF_EQUAL, ''));\n var pointer = 0;\n var count_delete = 0;\n var count_insert = 0;\n var text_delete = '';\n var text_insert = '';\n var commonlength;\n while (pointer < diffs.length) {\n switch (diffs[pointer][0]) {\n case DIFF_INSERT:\n count_insert++;\n text_insert += diffs[pointer][1];\n pointer++;\n break;\n case DIFF_DELETE:\n count_delete++;\n text_delete += diffs[pointer][1];\n pointer++;\n break;\n case DIFF_EQUAL:\n // Upon reaching an equality, check for prior redundancies.\n if (count_delete + count_insert > 1) {\n if (count_delete !== 0 && count_insert !== 0) {\n // Factor out any common prefixies.\n commonlength = this.diff_commonPrefix(text_insert, text_delete);\n if (commonlength !== 0) {\n if ((pointer - count_delete - count_insert) > 0 &&\n diffs[pointer - count_delete - count_insert - 1][0] ==\n DIFF_EQUAL) {\n diffs[pointer - count_delete - count_insert - 1][1] +=\n text_insert.substring(0, commonlength);\n } else {\n diffs.splice(0, 0, new diff_match_patch.Diff(DIFF_EQUAL,\n text_insert.substring(0, commonlength)));\n pointer++;\n }\n text_insert = text_insert.substring(commonlength);\n text_delete = text_delete.substring(commonlength);\n }\n // Factor out any common suffixies.\n commonlength = this.diff_commonSuffix(text_insert, text_delete);\n if (commonlength !== 0) {\n diffs[pointer][1] = text_insert.substring(text_insert.length -\n commonlength) + diffs[pointer][1];\n text_insert = text_insert.substring(0, text_insert.length -\n commonlength);\n text_delete = text_delete.substring(0, text_delete.length -\n commonlength);\n }\n }\n // Delete the offending records and add the merged ones.\n pointer -= count_delete + count_insert;\n diffs.splice(pointer, count_delete + count_insert);\n if (text_delete.length) {\n diffs.splice(pointer, 0,\n new diff_match_patch.Diff(DIFF_DELETE, text_delete));\n pointer++;\n }\n if (text_insert.length) {\n diffs.splice(pointer, 0,\n new diff_match_patch.Diff(DIFF_INSERT, text_insert));\n pointer++;\n }\n pointer++;\n } else if (pointer !== 0 && diffs[pointer - 1][0] == DIFF_EQUAL) {\n // Merge this equality with the previous one.\n diffs[pointer - 1][1] += diffs[pointer][1];\n diffs.splice(pointer, 1);\n } else {\n pointer++;\n }\n count_insert = 0;\n count_delete = 0;\n text_delete = '';\n text_insert = '';\n break;\n }\n }\n if (diffs[diffs.length - 1][1] === '') {\n diffs.pop(); // Remove the dummy entry at the end.\n }\n\n // Second pass: look for single edits surrounded on both sides by equalities\n // which can be shifted sideways to eliminate an equality.\n // e.g: ABAC -> ABAC\n var changes = false;\n pointer = 1;\n // Intentionally ignore the first and last element (don't need checking).\n while (pointer < diffs.length - 1) {\n if (diffs[pointer - 1][0] == DIFF_EQUAL &&\n diffs[pointer + 1][0] == DIFF_EQUAL) {\n // This is a single edit surrounded by equalities.\n if (diffs[pointer][1].substring(diffs[pointer][1].length -\n diffs[pointer - 1][1].length) == diffs[pointer - 1][1]) {\n // Shift the edit over the previous equality.\n diffs[pointer][1] = diffs[pointer - 1][1] +\n diffs[pointer][1].substring(0, diffs[pointer][1].length -\n diffs[pointer - 1][1].length);\n diffs[pointer + 1][1] = diffs[pointer - 1][1] + diffs[pointer + 1][1];\n diffs.splice(pointer - 1, 1);\n changes = true;\n } else if (diffs[pointer][1].substring(0, diffs[pointer + 1][1].length) ==\n diffs[pointer + 1][1]) {\n // Shift the edit over the next equality.\n diffs[pointer - 1][1] += diffs[pointer + 1][1];\n diffs[pointer][1] =\n diffs[pointer][1].substring(diffs[pointer + 1][1].length) +\n diffs[pointer + 1][1];\n diffs.splice(pointer + 1, 1);\n changes = true;\n }\n }\n pointer++;\n }\n // If shifts were made, the diff needs reordering and another shift sweep.\n if (changes) {\n this.diff_cleanupMerge(diffs);\n }\n};\n\n\n/**\n * loc is a location in text1, compute and return the equivalent location in\n * text2.\n * e.g. 'The cat' vs 'The big cat', 1->1, 5->8\n * @param {!Array.} diffs Array of diff tuples.\n * @param {number} loc Location within text1.\n * @return {number} Location within text2.\n */\ndiff_match_patch.prototype.diff_xIndex = function(diffs, loc) {\n var chars1 = 0;\n var chars2 = 0;\n var last_chars1 = 0;\n var last_chars2 = 0;\n var x;\n for (x = 0; x < diffs.length; x++) {\n if (diffs[x][0] !== DIFF_INSERT) { // Equality or deletion.\n chars1 += diffs[x][1].length;\n }\n if (diffs[x][0] !== DIFF_DELETE) { // Equality or insertion.\n chars2 += diffs[x][1].length;\n }\n if (chars1 > loc) { // Overshot the location.\n break;\n }\n last_chars1 = chars1;\n last_chars2 = chars2;\n }\n // Was the location was deleted?\n if (diffs.length != x && diffs[x][0] === DIFF_DELETE) {\n return last_chars2;\n }\n // Add the remaining character length.\n return last_chars2 + (loc - last_chars1);\n};\n\n\n/**\n * Convert a diff array into a pretty HTML report.\n * @param {!Array.} diffs Array of diff tuples.\n * @return {string} HTML representation.\n */\ndiff_match_patch.prototype.diff_prettyHtml = function(diffs) {\n var html = [];\n var pattern_amp = /&/g;\n var pattern_lt = //g;\n var pattern_para = /\\n/g;\n for (var x = 0; x < diffs.length; x++) {\n var op = diffs[x][0]; // Operation (insert, delete, equal)\n var data = diffs[x][1]; // Text of change.\n var text = data.replace(pattern_amp, '&').replace(pattern_lt, '<')\n .replace(pattern_gt, '>').replace(pattern_para, '¶
');\n switch (op) {\n case DIFF_INSERT:\n html[x] = '' + text + '';\n break;\n case DIFF_DELETE:\n html[x] = '' + text + '';\n break;\n case DIFF_EQUAL:\n html[x] = '' + text + '';\n break;\n }\n }\n return html.join('');\n};\n\n\n/**\n * Compute and return the source text (all equalities and deletions).\n * @param {!Array.} diffs Array of diff tuples.\n * @return {string} Source text.\n */\ndiff_match_patch.prototype.diff_text1 = function(diffs) {\n var text = [];\n for (var x = 0; x < diffs.length; x++) {\n if (diffs[x][0] !== DIFF_INSERT) {\n text[x] = diffs[x][1];\n }\n }\n return text.join('');\n};\n\n\n/**\n * Compute and return the destination text (all equalities and insertions).\n * @param {!Array.} diffs Array of diff tuples.\n * @return {string} Destination text.\n */\ndiff_match_patch.prototype.diff_text2 = function(diffs) {\n var text = [];\n for (var x = 0; x < diffs.length; x++) {\n if (diffs[x][0] !== DIFF_DELETE) {\n text[x] = diffs[x][1];\n }\n }\n return text.join('');\n};\n\n\n/**\n * Compute the Levenshtein distance; the number of inserted, deleted or\n * substituted characters.\n * @param {!Array.} diffs Array of diff tuples.\n * @return {number} Number of changes.\n */\ndiff_match_patch.prototype.diff_levenshtein = function(diffs) {\n var levenshtein = 0;\n var insertions = 0;\n var deletions = 0;\n for (var x = 0; x < diffs.length; x++) {\n var op = diffs[x][0];\n var data = diffs[x][1];\n switch (op) {\n case DIFF_INSERT:\n insertions += data.length;\n break;\n case DIFF_DELETE:\n deletions += data.length;\n break;\n case DIFF_EQUAL:\n // A deletion and an insertion is one substitution.\n levenshtein += Math.max(insertions, deletions);\n insertions = 0;\n deletions = 0;\n break;\n }\n }\n levenshtein += Math.max(insertions, deletions);\n return levenshtein;\n};\n\n\n/**\n * Crush the diff into an encoded string which describes the operations\n * required to transform text1 into text2.\n * E.g. =3\\t-2\\t+ing -> Keep 3 chars, delete 2 chars, insert 'ing'.\n * Operations are tab-separated. Inserted text is escaped using %xx notation.\n * @param {!Array.} diffs Array of diff tuples.\n * @return {string} Delta text.\n */\ndiff_match_patch.prototype.diff_toDelta = function(diffs) {\n var text = [];\n for (var x = 0; x < diffs.length; x++) {\n switch (diffs[x][0]) {\n case DIFF_INSERT:\n text[x] = '+' + encodeURI(diffs[x][1]);\n break;\n case DIFF_DELETE:\n text[x] = '-' + diffs[x][1].length;\n break;\n case DIFF_EQUAL:\n text[x] = '=' + diffs[x][1].length;\n break;\n }\n }\n return text.join('\\t').replace(/%20/g, ' ');\n};\n\n\n/**\n * Given the original text1, and an encoded string which describes the\n * operations required to transform text1 into text2, compute the full diff.\n * @param {string} text1 Source string for the diff.\n * @param {string} delta Delta text.\n * @return {!Array.} Array of diff tuples.\n * @throws {!Error} If invalid input.\n */\ndiff_match_patch.prototype.diff_fromDelta = function(text1, delta) {\n var diffs = [];\n var diffsLength = 0; // Keeping our own length var is faster in JS.\n var pointer = 0; // Cursor in text1\n var tokens = delta.split(/\\t/g);\n for (var x = 0; x < tokens.length; x++) {\n // Each token begins with a one character parameter which specifies the\n // operation of this token (delete, insert, equality).\n var param = tokens[x].substring(1);\n switch (tokens[x].charAt(0)) {\n case '+':\n try {\n diffs[diffsLength++] =\n new diff_match_patch.Diff(DIFF_INSERT, decodeURI(param));\n } catch (ex) {\n // Malformed URI sequence.\n throw new Error('Illegal escape in diff_fromDelta: ' + param);\n }\n break;\n case '-':\n // Fall through.\n case '=':\n var n = parseInt(param, 10);\n if (isNaN(n) || n < 0) {\n throw new Error('Invalid number in diff_fromDelta: ' + param);\n }\n var text = text1.substring(pointer, pointer += n);\n if (tokens[x].charAt(0) == '=') {\n diffs[diffsLength++] = new diff_match_patch.Diff(DIFF_EQUAL, text);\n } else {\n diffs[diffsLength++] = new diff_match_patch.Diff(DIFF_DELETE, text);\n }\n break;\n default:\n // Blank tokens are ok (from a trailing \\t).\n // Anything else is an error.\n if (tokens[x]) {\n throw new Error('Invalid diff operation in diff_fromDelta: ' +\n tokens[x]);\n }\n }\n }\n if (pointer != text1.length) {\n throw new Error('Delta length (' + pointer +\n ') does not equal source text length (' + text1.length + ').');\n }\n return diffs;\n};\n\n\n// MATCH FUNCTIONS\n\n\n/**\n * Locate the best instance of 'pattern' in 'text' near 'loc'.\n * @param {string} text The text to search.\n * @param {string} pattern The pattern to search for.\n * @param {number} loc The location to search around.\n * @return {number} Best match index or -1.\n */\ndiff_match_patch.prototype.match_main = function(text, pattern, loc) {\n // Check for null inputs.\n if (text == null || pattern == null || loc == null) {\n throw new Error('Null input. (match_main)');\n }\n\n loc = Math.max(0, Math.min(loc, text.length));\n if (text == pattern) {\n // Shortcut (potentially not guaranteed by the algorithm)\n return 0;\n } else if (!text.length) {\n // Nothing to match.\n return -1;\n } else if (text.substring(loc, loc + pattern.length) == pattern) {\n // Perfect match at the perfect spot! (Includes case of null pattern)\n return loc;\n } else {\n // Do a fuzzy compare.\n return this.match_bitap_(text, pattern, loc);\n }\n};\n\n\n/**\n * Locate the best instance of 'pattern' in 'text' near 'loc' using the\n * Bitap algorithm.\n * @param {string} text The text to search.\n * @param {string} pattern The pattern to search for.\n * @param {number} loc The location to search around.\n * @return {number} Best match index or -1.\n * @private\n */\ndiff_match_patch.prototype.match_bitap_ = function(text, pattern, loc) {\n if (pattern.length > this.Match_MaxBits) {\n throw new Error('Pattern too long for this browser.');\n }\n\n // Initialise the alphabet.\n var s = this.match_alphabet_(pattern);\n\n var dmp = this; // 'this' becomes 'window' in a closure.\n\n /**\n * Compute and return the score for a match with e errors and x location.\n * Accesses loc and pattern through being a closure.\n * @param {number} e Number of errors in match.\n * @param {number} x Location of match.\n * @return {number} Overall score for match (0.0 = good, 1.0 = bad).\n * @private\n */\n function match_bitapScore_(e, x) {\n var accuracy = e / pattern.length;\n var proximity = Math.abs(loc - x);\n if (!dmp.Match_Distance) {\n // Dodge divide by zero error.\n return proximity ? 1.0 : accuracy;\n }\n return accuracy + (proximity / dmp.Match_Distance);\n }\n\n // Highest score beyond which we give up.\n var score_threshold = this.Match_Threshold;\n // Is there a nearby exact match? (speedup)\n var best_loc = text.indexOf(pattern, loc);\n if (best_loc != -1) {\n score_threshold = Math.min(match_bitapScore_(0, best_loc), score_threshold);\n // What about in the other direction? (speedup)\n best_loc = text.lastIndexOf(pattern, loc + pattern.length);\n if (best_loc != -1) {\n score_threshold =\n Math.min(match_bitapScore_(0, best_loc), score_threshold);\n }\n }\n\n // Initialise the bit arrays.\n var matchmask = 1 << (pattern.length - 1);\n best_loc = -1;\n\n var bin_min, bin_mid;\n var bin_max = pattern.length + text.length;\n var last_rd;\n for (var d = 0; d < pattern.length; d++) {\n // Scan for the best match; each iteration allows for one more error.\n // Run a binary search to determine how far from 'loc' we can stray at this\n // error level.\n bin_min = 0;\n bin_mid = bin_max;\n while (bin_min < bin_mid) {\n if (match_bitapScore_(d, loc + bin_mid) <= score_threshold) {\n bin_min = bin_mid;\n } else {\n bin_max = bin_mid;\n }\n bin_mid = Math.floor((bin_max - bin_min) / 2 + bin_min);\n }\n // Use the result from this iteration as the maximum for the next.\n bin_max = bin_mid;\n var start = Math.max(1, loc - bin_mid + 1);\n var finish = Math.min(loc + bin_mid, text.length) + pattern.length;\n\n var rd = Array(finish + 2);\n rd[finish + 1] = (1 << d) - 1;\n for (var j = finish; j >= start; j--) {\n // The alphabet (s) is a sparse hash, so the following line generates\n // warnings.\n var charMatch = s[text.charAt(j - 1)];\n if (d === 0) { // First pass: exact match.\n rd[j] = ((rd[j + 1] << 1) | 1) & charMatch;\n } else { // Subsequent passes: fuzzy match.\n rd[j] = (((rd[j + 1] << 1) | 1) & charMatch) |\n (((last_rd[j + 1] | last_rd[j]) << 1) | 1) |\n last_rd[j + 1];\n }\n if (rd[j] & matchmask) {\n var score = match_bitapScore_(d, j - 1);\n // This match will almost certainly be better than any existing match.\n // But check anyway.\n if (score <= score_threshold) {\n // Told you so.\n score_threshold = score;\n best_loc = j - 1;\n if (best_loc > loc) {\n // When passing loc, don't exceed our current distance from loc.\n start = Math.max(1, 2 * loc - best_loc);\n } else {\n // Already passed loc, downhill from here on in.\n break;\n }\n }\n }\n }\n // No hope for a (better) match at greater error levels.\n if (match_bitapScore_(d + 1, loc) > score_threshold) {\n break;\n }\n last_rd = rd;\n }\n return best_loc;\n};\n\n\n/**\n * Initialise the alphabet for the Bitap algorithm.\n * @param {string} pattern The text to encode.\n * @return {!Object} Hash of character locations.\n * @private\n */\ndiff_match_patch.prototype.match_alphabet_ = function(pattern) {\n var s = {};\n for (var i = 0; i < pattern.length; i++) {\n s[pattern.charAt(i)] = 0;\n }\n for (var i = 0; i < pattern.length; i++) {\n s[pattern.charAt(i)] |= 1 << (pattern.length - i - 1);\n }\n return s;\n};\n\n\n// PATCH FUNCTIONS\n\n\n/**\n * Increase the context until it is unique,\n * but don't let the pattern expand beyond Match_MaxBits.\n * @param {!diff_match_patch.patch_obj} patch The patch to grow.\n * @param {string} text Source text.\n * @private\n */\ndiff_match_patch.prototype.patch_addContext_ = function(patch, text) {\n if (text.length == 0) {\n return;\n }\n if (patch.start2 === null) {\n throw Error('patch not initialized');\n }\n var pattern = text.substring(patch.start2, patch.start2 + patch.length1);\n var padding = 0;\n\n // Look for the first and last matches of pattern in text. If two different\n // matches are found, increase the pattern length.\n while (text.indexOf(pattern) != text.lastIndexOf(pattern) &&\n pattern.length < this.Match_MaxBits - this.Patch_Margin -\n this.Patch_Margin) {\n padding += this.Patch_Margin;\n pattern = text.substring(patch.start2 - padding,\n patch.start2 + patch.length1 + padding);\n }\n // Add one chunk for good luck.\n padding += this.Patch_Margin;\n\n // Add the prefix.\n var prefix = text.substring(patch.start2 - padding, patch.start2);\n if (prefix) {\n patch.diffs.unshift(new diff_match_patch.Diff(DIFF_EQUAL, prefix));\n }\n // Add the suffix.\n var suffix = text.substring(patch.start2 + patch.length1,\n patch.start2 + patch.length1 + padding);\n if (suffix) {\n patch.diffs.push(new diff_match_patch.Diff(DIFF_EQUAL, suffix));\n }\n\n // Roll back the start points.\n patch.start1 -= prefix.length;\n patch.start2 -= prefix.length;\n // Extend the lengths.\n patch.length1 += prefix.length + suffix.length;\n patch.length2 += prefix.length + suffix.length;\n};\n\n\n/**\n * Compute a list of patches to turn text1 into text2.\n * Use diffs if provided, otherwise compute it ourselves.\n * There are four ways to call this function, depending on what data is\n * available to the caller:\n * Method 1:\n * a = text1, b = text2\n * Method 2:\n * a = diffs\n * Method 3 (optimal):\n * a = text1, b = diffs\n * Method 4 (deprecated, use method 3):\n * a = text1, b = text2, c = diffs\n *\n * @param {string|!Array.} a text1 (methods 1,3,4) or\n * Array of diff tuples for text1 to text2 (method 2).\n * @param {string|!Array.=} opt_b text2 (methods 1,4) or\n * Array of diff tuples for text1 to text2 (method 3) or undefined (method 2).\n * @param {string|!Array.=} opt_c Array of diff tuples\n * for text1 to text2 (method 4) or undefined (methods 1,2,3).\n * @return {!Array.} Array of Patch objects.\n */\ndiff_match_patch.prototype.patch_make = function(a, opt_b, opt_c) {\n var text1, diffs;\n if (typeof a == 'string' && typeof opt_b == 'string' &&\n typeof opt_c == 'undefined') {\n // Method 1: text1, text2\n // Compute diffs from text1 and text2.\n text1 = /** @type {string} */(a);\n diffs = this.diff_main(text1, /** @type {string} */(opt_b), true);\n if (diffs.length > 2) {\n this.diff_cleanupSemantic(diffs);\n this.diff_cleanupEfficiency(diffs);\n }\n } else if (a && typeof a == 'object' && typeof opt_b == 'undefined' &&\n typeof opt_c == 'undefined') {\n // Method 2: diffs\n // Compute text1 from diffs.\n diffs = /** @type {!Array.} */(a);\n text1 = this.diff_text1(diffs);\n } else if (typeof a == 'string' && opt_b && typeof opt_b == 'object' &&\n typeof opt_c == 'undefined') {\n // Method 3: text1, diffs\n text1 = /** @type {string} */(a);\n diffs = /** @type {!Array.} */(opt_b);\n } else if (typeof a == 'string' && typeof opt_b == 'string' &&\n opt_c && typeof opt_c == 'object') {\n // Method 4: text1, text2, diffs\n // text2 is not used.\n text1 = /** @type {string} */(a);\n diffs = /** @type {!Array.} */(opt_c);\n } else {\n throw new Error('Unknown call format to patch_make.');\n }\n\n if (diffs.length === 0) {\n return []; // Get rid of the null case.\n }\n var patches = [];\n var patch = new diff_match_patch.patch_obj();\n var patchDiffLength = 0; // Keeping our own length var is faster in JS.\n var char_count1 = 0; // Number of characters into the text1 string.\n var char_count2 = 0; // Number of characters into the text2 string.\n // Start with text1 (prepatch_text) and apply the diffs until we arrive at\n // text2 (postpatch_text). We recreate the patches one by one to determine\n // context info.\n var prepatch_text = text1;\n var postpatch_text = text1;\n for (var x = 0; x < diffs.length; x++) {\n var diff_type = diffs[x][0];\n var diff_text = diffs[x][1];\n\n if (!patchDiffLength && diff_type !== DIFF_EQUAL) {\n // A new patch starts here.\n patch.start1 = char_count1;\n patch.start2 = char_count2;\n }\n\n switch (diff_type) {\n case DIFF_INSERT:\n patch.diffs[patchDiffLength++] = diffs[x];\n patch.length2 += diff_text.length;\n postpatch_text = postpatch_text.substring(0, char_count2) + diff_text +\n postpatch_text.substring(char_count2);\n break;\n case DIFF_DELETE:\n patch.length1 += diff_text.length;\n patch.diffs[patchDiffLength++] = diffs[x];\n postpatch_text = postpatch_text.substring(0, char_count2) +\n postpatch_text.substring(char_count2 +\n diff_text.length);\n break;\n case DIFF_EQUAL:\n if (diff_text.length <= 2 * this.Patch_Margin &&\n patchDiffLength && diffs.length != x + 1) {\n // Small equality inside a patch.\n patch.diffs[patchDiffLength++] = diffs[x];\n patch.length1 += diff_text.length;\n patch.length2 += diff_text.length;\n } else if (diff_text.length >= 2 * this.Patch_Margin) {\n // Time for a new patch.\n if (patchDiffLength) {\n this.patch_addContext_(patch, prepatch_text);\n patches.push(patch);\n patch = new diff_match_patch.patch_obj();\n patchDiffLength = 0;\n // Unlike Unidiff, our patch lists have a rolling context.\n // https://github.com/google/diff-match-patch/wiki/Unidiff\n // Update prepatch text & pos to reflect the application of the\n // just completed patch.\n prepatch_text = postpatch_text;\n char_count1 = char_count2;\n }\n }\n break;\n }\n\n // Update the current character count.\n if (diff_type !== DIFF_INSERT) {\n char_count1 += diff_text.length;\n }\n if (diff_type !== DIFF_DELETE) {\n char_count2 += diff_text.length;\n }\n }\n // Pick up the leftover patch if not empty.\n if (patchDiffLength) {\n this.patch_addContext_(patch, prepatch_text);\n patches.push(patch);\n }\n\n return patches;\n};\n\n\n/**\n * Given an array of patches, return another array that is identical.\n * @param {!Array.} patches Array of Patch objects.\n * @return {!Array.} Array of Patch objects.\n */\ndiff_match_patch.prototype.patch_deepCopy = function(patches) {\n // Making deep copies is hard in JavaScript.\n var patchesCopy = [];\n for (var x = 0; x < patches.length; x++) {\n var patch = patches[x];\n var patchCopy = new diff_match_patch.patch_obj();\n patchCopy.diffs = [];\n for (var y = 0; y < patch.diffs.length; y++) {\n patchCopy.diffs[y] =\n new diff_match_patch.Diff(patch.diffs[y][0], patch.diffs[y][1]);\n }\n patchCopy.start1 = patch.start1;\n patchCopy.start2 = patch.start2;\n patchCopy.length1 = patch.length1;\n patchCopy.length2 = patch.length2;\n patchesCopy[x] = patchCopy;\n }\n return patchesCopy;\n};\n\n\n/**\n * Merge a set of patches onto the text. Return a patched text, as well\n * as a list of true/false values indicating which patches were applied.\n * @param {!Array.} patches Array of Patch objects.\n * @param {string} text Old text.\n * @return {!Array.>} Two element Array, containing the\n * new text and an array of boolean values.\n */\ndiff_match_patch.prototype.patch_apply = function(patches, text) {\n if (patches.length == 0) {\n return [text, []];\n }\n\n // Deep copy the patches so that no changes are made to originals.\n patches = this.patch_deepCopy(patches);\n\n var nullPadding = this.patch_addPadding(patches);\n text = nullPadding + text + nullPadding;\n\n this.patch_splitMax(patches);\n // delta keeps track of the offset between the expected and actual location\n // of the previous patch. If there are patches expected at positions 10 and\n // 20, but the first patch was found at 12, delta is 2 and the second patch\n // has an effective expected position of 22.\n var delta = 0;\n var results = [];\n for (var x = 0; x < patches.length; x++) {\n var expected_loc = patches[x].start2 + delta;\n var text1 = this.diff_text1(patches[x].diffs);\n var start_loc;\n var end_loc = -1;\n if (text1.length > this.Match_MaxBits) {\n // patch_splitMax will only provide an oversized pattern in the case of\n // a monster delete.\n start_loc = this.match_main(text, text1.substring(0, this.Match_MaxBits),\n expected_loc);\n if (start_loc != -1) {\n end_loc = this.match_main(text,\n text1.substring(text1.length - this.Match_MaxBits),\n expected_loc + text1.length - this.Match_MaxBits);\n if (end_loc == -1 || start_loc >= end_loc) {\n // Can't find valid trailing context. Drop this patch.\n start_loc = -1;\n }\n }\n } else {\n start_loc = this.match_main(text, text1, expected_loc);\n }\n if (start_loc == -1) {\n // No match found. :(\n results[x] = false;\n // Subtract the delta for this failed patch from subsequent patches.\n delta -= patches[x].length2 - patches[x].length1;\n } else {\n // Found a match. :)\n results[x] = true;\n delta = start_loc - expected_loc;\n var text2;\n if (end_loc == -1) {\n text2 = text.substring(start_loc, start_loc + text1.length);\n } else {\n text2 = text.substring(start_loc, end_loc + this.Match_MaxBits);\n }\n if (text1 == text2) {\n // Perfect match, just shove the replacement text in.\n text = text.substring(0, start_loc) +\n this.diff_text2(patches[x].diffs) +\n text.substring(start_loc + text1.length);\n } else {\n // Imperfect match. Run a diff to get a framework of equivalent\n // indices.\n var diffs = this.diff_main(text1, text2, false);\n if (text1.length > this.Match_MaxBits &&\n this.diff_levenshtein(diffs) / text1.length >\n this.Patch_DeleteThreshold) {\n // The end points match, but the content is unacceptably bad.\n results[x] = false;\n } else {\n this.diff_cleanupSemanticLossless(diffs);\n var index1 = 0;\n var index2;\n for (var y = 0; y < patches[x].diffs.length; y++) {\n var mod = patches[x].diffs[y];\n if (mod[0] !== DIFF_EQUAL) {\n index2 = this.diff_xIndex(diffs, index1);\n }\n if (mod[0] === DIFF_INSERT) { // Insertion\n text = text.substring(0, start_loc + index2) + mod[1] +\n text.substring(start_loc + index2);\n } else if (mod[0] === DIFF_DELETE) { // Deletion\n text = text.substring(0, start_loc + index2) +\n text.substring(start_loc + this.diff_xIndex(diffs,\n index1 + mod[1].length));\n }\n if (mod[0] !== DIFF_DELETE) {\n index1 += mod[1].length;\n }\n }\n }\n }\n }\n }\n // Strip the padding off.\n text = text.substring(nullPadding.length, text.length - nullPadding.length);\n return [text, results];\n};\n\n\n/**\n * Add some padding on text start and end so that edges can match something.\n * Intended to be called only from within patch_apply.\n * @param {!Array.} patches Array of Patch objects.\n * @return {string} The padding string added to each side.\n */\ndiff_match_patch.prototype.patch_addPadding = function(patches) {\n var paddingLength = this.Patch_Margin;\n var nullPadding = '';\n for (var x = 1; x <= paddingLength; x++) {\n nullPadding += String.fromCharCode(x);\n }\n\n // Bump all the patches forward.\n for (var x = 0; x < patches.length; x++) {\n patches[x].start1 += paddingLength;\n patches[x].start2 += paddingLength;\n }\n\n // Add some padding on start of first diff.\n var patch = patches[0];\n var diffs = patch.diffs;\n if (diffs.length == 0 || diffs[0][0] != DIFF_EQUAL) {\n // Add nullPadding equality.\n diffs.unshift(new diff_match_patch.Diff(DIFF_EQUAL, nullPadding));\n patch.start1 -= paddingLength; // Should be 0.\n patch.start2 -= paddingLength; // Should be 0.\n patch.length1 += paddingLength;\n patch.length2 += paddingLength;\n } else if (paddingLength > diffs[0][1].length) {\n // Grow first equality.\n var extraLength = paddingLength - diffs[0][1].length;\n diffs[0][1] = nullPadding.substring(diffs[0][1].length) + diffs[0][1];\n patch.start1 -= extraLength;\n patch.start2 -= extraLength;\n patch.length1 += extraLength;\n patch.length2 += extraLength;\n }\n\n // Add some padding on end of last diff.\n patch = patches[patches.length - 1];\n diffs = patch.diffs;\n if (diffs.length == 0 || diffs[diffs.length - 1][0] != DIFF_EQUAL) {\n // Add nullPadding equality.\n diffs.push(new diff_match_patch.Diff(DIFF_EQUAL, nullPadding));\n patch.length1 += paddingLength;\n patch.length2 += paddingLength;\n } else if (paddingLength > diffs[diffs.length - 1][1].length) {\n // Grow last equality.\n var extraLength = paddingLength - diffs[diffs.length - 1][1].length;\n diffs[diffs.length - 1][1] += nullPadding.substring(0, extraLength);\n patch.length1 += extraLength;\n patch.length2 += extraLength;\n }\n\n return nullPadding;\n};\n\n\n/**\n * Look through the patches and break up any which are longer than the maximum\n * limit of the match algorithm.\n * Intended to be called only from within patch_apply.\n * @param {!Array.} patches Array of Patch objects.\n */\ndiff_match_patch.prototype.patch_splitMax = function(patches) {\n var patch_size = this.Match_MaxBits;\n for (var x = 0; x < patches.length; x++) {\n if (patches[x].length1 <= patch_size) {\n continue;\n }\n var bigpatch = patches[x];\n // Remove the big old patch.\n patches.splice(x--, 1);\n var start1 = bigpatch.start1;\n var start2 = bigpatch.start2;\n var precontext = '';\n while (bigpatch.diffs.length !== 0) {\n // Create one of several smaller patches.\n var patch = new diff_match_patch.patch_obj();\n var empty = true;\n patch.start1 = start1 - precontext.length;\n patch.start2 = start2 - precontext.length;\n if (precontext !== '') {\n patch.length1 = patch.length2 = precontext.length;\n patch.diffs.push(new diff_match_patch.Diff(DIFF_EQUAL, precontext));\n }\n while (bigpatch.diffs.length !== 0 &&\n patch.length1 < patch_size - this.Patch_Margin) {\n var diff_type = bigpatch.diffs[0][0];\n var diff_text = bigpatch.diffs[0][1];\n if (diff_type === DIFF_INSERT) {\n // Insertions are harmless.\n patch.length2 += diff_text.length;\n start2 += diff_text.length;\n patch.diffs.push(bigpatch.diffs.shift());\n empty = false;\n } else if (diff_type === DIFF_DELETE && patch.diffs.length == 1 &&\n patch.diffs[0][0] == DIFF_EQUAL &&\n diff_text.length > 2 * patch_size) {\n // This is a large deletion. Let it pass in one chunk.\n patch.length1 += diff_text.length;\n start1 += diff_text.length;\n empty = false;\n patch.diffs.push(new diff_match_patch.Diff(diff_type, diff_text));\n bigpatch.diffs.shift();\n } else {\n // Deletion or equality. Only take as much as we can stomach.\n diff_text = diff_text.substring(0,\n patch_size - patch.length1 - this.Patch_Margin);\n patch.length1 += diff_text.length;\n start1 += diff_text.length;\n if (diff_type === DIFF_EQUAL) {\n patch.length2 += diff_text.length;\n start2 += diff_text.length;\n } else {\n empty = false;\n }\n patch.diffs.push(new diff_match_patch.Diff(diff_type, diff_text));\n if (diff_text == bigpatch.diffs[0][1]) {\n bigpatch.diffs.shift();\n } else {\n bigpatch.diffs[0][1] =\n bigpatch.diffs[0][1].substring(diff_text.length);\n }\n }\n }\n // Compute the head context for the next patch.\n precontext = this.diff_text2(patch.diffs);\n precontext =\n precontext.substring(precontext.length - this.Patch_Margin);\n // Append the end context for this patch.\n var postcontext = this.diff_text1(bigpatch.diffs)\n .substring(0, this.Patch_Margin);\n if (postcontext !== '') {\n patch.length1 += postcontext.length;\n patch.length2 += postcontext.length;\n if (patch.diffs.length !== 0 &&\n patch.diffs[patch.diffs.length - 1][0] === DIFF_EQUAL) {\n patch.diffs[patch.diffs.length - 1][1] += postcontext;\n } else {\n patch.diffs.push(new diff_match_patch.Diff(DIFF_EQUAL, postcontext));\n }\n }\n if (!empty) {\n patches.splice(++x, 0, patch);\n }\n }\n }\n};\n\n\n/**\n * Take a list of patches and return a textual representation.\n * @param {!Array.} patches Array of Patch objects.\n * @return {string} Text representation of patches.\n */\ndiff_match_patch.prototype.patch_toText = function(patches) {\n var text = [];\n for (var x = 0; x < patches.length; x++) {\n text[x] = patches[x];\n }\n return text.join('');\n};\n\n\n/**\n * Parse a textual representation of patches and return a list of Patch objects.\n * @param {string} textline Text representation of patches.\n * @return {!Array.} Array of Patch objects.\n * @throws {!Error} If invalid input.\n */\ndiff_match_patch.prototype.patch_fromText = function(textline) {\n var patches = [];\n if (!textline) {\n return patches;\n }\n var text = textline.split('\\n');\n var textPointer = 0;\n var patchHeader = /^@@ -(\\d+),?(\\d*) \\+(\\d+),?(\\d*) @@$/;\n while (textPointer < text.length) {\n var m = text[textPointer].match(patchHeader);\n if (!m) {\n throw new Error('Invalid patch string: ' + text[textPointer]);\n }\n var patch = new diff_match_patch.patch_obj();\n patches.push(patch);\n patch.start1 = parseInt(m[1], 10);\n if (m[2] === '') {\n patch.start1--;\n patch.length1 = 1;\n } else if (m[2] == '0') {\n patch.length1 = 0;\n } else {\n patch.start1--;\n patch.length1 = parseInt(m[2], 10);\n }\n\n patch.start2 = parseInt(m[3], 10);\n if (m[4] === '') {\n patch.start2--;\n patch.length2 = 1;\n } else if (m[4] == '0') {\n patch.length2 = 0;\n } else {\n patch.start2--;\n patch.length2 = parseInt(m[4], 10);\n }\n textPointer++;\n\n while (textPointer < text.length) {\n var sign = text[textPointer].charAt(0);\n try {\n var line = decodeURI(text[textPointer].substring(1));\n } catch (ex) {\n // Malformed URI sequence.\n throw new Error('Illegal escape in patch_fromText: ' + line);\n }\n if (sign == '-') {\n // Deletion.\n patch.diffs.push(new diff_match_patch.Diff(DIFF_DELETE, line));\n } else if (sign == '+') {\n // Insertion.\n patch.diffs.push(new diff_match_patch.Diff(DIFF_INSERT, line));\n } else if (sign == ' ') {\n // Minor equality.\n patch.diffs.push(new diff_match_patch.Diff(DIFF_EQUAL, line));\n } else if (sign == '@') {\n // Start of next patch.\n break;\n } else if (sign === '') {\n // Blank line? Whatever.\n } else {\n // WTF?\n throw new Error('Invalid patch mode \"' + sign + '\" in: ' + line);\n }\n textPointer++;\n }\n }\n return patches;\n};\n\n\n/**\n * Class representing one patch operation.\n * @constructor\n */\ndiff_match_patch.patch_obj = function() {\n /** @type {!Array.} */\n this.diffs = [];\n /** @type {?number} */\n this.start1 = null;\n /** @type {?number} */\n this.start2 = null;\n /** @type {number} */\n this.length1 = 0;\n /** @type {number} */\n this.length2 = 0;\n};\n\n\n/**\n * Emulate GNU diff's format.\n * Header: @@ -382,8 +481,9 @@\n * Indices are printed as 1-based, not 0-based.\n * @return {string} The GNU diff string.\n */\ndiff_match_patch.patch_obj.prototype.toString = function() {\n var coords1, coords2;\n if (this.length1 === 0) {\n coords1 = this.start1 + ',0';\n } else if (this.length1 == 1) {\n coords1 = this.start1 + 1;\n } else {\n coords1 = (this.start1 + 1) + ',' + this.length1;\n }\n if (this.length2 === 0) {\n coords2 = this.start2 + ',0';\n } else if (this.length2 == 1) {\n coords2 = this.start2 + 1;\n } else {\n coords2 = (this.start2 + 1) + ',' + this.length2;\n }\n var text = ['@@ -' + coords1 + ' +' + coords2 + ' @@\\n'];\n var op;\n // Escape the body of the patch with %xx notation.\n for (var x = 0; x < this.diffs.length; x++) {\n switch (this.diffs[x][0]) {\n case DIFF_INSERT:\n op = '+';\n break;\n case DIFF_DELETE:\n op = '-';\n break;\n case DIFF_EQUAL:\n op = ' ';\n break;\n }\n text[x + 1] = op + encodeURI(this.diffs[x][1]) + '\\n';\n }\n return text.join('').replace(/%20/g, ' ');\n};\n\n\n// The following export code was added by @ForbesLindesay\nmodule.exports = diff_match_patch;\nmodule.exports['diff_match_patch'] = diff_match_patch;\nmodule.exports['DIFF_DELETE'] = DIFF_DELETE;\nmodule.exports['DIFF_INSERT'] = DIFF_INSERT;\nmodule.exports['DIFF_EQUAL'] = DIFF_EQUAL;","/**\n * lodash (Custom Build) \n * Build: `lodash modularize exports=\"npm\" -o ./`\n * Copyright jQuery Foundation and other contributors \n * Released under MIT license \n * Based on Underscore.js 1.8.3 \n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n */\n\n/** Used as the `TypeError` message for \"Functions\" methods. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/** `Object#toString` result references. */\nvar funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n symbolTag = '[object Symbol]';\n\n/** Used to match property names within property paths. */\nvar reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\n reIsPlainProp = /^\\w*$/,\n reLeadingDot = /^\\./,\n rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to match backslashes in property paths. */\nvar reEscapeChar = /\\\\(\\\\)?/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\n/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\n/**\n * Checks if `value` is a host object in IE < 9.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a host object, else `false`.\n */\nfunction isHostObject(value) {\n // Many host objects are `Object` objects that can coerce to strings\n // despite having improperly defined `toString` methods.\n var result = false;\n if (value != null && typeof value.toString != 'function') {\n try {\n result = !!(value + '');\n } catch (e) {}\n }\n return result;\n}\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype,\n funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar objectToString = objectProto.toString;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/** Built-in value references. */\nvar Symbol = root.Symbol,\n splice = arrayProto.splice;\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map'),\n nativeCreate = getNative(Object, 'create');\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries ? entries.length : 0;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n}\n\n/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n return this.has(key) && delete this.__data__[key];\n}\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? data[key] !== undefined : hasOwnProperty.call(data, key);\n}\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries ? entries.length : 0;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n}\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n return true;\n}\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries ? entries.length : 0;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n return getMapData(this, key)['delete'](key);\n}\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n getMapData(this, key).set(key, value);\n return this;\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\n/**\n * The base implementation of `_.get` without support for default values.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @returns {*} Returns the resolved value.\n */\nfunction baseGet(object, path) {\n path = isKey(path, object) ? [path] : castPath(path);\n\n var index = 0,\n length = path.length;\n\n while (object != null && index < length) {\n object = object[toKey(path[index++])];\n }\n return (index && index == length) ? object : undefined;\n}\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = (isFunction(value) || isHostObject(value)) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\n/**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\nfunction baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\n/**\n * Casts `value` to a path array if it's not one.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {Array} Returns the cast property path array.\n */\nfunction castPath(value) {\n return isArray(value) ? value : stringToPath(value);\n}\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\n/**\n * Checks if `value` is a property name and not a property path.\n *\n * @private\n * @param {*} value The value to check.\n * @param {Object} [object] The object to query keys on.\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\n */\nfunction isKey(value, object) {\n if (isArray(value)) {\n return false;\n }\n var type = typeof value;\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\n value == null || isSymbol(value)) {\n return true;\n }\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\n (object != null && value in Object(object));\n}\n\n/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\n/**\n * Converts `string` to a property path array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the property path array.\n */\nvar stringToPath = memoize(function(string) {\n string = toString(string);\n\n var result = [];\n if (reLeadingDot.test(string)) {\n result.push('');\n }\n string.replace(rePropName, function(match, number, quote, string) {\n result.push(quote ? string.replace(reEscapeChar, '$1') : (number || match));\n });\n return result;\n});\n\n/**\n * Converts `value` to a string key if it's not a string or symbol.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {string|symbol} Returns the key.\n */\nfunction toKey(value) {\n if (typeof value == 'string' || isSymbol(value)) {\n return value;\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to process.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\n/**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\nfunction memoize(func, resolver) {\n if (typeof func != 'function' || (resolver && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result);\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n}\n\n// Assign cache to `_.memoize`.\nmemoize.Cache = MapCache;\n\n/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\n/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 8-9 which returns 'object' for typed array and other constructors.\n var tag = isObject(value) ? objectToString.call(value) : '';\n return tag == funcTag || tag == genTag;\n}\n\n/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return !!value && (type == 'object' || type == 'function');\n}\n\n/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return !!value && typeof value == 'object';\n}\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && objectToString.call(value) == symbolTag);\n}\n\n/**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\nfunction toString(value) {\n return value == null ? '' : baseToString(value);\n}\n\n/**\n * Gets the value at `path` of `object`. If the resolved value is\n * `undefined`, the `defaultValue` is returned in its place.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.get(object, 'a[0].b.c');\n * // => 3\n *\n * _.get(object, ['a', '0', 'b', 'c']);\n * // => 3\n *\n * _.get(object, 'a.b.c', 'default');\n * // => 'default'\n */\nfunction get(object, path, defaultValue) {\n var result = object == null ? undefined : baseGet(object, path);\n return result === undefined ? defaultValue : result;\n}\n\nmodule.exports = get;\n","/**\n * Lodash (Custom Build) \n * Build: `lodash modularize exports=\"npm\" -o ./`\n * Copyright JS Foundation and other contributors \n * Released under MIT license \n * Based on Underscore.js 1.8.3 \n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n */\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n asyncTag = '[object AsyncFunction]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n nullTag = '[object Null]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n proxyTag = '[object Proxy]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]',\n undefinedTag = '[object Undefined]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\n/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n}\n\n/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\n/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\n/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\n/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\n/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\n/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\n/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\n/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype,\n funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined,\n Symbol = root.Symbol,\n Uint8Array = root.Uint8Array,\n propertyIsEnumerable = objectProto.propertyIsEnumerable,\n splice = arrayProto.splice,\n symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols,\n nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined,\n nativeKeys = overArg(Object.keys, Object);\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView'),\n Map = getNative(root, 'Map'),\n Promise = getNative(root, 'Promise'),\n Set = getNative(root, 'Set'),\n WeakMap = getNative(root, 'WeakMap'),\n nativeCreate = getNative(Object, 'create');\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\n/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\n/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\n/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\n/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\n/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(array);\n if (stacked && stack.get(other)) {\n return stacked == other;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked && stack.get(other)) {\n return stacked == other;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n length = length == null ? MAX_SAFE_INTEGER : length;\n return !!length &&\n (typeof value == 'number' || reIsUint.test(value)) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\n/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\n/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\n/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\n/**\n * Performs a deep comparison between two values to determine if they are\n * equivalent.\n *\n * **Note:** This method supports comparing arrays, array buffers, booleans,\n * date objects, error objects, maps, numbers, `Object` objects, regexes,\n * sets, strings, symbols, and typed arrays. `Object` objects are compared\n * by their own, not inherited, enumerable properties. Functions and DOM\n * nodes are compared by strict equality, i.e. `===`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.isEqual(object, other);\n * // => true\n *\n * object === other;\n * // => false\n */\nfunction isEqual(value, other) {\n return baseIsEqual(value, other);\n}\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\n/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\n/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\n/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\n/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nmodule.exports = isEqual;\n"],"names":["isEqual","ace","props","method","node","parent","className","onBeforeLoad","onValidate","mode","focus","theme","fontSize","lineHeight","value","defaultValue","showGutter","wrapEnabled","showPrintMargin","scrollMargin","keyboardHandler","onLoad","commands","annotations","markers","placeholder","editorProps","i","availableOptions","option","command","prevProps","oldProps","nextProps","appliedClasses","oldClassesArray","oldClass","index","valueChanged","pos","margins","event","text","setOptions","y","currentMarkers","startRow","startCol","endRow","endCol","type","inFront","range","editor","showPlaceholder","item","name","width","height","style","divStyle","PropTypes","React","ReactAce","DiffMatchPatch","dmp","lhString","rhString","diff","diffedLines","codeEditorSettings","C","cursor","chunk","chunkType","lines","firstChar","lastChar","linesToHighlight","newMarkerSet","markerObj","DiffComponent","editorOptions","editorEvents","getAceInstance","debounce","fn","delay","timer","context","args","get","cursorStart","splits","split","defaultValueForEditor","valueForEditor","newAnnotations","newMarkers","sp","nextValue","oldAnnotations","oldMarkers","SplitComponent","ACE_NAMESPACE","global","define","module","deps","payload","_require","parentId","callback","lookup","params","l","dep","require","packagedModule","normalizeModule","moduleName","chunks","base","previous","exports","mod","req","returnValue","exportAce","ns","root","defineProp","obj","val","searchString","position","subjectString","lastIndex","count","result","string","str","target","output","source","key","o","k","predicate","len","thisArg","kValue","O","start","relativeStart","end","relativeEnd","final","deepCopy","copy","a","trimBeginRegexp","trimEndRegexp","array","arr","map","regExp","matches","fcn","deferred","timeout","defaultTimeout","_self","e","line","last","supportsUnicodeFlag","_navigator","os","ua","appName","useragent","XHTML_NS","buildDom","refs","txt","els","ch","el","options","childIndex","n","doc","tag","element","textContent","classes","add","include","id","sheets","strictCSP","cssCache","insertPendingStyles","cache","importCssString","cssText","container","uri","inner","outer","body","noScrollbar","withScrollbar","styles","property","div","tx","ty","dom","url","xhr","path","head","s","_","isAbort","ctor","superCtor","mixin","proto","EventEmitter","stopPropagation","preventDefault","eventName","listeners","defaultHandler","newCallback","resolve","handlers","old","disabled","capturing","msg","data","defaultEnglishMessages","oop","reportError","optionsProvider","optList","optionNames","opt","warn","message","messages","nlsPlaceholders","AppConfig","opts","optionHash","defaultString","translated","dollarMatch","curlyBracketMatch","lang","net","component","parts","sep","re","subst","loader","cb","customLoader","moduleId","loadedModule","moduleType","load","afterLoad","err","reportErrorIfPathIsNotConfigured","config","init","packaged","scriptOptions","scriptUrl","currentScript","currentDocument","scripts","script","src","attributes","j","attr","deHyphenate","m","m1","Range","startColumn","endColumn","row","column","cmp","p","firstRow","lastRow","session","screenPosStart","screenPosEnd","p1","p2","Keys","codeToKeyCode","chr","modifiers","mods","x","keyCode","keyString","keys","pressedKeys","ts","activeListenerOptions","detectListenerOptionsSupport","getListenerOptions","EventListener","elem","removeListener","addListener","destroyer","eventHandler","releaseCaptureHandler","ownerDocument","onMouseUp","factor","deltaX","deltaY","linePixels","pagePixels","elements","timeouts","callbackName","clicks","startX","startY","eventNames","onMousedown","isNewClick","getModifierHash","normalizeCommandKeys","hashId","location","dt","lastDefaultPrevented","resetPressedKeys","postMessageId","win","messageName","listener","handler","$cancelT","nls","clipboard","BROKEN_SETDATA","USE_IE_MIME_TYPE","HAS_FOCUS_ARGS","MAX_LINE_LENGTH","KEYS","MODS","isIOS","valueResetRegex","isMobile","TextInput","parentNode","host","copied","pasted","inComposition","sendingText","tempStyle","commandMode","ignoreFocusEvents","lastValue","lastSelectionStart","lastSelectionEnd","lastRestoreEnd","rowStart","rowEnd","numberOfExtraLines","isFocused","number","ariaLabel","resetSelection","top","isTransformed","ancestors","t","curOp","commandName","isUserAction","onCompositionEnd","positionToSelection","selection","newValue","selectionStart","selectionEnd","afterContextMenu","prevLine","nextLine","isAllSelected","onSelect","inputHandler","sendText","fromInput","extendLeft","extendRight","inserted","restoreStart","restoreEnd","endIndex","shouldReset","onInput","onCompositionUpdate","handleClipboardData","forceIEMime","clipboardData","mime","doCopy","isCut","onCut","onCopy","onPaste","onCompositionStart","cancelComposition","syncComposition","onKeyup","readOnly","bringToFront","rect","left","maxTop","move","closeTimeout","onContextMenuClose","onContextMenu","addIosSelectionHandler","typingResetTimeout","typing","detectArrowKeys","modifier","_isMobile","_isIOS","DRAG_OFFSET","SCROLL_COOLDOWN_T","DefaultHandlers","mouseHandler","ev","inSelection","button","selectionRange","selectionEmpty","waitForClickSelection","anchor","orientedRange","calcRangeOrientation","unitName","cmpStart","cmpEnd","distance","calcDistance","time","prevScroll","vx","vy","direction","canScroll","isSlower","ax","ay","bx","by","contentOverflows","__extends","extendStatics","d","b","__","__values","preventParentScroll","CLASSNAME","Tooltip","html","PopupManager","popup","e_1","_a","e_2","_b","visiblepopups","_c","_d","shouldDisplay","visiblepopups_1","visiblepopups_1_1","visiblePopup","e_2_1","e_1_1","popupA","popupB","rectA","rectB","popupManager","HoverTooltip","_super","_this","isMousePressed","docPos","screenPos","clippedPos","domNode","startingEvent","MARGIN","renderer","labelHeight","labelWidth","spaceBelow","isAbove","GutterHandler","gutter","tooltip","GutterTooltip","gutterRegion","tooltipTimeout","mouseEvent","showTooltip","maxRow","screenRow","hideTooltip","moveTooltip","gutterRow","gutterCell","gutterElement","windowWidth","windowHeight","annotationsInRow","annotation","fold","annotationsInFold","severityRank","mostSevereAnnotationTypeInFold","annotationType","summaryFoldedAnnotations","annotationMessages","iconClassName","lineElement","iconElement","tooltipElement","summary","annotationTypes","annotationTypes_1","annotationTypes_1_1","label","MouseEvent","domEvent","documentRow","screenTopRow","AUTOSCROLL_DELAY","SCROLL_CURSOR_DELAY","SCROLL_CURSOR_HYSTERESIS","DragdropHandler","dragImage","mouseTarget","dragSelectionMarker","timerId","dragCursor","counter","dragOperation","isInternal","autoScrollStartTime","cursorMovedTime","cursorPointOnCaretMoved","self","dataTransfer","dropEffect","canAccept","addDragMarker","getDropEffect","onMouseMoveTimer","clearDragMarker","dropData","scrollCursorIntoView","prevCursor","now","vMovement","hMovement","autoScroll","characterWidth","editorRect","offsets","nearestXOffset","nearestYOffset","scrollCursor","vScroll","hScroll","onDragInterval","onMouseMove","types","copyAllowed","moveAllowed","copyModifierState","effectAllowed","interval","cursorStyle","clickCount","eventTarget","touchStartT","lastT","longTouchTimer","animationTimer","animationSteps","vX","vY","pressed","contextMenu","createContextMenu","isOpen","updateMenu","selected","hasUndo","canExecuteCommand","cmd","handleClick","action","showContextMenu","hideContextMenu","pagePos","leftOffset","scrollLeft","handleLongTap","switchToSelectionMode","textarea","touches","h","w","touchObj","cursorPos","anchorPos","offsetTop","offsetLeft","weightedDistance","diff1","diff2","animate","wheelX","wheelY","oldScrollTop","DefaultGutterHandler","addTouchListeners","MouseHandler","focusEditor","windowBlurred","gutterEl","character","state","mouseMoveHandler","onCaptureEnd","onOperationEnd","onCaptureInterval","stop","FoldHandler","keyUtil","KeyBinding","kb","toExecute","success","ArabicAlefBetIntervalsBegine","ArabicAlefBetIntervalsEnd","dir","hiLevel","lastArabic","hasUBAT_AL","hasUBAT_B","hasUBAT_S","hasBlockSep","hasSegSep","impTab_LTR","impTab_RTL","LTR","RTL","L","R","EN","AN","ON","B","S","AL","WS","CS","ES","ET","NSM","LRE","RLE","PDF","LRO","RLO","BN","UnicodeTBL00","UnicodeTBL20","_computeLevels","chars","levels","charTypes","impTab","prevState","newClass","newLevel","newState","cond","condPos","ix","_getCharacterType","_getCharClass","_invertLevel","lev","_array","lo","hi","tmp","cType","wType","nType","c","rtlCandidate","uc","_isArabicDiacritics","textCharTypes","isRtl","logicalFromVisual","bidiLevels","ret","logIdx","rowMap","bidiUtil","bidiRE","BidiHandler","docRow","splitIndex","delta","rowCache","currentIndex","prevIndex","isLastRow","endOfLine","shift","size","fontMetrics","bidiCharWidth","showInvisibles","eolChar","isRtlDir","col","leftBoundary","logicalIdx","visualIdx","level","selections","offset","selColMin","selColMax","isSelected","isSelectedPrev","visIdx","posX","charWidth","Selection","lead","reverse","anchorRow","anchorColumn","cursorRow","cursorColumn","wasEmpty","wasMultiselect","mover","excludeLastChar","foldLine","tabSize","firstColumnPosition","beforeCursor","leadingSpace","lineEnd","textEnd","rightOfCursor","leftOfCursor","whitespaceRe","tokenRe","rows","offsetX","widget","keepDesiredColumn","r","func","r1","MAX_TOKEN_COUNT","Tokenizer","rules","ruleRegExps","matchTotal","mapping","flag","splitterRurles","rule","adjustedregex","matchcount","match","digit","values","tokens","stack","inChClass","lastCapture","esc","parenOpen","parenClose","square","startState","currentState","matchAttempts","token","skipped","TextHighlightRules","prefix","HighlightRules","escapeRules","states","append","embedRules","addRules","pushState","popState","processState","toInsert","next","stateName","includeName","defaultToken","ignoreCase","splitChar","keywords","list","word","Behaviour","behaviours","filter","TokenIterator","initialRow","initialColumn","rowCount","rowTokens","tokenIndex","SAFE_INSERT_IN_TOKENS","SAFE_INSERT_BEFORE_TOKENS","contextCache","defaultQuotes","initContext","getWrapped","opening","closing","rowDiff","CstyleBehaviour","excludeTokens","rightChar","matching","openBracePos","next_indent","indent","quotes","quote","leftChar","rightToken","stringBefore","stringAfter","pair","wordRe","isWordBefore","isWordAfter","pairQuotesAfter","shouldPairQuotes","charBefore","currentToken","nextToken","cursorPosInToken","closeDocPos","openDocPos","iterator","iterator2","bracket","wordChars","code","unicode","Mode","ignoreBlankLines","shouldRemove","minIndent","insertAtTabStop","regexpStart","lineCommentStart","uncomment","shouldInsertSpace","commentWithSpace","comment","testRemove","before","after","spaces","lineCommentEnd","regexpEnd","iter","fun","minEmptyLength","sel","initialRange","colDiff","startRange","endRange","tab","input","delegations","_loop_1","scope","functionName","this_1","language","param","completionKeywords","ruleItr","aLength","LineWidgets","screenRows","lineWidgets","hide","removed","noWidgets","w1","changedWidgets","min","first","throwDeltaError","errorText","positionInDocument","docLines","validateDelta","numRangeRows","numRangeLastLineChars","doNotValidate","Anchor","point","$getTransformedPoint","noClip","$pointsInOrder","point1","point2","equalPointsInOrder","bColIsAfter","moveIfEqual","deltaIsInsert","deltaRowShift","deltaColShift","deltaStart","deltaEnd","applyDelta","Document","textOrLines","newLineMode","length","deleteFirstNewLine","deleteLastNewLine","deletedLines","deltas","isInsert","docLength","MAX","from","to","newlineLength","BackgroundTokenizer","tokenizer","workerStart","currentLine","endLine","startLine","processedLines","SearchHighlight","clazz","markerLayer","renderedMarkerRanges","ranges","rangeToAddMarkerTo","rangeAsString","UndoManager","allowMerge","undoStackLength","rev","dontSelect","rearrangeUndoStack","deltaSet","undoSelectionRange","rebaseRedoStack","redoSelectionRange","nextDelta","json","stringifyDelta","swapped","swapGroups","comparePoints","$updateMarkers","rowShift","colShift","cmp2","clonePos","cloneDelta","stringifyRange","swap","d1","d2","i1","i2","ds1","ds2","xform","c1","splitDelta","shiftPos","rowsBefore","otherLines","rest","moveDeltasByOne","redoStack","xformed","deltaSets","FoldLine","foldData","folds","lastEnd","isNewRow","foldBefore","newFoldLine","foldLineNext","idx","lastFoldEndColumn","RangeList","excludeEdges","startIndex","clipped","lineDif","Fold","subFold","consumeRange","afterStart","firstConsumed","consumedFolds","restoreRange","consumePoint","restorePoint","Folding","side","foldLines","foundFolds","trim","lastFold","startFoldLine","added","startFold","endFold","cloneFolds","expandInner","outermostFolds","startFoldRow","textLine","lastColumn","fd","tryToUnfold","bracketPos","initState","depth","test","foldWidgets","foldMode","ignoreCurrent","fw","firstRange","toggleParent","BracketMatch","charBeforeCursor","isBackwards","bracketsRegExp","typeRe","openBracket","valueIndex","closingBracket","valueLength","prevToken","found","backward","currentTag","openTagStart","openTagName","foundOpenTagEnd","openTagEnd","closeTagStart","closeTagName","closeTagEnd","stepCount","tmpToken","TextMode","EditSession","commandEvent","currentSelection","widgetManager","cacheArray","low","mid","removedFolds","undoManager","editSession","navigateWithinSoftTabs","overwrite","marker","markerId","highlight","inToken","wordRange","useWorker","$isPlaceholder","oldMode","onReloadTokenizer","scrollTop","force","longestScreenLine","foldIndex","foldStart","enable","isUndo","fromRange","toPosition","toRange","collDiff","oldStart","newStart","indentString","rowRange","deleteRange","useWrapMode","max","desiredLimit","$printMargin","limits","wrapLimit","limit","foldLineBefore","wrapData","walkTokens","PLACEHOLDER_START","PLACEHOLDER_BODY","displayLength","lastSplit","lastDocSplit","isCode","indentedSoftWrap","maxIndent","getWrapIndent","indentation","SPACE","TAB","TAB_SPACE","addSplit","minSplit","PUNCTUATION","CHAR_EXT","isFullWidth","CHAR","maxScreenColumn","screenColumn","docColumn","rowLength","doCache","wrapIndent","foldStartRow","wrapRow","screenRowOffset","fm","Search","sr","sc","er","ec","prevRange","replacement","$disableFakeMultiline","needle","addWordBoundary","backwards","skipCurrent","forEach","forEachInLine","supportsLookbehind","wordBoundary","wordRegExp","needleArray","KEY_MODS","MultiHashHandler","platform","$singleCommand","keepCommand","ckb","keyId","cmdGroup","keyPart","chain","binding","getPosition","other","otherPos","keyList","HashHandler","CommandManager","bindKey","mac","cutLine","firstLineEndCol","selectedText","selectedCount","insertLine","curLine","newRanges","GutterKeyboardHandler","nearestFoldIndex","nearestAnnotationIndex","GutterKeyboardEvent","rowFoldingWidget","isRowFullyVisible","isIconVisible","cell","foldWidget","desinationLane","annotationIndex","foldWidgetIndex","gutterKeyboardHandler","defaultCommands","Editor","scrollIntoView","prev","mergeableCommands","shouldMerge","oldSession","tagNamesRanges","markerType","wrap","wordWithBoundary","nl","copyLine","lineMode","isFullLine","transform","lineState","shouldOutdent","lineIndent","prevLineState","currIndent","composition","applyComposition","speed","dragDelay","shouldHighlight","shouldAnimate","display","enabled","show","fade","new_range","originalRange","_numberRx","amount","charRange","nr","fp","decimals","nnr","replaceRange","currWordStart","wordParts","curLength","itLength","that","wordPairs","reg","negate","firstCondition","secondCondition","res","columnPosition","previousPosition","currentPosition","wordParts_1","wordParts_1_1","endPoint","moved","totalDiff","rangeIndex","subRows","compositionState","select","center","expand","tokenCount","matchType","bracketType","brackets","tagsRanges","lineNumber","times","replaced","newRange","shouldScroll","scrollAnchor","onChangeSelection","onBeforeRender","onAfterRender","cursorLayer","relativeNumberRenderer","hasValue","blurCommand","focusOnEnterKeyup","lastLineNumber","Lines","canvasHeight","oldConfig","newConfig","screenTop","screenPage","lineTop","fragment","initElement","Gutter","parentEl","rowInfo","annoText","displayAnnoText","annoType","onCreateCell","gutterRenderer","firstLineNumber","lastLineText","gutterWidth","padding","cells","oldLastRow","textNode","annotationNode","annotationIconNode","breakpoints","decorations","rowText","foldClass","isClosedFold","foldAnnotationClass","annotationInFold","foldRange","highlightGutterLine","Marker","css","layerConfig","stringBuilder","extraStyle","curr","lineRange","getBorderClass","range1","radiusClass","extraLength","tl","tr","br","bl","textTokens","tokenType","isTextToken","Text","unixMode","EOL_CHAR","measure","tabStr","span","spaceClass","spaceContent","tabClass","tabContent","lineElements","lineElementsIdx","heightChanged","lineEl","valueFragment","simpleSpace","controlCharacter","cjkSpace","cjk","cols","initialIndent","elementIndentLevel","bracketHighlight","currentIndent","childNodes","indentLevel","splitChars","overflowEl","lastLineEl","invisibleEl","renderTokens","addTokens","Cursor","cursors","blinking","blinkInterval","smoothBlinking","update","blink","onScreen","cursorLeft","cursorTop","pixelPos","cursorIndex","MAX_SCROLL_H","Scrollbar","classSuffix","isVisible","VScrollBar","HScrollBar","ScrollBar","eType","mousePageY","startTop","onScrollInterval","thumbTop","mousePageX","startLeft","thumbLeft","RenderLoop","onRender","changes","change","CHAR_COUNT","USE_OBSERVER","FontMetrics","isRoot","boldSize","clientPos","elPos","zoom","mul","solve","l1","l2","det","sub","m2","ut","u","f","Decorator","colors","allLineHeight","ctx","compare","priorities","compensateFold","currentY","y1","y2","yCenter","GutterLayer","MarkerLayer","TextLayer","CursorLayer","HScrollBarCustom","VScrollBarCustom","editorCss","VirtualRenderer","textLayer","oldSize","right","availableWidth","printMarginColumn","containerEl","posTop","posLeft","bottom","sm","alwaysVisible","scrollHeight","scrollerHeight","st","maxHeight","desiredHeight","hideScrollbars","screenLines","longestLine","horizScroll","hScrollChanged","vScrollBefore","minHeight","scrollPastEnd","vScrollChanged","lineCount","firstRowScreen","firstRowHeight","charCount","$viewMargin","newLeft","newTop","topMargin","bottomMargin","currentTop","currentLeft","twoCharsWidth","alignment","fromValue","toValue","steps","x_min","dx","initialScroll","oldSteps","endAnimation","canvasPos","insertPosition","textChunks","widgetDiv","hiddenTokens","lastLineDiv","chunkDiv","chunkSpan","pixelPosition","ghostTextHeight","fitsY","textLines","displayTokens","wrapSplits","textSlice","newToken","hasPassedCursor","$workerBlob","workerUrl","BlobBuilder","blobBuilder","createWorker","blob","URL","blobURL","WorkerClient","worker","topLevelNamespaces","classname","importScripts","normalizePath","tlns","ex","q","UIWorkerClient","main","emitSync","sender","messageBuffer","workerClient","processNext","callbackId","Main","PlaceHolder","others","mainClass","othersClass","undoStack","lengthDiff","inMainRange","distanceFromStart","newPos","updateMarker","undosRequired","isSamePoint","onMouseDown","alt","ctrl","accel","isMultiSelect","mouseX","mouseY","onMouseSelection","screenAnchor","screenCursor","selectionMode","oldRange","tmpSel","rectSel","blockSelect","newCursor","onMouseSelectionEnd","onSelectionInterval","search","find","$blockChangeEvents","lastRange","includeEmptyLines","xBackwards","startOffsetX","endOffsetX","yBackwards","docEnd","markerList","keepOrder","$byLines","rangeList","cmdResult","anim","buf","additive","skip","screenLead","toRemove","all","tmp_1","words","stopAtFirst","sameRowRanges","fr","lr","guessRange","maxCol","minSpace","spaceOffsets","spaceOffset","forceLeft","isLeftAligned","isRightAligned","startW","textW","endW","alignLeft","alignRight","unAlign","MultiSelect","addAltCursorListeners","altCursor","altDown","reset","FoldMode","foldStyle","startLevel","binarySearch","comparator","findAnnotations","matched","oldWidget","gutterAnno","arrow","annoTextLine","Renderer","_id","oldNode","env","version","Split","keybinding","isUsed","orientation","editorWidth","editorHeight","diff_match_patch","DIFF_DELETE","DIFF_INSERT","DIFF_EQUAL","op","text1","text2","opt_checklines","opt_deadline","deadline","checklines","commonlength","commonprefix","commonsuffix","diffs","longtext","shorttext","hm","text1_a","text1_b","text2_a","text2_b","mid_common","diffs_a","diffs_b","linearray","pointer","count_delete","count_insert","text_delete","text_insert","subDiff","text1_length","text2_length","max_d","v_offset","v_length","v1","v2","front","k1start","k1end","k2start","k2end","k1","k1_offset","x1","k2_offset","x2","k2","text1a","text2a","text1b","text2b","diffsb","lineArray","lineHash","diff_linesToCharsMunge_","lineStart","lineArrayLength","maxLines","chars1","chars2","pointermin","pointermax","pointermid","pointerstart","pointerend","text_length","best","pattern","diff_halfMatchI_","seed","best_common","best_longtext_a","best_longtext_b","best_shorttext_a","best_shorttext_b","prefixLength","suffixLength","hm1","hm2","equalities","equalitiesLength","lastEquality","length_insertions1","length_deletions1","length_insertions2","length_deletions2","deletion","insertion","overlap_length1","overlap_length2","diff_cleanupSemanticScore_","one","two","char1","char2","nonAlphaNumeric1","nonAlphaNumeric2","whitespace1","whitespace2","lineBreak1","lineBreak2","blankLine1","blankLine2","equality1","edit","equality2","commonOffset","commonString","bestEquality1","bestEdit","bestEquality2","bestScore","score","pre_ins","pre_del","post_ins","post_del","loc","last_chars1","last_chars2","pattern_amp","pattern_lt","pattern_gt","pattern_para","levenshtein","insertions","deletions","diffsLength","match_bitapScore_","accuracy","proximity","score_threshold","best_loc","matchmask","bin_min","bin_mid","bin_max","last_rd","finish","rd","charMatch","patch","suffix","opt_b","opt_c","patches","patchDiffLength","char_count1","char_count2","prepatch_text","postpatch_text","diff_type","diff_text","patchesCopy","patchCopy","nullPadding","results","expected_loc","start_loc","end_loc","index1","index2","paddingLength","patch_size","bigpatch","start1","start2","precontext","empty","postcontext","textline","textPointer","patchHeader","sign","coords1","coords2","FUNC_ERROR_TEXT","HASH_UNDEFINED","INFINITY","funcTag","genTag","symbolTag","reIsDeepProp","reIsPlainProp","reLeadingDot","rePropName","reRegExpChar","reEscapeChar","reIsHostCtor","freeGlobal","freeSelf","getValue","object","isHostObject","arrayProto","funcProto","objectProto","coreJsData","maskSrcKey","uid","funcToString","hasOwnProperty","objectToString","reIsNative","Symbol","splice","Map","getNative","nativeCreate","symbolProto","symbolToString","Hash","entries","entry","hashClear","hashDelete","hashGet","hashHas","hashSet","ListCache","listCacheClear","listCacheDelete","assocIndexOf","listCacheGet","listCacheHas","listCacheSet","MapCache","mapCacheClear","mapCacheDelete","getMapData","mapCacheGet","mapCacheHas","mapCacheSet","eq","baseGet","isKey","castPath","toKey","baseIsNative","isObject","isMasked","isFunction","toSource","baseToString","isSymbol","isArray","stringToPath","isKeyable","memoize","toString","resolver","memoized","isObjectLike","LARGE_ARRAY_SIZE","COMPARE_PARTIAL_FLAG","COMPARE_UNORDERED_FLAG","MAX_SAFE_INTEGER","argsTag","arrayTag","asyncTag","boolTag","dateTag","errorTag","mapTag","numberTag","nullTag","objectTag","promiseTag","proxyTag","regexpTag","setTag","stringTag","undefinedTag","weakMapTag","arrayBufferTag","dataViewTag","float32Tag","float64Tag","int8Tag","int16Tag","int32Tag","uint8Tag","uint8ClampedTag","uint16Tag","uint32Tag","reIsUint","typedArrayTags","freeExports","freeModule","moduleExports","freeProcess","nodeUtil","nodeIsTypedArray","arrayFilter","resIndex","arrayPush","arraySome","baseTimes","iteratee","baseUnary","cacheHas","mapToArray","overArg","arg","setToArray","set","nativeObjectToString","Buffer","Uint8Array","propertyIsEnumerable","symToStringTag","nativeGetSymbols","nativeIsBuffer","nativeKeys","DataView","Promise","Set","WeakMap","dataViewCtorString","mapCtorString","promiseCtorString","setCtorString","weakMapCtorString","symbolValueOf","SetCache","setCacheAdd","setCacheHas","Stack","stackClear","stackDelete","stackGet","stackHas","stackSet","pairs","arrayLikeKeys","inherited","isArr","isArg","isArguments","isBuff","isBuffer","isType","isTypedArray","skipIndexes","isIndex","baseGetAllKeys","keysFunc","symbolsFunc","baseGetTag","getRawTag","baseIsArguments","baseIsEqual","bitmask","customizer","baseIsEqualDeep","equalFunc","objIsArr","othIsArr","objTag","getTag","othTag","objIsObj","othIsObj","isSameTag","equalArrays","equalByTag","objIsWrapped","othIsWrapped","objUnwrapped","othUnwrapped","equalObjects","baseIsTypedArray","isLength","baseKeys","isPrototype","isPartial","arrLength","othLength","stacked","seen","arrValue","othValue","compared","othIndex","convert","objProps","getAllKeys","objLength","othProps","skipCtor","objValue","objCtor","othCtor","getSymbols","isOwn","unmasked","symbol","stubArray","Ctor","ctorString","isArrayLike","stubFalse"],"sourceRoot":""} \ No newline at end of file diff --git a/admin/custom/static/js/vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45.ca314fb3.chunk.js b/admin/custom/static/js/vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45.ca314fb3.chunk.js new file mode 100644 index 0000000..9714139 --- /dev/null +++ b/admin/custom/static/js/vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45.ca314fb3.chunk.js @@ -0,0 +1,17 @@ +"use strict";var _e=Object.defineProperty,ue=Object.defineProperties;var fe=Object.getOwnPropertyDescriptors;var V=Object.getOwnPropertySymbols;var te=Object.prototype.hasOwnProperty,ne=Object.prototype.propertyIsEnumerable;var ee=(d,r,e)=>r in d?_e(d,r,{enumerable:!0,configurable:!0,writable:!0,value:e}):d[r]=e,L=(d,r)=>{for(var e in r||(r={}))te.call(r,e)&&ee(d,e,r[e]);if(V)for(var e of V(r))ne.call(r,e)&&ee(d,e,r[e]);return d},X=(d,r)=>ue(d,fe(r));var $=(d,r)=>{var e={};for(var s in d)te.call(d,s)&&r.indexOf(s)<0&&(e[s]=d[s]);if(d!=null&&V)for(var s of V(d))r.indexOf(s)<0&&ne.call(d,s)&&(e[s]=d[s]);return e};(self.webpackChunk_iobroker_admin_component_easy_access=self.webpackChunk_iobroker_admin_component_easy_access||[]).push([["vendors-node_modules_mui_material_DefaultPropsProvider_DefaultPropsProvider_js-node_modules_m-7a6f45"],{2927:(d,r,e)=>{e.d(r,{A:()=>s});function s(f){var c=Object.create(null);return function(n){return c[n]===void 0&&(c[n]=f(n)),c[n]}}},938:(d,r,e)=>{e.d(r,{J:()=>U});function s(y){for(var t=0,l,a=0,m=y.length;m>=4;++a,m-=4)l=y.charCodeAt(a)&255|(y.charCodeAt(++a)&255)<<8|(y.charCodeAt(++a)&255)<<16|(y.charCodeAt(++a)&255)<<24,l=(l&65535)*1540483477+((l>>>16)*59797<<16),l^=l>>>24,t=(l&65535)*1540483477+((l>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(m){case 3:t^=(y.charCodeAt(a+2)&255)<<16;case 2:t^=(y.charCodeAt(a+1)&255)<<8;case 1:t^=y.charCodeAt(a)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var f={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},c=e(2927),n=!1,_=/[A-Z]|^ms/g,o=/_EMO_([^_]+?)_([^]*?)_EMO_/g,i=function(t){return t.charCodeAt(1)===45},E=function(t){return t!=null&&typeof t!="boolean"},A=(0,c.A)(function(y){return i(y)?y:y.replace(_,"-$&").toLowerCase()}),u=function(t,l){switch(t){case"animation":case"animationName":if(typeof l=="string")return l.replace(o,function(a,m,P){return D={name:m,styles:P,next:D},m})}return f[t]!==1&&!i(t)&&typeof l=="number"&&l!==0?l+"px":l},O="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function p(y,t,l){if(l==null)return"";var a=l;if(a.__emotion_styles!==void 0)return a;switch(typeof l){case"boolean":return"";case"object":{var m=l;if(m.anim===1)return D={name:m.name,styles:m.styles,next:D},m.name;var P=l;if(P.styles!==void 0){var h=P.next;if(h!==void 0)for(;h!==void 0;)D={name:h.name,styles:h.styles,next:D},h=h.next;var v=P.styles+";";return v}return M(y,t,l)}case"function":{if(y!==void 0){var C=D,W=l(y);return D=C,p(y,t,W)}break}}var S=l;if(t==null)return S;var x=t[S];return x!==void 0?x:S}function M(y,t,l){var a="";if(Array.isArray(l))for(var m=0;m{e.d(r,{b:()=>A});var s=e(8437),f=e.n(s),c=e(5973),n=e.n(c),_=e(1639),o=e(4922);function i(u){return _jsx(SystemDefaultPropsProvider,L({},u))}var E=null;function A(u){return(0,_.b)(u)}},2884:(d,r,e)=>{e.d(r,{A:()=>c});var s=e(4116);const c=n=>(0,s.A)(n)&&n!=="classes"},4116:(d,r,e)=>{e.d(r,{A:()=>f});function s(c){return c!=="ownerState"&&c!=="theme"&&c!=="sx"&&c!=="as"}const f=s},6186:(d,r,e)=>{e.d(r,{Ay:()=>o});var s=e(5873),f=e(7),c=e(2066),n=e(2884);const o=(0,s.Ay)({themeId:c.A,defaultTheme:f.A,rootShouldForwardProp:n.A})},16:(d,r,e)=>{e.d(r,{A:()=>f});var s=e(465);const f=s.A},8255:(d,r,e)=>{e.d(r,{A:()=>_});var s=e(3128);const f={theme:void 0};function c(o){let i,E;return function(u){let O=i;return(O===void 0||u.theme!==E)&&(f.theme=u.theme,O=(0,s.A)(o(f)),i=O,E=u.theme),O}}const _=c},5721:(d,r,e)=>{e.d(r,{Ay:()=>o,HX:()=>i,tT:()=>A});var s=e(9702),f=e.n(s),c=e(938),n=e(5746),_=e.n(n);/** + * @mui/styled-engine v6.1.10 + * + * @license MIT + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */function o(u,O){return f()(u,O)}function i(u,O){Array.isArray(u.__emotion_styles)&&(u.__emotion_styles=O(u.__emotion_styles))}const E=[];function A(u){return E[0]=u,(0,c.J)(E)}},1639:(d,r,e)=>{e.d(r,{A:()=>O,b:()=>u});var s=e(8437),f=e.n(s),c=e(5973),n=e.n(c),_=e(4517),o=e(4922);const i=s.createContext(void 0);function E({value:p,children:M}){return(0,o.jsx)(i.Provider,{value:p,children:M})}function A(p){const{theme:M,name:T,props:D}=p;if(!M||!M.components||!M.components[T])return D;const U=M.components[T];return U.defaultProps?(0,_.A)(U.defaultProps,D):!U.styleOverrides&&!U.variants?(0,_.A)(U,D):D}function u({props:p,name:M}){const T=s.useContext(i);return A({props:p,name:M,theme:{components:T}})}const O=E},5873:(d,r,e)=>{e.d(r,{Ay:()=>p,MC:()=>i});var s=e(5721),f=e(2783),c=e(221),n=e(2885),_=e(3128);const o=(0,c.A)();function i(t){return t!=="ownerState"&&t!=="theme"&&t!=="sx"&&t!=="as"}function E(t){return t?(l,a)=>a[t]:null}function A(t,l,a){t.theme=D(t.theme)?a:t.theme[l]||t.theme}function u(t,l){const a=typeof l=="function"?l(t):l;if(Array.isArray(a))return a.flatMap(P=>u(t,P));if(Array.isArray(a==null?void 0:a.variants)){let P;if(a.isProcessed)P=a.style;else{const m=a,{variants:h}=m;P=$(m,["variants"])}return O(t,a.variants,[P])}return a!=null&&a.isProcessed?a.style:a}function O(t,l,a=[]){var P;let m;e:for(let h=0;h{(0,s.HX)(C,R=>R.filter(w=>w!==n.A));const Q=W,{name:S,slot:x,skipVariantsResolver:k,skipSx:oe,overridesResolver:H=E(y(x))}=Q,re=$(Q,["name","slot","skipVariantsResolver","skipSx","overridesResolver"]),se=k!==void 0?k:x&&x!=="Root"&&x!=="root"||!1,ae=oe||!1;let N=i;x==="Root"||x==="root"?N=m:x?N=P:U(C)&&(N=void 0);const z=(0,s.Ay)(C,L({shouldForwardProp:N,label:T(S,x)},re)),ie=R=>{if(typeof R=="function"&&R.__emotion_real!==R)return function(g){return u(g,R)};if((0,f.Q)(R)){const w=(0,_.A)(R);return w.variants?function(K){return u(K,w)}:w.style}return R},J=(...R)=>{const w=[],g=R.map(ie),K=[];if(w.push(h),S&&H&&K.push(function(I){var j,Z;const b=(Z=(j=I.theme.components)==null?void 0:j[S])==null?void 0:Z.styleOverrides;if(!b)return null;const F={};for(const q in b)F[q]=u(I,b[q]);return H(I,F)}),S&&!se&&K.push(function(I){var F,j;const B=I.theme,b=(j=(F=B==null?void 0:B.components)==null?void 0:F[S])==null?void 0:j.variants;return b?O(I,b):null}),ae||K.push(n.A),Array.isArray(g[0])){const G=g.shift(),I=new Array(w.length).fill(""),B=new Array(K.length).fill("");let b;b=[...I,...G,...B],b.raw=[...I,...G.raw,...B],w.unshift(b)}const le=[...w,...g,...K],Y=z(...le);return C.muiName&&(Y.muiName=C.muiName),Y};return z.withConfig&&(J.withConfig=z.withConfig),J}}function M(t,l,a){return t?`${t}${capitalize(l||"")}`:`Styled(${getDisplayName(a)})`}function T(t,l){return void 0}function D(t){for(const l in t)return!1;return!0}function U(t){return typeof t=="string"&&t.charCodeAt(0)>96}function y(t){return t&&t.charAt(0).toLowerCase()+t.slice(1)}},3128:(d,r,e)=>{e.d(r,{A:()=>f});var s=e(5721);function f(c){const i=c,{variants:n}=i,_=$(i,["variants"]),o={variants:n,style:(0,s.tT)(_),isProcessed:!0};return o.style===_||n&&n.forEach(E=>{typeof E.style!="function"&&(E.style=(0,s.tT)(E.style))}),o}},1417:(d,r,e)=>{e.d(r,{A:()=>n});const s=_=>_,n=(()=>{let _=s;return{configure(o){_=o},generate(o){return _(o)},reset(){_=s}}})()},7413:(d,r,e)=>{e.d(r,{A:()=>s});function s(f,c,n=void 0){const _={};for(const o in f){const i=f[o];let E="",A=!0;for(let u=0;u{e.d(r,{Ay:()=>c});var s=e(1417);const f={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function c(_,o,i="Mui"){const E=f[o];return E?`${i}-${E}`:`${s.A.generate(_)}-${o}`}function n(_){return f[_]!==void 0}},2679:(d,r,e)=>{e.d(r,{A:()=>f});var s=e(3899);function f(c,n,_="Mui"){const o={};return n.forEach(i=>{o[i]=(0,s.Ay)(c,i,_)}),o}},4517:(d,r,e)=>{e.d(r,{A:()=>s});function s(f,c){const n=L({},c);for(const _ in f)if(Object.prototype.hasOwnProperty.call(f,_)){const o=_;if(o==="components"||o==="slots")n[o]=L(L({},f[o]),n[o]);else if(o==="componentsProps"||o==="slotProps"){const i=f[o],E=c[o];if(!E)n[o]=i||{};else if(!i)n[o]=E;else{n[o]=L({},E);for(const A in i)if(Object.prototype.hasOwnProperty.call(i,A)){const u=A;n[o][u]=s(i[u],E[u])}}}else n[o]===void 0&&(n[o]=f[o])}return n}},3394:(d,r,e)=>{var s;/** + * @license React + * react-jsx-runtime.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var f=e(8437),c=Symbol.for("react.element"),n=Symbol.for("react.fragment"),_=Object.prototype.hasOwnProperty,o=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};function E(A,u,O){var p,M={},T=null,D=null;O!==void 0&&(T=""+O),u.key!==void 0&&(T=""+u.key),u.ref!==void 0&&(D=u.ref);for(p in u)_.call(u,p)&&!i.hasOwnProperty(p)&&(M[p]=u[p]);if(A&&A.defaultProps)for(p in u=A.defaultProps,u)M[p]===void 0&&(M[p]=u[p]);return{$$typeof:c,type:A,key:T,ref:D,props:M,_owner:o.current}}s=n,r.jsx=E,r.jsxs=E},4922:(d,r,e)=>{d.exports=e(3394)},4984:(d,r,e)=>{e.d(r,{A:()=>c});function s(n){var _,o,i="";if(typeof n=="string"||typeof n=="number")i+=n;else if(typeof n=="object")if(Array.isArray(n)){var E=n.length;for(_=0;_= 4; ++i, len -= 4) {\n k = str.charCodeAt(i) & 0xff | (str.charCodeAt(++i) & 0xff) << 8 | (str.charCodeAt(++i) & 0xff) << 16 | (str.charCodeAt(++i) & 0xff) << 24;\n k =\n /* Math.imul(k, m): */\n (k & 0xffff) * 0x5bd1e995 + ((k >>> 16) * 0xe995 << 16);\n k ^=\n /* k >>> r: */\n k >>> 24;\n h =\n /* Math.imul(k, m): */\n (k & 0xffff) * 0x5bd1e995 + ((k >>> 16) * 0xe995 << 16) ^\n /* Math.imul(h, m): */\n (h & 0xffff) * 0x5bd1e995 + ((h >>> 16) * 0xe995 << 16);\n } // Handle the last few bytes of the input array\n\n\n switch (len) {\n case 3:\n h ^= (str.charCodeAt(i + 2) & 0xff) << 16;\n\n case 2:\n h ^= (str.charCodeAt(i + 1) & 0xff) << 8;\n\n case 1:\n h ^= str.charCodeAt(i) & 0xff;\n h =\n /* Math.imul(h, m): */\n (h & 0xffff) * 0x5bd1e995 + ((h >>> 16) * 0xe995 << 16);\n } // Do a few final mixes of the hash to ensure the last few\n // bytes are well-incorporated.\n\n\n h ^= h >>> 13;\n h =\n /* Math.imul(h, m): */\n (h & 0xffff) * 0x5bd1e995 + ((h >>> 16) * 0xe995 << 16);\n return ((h ^ h >>> 15) >>> 0).toString(36);\n}\n\nexport { murmur2 as default };\n","var unitlessKeys = {\n animationIterationCount: 1,\n aspectRatio: 1,\n borderImageOutset: 1,\n borderImageSlice: 1,\n borderImageWidth: 1,\n boxFlex: 1,\n boxFlexGroup: 1,\n boxOrdinalGroup: 1,\n columnCount: 1,\n columns: 1,\n flex: 1,\n flexGrow: 1,\n flexPositive: 1,\n flexShrink: 1,\n flexNegative: 1,\n flexOrder: 1,\n gridRow: 1,\n gridRowEnd: 1,\n gridRowSpan: 1,\n gridRowStart: 1,\n gridColumn: 1,\n gridColumnEnd: 1,\n gridColumnSpan: 1,\n gridColumnStart: 1,\n msGridRow: 1,\n msGridRowSpan: 1,\n msGridColumn: 1,\n msGridColumnSpan: 1,\n fontWeight: 1,\n lineHeight: 1,\n opacity: 1,\n order: 1,\n orphans: 1,\n scale: 1,\n tabSize: 1,\n widows: 1,\n zIndex: 1,\n zoom: 1,\n WebkitLineClamp: 1,\n // SVG-related properties\n fillOpacity: 1,\n floodOpacity: 1,\n stopOpacity: 1,\n strokeDasharray: 1,\n strokeDashoffset: 1,\n strokeMiterlimit: 1,\n strokeOpacity: 1,\n strokeWidth: 1\n};\n\nexport { unitlessKeys as default };\n","import hashString from '@emotion/hash';\nimport unitless from '@emotion/unitless';\nimport memoize from '@emotion/memoize';\n\nvar isDevelopment = false;\n\nvar hyphenateRegex = /[A-Z]|^ms/g;\nvar animationRegex = /_EMO_([^_]+?)_([^]*?)_EMO_/g;\n\nvar isCustomProperty = function isCustomProperty(property) {\n return property.charCodeAt(1) === 45;\n};\n\nvar isProcessableValue = function isProcessableValue(value) {\n return value != null && typeof value !== 'boolean';\n};\n\nvar processStyleName = /* #__PURE__ */memoize(function (styleName) {\n return isCustomProperty(styleName) ? styleName : styleName.replace(hyphenateRegex, '-$&').toLowerCase();\n});\n\nvar processStyleValue = function processStyleValue(key, value) {\n switch (key) {\n case 'animation':\n case 'animationName':\n {\n if (typeof value === 'string') {\n return value.replace(animationRegex, function (match, p1, p2) {\n cursor = {\n name: p1,\n styles: p2,\n next: cursor\n };\n return p1;\n });\n }\n }\n }\n\n if (unitless[key] !== 1 && !isCustomProperty(key) && typeof value === 'number' && value !== 0) {\n return value + 'px';\n }\n\n return value;\n};\n\nvar noComponentSelectorMessage = 'Component selectors can only be used in conjunction with ' + '@emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware ' + 'compiler transform.';\n\nfunction handleInterpolation(mergedProps, registered, interpolation) {\n if (interpolation == null) {\n return '';\n }\n\n var componentSelector = interpolation;\n\n if (componentSelector.__emotion_styles !== undefined) {\n\n return componentSelector;\n }\n\n switch (typeof interpolation) {\n case 'boolean':\n {\n return '';\n }\n\n case 'object':\n {\n var keyframes = interpolation;\n\n if (keyframes.anim === 1) {\n cursor = {\n name: keyframes.name,\n styles: keyframes.styles,\n next: cursor\n };\n return keyframes.name;\n }\n\n var serializedStyles = interpolation;\n\n if (serializedStyles.styles !== undefined) {\n var next = serializedStyles.next;\n\n if (next !== undefined) {\n // not the most efficient thing ever but this is a pretty rare case\n // and there will be very few iterations of this generally\n while (next !== undefined) {\n cursor = {\n name: next.name,\n styles: next.styles,\n next: cursor\n };\n next = next.next;\n }\n }\n\n var styles = serializedStyles.styles + \";\";\n return styles;\n }\n\n return createStringFromObject(mergedProps, registered, interpolation);\n }\n\n case 'function':\n {\n if (mergedProps !== undefined) {\n var previousCursor = cursor;\n var result = interpolation(mergedProps);\n cursor = previousCursor;\n return handleInterpolation(mergedProps, registered, result);\n }\n\n break;\n }\n } // finalize string values (regular strings and functions interpolated into css calls)\n\n\n var asString = interpolation;\n\n if (registered == null) {\n return asString;\n }\n\n var cached = registered[asString];\n return cached !== undefined ? cached : asString;\n}\n\nfunction createStringFromObject(mergedProps, registered, obj) {\n var string = '';\n\n if (Array.isArray(obj)) {\n for (var i = 0; i < obj.length; i++) {\n string += handleInterpolation(mergedProps, registered, obj[i]) + \";\";\n }\n } else {\n for (var key in obj) {\n var value = obj[key];\n\n if (typeof value !== 'object') {\n var asString = value;\n\n if (registered != null && registered[asString] !== undefined) {\n string += key + \"{\" + registered[asString] + \"}\";\n } else if (isProcessableValue(asString)) {\n string += processStyleName(key) + \":\" + processStyleValue(key, asString) + \";\";\n }\n } else {\n if (key === 'NO_COMPONENT_SELECTOR' && isDevelopment) {\n throw new Error(noComponentSelectorMessage);\n }\n\n if (Array.isArray(value) && typeof value[0] === 'string' && (registered == null || registered[value[0]] === undefined)) {\n for (var _i = 0; _i < value.length; _i++) {\n if (isProcessableValue(value[_i])) {\n string += processStyleName(key) + \":\" + processStyleValue(key, value[_i]) + \";\";\n }\n }\n } else {\n var interpolated = handleInterpolation(mergedProps, registered, value);\n\n switch (key) {\n case 'animation':\n case 'animationName':\n {\n string += processStyleName(key) + \":\" + interpolated + \";\";\n break;\n }\n\n default:\n {\n\n string += key + \"{\" + interpolated + \"}\";\n }\n }\n }\n }\n }\n }\n\n return string;\n}\n\nvar labelPattern = /label:\\s*([^\\s;{]+)\\s*(;|$)/g; // this is the cursor for keyframes\n// keyframes are stored on the SerializedStyles object as a linked list\n\nvar cursor;\nfunction serializeStyles(args, registered, mergedProps) {\n if (args.length === 1 && typeof args[0] === 'object' && args[0] !== null && args[0].styles !== undefined) {\n return args[0];\n }\n\n var stringMode = true;\n var styles = '';\n cursor = undefined;\n var strings = args[0];\n\n if (strings == null || strings.raw === undefined) {\n stringMode = false;\n styles += handleInterpolation(mergedProps, registered, strings);\n } else {\n var asTemplateStringsArr = strings;\n\n styles += asTemplateStringsArr[0];\n } // we start at 1 since we've already handled the first arg\n\n\n for (var i = 1; i < args.length; i++) {\n styles += handleInterpolation(mergedProps, registered, args[i]);\n\n if (stringMode) {\n var templateStringsArr = strings;\n\n styles += templateStringsArr[i];\n }\n } // using a global regex with .exec is stateful so lastIndex has to be reset each time\n\n\n labelPattern.lastIndex = 0;\n var identifierName = '';\n var match; // https://esbench.com/bench/5b809c2cf2949800a0f61fb5\n\n while ((match = labelPattern.exec(styles)) !== null) {\n identifierName += '-' + match[1];\n }\n\n var name = hashString(styles) + identifierName;\n\n return {\n name: name,\n styles: styles,\n next: cursor\n };\n}\n\nexport { serializeStyles };\n","'use client';\n\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport SystemDefaultPropsProvider, { useDefaultProps as useSystemDefaultProps } from '@mui/system/DefaultPropsProvider';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction DefaultPropsProvider(props) {\n return /*#__PURE__*/_jsx(SystemDefaultPropsProvider, {\n ...props\n });\n}\nprocess.env.NODE_ENV !== \"production\" ? DefaultPropsProvider.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * @ignore\n */\n children: PropTypes.node,\n /**\n * @ignore\n */\n value: PropTypes.object.isRequired\n} : void 0;\nexport default DefaultPropsProvider;\nexport function useDefaultProps(params) {\n return useSystemDefaultProps(params);\n}","import slotShouldForwardProp from \"./slotShouldForwardProp.js\";\nconst rootShouldForwardProp = prop => slotShouldForwardProp(prop) && prop !== 'classes';\nexport default rootShouldForwardProp;","// copied from @mui/system/createStyled\nfunction slotShouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport default slotShouldForwardProp;","'use client';\n\nimport createStyled from '@mui/system/createStyled';\nimport defaultTheme from \"./defaultTheme.js\";\nimport THEME_ID from \"./identifier.js\";\nimport rootShouldForwardProp from \"./rootShouldForwardProp.js\";\nexport { default as slotShouldForwardProp } from \"./slotShouldForwardProp.js\";\nexport { default as rootShouldForwardProp } from \"./rootShouldForwardProp.js\";\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import capitalize from '@mui/utils/capitalize';\nexport default capitalize;","import preprocessStyles from \"./preprocessStyles.js\";\n\n/* eslint-disable @typescript-eslint/naming-convention */\n\n// We need to pass an argument as `{ theme }` for PigmentCSS, but we don't want to\n// allocate more objects.\nconst arg = {\n theme: undefined\n};\n\n/**\n * Memoize style function on theme.\n * Intended to be used in styled() calls that only need access to the theme.\n */\nexport default function unstable_memoTheme(styleFn) {\n let lastValue;\n let lastTheme;\n return function styleMemoized(props) {\n let value = lastValue;\n if (value === undefined || props.theme !== lastTheme) {\n arg.theme = props.theme;\n value = preprocessStyles(styleFn(arg));\n lastValue = value;\n lastTheme = props.theme;\n }\n return value;\n };\n}","import { unstable_memoTheme } from '@mui/system';\nconst memoTheme = unstable_memoTheme;\nexport default memoTheme;","/**\n * @mui/styled-engine v6.1.10\n *\n * @license MIT\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n/* eslint-disable no-underscore-dangle */\nimport emStyled from '@emotion/styled';\nimport { serializeStyles as emSerializeStyles } from '@emotion/serialize';\nexport default function styled(tag, options) {\n const stylesFactory = emStyled(tag, options);\n if (process.env.NODE_ENV !== 'production') {\n return (...styles) => {\n const component = typeof tag === 'string' ? `\"${tag}\"` : 'component';\n if (styles.length === 0) {\n console.error([`MUI: Seems like you called \\`styled(${component})()\\` without a \\`style\\` argument.`, 'You must provide a `styles` argument: `styled(\"div\")(styleYouForgotToPass)`.'].join('\\n'));\n } else if (styles.some(style => style === undefined)) {\n console.error(`MUI: the styled(${component})(...args) API requires all its args to be defined.`);\n }\n return stylesFactory(...styles);\n };\n }\n return stylesFactory;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function internal_mutateStyles(tag, processor) {\n // Emotion attaches all the styles as `__emotion_styles`.\n // Ref: https://github.com/emotion-js/emotion/blob/16d971d0da229596d6bcc39d282ba9753c9ee7cf/packages/styled/src/base.js#L186\n if (Array.isArray(tag.__emotion_styles)) {\n tag.__emotion_styles = processor(tag.__emotion_styles);\n }\n}\n\n// Emotion only accepts an array, but we want to avoid allocations\nconst wrapper = [];\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function internal_serializeStyles(styles) {\n wrapper[0] = styles;\n return emSerializeStyles(wrapper);\n}\nexport { ThemeContext, keyframes, css } from '@emotion/react';\nexport { default as StyledEngineProvider } from \"./StyledEngineProvider/index.js\";\nexport { default as GlobalStyles } from \"./GlobalStyles/index.js\";","'use client';\n\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport resolveProps from '@mui/utils/resolveProps';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PropsContext = /*#__PURE__*/React.createContext(undefined);\nfunction DefaultPropsProvider({\n value,\n children\n}) {\n return /*#__PURE__*/_jsx(PropsContext.Provider, {\n value: value,\n children: children\n });\n}\nprocess.env.NODE_ENV !== \"production\" ? DefaultPropsProvider.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * @ignore\n */\n children: PropTypes.node,\n /**\n * @ignore\n */\n value: PropTypes.object\n} : void 0;\nfunction getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name]) {\n return props;\n }\n const config = theme.components[name];\n if (config.defaultProps) {\n // compatible with v5 signature\n return resolveProps(config.defaultProps, props);\n }\n if (!config.styleOverrides && !config.variants) {\n // v6 signature, no property 'defaultProps'\n return resolveProps(config, props);\n }\n return props;\n}\nexport function useDefaultProps({\n props,\n name\n}) {\n const ctx = React.useContext(PropsContext);\n return getThemeProps({\n props,\n name,\n theme: {\n components: ctx\n }\n });\n}\nexport default DefaultPropsProvider;","import styledEngineStyled, { internal_mutateStyles as mutateStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from \"../createTheme/index.js\";\nimport styleFunctionSx from \"../styleFunctionSx/index.js\";\nimport preprocessStyles from \"../preprocessStyles.js\";\n\n/* eslint-disable no-underscore-dangle */\n/* eslint-disable no-labels */\n/* eslint-disable no-lone-blocks */\n\nexport const systemDefaultTheme = createTheme();\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (_props, styles) => styles[slot];\n}\nfunction attachTheme(props, themeId, defaultTheme) {\n props.theme = isObjectEmpty(props.theme) ? defaultTheme : props.theme[themeId] || props.theme;\n}\nfunction processStyle(props, style) {\n /*\n * Style types:\n * - null/undefined\n * - string\n * - CSS style object: { [cssKey]: [cssValue], variants }\n * - Processed style object: { style, variants, isProcessed: true }\n * - Array of any of the above\n */\n\n const resolvedStyle = typeof style === 'function' ? style(props) : style;\n if (Array.isArray(resolvedStyle)) {\n return resolvedStyle.flatMap(subStyle => processStyle(props, subStyle));\n }\n if (Array.isArray(resolvedStyle?.variants)) {\n let rootStyle;\n if (resolvedStyle.isProcessed) {\n rootStyle = resolvedStyle.style;\n } else {\n const {\n variants,\n ...otherStyles\n } = resolvedStyle;\n rootStyle = otherStyles;\n }\n return processStyleVariants(props, resolvedStyle.variants, [rootStyle]);\n }\n if (resolvedStyle?.isProcessed) {\n return resolvedStyle.style;\n }\n return resolvedStyle;\n}\nfunction processStyleVariants(props, variants, results = []) {\n let mergedState; // We might not need it, initialized lazily\n\n variantLoop: for (let i = 0; i < variants.length; i += 1) {\n const variant = variants[i];\n if (typeof variant.props === 'function') {\n mergedState ??= {\n ...props,\n ...props.ownerState,\n ownerState: props.ownerState\n };\n if (!variant.props(mergedState)) {\n continue;\n }\n } else {\n for (const key in variant.props) {\n if (props[key] !== variant.props[key] && props.ownerState?.[key] !== variant.props[key]) {\n continue variantLoop;\n }\n }\n }\n if (typeof variant.style === 'function') {\n mergedState ??= {\n ...props,\n ...props.ownerState,\n ownerState: props.ownerState\n };\n results.push(variant.style(mergedState));\n } else {\n results.push(variant.style);\n }\n }\n return results;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n function styleAttachTheme(props) {\n attachTheme(props, themeId, defaultTheme);\n }\n const styled = (tag, inputOptions = {}) => {\n // If `tag` is already a styled component, filter out the `sx` style function\n // to prevent unnecessary styles generated by the composite components.\n mutateStyles(tag, styles => styles.filter(style => style !== styleFunctionSx));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot)),\n ...options\n } = inputOptions;\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, {\n shouldForwardProp: shouldForwardPropOption,\n label: generateStyledLabel(componentName, componentSlot),\n ...options\n });\n const transformStyle = style => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof style === 'function' && style.__emotion_real !== style) {\n return function styleFunctionProcessor(props) {\n return processStyle(props, style);\n };\n }\n if (isPlainObject(style)) {\n const serialized = preprocessStyles(style);\n if (!serialized.variants) {\n return serialized.style;\n }\n return function styleObjectProcessor(props) {\n return processStyle(props, serialized);\n };\n }\n return style;\n };\n const muiStyledResolver = (...expressionsInput) => {\n const expressionsHead = [];\n const expressionsBody = expressionsInput.map(transformStyle);\n const expressionsTail = [];\n\n // Preprocess `props` to set the scoped theme value.\n // This must run before any other expression.\n expressionsHead.push(styleAttachTheme);\n if (componentName && overridesResolver) {\n expressionsTail.push(function styleThemeOverrides(props) {\n const theme = props.theme;\n const styleOverrides = theme.components?.[componentName]?.styleOverrides;\n if (!styleOverrides) {\n return null;\n }\n const resolvedStyleOverrides = {};\n\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n // eslint-disable-next-line guard-for-in\n for (const slotKey in styleOverrides) {\n resolvedStyleOverrides[slotKey] = processStyle(props, styleOverrides[slotKey]);\n }\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsTail.push(function styleThemeVariants(props) {\n const theme = props.theme;\n const themeVariants = theme?.components?.[componentName]?.variants;\n if (!themeVariants) {\n return null;\n }\n return processStyleVariants(props, themeVariants);\n });\n }\n if (!skipSx) {\n expressionsTail.push(styleFunctionSx);\n }\n\n // This function can be called as a tagged template, so the first argument would contain\n // CSS `string[]` values.\n if (Array.isArray(expressionsBody[0])) {\n const inputStrings = expressionsBody.shift();\n\n // We need to add placeholders in the tagged template for the custom functions we have\n // possibly added (attachTheme, overrides, variants, and sx).\n const placeholdersHead = new Array(expressionsHead.length).fill('');\n const placeholdersTail = new Array(expressionsTail.length).fill('');\n let outputStrings;\n // prettier-ignore\n {\n outputStrings = [...placeholdersHead, ...inputStrings, ...placeholdersTail];\n outputStrings.raw = [...placeholdersHead, ...inputStrings.raw, ...placeholdersTail];\n }\n\n // The only case where we put something before `attachTheme`\n expressionsHead.unshift(outputStrings);\n }\n const expressions = [...expressionsHead, ...expressionsBody, ...expressionsTail];\n const Component = defaultStyledResolver(...expressions);\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n if (process.env.NODE_ENV !== 'production') {\n Component.displayName = generateDisplayName(componentName, componentSlot, tag);\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n return styled;\n}\nfunction generateDisplayName(componentName, componentSlot, tag) {\n if (componentName) {\n return `${componentName}${capitalize(componentSlot || '')}`;\n }\n return `Styled(${getDisplayName(tag)})`;\n}\nfunction generateStyledLabel(componentName, componentSlot) {\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n return label;\n}\nfunction isObjectEmpty(object) {\n // eslint-disable-next-line\n for (const _ in object) {\n return false;\n }\n return true;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\nfunction lowercaseFirstLetter(string) {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n}","import { internal_serializeStyles } from '@mui/styled-engine';\nexport default function preprocessStyles(input) {\n const {\n variants,\n ...style\n } = input;\n const result = {\n variants,\n style: internal_serializeStyles(style),\n isProcessed: true\n };\n\n // Not supported on styled-components\n if (result.style === style) {\n return result;\n }\n if (variants) {\n variants.forEach(variant => {\n if (typeof variant.style !== 'function') {\n variant.style = internal_serializeStyles(variant.style);\n }\n });\n }\n return result;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","/* eslint no-restricted-syntax: 0, prefer-template: 0, guard-for-in: 0\n ---\n These rules are preventing the performance optimizations below.\n */\n\nexport default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n for (const slotName in slots) {\n const slot = slots[slotName];\n let buffer = '';\n let start = true;\n for (let i = 0; i < slot.length; i += 1) {\n const value = slot[i];\n if (value) {\n buffer += (start === true ? '' : ' ') + getUtilityClass(value);\n start = false;\n if (classes && classes[value]) {\n buffer += ' ' + classes[value];\n }\n }\n }\n output[slotName] = buffer;\n }\n return output;\n}","import ClassNameGenerator from \"../ClassNameGenerator/index.js\";\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from \"../generateUtilityClass/index.js\";\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param defaultProps\n * @param props\n * @returns resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = {\n ...props\n };\n for (const key in defaultProps) {\n if (Object.prototype.hasOwnProperty.call(defaultProps, key)) {\n const propName = key;\n if (propName === 'components' || propName === 'slots') {\n output[propName] = {\n ...defaultProps[propName],\n ...output[propName]\n };\n } else if (propName === 'componentsProps' || propName === 'slotProps') {\n const defaultSlotProps = defaultProps[propName];\n const slotProps = props[propName];\n if (!slotProps) {\n output[propName] = defaultSlotProps || {};\n } else if (!defaultSlotProps) {\n output[propName] = slotProps;\n } else {\n output[propName] = {\n ...slotProps\n };\n for (const slotKey in defaultSlotProps) {\n if (Object.prototype.hasOwnProperty.call(defaultSlotProps, slotKey)) {\n const slotPropName = slotKey;\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n }\n }\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n }\n }\n return output;\n}","/**\n * @license React\n * react-jsx-runtime.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var f=require(\"react\"),k=Symbol.for(\"react.element\"),l=Symbol.for(\"react.fragment\"),m=Object.prototype.hasOwnProperty,n=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p={key:!0,ref:!0,__self:!0,__source:!0};\nfunction q(c,a,g){var b,d={},e=null,h=null;void 0!==g&&(e=\"\"+g);void 0!==a.key&&(e=\"\"+a.key);void 0!==a.ref&&(h=a.ref);for(b in a)m.call(a,b)&&!p.hasOwnProperty(b)&&(d[b]=a[b]);if(c&&c.defaultProps)for(b in a=c.defaultProps,a)void 0===d[b]&&(d[b]=a[b]);return{$$typeof:k,type:c,key:e,ref:h,props:d,_owner:n.current}}exports.Fragment=l;exports.jsx=q;exports.jsxs=q;\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","function r(e){var t,f,n=\"\";if(\"string\"==typeof e||\"number\"==typeof e)n+=e;else if(\"object\"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t{re.r(mo),re.d(mo,{ArrowDropDownIcon:()=>bo,ArrowLeftIcon:()=>yo,ArrowRightIcon:()=>go,CalendarIcon:()=>cn,ClearIcon:()=>xo,ClockIcon:()=>Ao,DEFAULT_DESKTOP_MODE_MEDIA_QUERY:()=>Qt,DateCalendar:()=>js,DateField:()=>Ln,DatePicker:()=>Su,DatePickerToolbar:()=>$s,DateRangeIcon:()=>Co,DateTimeField:()=>jn,DateTimePicker:()=>fd,DateTimePickerTabs:()=>tr,DateTimePickerToolbar:()=>or,DayCalendarSkeleton:()=>wc,DesktopDatePicker:()=>Xn,DesktopDateTimePicker:()=>ro,DesktopDateTimePickerLayout:()=>sr,DesktopTimePicker:()=>no,DigitalClock:()=>_o,LocalizationProvider:()=>ln,MobileDatePicker:()=>Zn,MobileDateTimePicker:()=>ao,MobileTimePicker:()=>oo,MonthCalendar:()=>Ts,MuiPickersAdapterContext:()=>Ht,MultiSectionDigitalClock:()=>os,PickersActionBar:()=>zs,PickersCalendarHeader:()=>Vs,PickersDay:()=>is,PickersFilledInput:()=>Vn,PickersInput:()=>Fn,PickersInputBase:()=>en,PickersLayout:()=>sn,PickersLayoutContentWrapper:()=>Kn,PickersLayoutRoot:()=>Yn,PickersOutlinedInput:()=>Rn,PickersShortcuts:()=>Us,PickersTextField:()=>tn,StaticDatePicker:()=>Xs,StaticDateTimePicker:()=>rr,StaticTimePicker:()=>qs,TimeClock:()=>Xo,TimeField:()=>Nn,TimeIcon:()=>vo,TimePicker:()=>Xu,TimePickerToolbar:()=>Qs,Unstable_PickersSectionList:()=>bs,Unstable_PickersSectionListRoot:()=>wn,Unstable_PickersSectionListSection:()=>Sn,Unstable_PickersSectionListSectionContent:()=>Mn,Unstable_PickersSectionListSectionSeparator:()=>Tn,YearCalendar:()=>Is,clockClasses:()=>Er,clockNumberClasses:()=>Ft,clockPointerClasses:()=>Rr,dateCalendarClasses:()=>pc,datePickerToolbarClasses:()=>Fc,dateTimePickerTabsClasses:()=>qu,dateTimePickerToolbarClasses:()=>rn,dayCalendarClasses:()=>gl,dayCalendarSkeletonClasses:()=>Ac,digitalClockClasses:()=>qo,extractValidationProps:()=>nt,getDateCalendarUtilityClass:()=>Ns,getDayCalendarSkeletonUtilityClass:()=>Es,getDigitalClockUtilityClass:()=>Jo,getMonthCalendarUtilityClass:()=>Ss,getMultiSectionDigitalClockUtilityClass:()=>es,getPickersDayUtilityClass:()=>ss,getPickersFilledInputUtilityClass:()=>ys,getPickersInputBaseUtilityClass:()=>ps,getPickersInputUtilityClass:()=>gs,getPickersOutlinedInputUtilityClass:()=>ms,getPickersSectionListUtilityClass:()=>hs,getPickersTextFieldUtilityClass:()=>ds,getTimeClockUtilityClass:()=>To,getYearCalendarUtilityClass:()=>Ms,monthCalendarClasses:()=>Bl,multiSectionDigitalClockClasses:()=>An,multiSectionDigitalClockSectionClasses:()=>ts,pickersCalendarHeaderClasses:()=>Rs,pickersDayClasses:()=>Ye,pickersFadeTransitionGroupClasses:()=>tl,pickersFilledInputClasses:()=>Ge,pickersInputBaseClasses:()=>ot,pickersInputClasses:()=>At,pickersLayoutClasses:()=>Oe,pickersMonthClasses:()=>Nt,pickersOutlinedInputClasses:()=>Fe,pickersSectionListClasses:()=>gt,pickersSlideTransitionClasses:()=>Me,pickersTextFieldClasses:()=>mi,pickersYearClasses:()=>jt,renderDateViewCalendar:()=>De,renderDigitalClockTimeView:()=>to,renderMultiSectionDigitalClockTimeView:()=>Bt,renderTimeViewClock:()=>Re,timeClockClasses:()=>kr,timePickerToolbarClasses:()=>Dt,unstable_useDateField:()=>cs,unstable_useDateTimeField:()=>Cs,unstable_useTimeField:()=>As,useClearableField:()=>Jt,useParsedFormat:()=>hd,usePickerLayout:()=>Un,usePickersContext:()=>bd,usePickersTranslations:()=>xe,useSplitFieldProps:()=>Zt,useValidation:()=>vn,validateDate:()=>Ke,validateDateTime:()=>Ct,validateTime:()=>st,yearCalendarClasses:()=>Zl});var m=re(8168),ie=re(8587),b=re(8437),fo=re.n(b),fe=re(4984),lr=re(5973),r=re.n(lr),W=re(6186),pe=re(8399),he=re(7413),it=re(8871),y=re(4922);const cr=["localeText"],Ht=b.createContext(null),ln=function(t){var D;const{localeText:o}=t,n=(0,ie.A)(t,cr),{utils:s,localeText:a}=(D=b.useContext(Ht))!=null?D:{utils:void 0,localeText:void 0},i=(0,pe.A)({props:n,name:"MuiLocalizationProvider"}),{children:c,dateAdapter:l,dateFormats:u,dateLibInstance:d,adapterLocale:p,localeText:f}=i,A=b.useMemo(()=>(0,m.A)({},f,a,o),[f,a,o]),h=b.useMemo(()=>{if(!l)return s||null;const v=new l({locale:p,formats:u,instance:d});if(!v.isMUIAdapter)throw new Error(["MUI X: The date adapter should be imported from `@mui/x-date-pickers` or `@mui/x-date-pickers-pro`, not from `@date-io`","For example, `import { AdapterDayjs } from '@mui/x-date-pickers/AdapterDayjs'` instead of `import AdapterDayjs from '@date-io/dayjs'`","More information on the installation documentation: https://mui.com/x/react-date-pickers/getting-started/#installation"].join(` +`));return v},[l,p,u,d,s]),C=b.useMemo(()=>h?{minDate:h.date("1900-01-01T00:00:00.000"),maxDate:h.date("2099-12-31T00:00:00.000")}:null,[h]),g=b.useMemo(()=>({utils:h,defaultDates:C,localeText:A}),[C,h,A]);return(0,y.jsx)(Ht.Provider,{value:g,children:c})},ur=e=>({components:{MuiLocalizationProvider:{defaultProps:{localeText:(0,m.A)({},e)}}}}),lt=e=>{const{utils:t,formatKey:o,contextTranslation:n,propsTranslation:s}=e;return a=>{const i=a!==null&&t.isValid(a)?t.format(a,o):null;return(s!=null?s:n)(a,t,i)}},ho={previousMonth:"Previous month",nextMonth:"Next month",openPreviousView:"Open previous view",openNextView:"Open next view",calendarViewSwitchingButtonAriaLabel:e=>e==="year"?"year view is open, switch to calendar view":"calendar view is open, switch to year view",start:"Start",end:"End",startDate:"Start date",startTime:"Start time",endDate:"End date",endTime:"End time",cancelButtonLabel:"Cancel",clearButtonLabel:"Clear",okButtonLabel:"OK",todayButtonLabel:"Today",datePickerToolbarTitle:"Select date",dateTimePickerToolbarTitle:"Select date & time",timePickerToolbarTitle:"Select time",dateRangePickerToolbarTitle:"Select date range",clockLabelText:(e,t,o,n)=>`Select ${e}. ${!n&&(t===null||!o.isValid(t))?"No time selected":`Selected time is ${n!=null?n:o.format(t,"fullTime")}`}`,hoursClockNumberText:e=>`${e} hours`,minutesClockNumberText:e=>`${e} minutes`,secondsClockNumberText:e=>`${e} seconds`,selectViewText:e=>`Select ${e}`,calendarWeekNumberHeaderLabel:"Week number",calendarWeekNumberHeaderText:"#",calendarWeekNumberAriaLabelText:e=>`Week ${e}`,calendarWeekNumberText:e=>`${e}`,openDatePickerDialogue:(e,t,o)=>o||e!==null&&t.isValid(e)?`Choose date, selected date is ${o!=null?o:t.format(e,"fullDate")}`:"Choose date",openTimePickerDialogue:(e,t,o)=>o||e!==null&&t.isValid(e)?`Choose time, selected time is ${o!=null?o:t.format(e,"fullTime")}`:"Choose time",fieldClearLabel:"Clear",timeTableLabel:"pick time",dateTableLabel:"pick date",fieldYearPlaceholder:e=>"Y".repeat(e.digitAmount),fieldMonthPlaceholder:e=>e.contentType==="letter"?"MMMM":"MM",fieldDayPlaceholder:()=>"DD",fieldWeekDayPlaceholder:e=>e.contentType==="letter"?"EEEE":"EE",fieldHoursPlaceholder:()=>"hh",fieldMinutesPlaceholder:()=>"mm",fieldSecondsPlaceholder:()=>"ss",fieldMeridiemPlaceholder:()=>"aa",year:"Year",month:"Month",day:"Day",weekDay:"Week day",hours:"Hours",minutes:"Minutes",seconds:"Seconds",meridiem:"Meridiem",empty:"Empty"},dr=ho,Dd=ur(ho),Ze=()=>{const e=b.useContext(Ht);if(e===null)throw new Error(["MUI X: Can not find the date and time pickers localization context.","It looks like you forgot to wrap your component in LocalizationProvider.","This can also happen if you are bundling multiple versions of the `@mui/x-date-pickers` package"].join(` +`));if(e.utils===null)throw new Error(["MUI X: Can not find the date and time pickers adapter from its localization context.","It looks like you forgot to pass a `dateAdapter` to your LocalizationProvider."].join(` +`));const t=b.useMemo(()=>(0,m.A)({},dr,e.localeText),[e.localeText]);return b.useMemo(()=>(0,m.A)({},e,{localeText:t}),[e,t])},me=()=>Ze().utils,Je=()=>Ze().defaultDates,qe=e=>{const t=me(),o=b.useRef();return o.current===void 0&&(o.current=t.date(void 0,e)),o.current},xe=()=>Ze().localeText;var ze=re(5437),we=re(9262),ge=re(3547),ct=re(5325),Ue=re(5131);const bo=(0,Ue.A)((0,y.jsx)("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown"),yo=(0,Ue.A)((0,y.jsx)("path",{d:"M15.41 16.59L10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z"}),"ArrowLeft"),go=(0,Ue.A)((0,y.jsx)("path",{d:"M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"}),"ArrowRight"),cn=(0,Ue.A)((0,y.jsx)("path",{d:"M17 12h-5v5h5v-5zM16 1v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2h-1V1h-2zm3 18H5V8h14v11z"}),"Calendar"),Ao=(0,Ue.A)((0,y.jsxs)(b.Fragment,{children:[(0,y.jsx)("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),(0,y.jsx)("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]}),"Clock"),Co=(0,Ue.A)((0,y.jsx)("path",{d:"M9 11H7v2h2v-2zm4 0h-2v2h2v-2zm4 0h-2v2h2v-2zm2-7h-1V2h-2v2H8V2H6v2H5c-1.11 0-1.99.9-1.99 2L3 20c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H5V9h14v11z"}),"DateRange"),vo=(0,Ue.A)((0,y.jsxs)(b.Fragment,{children:[(0,y.jsx)("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),(0,y.jsx)("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]}),"Time"),xo=(0,Ue.A)((0,y.jsx)("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Clear");var be=re(3899),ye=re(2679);function pr(e){return(0,be.Ay)("MuiPickersArrowSwitcher",e)}const kd=(0,ye.A)("MuiPickersArrowSwitcher",["root","spacer","button","previousIconButton","nextIconButton","leftArrowIcon","rightArrowIcon"]),mr=["children","className","slots","slotProps","isNextDisabled","isNextHidden","onGoToNext","nextLabel","isPreviousDisabled","isPreviousHidden","onGoToPrevious","previousLabel","labelId"],fr=["ownerState"],hr=["ownerState"],br=(0,W.Ay)("div",{name:"MuiPickersArrowSwitcher",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex"}),yr=(0,W.Ay)("div",{name:"MuiPickersArrowSwitcher",slot:"Spacer",overridesResolver:(e,t)=>t.spacer})(({theme:e})=>({width:e.spacing(3)})),Do=(0,W.Ay)(ct.A,{name:"MuiPickersArrowSwitcher",slot:"Button",overridesResolver:(e,t)=>t.button})({variants:[{props:{hidden:!0},style:{visibility:"hidden"}}]}),gr=e=>{const{classes:t}=e,o={root:["root"],spacer:["spacer"],button:["button"],previousIconButton:["previousIconButton"],nextIconButton:["nextIconButton"],leftArrowIcon:["leftArrowIcon"],rightArrowIcon:["rightArrowIcon"]};return(0,he.A)(o,pr,t)},ko=b.forwardRef(function(t,o){var _,Z,Y,te;const n=(0,we.I)(),s=(0,pe.A)({props:t,name:"MuiPickersArrowSwitcher"}),{children:a,className:i,slots:c,slotProps:l,isNextDisabled:u,isNextHidden:d,onGoToNext:p,nextLabel:f,isPreviousDisabled:A,isPreviousHidden:h,onGoToPrevious:C,previousLabel:g,labelId:D}=s,v=(0,ie.A)(s,mr),k=s,P=gr(k),w={isDisabled:u,isHidden:d,goTo:p,label:f},T={isDisabled:A,isHidden:h,goTo:C,label:g},M=(_=c==null?void 0:c.previousIconButton)!=null?_:Do,x=(0,ge.A)({elementType:M,externalSlotProps:l==null?void 0:l.previousIconButton,additionalProps:{size:"medium",title:T.label,"aria-label":T.label,disabled:T.isDisabled,edge:"end",onClick:T.goTo},ownerState:(0,m.A)({},k,{hidden:T.isHidden}),className:(0,fe.A)(P.button,P.previousIconButton)}),R=(Z=c==null?void 0:c.nextIconButton)!=null?Z:Do,V=(0,ge.A)({elementType:R,externalSlotProps:l==null?void 0:l.nextIconButton,additionalProps:{size:"medium",title:w.label,"aria-label":w.label,disabled:w.isDisabled,edge:"start",onClick:w.goTo},ownerState:(0,m.A)({},k,{hidden:w.isHidden}),className:(0,fe.A)(P.button,P.nextIconButton)}),S=(Y=c==null?void 0:c.leftArrowIcon)!=null?Y:yo,N=(0,ge.A)({elementType:S,externalSlotProps:l==null?void 0:l.leftArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:k,className:P.leftArrowIcon}),j=(0,ie.A)(N,fr),F=(te=c==null?void 0:c.rightArrowIcon)!=null?te:go,E=(0,ge.A)({elementType:F,externalSlotProps:l==null?void 0:l.rightArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:k,className:P.rightArrowIcon}),H=(0,ie.A)(E,hr);return(0,y.jsxs)(br,(0,m.A)({ref:o,className:(0,fe.A)(P.root,i),ownerState:k},v,{children:[(0,y.jsx)(M,(0,m.A)({},x,{children:n?(0,y.jsx)(F,(0,m.A)({},H)):(0,y.jsx)(S,(0,m.A)({},j))})),a?(0,y.jsx)(ze.A,{variant:"subtitle1",component:"span",id:D,children:a}):(0,y.jsx)(yr,{className:P.spacer,ownerState:k}),(0,y.jsx)(R,(0,m.A)({},V,{children:n?(0,y.jsx)(S,(0,m.A)({},j)):(0,y.jsx)(F,(0,m.A)({},H))}))]}))}),Ee=(e,t)=>e.length!==t.length?!1:t.every(o=>e.includes(o)),un=({openTo:e,defaultOpenTo:t,views:o,defaultViews:n})=>{const s=o!=null?o:n;let a;if(e!=null)a=e;else if(s.includes(t))a=t;else if(s.length>0)a=s[0];else throw new Error("MUI X: The `views` prop must contain at least one view.");return{views:s,openTo:a}},Po=["hours","minutes","seconds"],ut=e=>Po.includes(e),kt=e=>Po.includes(e)||e==="meridiem",Ar=(e,t)=>e?t.getHours(e)>=12?"pm":"am":null,Pt=(e,t,o)=>o&&(e>=12?"pm":"am")!==t?t==="am"?e-12:e+12:e,Cr=(e,t,o,n)=>{const s=Pt(n.getHours(e),t,o);return n.setHours(e,s)},wo=(e,t)=>t.getHours(e)*3600+t.getMinutes(e)*60+t.getSeconds(e),wt=(e,t)=>(o,n)=>e?t.isAfter(o,n):wo(o,t)>wo(n,t),Wt=(e,{format:t,views:o,ampm:n})=>{if(t!=null)return t;const s=e.formats;return Ee(o,["hours"])?n?`${s.hours12h} ${s.meridiem}`:s.hours24h:Ee(o,["minutes"])?s.minutes:Ee(o,["seconds"])?s.seconds:Ee(o,["minutes","seconds"])?`${s.minutes}:${s.seconds}`:Ee(o,["hours","minutes","seconds"])?n?`${s.hours12h}:${s.minutes}:${s.seconds} ${s.meridiem}`:`${s.hours24h}:${s.minutes}:${s.seconds}`:n?`${s.hours12h}:${s.minutes} ${s.meridiem}`:`${s.hours24h}:${s.minutes}`};var oe=re(1733),_e=re(8319);let Pd=!1;function St({onChange:e,onViewChange:t,openTo:o,view:n,views:s,autoFocus:a,focusedView:i,onFocusedViewChange:c}){var M,x;const l=b.useRef(o),u=b.useRef(s),d=b.useRef(s.includes(o)?o:s[0]),[p,f]=(0,_e.A)({name:"useViews",state:"view",controlled:n,default:d.current}),A=b.useRef(a?p:null),[h,C]=(0,_e.A)({name:"useViews",state:"focusedView",controlled:i,default:A.current});b.useEffect(()=>{(l.current&&l.current!==o||u.current&&u.current.some(R=>!s.includes(R)))&&(f(s.includes(o)?o:s[0]),u.current=s,l.current=o)},[o,f,p,s]);const g=s.indexOf(p),D=(M=s[g-1])!=null?M:null,v=(x=s[g+1])!=null?x:null,k=(0,oe.A)((R,V)=>{C(V?R:S=>R===S?null:S),c==null||c(R,V)}),P=(0,oe.A)(R=>{k(R,!0),R!==p&&(f(R),t&&t(R))}),w=(0,oe.A)(()=>{v&&P(v)}),T=(0,oe.A)((R,V,S)=>{const N=V==="finish",j=S?s.indexOf(S){const a=s.date(void 0,n),i=s.startOfMonth(t&&s.isBefore(a,o)?a:o);return!s.isAfter(i,e)},[t,o,e,s,n])}function xr(e,{disablePast:t,minDate:o,timezone:n}){const s=me();return b.useMemo(()=>{const a=s.date(void 0,n),i=s.startOfMonth(t&&s.isAfter(a,o)?a:o);return!s.isBefore(i,e)},[t,o,e,s,n])}function zt(e,t,o,n){const s=me(),a=Ar(e,s),i=b.useCallback(c=>{const l=e==null?null:Cr(e,c,!!t,s);o(l,n!=null?n:"partial")},[t,e,o,n,s]);return{meridiemMode:a,handleMeridiemChange:i}}const et=36,dt=2,Tt=320,Dr=280,Ut=336,So=232,Mt=48,Yt=(0,W.Ay)("div")({overflow:"hidden",width:Tt,maxHeight:Ut,display:"flex",flexDirection:"column",margin:"0 auto"});function To(e){return(0,be.Ay)("MuiTimeClock",e)}const kr=(0,ye.A)("MuiTimeClock",["root","arrowSwitcher"]);var He=re(4251);const pt=220,We=36,It={x:pt/2,y:pt/2},Mo={x:It.x,y:0},Pr=Mo.x-It.x,wr=Mo.y-It.y,Sr=e=>e*(180/Math.PI),Io=(e,t,o)=>{const n=t-It.x,s=o-It.y,a=Math.atan2(Pr,wr)-Math.atan2(n,s);let i=Sr(a);i=Math.round(i/e)*e,i%=360;const c=Math.floor(i/e)||0,l=po(n,2)+po(s,2),u=Math.sqrt(l);return{value:c,distance:u}},Tr=(e,t,o=1)=>{const n=o*6;let{value:s}=Io(n,e,t);return s=s*o%60,s},Mr=(e,t,o)=>{const{value:n,distance:s}=Io(30,e,t);let a=n||12;return o?a%=12:s{const{classes:t}=e,o={root:["root"],thumb:["thumb"]};return(0,he.A)(o,Ir,t)},Or=(0,W.Ay)("div",{name:"MuiClockPointer",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({width:2,backgroundColor:(e.vars||e).palette.primary.main,position:"absolute",left:"calc(50% - 1px)",bottom:"50%",transformOrigin:"center bottom 0px",variants:[{props:{shouldAnimate:!0},style:{transition:e.transitions.create(["transform","height"])}}]})),Lr=(0,W.Ay)("div",{name:"MuiClockPointer",slot:"Thumb",overridesResolver:(e,t)=>t.thumb})(({theme:e})=>({width:4,height:4,backgroundColor:(e.vars||e).palette.primary.contrastText,borderRadius:"50%",position:"absolute",top:-21,left:`calc(50% - ${We/2}px)`,border:`${(We-4)/2}px solid ${(e.vars||e).palette.primary.main}`,boxSizing:"content-box",variants:[{props:{hasSelected:!0},style:{backgroundColor:(e.vars||e).palette.primary.main}}]}));function Nr(e){const t=(0,pe.A)({props:e,name:"MuiClockPointer"}),{className:o,isInner:n,type:s,viewValue:a}=t,i=(0,ie.A)(t,Vr),c=b.useRef(s);b.useEffect(()=>{c.current=s},[s]);const l=(0,m.A)({},t,{shouldAnimate:c.current!==s}),u=Fr(l),d=()=>{let f=360/(s==="hours"?12:60)*a;return s==="hours"&&a>12&&(f-=360),{height:Math.round((n?.26:.4)*pt),transform:`rotateZ(${f}deg)`}};return(0,y.jsx)(Or,(0,m.A)({style:d(),className:(0,fe.A)(u.root,o),ownerState:l},i,{children:(0,y.jsx)(Lr,{ownerState:l,className:u.thumb})}))}function jr(e){return(0,be.Ay)("MuiClock",e)}const Er=(0,ye.A)("MuiClock",["root","clock","wrapper","squareMask","pin","amButton","pmButton","meridiemText","selected"]),Kt=(e,t,o)=>{let n=t;return n=e.setHours(n,e.getHours(o)),n=e.setMinutes(n,e.getMinutes(o)),n=e.setSeconds(n,e.getSeconds(o)),n=e.setMilliseconds(n,e.getMilliseconds(o)),n},Rt=({date:e,disableFuture:t,disablePast:o,maxDate:n,minDate:s,isDateDisabled:a,utils:i,timezone:c})=>{const l=Kt(i,i.date(void 0,c),e);o&&i.isBefore(s,l)&&(s=l),t&&i.isAfter(n,l)&&(n=l);let u=e,d=e;for(i.isBefore(e,s)&&(u=s,d=null),i.isAfter(e,n)&&(d&&(d=n),u=null);u||d;){if(u&&i.isAfter(u,n)&&(u=null),d&&i.isBefore(d,s)&&(d=null),u){if(!a(u))return u;u=i.addDays(u,1)}if(d){if(!a(d))return d;d=i.addDays(d,-1)}}return null},Br=(e,t)=>t==null||!e.isValid(t)?null:t,Pe=(e,t,o)=>t==null||!e.isValid(t)?o:t,$r=(e,t,o)=>!e.isValid(t)&&t!=null&&!e.isValid(o)&&o!=null?!0:e.isEqual(t,o),dn=(e,t)=>{const n=[e.startOfYear(t)];for(;n.length<12;){const s=n[n.length-1];n.push(e.addMonths(s,1))}return n},pn=(e,t,o)=>o==="date"?e.startOfDay(e.date(void 0,t)):e.date(void 0,t),Ne=(e,t)=>{const o=e.setHours(e.date(),t==="am"?2:14);return e.format(o,"meridiem")},Hr=["year","month","day"],mt=e=>Hr.includes(e),Vt=(e,{format:t,views:o},n)=>{if(t!=null)return t;const s=e.formats;return Ee(o,["year"])?s.year:Ee(o,["month"])?s.month:Ee(o,["day"])?s.dayOfMonth:Ee(o,["month","year"])?`${s.month} ${s.year}`:Ee(o,["day","month"])?`${s.month} ${s.dayOfMonth}`:n?/en/.test(e.getCurrentLocaleCode())?s.normalDateWithWeekday:s.normalDate:s.keyboardDate},Wr=(e,t)=>{const o=e.startOfWeek(t);return[0,1,2,3,4,5,6].map(n=>e.addDays(o,n))},zr=e=>{const{classes:t,meridiemMode:o}=e,n={root:["root"],clock:["clock"],wrapper:["wrapper"],squareMask:["squareMask"],pin:["pin"],amButton:["amButton",o==="am"&&"selected"],pmButton:["pmButton",o==="pm"&&"selected"],meridiemText:["meridiemText"]};return(0,he.A)(n,jr,t)},Ur=(0,W.Ay)("div",{name:"MuiClock",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({display:"flex",justifyContent:"center",alignItems:"center",margin:e.spacing(2)})),Yr=(0,W.Ay)("div",{name:"MuiClock",slot:"Clock",overridesResolver:(e,t)=>t.clock})({backgroundColor:"rgba(0,0,0,.07)",borderRadius:"50%",height:220,width:220,flexShrink:0,position:"relative",pointerEvents:"none"}),Kr=(0,W.Ay)("div",{name:"MuiClock",slot:"Wrapper",overridesResolver:(e,t)=>t.wrapper})({"&:focus":{outline:"none"}}),Gr=(0,W.Ay)("div",{name:"MuiClock",slot:"SquareMask",overridesResolver:(e,t)=>t.squareMask})({width:"100%",height:"100%",position:"absolute",pointerEvents:"auto",outline:0,touchAction:"none",userSelect:"none",variants:[{props:{disabled:!1},style:{"@media (pointer: fine)":{cursor:"pointer",borderRadius:"50%"},"&:active":{cursor:"move"}}}]}),Xr=(0,W.Ay)("div",{name:"MuiClock",slot:"Pin",overridesResolver:(e,t)=>t.pin})(({theme:e})=>({width:6,height:6,borderRadius:"50%",backgroundColor:(e.vars||e).palette.primary.main,position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"})),Ro=(e,t)=>({zIndex:1,bottom:8,paddingLeft:4,paddingRight:4,width:We,variants:[{props:{meridiemMode:t},style:{backgroundColor:(e.vars||e).palette.primary.main,color:(e.vars||e).palette.primary.contrastText,"&:hover":{backgroundColor:(e.vars||e).palette.primary.light}}}]}),Qr=(0,W.Ay)(ct.A,{name:"MuiClock",slot:"AmButton",overridesResolver:(e,t)=>t.amButton})(({theme:e})=>(0,m.A)({},Ro(e,"am"),{position:"absolute",left:8})),Zr=(0,W.Ay)(ct.A,{name:"MuiClock",slot:"PmButton",overridesResolver:(e,t)=>t.pmButton})(({theme:e})=>(0,m.A)({},Ro(e,"pm"),{position:"absolute",right:8})),Vo=(0,W.Ay)(ze.A,{name:"MuiClock",slot:"meridiemText",overridesResolver:(e,t)=>t.meridiemText})({overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"});function Jr(e){const t=(0,pe.A)({props:e,name:"MuiClock"}),{ampm:o,ampmInClock:n,autoFocus:s,children:a,value:i,handleMeridiemChange:c,isTimeDisabled:l,meridiemMode:u,minutesStep:d=1,onChange:p,selectedId:f,type:A,viewValue:h,disabled:C=!1,readOnly:g,className:D}=t,v=t,k=me(),P=xe(),w=b.useRef(!1),T=zr(v),M=l(h,A),x=!o&&A==="hours"&&(h<1||h>12),R=(Y,te)=>{C||g||l(Y,A)||p(Y,te)},V=(Y,te)=>{let{offsetX:se,offsetY:le}=Y;if(se===void 0){const ce=Y.target.getBoundingClientRect();se=Y.changedTouches[0].clientX-ce.left,le=Y.changedTouches[0].clientY-ce.top}const de=A==="seconds"||A==="minutes"?Tr(se,le,d):Mr(se,le,!!o);R(de,te)},S=Y=>{w.current=!0,V(Y,"shallow")},N=Y=>{w.current&&(V(Y,"finish"),w.current=!1),Y.preventDefault()},j=Y=>{Y.buttons>0&&V(Y.nativeEvent,"shallow")},F=Y=>{w.current&&(w.current=!1),V(Y.nativeEvent,"finish")},E=b.useMemo(()=>A==="hours"?!0:h%5===0,[A,h]),H=A==="minutes"?d:1,_=b.useRef(null);(0,He.A)(()=>{s&&_.current.focus()},[s]);const Z=Y=>{if(!w.current)switch(Y.key){case"Home":R(0,"partial"),Y.preventDefault();break;case"End":R(A==="minutes"?59:23,"partial"),Y.preventDefault();break;case"ArrowUp":R(h+H,"partial"),Y.preventDefault();break;case"ArrowDown":R(h-H,"partial"),Y.preventDefault();break;case"PageUp":R(h+5,"partial"),Y.preventDefault();break;case"PageDown":R(h-5,"partial"),Y.preventDefault();break;case"Enter":case" ":R(h,"finish"),Y.preventDefault();break;default:}};return(0,y.jsxs)(Ur,{className:(0,fe.A)(T.root,D),children:[(0,y.jsxs)(Yr,{className:T.clock,children:[(0,y.jsx)(Gr,{onTouchMove:S,onTouchStart:S,onTouchEnd:N,onMouseUp:F,onMouseMove:j,ownerState:{disabled:C},className:T.squareMask}),!M&&(0,y.jsxs)(b.Fragment,{children:[(0,y.jsx)(Xr,{className:T.pin}),i!=null&&(0,y.jsx)(Nr,{type:A,viewValue:h,isInner:x,hasSelected:E})]}),(0,y.jsx)(Kr,{"aria-activedescendant":f,"aria-label":P.clockLabelText(A,i,k,i==null?null:k.format(i,"fullTime")),ref:_,role:"listbox",onKeyDown:Z,tabIndex:0,className:T.wrapper,children:a})]}),o&&n&&(0,y.jsxs)(b.Fragment,{children:[(0,y.jsx)(Qr,{onClick:g?void 0:()=>c("am"),disabled:C||u===null,ownerState:v,className:T.amButton,title:Ne(k,"am"),children:(0,y.jsx)(Vo,{variant:"caption",className:T.meridiemText,children:Ne(k,"am")})}),(0,y.jsx)(Zr,{disabled:C||u===null,onClick:g?void 0:()=>c("pm"),ownerState:v,className:T.pmButton,title:Ne(k,"pm"),children:(0,y.jsx)(Vo,{variant:"caption",className:T.meridiemText,children:Ne(k,"pm")})})]})]})}function qr(e){return(0,be.Ay)("MuiClockNumber",e)}const Ft=(0,ye.A)("MuiClockNumber",["root","selected","disabled"]),_r=["className","disabled","index","inner","label","selected"],ea=e=>{const{classes:t,selected:o,disabled:n}=e,s={root:["root",o&&"selected",n&&"disabled"]};return(0,he.A)(s,qr,t)},ta=(0,W.Ay)("span",{name:"MuiClockNumber",slot:"Root",overridesResolver:(e,t)=>[t.root,{[`&.${Ft.disabled}`]:t.disabled},{[`&.${Ft.selected}`]:t.selected}]})(({theme:e})=>({height:We,width:We,position:"absolute",left:`calc((100% - ${We}px) / 2)`,display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:"50%",color:(e.vars||e).palette.text.primary,fontFamily:e.typography.fontFamily,"&:focused":{backgroundColor:(e.vars||e).palette.background.paper},[`&.${Ft.selected}`]:{color:(e.vars||e).palette.primary.contrastText},[`&.${Ft.disabled}`]:{pointerEvents:"none",color:(e.vars||e).palette.text.disabled},variants:[{props:{inner:!0},style:(0,m.A)({},e.typography.body2,{color:(e.vars||e).palette.text.secondary})}]}));function Fo(e){const t=(0,pe.A)({props:e,name:"MuiClockNumber"}),{className:o,disabled:n,index:s,inner:a,label:i,selected:c}=t,l=(0,ie.A)(t,_r),u=t,d=ea(u),p=s%12/12*Math.PI*2-Math.PI/2,f=(pt-We-2)/2*(a?.65:1),A=Math.round(Math.cos(p)*f),h=Math.round(Math.sin(p)*f);return(0,y.jsx)(ta,(0,m.A)({className:(0,fe.A)(d.root,o),"aria-disabled":n?!0:void 0,"aria-selected":c?!0:void 0,role:"option",style:{transform:`translate(${A}px, ${h+(pt-We)/2}px`},ownerState:u},l,{children:i}))}const na=({ampm:e,value:t,getClockNumberText:o,isDisabled:n,selectedId:s,utils:a})=>{const i=t?a.getHours(t):null,c=[],l=e?1:0,u=e?12:23,d=p=>i===null?!1:e?p===12?i===12||i===0:i===p||i-12===p:i===p;for(let p=l;p<=u;p+=1){let f=p.toString();p===0&&(f="00");const A=!e&&(p===0||p>12);f=a.formatNumber(f);const h=d(p);c.push((0,y.jsx)(Fo,{id:h?s:void 0,index:p,inner:A,selected:h,disabled:n(p),label:f,"aria-label":o(f)},p))}return c},Oo=({utils:e,value:t,isDisabled:o,getClockNumberText:n,selectedId:s})=>{const a=e.formatNumber;return[[5,a("05")],[10,a("10")],[15,a("15")],[20,a("20")],[25,a("25")],[30,a("30")],[35,a("35")],[40,a("40")],[45,a("45")],[50,a("50")],[55,a("55")],[0,a("00")]].map(([i,c],l)=>{const u=i===t;return(0,y.jsx)(Fo,{label:c,id:u?s:void 0,index:l+1,inner:!1,disabled:o(i),selected:u,"aria-label":n(c)},i)})},mn=({timezone:e,value:t,defaultValue:o,referenceDate:n,onChange:s,valueManager:a})=>{var h;const i=me(),c=b.useRef(o),l=(h=t!=null?t:c.current)!=null?h:a.emptyValue,u=b.useMemo(()=>a.getTimezone(i,l),[i,a,l]),d=(0,oe.A)(C=>u==null?C:a.setTimezone(i,u,C));let p;e?p=e:u?p=u:n?p=i.getTimezone(n):p="default";const f=b.useMemo(()=>a.setTimezone(i,p,l),[a,i,p,l]),A=(0,oe.A)((C,...g)=>{const D=d(C);s==null||s(D,...g)});return{value:f,handleValueChange:A,timezone:p}},ft=({name:e,timezone:t,value:o,defaultValue:n,referenceDate:s,onChange:a,valueManager:i})=>{const[c,l]=(0,_e.A)({name:e,state:"value",controlled:o,default:n!=null?n:i.emptyValue}),u=(0,oe.A)((d,...p)=>{l(d),a==null||a(d,...p)});return mn({timezone:t,value:c,defaultValue:void 0,referenceDate:s,onChange:u,valueManager:i})},je={year:1,month:2,day:3,hours:4,minutes:5,seconds:6,milliseconds:7},oa=e=>Math.max(...e.map(t=>{var o;return(o=je[t.type])!=null?o:1})),Ot=(e,t,o)=>{if(t===je.year)return e.startOfYear(o);if(t===je.month)return e.startOfMonth(o);if(t===je.day)return e.startOfDay(o);let n=o;return t{var c;let a=s?s():Ot(t,o,pn(t,n));e.minDate!=null&&t.isAfterDay(e.minDate,a)&&(a=Ot(t,o,e.minDate)),e.maxDate!=null&&t.isBeforeDay(e.maxDate,a)&&(a=Ot(t,o,e.maxDate));const i=wt((c=e.disableIgnoringDatePartForTimeValidation)!=null?c:!1,t);return e.minTime!=null&&i(e.minTime,a)&&(a=Ot(t,o,e.disableIgnoringDatePartForTimeValidation?e.minTime:Kt(t,a,e.minTime))),e.maxTime!=null&&i(a,e.maxTime)&&(a=Ot(t,o,e.disableIgnoringDatePartForTimeValidation?e.maxTime:Kt(t,a,e.maxTime))),a},Lo=(e,t)=>{const o=e.formatTokenMap[t];if(o==null)throw new Error([`MUI X: The token "${t}" is not supported by the Date and Time Pickers.`,"Please try using another token or open an issue on https://github.com/mui/mui-x/issues/new/choose if you think it should be supported."].join(` +`));return typeof o=="string"?{type:o,contentType:o==="meridiem"?"letter":"digit",maxLength:void 0}:{type:o.sectionType,contentType:o.contentType,maxLength:o.maxLength}},ra=e=>{switch(e){case"ArrowUp":return 1;case"ArrowDown":return-1;case"PageUp":return 5;case"PageDown":return-5;default:return 0}},Gt=(e,t)=>{const o=[],n=e.date(void 0,"default"),s=e.startOfWeek(n),a=e.endOfWeek(n);let i=s;for(;e.isBefore(i,a);)o.push(i),i=e.addDays(i,1);return o.map(c=>e.formatByString(c,t))},No=(e,t,o,n)=>{switch(o){case"month":return dn(e,e.date(void 0,t)).map(s=>e.formatByString(s,n));case"weekDay":return Gt(e,n);case"meridiem":{const s=e.date(void 0,t);return[e.startOfDay(s),e.endOfDay(s)].map(a=>e.formatByString(a,n))}default:return[]}},jo="s",aa=["0","1","2","3","4","5","6","7","8","9"],Eo=e=>{const t=e.date(void 0);return e.formatByString(e.setSeconds(t,0),jo)==="0"?aa:Array.from({length:10}).map((n,s)=>e.formatByString(e.setSeconds(t,s),jo))},tt=(e,t)=>{if(t[0]==="0")return e;const o=[];let n="";for(let s=0;s-1&&(o.push(a.toString()),n="")}return o.join("")},fn=(e,t)=>t[0]==="0"?e:e.split("").map(o=>t[Number(o)]).join(""),Bo=(e,t)=>{const o=tt(e,t);return o!==" "&&!Number.isNaN(Number(o))},$o=(e,t)=>{let o=e;for(o=Number(o).toString();o.length{if(s.type==="day"&&s.contentType==="digit-with-letter"){const i=e.setDate(o.longestMonth,t);return e.formatByString(i,s.format)}let a=t.toString();return s.hasLeadingZerosInInput&&(a=$o(a,s.maxLength)),fn(a,n)},ia=(e,t,o,n,s,a,i,c)=>{const l=ra(n),u=n==="Home",d=n==="End",p=o.value===""||u||d,f=()=>{const h=s[o.type]({currentDate:i,format:o.format,contentType:o.contentType}),C=k=>Ho(e,k,h,a,o),g=o.type==="minutes"&&(c!=null&&c.minutesStep)?c.minutesStep:1;let v=parseInt(tt(o.value,a),10)+l*g;if(p){if(o.type==="year"&&!d&&!u)return e.formatByString(e.date(void 0,t),o.format);l>0||u?v=h.minimum:v=h.maximum}return v%g!==0&&((l<0||u)&&(v+=g-(g+v)%g),(l>0||d)&&(v-=v%g)),v>h.maximum?C(h.minimum+(v-h.maximum-1)%(h.maximum-h.minimum+1)):v{const h=No(e,t,o.type,o.format);if(h.length===0)return o.value;if(p)return l>0||u?h[0]:h[h.length-1];const D=((h.indexOf(o.value)+l)%h.length+h.length)%h.length;return h[D]};return o.contentType==="digit"||o.contentType==="digit-with-letter"?f():A()},hn=(e,t,o)=>{let n=e.value||e.placeholder;const s=t==="non-input"?e.hasLeadingZerosInFormat:e.hasLeadingZerosInInput;return t==="non-input"&&e.hasLeadingZerosInInput&&!e.hasLeadingZerosInFormat&&(n=Number(tt(n,o)).toString()),["input-rtl","input-ltr"].includes(t)&&e.contentType==="digit"&&!s&&n.length===1&&(n=`${n}\u200E`),t==="input-rtl"&&(n=`\u2068${n}\u2069`),n},Wo=(e,t,o,n)=>e.formatByString(e.parse(t,o),n),zo=(e,t)=>e.formatByString(e.date(void 0,"system"),t).length===4,Uo=(e,t,o,n)=>{if(t!=="digit")return!1;const s=e.date(void 0,"default");switch(o){case"year":return zo(e,n)?e.formatByString(e.setYear(s,1),n)==="0001":e.formatByString(e.setYear(s,2001),n)==="01";case"month":return e.formatByString(e.startOfYear(s),n).length>1;case"day":return e.formatByString(e.startOfMonth(s),n).length>1;case"weekDay":return e.formatByString(e.startOfWeek(s),n).length>1;case"hours":return e.formatByString(e.setHours(s,1),n).length>1;case"minutes":return e.formatByString(e.setMinutes(s,1),n).length>1;case"seconds":return e.formatByString(e.setSeconds(s,1),n).length>1;default:throw new Error("Invalid section type")}},la=(e,t,o)=>{const n=t.some(l=>l.type==="day"),s=[],a=[];for(let l=0;le.map(t=>`${t.startSeparator}${t.value||t.placeholder}${t.endSeparator}`).join(""),ua=(e,t,o)=>{const s=e.map(a=>{const i=hn(a,o?"input-rtl":"input-ltr",t);return`${a.startSeparator}${i}${a.endSeparator}`}).join("");return o?`\u2066${s}\u2069`:s},da=(e,t,o)=>{const n=e.date(void 0,o),s=e.endOfYear(n),a=e.endOfDay(n),{maxDaysInMonth:i,longestMonth:c}=dn(e,n).reduce((l,u)=>{const d=e.getDaysInMonth(u);return d>l.maxDaysInMonth?{maxDaysInMonth:d,longestMonth:u}:l},{maxDaysInMonth:0,longestMonth:null});return{year:({format:l})=>({minimum:0,maximum:zo(e,l)?9999:99}),month:()=>({minimum:1,maximum:e.getMonth(s)+1}),day:({currentDate:l})=>({minimum:1,maximum:l!=null&&e.isValid(l)?e.getDaysInMonth(l):i,longestMonth:c}),weekDay:({format:l,contentType:u})=>{if(u==="digit"){const d=Gt(e,l).map(Number);return{minimum:Math.min(...d),maximum:Math.max(...d)}}return{minimum:1,maximum:7}},hours:({format:l})=>{const u=e.getHours(a);return tt(e.formatByString(e.endOfDay(n),l),t)!==u.toString()?{minimum:1,maximum:Number(tt(e.formatByString(e.startOfDay(n),l),t))}:{minimum:0,maximum:u}},minutes:()=>({minimum:0,maximum:e.getMinutes(a)}),seconds:()=>({minimum:0,maximum:e.getSeconds(a)}),meridiem:()=>({minimum:0,maximum:1}),empty:()=>({minimum:0,maximum:0})}};let wd=!1;const Yo=(e,t)=>{},pa=(e,t,o,n)=>{switch(t.type){case"year":return e.setYear(n,e.getYear(o));case"month":return e.setMonth(n,e.getMonth(o));case"weekDay":{const s=Gt(e,t.format),a=e.formatByString(o,t.format),i=s.indexOf(a),l=s.indexOf(t.value)-i;return e.addDays(o,l)}case"day":return e.setDate(n,e.getDate(o));case"meridiem":{const s=e.getHours(o)<12,a=e.getHours(n);return s&&a>=12?e.addHours(n,-12):!s&&a<12?e.addHours(n,12):n}case"hours":return e.setHours(n,e.getHours(o));case"minutes":return e.setMinutes(n,e.getMinutes(o));case"seconds":return e.setSeconds(n,e.getSeconds(o));default:return n}},Ko={year:1,month:2,day:3,weekDay:4,hours:5,minutes:6,seconds:7,meridiem:8,empty:9},Go=(e,t,o,n,s)=>[...o].sort((a,i)=>Ko[a.type]-Ko[i.type]).reduce((a,i)=>!s||i.modified?pa(e,i,t,a):a,n),ma=()=>navigator.userAgent.toLowerCase().includes("android"),fa=(e,t)=>{const o={};if(!t)return e.forEach((l,u)=>{const d=u===0?null:u-1,p=u===e.length-1?null:u+1;o[u]={leftIndex:d,rightIndex:p}}),{neighbors:o,startIndex:0,endIndex:e.length-1};const n={},s={};let a=0,i=0,c=e.length-1;for(;c>=0;){i=e.findIndex((l,u)=>{var d;return u>=a&&((d=l.endSeparator)==null?void 0:d.includes(" "))&&l.endSeparator!==" / "}),i===-1&&(i=e.length-1);for(let l=i;l>=a;l-=1)s[l]=c,n[c]=l,c-=1;a=i+1}return e.forEach((l,u)=>{const d=s[u],p=d===0?null:n[d-1],f=d===e.length-1?null:n[d+1];o[u]={leftIndex:p,rightIndex:f}}),{neighbors:o,startIndex:n[0],endIndex:n[e.length-1]}},bn=(e,t)=>{if(e==null)return null;if(e==="all")return"all";if(typeof e=="string"){const o=t.findIndex(n=>n.type===e);return o===-1?null:o}return e},ha=(e,t)=>{if(e.value)switch(e.type){case"month":{if(e.contentType==="digit")return t.format(t.setMonth(t.date(),Number(e.value)-1),"month");const o=t.parse(e.value,e.format);return o?t.format(o,"month"):void 0}case"day":return e.contentType==="digit"?t.format(t.setDate(t.startOfYear(t.date()),Number(e.value)),"dayOfMonthFull"):e.value;case"weekDay":return;default:return}},ba=(e,t)=>{if(e.value)switch(e.type){case"weekDay":return e.contentType==="letter"?void 0:Number(e.value);case"meridiem":{const o=t.parse(`01:00 ${e.value}`,`${t.formats.hours12h}:${t.formats.minutes} ${e.format}`);return o?t.getHours(o)>=12?1:0:void 0}case"day":return e.contentType==="digit-with-letter"?parseInt(e.value,10):Number(e.value);case"month":{if(e.contentType==="digit")return Number(e.value);const o=t.parse(e.value,e.format);return o?t.getMonth(o)+1:void 0}default:return e.contentType!=="letter"?Number(e.value):void 0}},ya=["value","referenceDate"],Ce={emptyValue:null,getTodayValue:pn,getInitialReferenceValue:e=>{let{value:t,referenceDate:o}=e,n=(0,ie.A)(e,ya);return t!=null&&n.utils.isValid(t)?t:o!=null?o:sa(n)},cleanValue:Br,areValuesEqual:$r,isSameError:(e,t)=>e===t,hasError:e=>e!=null,defaultErrorState:null,getTimezone:(e,t)=>t==null||!e.isValid(t)?null:e.getTimezone(t),setTimezone:(e,t,o)=>o==null?null:e.setTimezone(o,t)},yn={updateReferenceValue:(e,t,o)=>t==null||!e.isValid(t)?o:t,getSectionsFromValue:(e,t,o,n)=>!e.isValid(t)&&!!o?o:n(t),getV7HiddenInputValueFromSections:ca,getV6InputValueFromSections:ua,getActiveDateManager:(e,t)=>({date:t.value,referenceDate:t.referenceValue,getSections:o=>o,getNewValuesFromNewActiveDate:o=>({value:o,referenceValue:o==null||!e.isValid(o)?t.referenceValue:o})}),parseValueStr:(e,t,o)=>o(e.trim(),t)},gn=({value:e,referenceDate:t,utils:o,props:n,timezone:s})=>{const a=b.useMemo(()=>Ce.getInitialReferenceValue({value:e,utils:o,props:n,referenceDate:t,granularity:je.day,timezone:s,getTodayDate:()=>pn(o,s,"date")}),[]);return e!=null?e:a},ga=["ampm","ampmInClock","autoFocus","slots","slotProps","value","defaultValue","referenceDate","disableIgnoringDatePartForTimeValidation","maxTime","minTime","disableFuture","disablePast","minutesStep","shouldDisableTime","showViewSwitcher","onChange","view","views","openTo","onViewChange","focusedView","onFocusedViewChange","className","disabled","readOnly","timezone"],Aa=e=>{const{classes:t}=e,o={root:["root"],arrowSwitcher:["arrowSwitcher"]};return(0,he.A)(o,To,t)},Ca=(0,W.Ay)(Yt,{name:"MuiTimeClock",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexDirection:"column",position:"relative"}),va=(0,W.Ay)(ko,{name:"MuiTimeClock",slot:"ArrowSwitcher",overridesResolver:(e,t)=>t.arrowSwitcher})({position:"absolute",right:12,top:15}),xa=["hours","minutes"],Xo=b.forwardRef(function(t,o){const n=me(),s=(0,pe.A)({props:t,name:"MuiTimeClock"}),{ampm:a=n.is12HourCycleInCurrentLocale(),ampmInClock:i=!1,autoFocus:c,slots:l,slotProps:u,value:d,defaultValue:p,referenceDate:f,disableIgnoringDatePartForTimeValidation:A=!1,maxTime:h,minTime:C,disableFuture:g,disablePast:D,minutesStep:v=1,shouldDisableTime:k,showViewSwitcher:P,onChange:w,view:T,views:M=xa,openTo:x,onViewChange:R,focusedView:V,onFocusedViewChange:S,className:N,disabled:j,readOnly:F,timezone:E}=s,H=(0,ie.A)(s,ga),{value:_,handleValueChange:Z,timezone:Y}=ft({name:"TimeClock",timezone:E,value:d,defaultValue:p,referenceDate:f,onChange:w,valueManager:Ce}),te=gn({value:_,referenceDate:f,utils:n,props:s,timezone:Y}),se=xe(),le=qe(Y),{view:de,setView:ce,previousView:U,nextView:ne,setValueAndGoToNextView:G}=St({view:T,views:M,openTo:x,onViewChange:R,onChange:Z,focusedView:V,onFocusedViewChange:S}),{meridiemMode:O,handleMeridiemChange:B}=zt(te,a,G),ae=b.useCallback((X,$)=>{const Q=wt(A,n),L=$==="hours"||$==="minutes"&&M.includes("seconds"),z=({start:ue,end:Ae})=>!(C&&Q(C,Ae)||h&&Q(ue,h)||g&&Q(ue,le)||D&&Q(le,L?Ae:ue)),J=(ue,Ae=1)=>{if(ue%Ae!==0)return!1;if(k)switch($){case"hours":return!k(n.setHours(te,ue),"hours");case"minutes":return!k(n.setMinutes(te,ue),"minutes");case"seconds":return!k(n.setSeconds(te,ue),"seconds");default:return!1}return!0};switch($){case"hours":{const ue=Pt(X,O,a),Ae=n.setHours(te,ue),Le=n.setSeconds(n.setMinutes(Ae,0),0),at=n.setSeconds(n.setMinutes(Ae,59),59);return!z({start:Le,end:at})||!J(ue)}case"minutes":{const ue=n.setMinutes(te,X),Ae=n.setSeconds(ue,0),Le=n.setSeconds(ue,59);return!z({start:Ae,end:Le})||!J(X,v)}case"seconds":{const ue=n.setSeconds(te,X);return!z({start:ue,end:ue})||!J(X)}default:throw new Error("not supported")}},[a,te,A,h,O,C,v,k,n,g,D,le,M]),ee=(0,it.A)(),q=b.useMemo(()=>{switch(de){case"hours":{const X=($,Q)=>{const L=Pt($,O,a);G(n.setHours(te,L),Q,"hours")};return{onChange:X,viewValue:n.getHours(te),children:na({value:_,utils:n,ampm:a,onChange:X,getClockNumberText:se.hoursClockNumberText,isDisabled:$=>j||ae($,"hours"),selectedId:ee})}}case"minutes":{const X=n.getMinutes(te),$=(Q,L)=>{G(n.setMinutes(te,Q),L,"minutes")};return{viewValue:X,onChange:$,children:Oo({utils:n,value:X,onChange:$,getClockNumberText:se.minutesClockNumberText,isDisabled:Q=>j||ae(Q,"minutes"),selectedId:ee})}}case"seconds":{const X=n.getSeconds(te),$=(Q,L)=>{G(n.setSeconds(te,Q),L,"seconds")};return{viewValue:X,onChange:$,children:Oo({utils:n,value:X,onChange:$,getClockNumberText:se.secondsClockNumberText,isDisabled:Q=>j||ae(Q,"seconds"),selectedId:ee})}}default:throw new Error("You must provide the type for ClockView")}},[de,n,_,a,se.hoursClockNumberText,se.minutesClockNumberText,se.secondsClockNumberText,O,G,te,ae,ee,j]),I=s,K=Aa(I);return(0,y.jsxs)(Ca,(0,m.A)({ref:o,className:(0,fe.A)(K.root,N),ownerState:I},H,{children:[(0,y.jsx)(Jr,(0,m.A)({autoFocus:c!=null?c:!!V,ampmInClock:i&&M.includes("hours"),value:_,type:de,ampm:a,minutesStep:v,isTimeDisabled:ae,meridiemMode:O,handleMeridiemChange:B,selectedId:ee,disabled:j,readOnly:F},q)),P&&(0,y.jsx)(va,{className:K.arrowSwitcher,slots:l,slotProps:u,onGoToPrevious:()=>ce(U),isPreviousDisabled:!U,previousLabel:se.openPreviousView,onGoToNext:()=>ce(ne),isNextDisabled:!ne,nextLabel:se.openNextView,ownerState:I})]}))});var Be=re(8889),Qo=re(5471),Zo=re(705),Se=re(2181);function Jo(e){return(0,be.Ay)("MuiDigitalClock",e)}const qo=(0,ye.A)("MuiDigitalClock",["root","list","item"]);function ht(e,t){return Array.isArray(t)?t.every(o=>e.indexOf(o)!==-1):e.indexOf(t)!==-1}const Da=(e,t)=>o=>{(o.key==="Enter"||o.key===" ")&&(e(o),o.preventDefault(),o.stopPropagation()),t&&t(o)},Sd=e=>{setTimeout(e,0)},Te=(e=document)=>{const t=e.activeElement;return t?t.shadowRoot?Te(t.shadowRoot):t:null},Xt=e=>Array.from(e.children).indexOf(Te(document)),Qt="@media (pointer: fine)",ka=["ampm","timeStep","autoFocus","slots","slotProps","value","defaultValue","referenceDate","disableIgnoringDatePartForTimeValidation","maxTime","minTime","disableFuture","disablePast","minutesStep","shouldDisableTime","onChange","view","openTo","onViewChange","focusedView","onFocusedViewChange","className","disabled","readOnly","views","skipDisabled","timezone"],Pa=e=>{const{classes:t}=e,o={root:["root"],list:["list"],item:["item"]};return(0,he.A)(o,Jo,t)},wa=(0,W.Ay)(Yt,{name:"MuiDigitalClock",slot:"Root",overridesResolver:(e,t)=>t.root})({overflowY:"auto",width:"100%","@media (prefers-reduced-motion: no-preference)":{scrollBehavior:"auto"},maxHeight:So,variants:[{props:{alreadyRendered:!0},style:{"@media (prefers-reduced-motion: no-preference)":{scrollBehavior:"smooth"}}}]}),Sa=(0,W.Ay)(Zo.A,{name:"MuiDigitalClock",slot:"List",overridesResolver:(e,t)=>t.list})({padding:0}),Ta=(0,W.Ay)(Qo.A,{name:"MuiDigitalClock",slot:"Item",overridesResolver:(e,t)=>t.item})(({theme:e})=>({padding:"8px 16px",margin:"2px 4px","&:first-of-type":{marginTop:4},"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,Be.X4)(e.palette.primary.main,e.palette.action.hoverOpacity)},"&.Mui-selected":{backgroundColor:(e.vars||e).palette.primary.main,color:(e.vars||e).palette.primary.contrastText,"&:focus-visible, &:hover":{backgroundColor:(e.vars||e).palette.primary.dark}},"&.Mui-focusVisible":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.focusOpacity})`:(0,Be.X4)(e.palette.primary.main,e.palette.action.focusOpacity)}})),_o=b.forwardRef(function(t,o){var Q;const n=me(),s=b.useRef(null),a=(0,Se.A)(o,s),i=b.useRef(null),c=(0,pe.A)({props:t,name:"MuiDigitalClock"}),{ampm:l=n.is12HourCycleInCurrentLocale(),timeStep:u=30,autoFocus:d,slots:p,slotProps:f,value:A,defaultValue:h,referenceDate:C,disableIgnoringDatePartForTimeValidation:g=!1,maxTime:D,minTime:v,disableFuture:k,disablePast:P,minutesStep:w=1,shouldDisableTime:T,onChange:M,view:x,openTo:R,onViewChange:V,focusedView:S,onFocusedViewChange:N,className:j,disabled:F,readOnly:E,views:H=["hours"],skipDisabled:_=!1,timezone:Z}=c,Y=(0,ie.A)(c,ka),{value:te,handleValueChange:se,timezone:le}=ft({name:"DigitalClock",timezone:Z,value:A,defaultValue:h,referenceDate:C,onChange:M,valueManager:Ce}),de=xe(),ce=qe(le),U=b.useMemo(()=>(0,m.A)({},c,{alreadyRendered:!!s.current}),[c]),ne=Pa(U),G=(Q=p==null?void 0:p.digitalClockItem)!=null?Q:Ta,O=(0,ge.A)({elementType:G,externalSlotProps:f==null?void 0:f.digitalClockItem,ownerState:{},className:ne.item}),B=gn({value:te,referenceDate:C,utils:n,props:c,timezone:le}),ae=(0,oe.A)(L=>se(L,"finish","hours")),{setValueAndGoToNextView:ee}=St({view:x,views:H,openTo:R,onViewChange:V,onChange:ae,focusedView:S,onFocusedViewChange:N}),q=(0,oe.A)(L=>{ee(L,"finish")});b.useEffect(()=>{if(s.current===null)return;const L=s.current.querySelector('[role="listbox"] [role="option"][tabindex="0"], [role="listbox"] [role="option"][aria-selected="true"]');if(!L)return;const z=L.offsetTop;(d||S)&&L.focus(),s.current.scrollTop=z-4});const I=b.useCallback(L=>{const z=wt(g,n),J=()=>!(v&&z(v,L)||D&&z(L,D)||k&&z(L,ce)||P&&z(ce,L)),ue=()=>n.getMinutes(L)%w!==0?!1:T?!T(L,"hours"):!0;return!J()||!ue()},[g,n,v,D,k,ce,P,w,T]),K=b.useMemo(()=>{const L=[];let J=n.startOfDay(B);for(;n.isSameDay(B,J);)L.push(J),J=n.addMinutes(J,u);return L},[B,u,n]),X=K.findIndex(L=>n.isEqual(L,B)),$=L=>{switch(L.key){case"PageUp":{const z=Xt(i.current)-5,J=i.current.children,ue=Math.max(0,z),Ae=J[ue];Ae&&Ae.focus(),L.preventDefault();break}case"PageDown":{const z=Xt(i.current)+5,J=i.current.children,ue=Math.min(J.length-1,z),Ae=J[ue];Ae&&Ae.focus(),L.preventDefault();break}default:}};return(0,y.jsx)(wa,(0,m.A)({ref:a,className:(0,fe.A)(ne.root,j),ownerState:U},Y,{children:(0,y.jsx)(Sa,{ref:i,role:"listbox","aria-label":de.timePickerToolbarTitle,className:ne.list,onKeyDown:$,children:K.map((L,z)=>{if(_&&I(L))return null;const J=n.isEqual(L,te),ue=n.format(L,l?"fullTime12h":"fullTime24h"),Ae=X===z||X===-1&&z===0?0:-1;return(0,y.jsx)(G,(0,m.A)({onClick:()=>!E&&q(L),selected:J,disabled:F||I(L),disableRipple:E,role:"option","aria-disabled":E,"aria-selected":J,tabIndex:Ae},O,{children:ue}),`${L.valueOf()}-${ue}`)})})}))});function es(e){return(0,be.Ay)("MuiMultiSectionDigitalClock",e)}const An=(0,ye.A)("MuiMultiSectionDigitalClock",["root"]);function Ma(e){return(0,be.Ay)("MuiMultiSectionDigitalClockSection",e)}const ts=(0,ye.A)("MuiMultiSectionDigitalClockSection",["root","item"]),Ia=["autoFocus","onChange","className","disabled","readOnly","items","active","slots","slotProps","skipDisabled"],Ra=e=>{const{classes:t}=e,o={root:["root"],item:["item"]};return(0,he.A)(o,Ma,t)},Va=(0,W.Ay)(Zo.A,{name:"MuiMultiSectionDigitalClockSection",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({maxHeight:So,width:56,padding:0,overflow:"hidden","@media (prefers-reduced-motion: no-preference)":{scrollBehavior:"auto"},"@media (pointer: fine)":{"&:hover":{overflowY:"auto"}},"@media (pointer: none), (pointer: coarse)":{overflowY:"auto"},"&:not(:first-of-type)":{borderLeft:`1px solid ${(e.vars||e).palette.divider}`},"&::after":{display:"block",content:'""',height:"calc(100% - 40px - 6px)"},variants:[{props:{alreadyRendered:!0},style:{"@media (prefers-reduced-motion: no-preference)":{scrollBehavior:"smooth"}}}]})),Fa=(0,W.Ay)(Qo.A,{name:"MuiMultiSectionDigitalClockSection",slot:"Item",overridesResolver:(e,t)=>t.item})(({theme:e})=>({padding:8,margin:"2px 4px",width:Mt,justifyContent:"center","&:first-of-type":{marginTop:4},"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,Be.X4)(e.palette.primary.main,e.palette.action.hoverOpacity)},"&.Mui-selected":{backgroundColor:(e.vars||e).palette.primary.main,color:(e.vars||e).palette.primary.contrastText,"&:focus-visible, &:hover":{backgroundColor:(e.vars||e).palette.primary.dark}},"&.Mui-focusVisible":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.focusOpacity})`:(0,Be.X4)(e.palette.primary.main,e.palette.action.focusOpacity)}})),Oa=b.forwardRef(function(t,o){var M;const n=b.useRef(null),s=(0,Se.A)(o,n),a=b.useRef(null),i=(0,pe.A)({props:t,name:"MuiMultiSectionDigitalClockSection"}),{autoFocus:c,onChange:l,className:u,disabled:d,readOnly:p,items:f,active:A,slots:h,slotProps:C,skipDisabled:g}=i,D=(0,ie.A)(i,Ia),v=b.useMemo(()=>(0,m.A)({},i,{alreadyRendered:!!n.current}),[i]),k=Ra(v),P=(M=h==null?void 0:h.digitalClockSectionItem)!=null?M:Fa;b.useEffect(()=>{if(n.current===null)return;const x=n.current.querySelector('[role="option"][tabindex="0"], [role="option"][aria-selected="true"]');if(A&&c&&x&&x.focus(),!x||a.current===x)return;a.current=x;const R=x.offsetTop;n.current.scrollTop=R-4});const w=f.findIndex(x=>x.isFocused(x.value)),T=x=>{switch(x.key){case"PageUp":{const R=Xt(n.current)-5,V=n.current.children,S=Math.max(0,R),N=V[S];N&&N.focus(),x.preventDefault();break}case"PageDown":{const R=Xt(n.current)+5,V=n.current.children,S=Math.min(V.length-1,R),N=V[S];N&&N.focus(),x.preventDefault();break}default:}};return(0,y.jsx)(Va,(0,m.A)({ref:s,className:(0,fe.A)(k.root,u),ownerState:v,autoFocusItem:c&&A,role:"listbox",onKeyDown:T},D,{children:f.map((x,R)=>{var F;const V=(F=x.isDisabled)==null?void 0:F.call(x,x.value),S=d||V;if(g&&S)return null;const N=x.isSelected(x.value),j=w===R||w===-1&&R===0?0:-1;return(0,y.jsx)(P,(0,m.A)({onClick:()=>!p&&l(x.value),selected:N,disabled:S,disableRipple:p,role:"option","aria-disabled":p||S||void 0,"aria-label":x.ariaLabel,"aria-selected":N,tabIndex:j,className:k.item},C==null?void 0:C.digitalClockSectionItem,{children:x.label}),x.label)})}))}),La=({now:e,value:t,utils:o,ampm:n,isDisabled:s,resolveAriaLabel:a,timeStep:i,valueOrReferenceDate:c})=>{const l=t?o.getHours(t):null,u=[],d=(A,h)=>{const C=h!=null?h:l;return C===null?!1:n?A===12?C===12||C===0:C===A||C-12===A:C===A},p=A=>d(A,o.getHours(c)),f=n?11:23;for(let A=0;A<=f;A+=i){let h=o.format(o.setHours(e,A),n?"hours12h":"hours24h");const C=a(parseInt(h,10).toString());h=o.formatNumber(h),u.push({value:A,label:h,isSelected:d,isDisabled:s,isFocused:p,ariaLabel:C})}return u},ns=({value:e,utils:t,isDisabled:o,timeStep:n,resolveLabel:s,resolveAriaLabel:a,hasValue:i=!0})=>{const c=u=>e===null?!1:i&&e===u,l=u=>e===u;return[...Array.from({length:Math.ceil(60/n)},(u,d)=>{const p=n*d;return{value:p,label:t.formatNumber(s(p)),isDisabled:o,isSelected:c,isFocused:l,ariaLabel:a(p.toString())}})]},Na=["ampm","timeSteps","autoFocus","slots","slotProps","value","defaultValue","referenceDate","disableIgnoringDatePartForTimeValidation","maxTime","minTime","disableFuture","disablePast","minutesStep","shouldDisableTime","onChange","view","views","openTo","onViewChange","focusedView","onFocusedViewChange","className","disabled","readOnly","skipDisabled","timezone"],ja=e=>{const{classes:t}=e,o={root:["root"]};return(0,he.A)(o,es,t)},Ea=(0,W.Ay)(Yt,{name:"MuiMultiSectionDigitalClock",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({display:"flex",flexDirection:"row",width:"100%",borderBottom:`1px solid ${(e.vars||e).palette.divider}`})),os=b.forwardRef(function(t,o){const n=me(),s=(0,we.I)(),a=(0,pe.A)({props:t,name:"MuiMultiSectionDigitalClock"}),{ampm:i=n.is12HourCycleInCurrentLocale(),timeSteps:c,autoFocus:l,slots:u,slotProps:d,value:p,defaultValue:f,referenceDate:A,disableIgnoringDatePartForTimeValidation:h=!1,maxTime:C,minTime:g,disableFuture:D,disablePast:v,minutesStep:k=1,shouldDisableTime:P,onChange:w,view:T,views:M=["hours","minutes"],openTo:x,onViewChange:R,focusedView:V,onFocusedViewChange:S,className:N,disabled:j,readOnly:F,skipDisabled:E=!1,timezone:H}=a,_=(0,ie.A)(a,Na),{value:Z,handleValueChange:Y,timezone:te}=ft({name:"MultiSectionDigitalClock",timezone:H,value:p,defaultValue:f,referenceDate:A,onChange:w,valueManager:Ce}),se=xe(),le=qe(te),de=b.useMemo(()=>(0,m.A)({hours:1,minutes:5,seconds:5},c),[c]),ce=gn({value:Z,referenceDate:A,utils:n,props:a,timezone:te}),U=(0,oe.A)((z,J,ue)=>Y(z,J,ue)),ne=b.useMemo(()=>!i||!M.includes("hours")||M.includes("meridiem")?M:[...M,"meridiem"],[i,M]),{view:G,setValueAndGoToNextView:O,focusedView:B}=St({view:T,views:ne,openTo:x,onViewChange:R,onChange:U,focusedView:V,onFocusedViewChange:S}),ae=(0,oe.A)(z=>{O(z,"finish","meridiem")}),{meridiemMode:ee,handleMeridiemChange:q}=zt(ce,i,ae,"finish"),I=b.useCallback((z,J)=>{const ue=wt(h,n),Ae=J==="hours"||J==="minutes"&&ne.includes("seconds"),Le=({start:ke,end:Ve})=>!(g&&ue(g,Ve)||C&&ue(ke,C)||D&&ue(ke,le)||v&&ue(le,Ae?Ve:ke)),at=(ke,Ve=1)=>{if(ke%Ve!==0)return!1;if(P)switch(J){case"hours":return!P(n.setHours(ce,ke),"hours");case"minutes":return!P(n.setMinutes(ce,ke),"minutes");case"seconds":return!P(n.setSeconds(ce,ke),"seconds");default:return!1}return!0};switch(J){case"hours":{const ke=Pt(z,ee,i),Ve=n.setHours(ce,ke),Xe=n.setSeconds(n.setMinutes(Ve,0),0),an=n.setSeconds(n.setMinutes(Ve,59),59);return!Le({start:Xe,end:an})||!at(ke)}case"minutes":{const ke=n.setMinutes(ce,z),Ve=n.setSeconds(ke,0),Xe=n.setSeconds(ke,59);return!Le({start:Ve,end:Xe})||!at(z,k)}case"seconds":{const ke=n.setSeconds(ce,z);return!Le({start:ke,end:ke})||!at(z)}default:throw new Error("not supported")}},[i,ce,h,C,ee,g,k,P,n,D,v,le,ne]),K=b.useCallback(z=>{switch(z){case"hours":return{onChange:J=>{const ue=Pt(J,ee,i);O(n.setHours(ce,ue),"finish","hours")},items:La({now:le,value:Z,ampm:i,utils:n,isDisabled:J=>I(J,"hours"),timeStep:de.hours,resolveAriaLabel:se.hoursClockNumberText,valueOrReferenceDate:ce})};case"minutes":return{onChange:J=>{O(n.setMinutes(ce,J),"finish","minutes")},items:ns({value:n.getMinutes(ce),utils:n,isDisabled:J=>I(J,"minutes"),resolveLabel:J=>n.format(n.setMinutes(le,J),"minutes"),timeStep:de.minutes,hasValue:!!Z,resolveAriaLabel:se.minutesClockNumberText})};case"seconds":return{onChange:J=>{O(n.setSeconds(ce,J),"finish","seconds")},items:ns({value:n.getSeconds(ce),utils:n,isDisabled:J=>I(J,"seconds"),resolveLabel:J=>n.format(n.setSeconds(le,J),"seconds"),timeStep:de.seconds,hasValue:!!Z,resolveAriaLabel:se.secondsClockNumberText})};case"meridiem":{const J=Ne(n,"am"),ue=Ne(n,"pm");return{onChange:q,items:[{value:"am",label:J,isSelected:()=>!!Z&&ee==="am",isFocused:()=>!!ce&&ee==="am",ariaLabel:J},{value:"pm",label:ue,isSelected:()=>!!Z&&ee==="pm",isFocused:()=>!!ce&&ee==="pm",ariaLabel:ue}]}}default:throw new Error(`Unknown view: ${z} found.`)}},[le,Z,i,n,de.hours,de.minutes,de.seconds,se.hoursClockNumberText,se.minutesClockNumberText,se.secondsClockNumberText,ee,O,ce,I,q]),X=b.useMemo(()=>{if(!s)return ne;const z=ne.filter(J=>J!=="meridiem");return z.reverse(),ne.includes("meridiem")&&z.push("meridiem"),z},[s,ne]),$=b.useMemo(()=>ne.reduce((z,J)=>(0,m.A)({},z,{[J]:K(J)}),{}),[ne,K]),Q=a,L=ja(Q);return(0,y.jsx)(Ea,(0,m.A)({ref:o,className:(0,fe.A)(L.root,N),ownerState:Q,role:"group"},_,{children:X.map(z=>(0,y.jsx)(Oa,{items:$[z].items,onChange:$[z].onChange,active:G===z,autoFocus:l!=null?l:B===z,disabled:j,readOnly:F,slots:u,slotProps:d,skipDisabled:E,"aria-label":se.selectViewText(z)},z))}))});var Ba=re(1696);function ss(e){return(0,be.Ay)("MuiPickersDay",e)}const Ye=(0,ye.A)("MuiPickersDay",["root","dayWithMargin","dayOutsideMonth","hiddenDaySpacingFiller","today","selected","disabled"]),$a=["autoFocus","className","day","disabled","disableHighlightToday","disableMargin","hidden","isAnimating","onClick","onDaySelect","onFocus","onBlur","onKeyDown","onMouseDown","onMouseEnter","outsideCurrentMonth","selected","showDaysOutsideCurrentMonth","children","today","isFirstVisibleCell","isLastVisibleCell"],Ha=e=>{const{selected:t,disableMargin:o,disableHighlightToday:n,today:s,disabled:a,outsideCurrentMonth:i,showDaysOutsideCurrentMonth:c,classes:l}=e,u=i&&!c,d={root:["root",t&&!u&&"selected",a&&"disabled",!o&&"dayWithMargin",!n&&s&&"today",i&&c&&"dayOutsideMonth",u&&"hiddenDaySpacingFiller"],hiddenDaySpacingFiller:["hiddenDaySpacingFiller"]};return(0,he.A)(d,ss,l)},rs=({theme:e})=>(0,m.A)({},e.typography.caption,{width:et,height:et,borderRadius:"50%",padding:0,backgroundColor:"transparent",transition:e.transitions.create("background-color",{duration:e.transitions.duration.short}),color:(e.vars||e).palette.text.primary,"@media (pointer: fine)":{"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,Be.X4)(e.palette.primary.main,e.palette.action.hoverOpacity)}},"&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.focusOpacity})`:(0,Be.X4)(e.palette.primary.main,e.palette.action.focusOpacity),[`&.${Ye.selected}`]:{willChange:"background-color",backgroundColor:(e.vars||e).palette.primary.dark}},[`&.${Ye.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,fontWeight:e.typography.fontWeightMedium,"&:hover":{willChange:"background-color",backgroundColor:(e.vars||e).palette.primary.dark}},[`&.${Ye.disabled}:not(.${Ye.selected})`]:{color:(e.vars||e).palette.text.disabled},[`&.${Ye.disabled}&.${Ye.selected}`]:{opacity:.6},variants:[{props:{disableMargin:!1},style:{margin:`0 ${dt}px`}},{props:{outsideCurrentMonth:!0,showDaysOutsideCurrentMonth:!0},style:{color:(e.vars||e).palette.text.secondary}},{props:{disableHighlightToday:!1,today:!0},style:{[`&:not(.${Ye.selected})`]:{border:`1px solid ${(e.vars||e).palette.text.secondary}`}}}]}),as=(e,t)=>{const{ownerState:o}=e;return[t.root,!o.disableMargin&&t.dayWithMargin,!o.disableHighlightToday&&o.today&&t.today,!o.outsideCurrentMonth&&o.showDaysOutsideCurrentMonth&&t.dayOutsideMonth,o.outsideCurrentMonth&&!o.showDaysOutsideCurrentMonth&&t.hiddenDaySpacingFiller]},Wa=(0,W.Ay)(Ba.A,{name:"MuiPickersDay",slot:"Root",overridesResolver:as})(rs),za=(0,W.Ay)("div",{name:"MuiPickersDay",slot:"Root",overridesResolver:as})(({theme:e})=>(0,m.A)({},rs({theme:e}),{opacity:0,pointerEvents:"none"})),Lt=()=>{},Ua=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiPickersDay"}),{autoFocus:s=!1,className:a,day:i,disabled:c=!1,disableHighlightToday:l=!1,disableMargin:u=!1,isAnimating:d,onClick:p,onDaySelect:f,onFocus:A=Lt,onBlur:h=Lt,onKeyDown:C=Lt,onMouseDown:g=Lt,onMouseEnter:D=Lt,outsideCurrentMonth:v,selected:k=!1,showDaysOutsideCurrentMonth:P=!1,children:w,today:T=!1}=n,M=(0,ie.A)(n,$a),x=(0,m.A)({},n,{autoFocus:s,disabled:c,disableHighlightToday:l,disableMargin:u,selected:k,showDaysOutsideCurrentMonth:P,today:T}),R=Ha(x),V=me(),S=b.useRef(null),N=(0,Se.A)(S,o);(0,He.A)(()=>{s&&!c&&!d&&!v&&S.current.focus()},[s,c,d,v]);const j=E=>{g(E),v&&E.preventDefault()},F=E=>{c||f(i),v&&E.currentTarget.focus(),p&&p(E)};return v&&!P?(0,y.jsx)(za,{className:(0,fe.A)(R.root,R.hiddenDaySpacingFiller,a),ownerState:x,role:M.role}):(0,y.jsx)(Wa,(0,m.A)({className:(0,fe.A)(R.root,a),ref:N,centerRipple:!0,disabled:c,tabIndex:k?0:-1,onKeyDown:E=>C(E,i),onFocus:E=>A(E,i),onBlur:E=>h(E,i),onMouseEnter:E=>D(E,i),onClick:F,onMouseDown:j},M,{ownerState:x,children:w||V.format(i,"dayOfMonth")}))}),is=b.memo(Ua);var Cn=re(4273);function vn(e){const{props:t,validator:o,value:n,timezone:s,onError:a}=e,i=Ze(),c=b.useRef(o.valueManager.defaultErrorState),l=o({adapter:i,value:n,timezone:s,props:t}),u=o.valueManager.hasError(l);b.useEffect(()=>{a&&!o.valueManager.isSameError(l,c.current)&&a(l,n),c.current=l},[o,a,l,n]);const d=(0,oe.A)(p=>o({adapter:i,value:p,timezone:s,props:t}));return{validationError:l,hasValidationError:u,getValidationErrorForNewValue:d}}const Ya=({utils:e,format:t})=>{let o=10,n=t,s=e.expandFormat(t);for(;s!==n;)if(n=s,s=e.expandFormat(n),o-=1,o<0)throw new Error("MUI X: The format expansion seems to be in an infinite loop. Please open an issue with the format passed to the picker component.");return s},Ka=({utils:e,expandedFormat:t})=>{const o=[],{start:n,end:s}=e.escapedCharacters,a=new RegExp(`(\\${n}[^\\${s}]*\\${s})+`,"g");let i=null;for(;i=a.exec(t);)o.push({start:i.index,end:a.lastIndex-1});return o},Ga=(e,t,o,n)=>{switch(o.type){case"year":return t.fieldYearPlaceholder({digitAmount:e.formatByString(e.date(void 0,"default"),n).length,format:n});case"month":return t.fieldMonthPlaceholder({contentType:o.contentType,format:n});case"day":return t.fieldDayPlaceholder({format:n});case"weekDay":return t.fieldWeekDayPlaceholder({contentType:o.contentType,format:n});case"hours":return t.fieldHoursPlaceholder({format:n});case"minutes":return t.fieldMinutesPlaceholder({format:n});case"seconds":return t.fieldSecondsPlaceholder({format:n});case"meridiem":return t.fieldMeridiemPlaceholder({format:n});default:return n}},Xa=({utils:e,date:t,shouldRespectLeadingZeros:o,localeText:n,localizedDigits:s,now:a,token:i,startSeparator:c})=>{if(i==="")throw new Error("MUI X: Should not call `commitToken` with an empty token");const l=Lo(e,i),u=Uo(e,l.contentType,l.type,i),d=o?u:l.contentType==="digit",p=t!=null&&e.isValid(t);let f=p?e.formatByString(t,i):"",A=null;if(d)if(u)A=f===""?e.formatByString(a,i).length:f.length;else{if(l.maxLength==null)throw new Error(`MUI X: The token ${i} should have a 'maxDigitNumber' property on it's adapter`);A=l.maxLength,p&&(f=fn($o(tt(f,s),A),s))}return(0,m.A)({},l,{format:i,maxLength:A,value:f,placeholder:Ga(e,n,l,i),hasLeadingZerosInFormat:u,hasLeadingZerosInInput:d,startSeparator:c,endSeparator:"",modified:!1})},Qa=e=>{var A;const{utils:t,expandedFormat:o,escapedParts:n}=e,s=t.date(void 0),a=[];let i="";const c=Object.keys(t.formatTokenMap).sort((h,C)=>C.length-h.length),l=/^([a-zA-Z]+)/,u=new RegExp(`^(${c.join("|")})*$`),d=new RegExp(`^(${c.join("|")})`),p=h=>n.find(C=>C.start<=h&&C.end>=h);let f=0;for(;f0;){const v=d.exec(D)[1];D=D.slice(v.length),a.push(Xa((0,m.A)({},e,{now:s,token:v,startSeparator:i}))),i=""}f+=g.length}else{const D=o[f];C&&(h==null?void 0:h.start)===f||(h==null?void 0:h.end)===f||(a.length===0?i+=D:a[a.length-1].endSeparator+=D),f+=1}}return a.length===0&&i.length>0&&a.push({type:"empty",contentType:"letter",maxLength:null,format:"",value:"",placeholder:"",hasLeadingZerosInFormat:!1,hasLeadingZerosInInput:!1,startSeparator:i,endSeparator:"",modified:!1}),a},Za=({isRtl:e,formatDensity:t,sections:o})=>o.map(n=>{const s=a=>{let i=a;return e&&i!==null&&i.includes(" ")&&(i=`\u2069${i}\u2066`),t==="spacious"&&["/",".","-"].includes(i)&&(i=` ${i} `),i};return n.startSeparator=s(n.startSeparator),n.endSeparator=s(n.endSeparator),n}),xn=e=>{let t=Ya(e);e.isRtl&&e.enableAccessibleFieldDOMStructure&&(t=t.split(" ").reverse().join(" "));const o=Ka((0,m.A)({},e,{expandedFormat:t})),n=Qa((0,m.A)({},e,{expandedFormat:t,escapedParts:o}));return Za((0,m.A)({},e,{sections:n}))},Ja=e=>{const t=me(),o=xe(),n=Ze(),s=(0,we.I)(),{valueManager:a,fieldValueManager:i,valueType:c,validator:l,internalProps:u,internalProps:{value:d,defaultValue:p,referenceDate:f,onChange:A,format:h,formatDensity:C="dense",selectedSections:g,onSelectedSectionsChange:D,shouldRespectLeadingZeros:v=!1,timezone:k,enableAccessibleFieldDOMStructure:P=!1}}=e,{timezone:w,value:T,handleValueChange:M}=mn({timezone:k,value:d,defaultValue:p,referenceDate:f,onChange:A,valueManager:a}),x=b.useMemo(()=>Eo(t),[t]),R=b.useMemo(()=>da(t,x,w),[t,x,w]),V=b.useCallback((U,ne=null)=>i.getSectionsFromValue(t,U,ne,G=>xn({utils:t,localeText:o,localizedDigits:x,format:h,date:G,formatDensity:C,shouldRespectLeadingZeros:v,enableAccessibleFieldDOMStructure:P,isRtl:s})),[i,h,o,x,s,v,t,C,P]),[S,N]=b.useState(()=>{const U=V(T);Yo(U,c);const ne={sections:U,value:T,referenceValue:a.emptyValue,tempValueStrAndroid:null},G=oa(U),O=a.getInitialReferenceValue({referenceDate:f,value:T,utils:t,props:u,granularity:G,timezone:w});return(0,m.A)({},ne,{referenceValue:O})}),[j,F]=(0,_e.A)({controlled:g,default:null,name:"useField",state:"selectedSections"}),E=U=>{F(U),D==null||D(U)},H=b.useMemo(()=>bn(j,S.sections),[j,S.sections]),_=H==="all"?0:H,Z=({value:U,referenceValue:ne,sections:G})=>{if(N(B=>(0,m.A)({},B,{sections:G,value:U,referenceValue:ne,tempValueStrAndroid:null})),a.areValuesEqual(t,S.value,U))return;const O={validationError:l({adapter:n,value:U,timezone:w,props:u})};M(U,O)},Y=(U,ne)=>{const G=[...S.sections];return G[U]=(0,m.A)({},G[U],{value:ne,modified:!0}),G},te=()=>{Z({value:a.emptyValue,referenceValue:S.referenceValue,sections:V(a.emptyValue)})},se=()=>{if(_==null)return;const U=S.sections[_],ne=i.getActiveDateManager(t,S,U),O=ne.getSections(S.sections).filter(q=>q.value!=="").length===(U.value===""?0:1),B=Y(_,""),ae=O?null:t.getInvalidDate(),ee=ne.getNewValuesFromNewActiveDate(ae);Z((0,m.A)({},ee,{sections:B}))},le=U=>{const ne=(B,ae)=>{const ee=t.parse(B,h);if(ee==null||!t.isValid(ee))return null;const q=xn({utils:t,localeText:o,localizedDigits:x,format:h,date:ee,formatDensity:C,shouldRespectLeadingZeros:v,enableAccessibleFieldDOMStructure:P,isRtl:s});return Go(t,ee,q,ae,!1)},G=i.parseValueStr(U,S.referenceValue,ne),O=i.updateReferenceValue(t,G,S.referenceValue);Z({value:G,referenceValue:O,sections:V(G,S.sections)})},de=({activeSection:U,newSectionValue:ne,shouldGoToNextSection:G})=>{G&&_(0,m.A)({},K,q,{sections:B,tempValueStrAndroid:null}))},ce=U=>N(ne=>(0,m.A)({},ne,{tempValueStrAndroid:U}));return b.useEffect(()=>{const U=V(S.value);Yo(U,c),N(ne=>(0,m.A)({},ne,{sections:U}))},[h,t.locale,s]),b.useEffect(()=>{let U;a.areValuesEqual(t,S.value,T)?U=a.getTimezone(t,S.value)!==a.getTimezone(t,T):U=!0,U&&N(ne=>(0,m.A)({},ne,{value:T,referenceValue:i.updateReferenceValue(t,T,ne.referenceValue),sections:V(T)}))},[T]),{state:S,activeSectionIndex:_,parsedSelectedSections:H,setSelectedSections:E,clearValue:te,clearActiveSection:se,updateSectionValue:de,updateValueFromValueStr:le,setTempAndroidValueStr:ce,getSectionsFromValue:V,sectionsValueBoundaries:R,localizedDigits:x,timezone:w}},qa=5e3,bt=e=>e.saveQuery!=null,_a=({sections:e,updateSectionValue:t,sectionsValueBoundaries:o,localizedDigits:n,setTempAndroidValueStr:s,timezone:a})=>{const i=me(),[c,l]=b.useState(null),u=(0,oe.A)(()=>l(null));b.useEffect(()=>{var h;c!=null&&((h=e[c.sectionIndex])==null?void 0:h.type)!==c.sectionType&&u()},[e,c,u]),b.useEffect(()=>{if(c!=null){const h=setTimeout(()=>u(),qa);return()=>{clearTimeout(h)}}return()=>{}},[c,u]);const d=({keyPressed:h,sectionIndex:C},g,D)=>{const v=h.toLowerCase(),k=e[C];if(c!=null&&(!D||D(c.value))&&c.sectionIndex===C){const w=`${c.value}${v}`,T=g(w,k);if(!bt(T))return l({sectionIndex:C,value:w,sectionType:k.type}),T}const P=g(v,k);return bt(P)&&!P.saveQuery?(u(),null):(l({sectionIndex:C,value:v,sectionType:k.type}),bt(P)?null:P)},p=h=>{const C=(v,k,P)=>{const w=k.filter(T=>T.toLowerCase().startsWith(P));return w.length===0?{saveQuery:!1}:{sectionValue:w[0],shouldGoToNextSection:w.length===1}},g=(v,k,P,w)=>{const T=M=>No(i,a,k.type,M);if(k.contentType==="letter")return C(k.format,T(k.format),v);if(P&&w!=null&&Lo(i,P).contentType==="letter"){const M=T(P),x=C(P,M,v);return bt(x)?{saveQuery:!1}:(0,m.A)({},x,{sectionValue:w(x.sectionValue,M)})}return{saveQuery:!1}};return d(h,(v,k)=>{switch(k.type){case"month":{const P=w=>Wo(i,w,i.formats.month,k.format);return g(v,k,i.formats.month,P)}case"weekDay":{const P=(w,T)=>T.indexOf(w).toString();return g(v,k,i.formats.weekday,P)}case"meridiem":return g(v,k);default:return{saveQuery:!1}}})},f=h=>{const C=(D,v)=>{const k=tt(D,n),P=Number(k),w=o[v.type]({currentDate:null,format:v.format,contentType:v.contentType});if(P>w.maximum)return{saveQuery:!1};if(Pw.maximum||k.length===w.maximum.toString().length;return{sectionValue:Ho(i,P,w,n,v),shouldGoToNextSection:T}};return d(h,(D,v)=>{if(v.contentType==="digit"||v.contentType==="digit-with-letter")return C(D,v);if(v.type==="month"){const k=Uo(i,"digit","month","MM"),P=C(D,{type:v.type,format:"MM",hasLeadingZerosInFormat:k,hasLeadingZerosInInput:!0,contentType:"digit",maxLength:2});if(bt(P))return P;const w=Wo(i,P.sectionValue,"MM",v.format);return(0,m.A)({},P,{sectionValue:w})}if(v.type==="weekDay"){const k=C(D,v);if(bt(k))return k;const P=Gt(i,v.format)[Number(k.sectionValue)-1];return(0,m.A)({},k,{sectionValue:P})}return{saveQuery:!1}},D=>Bo(D,n))};return{applyCharacterEditing:(0,oe.A)(h=>{const C=e[h.sectionIndex],D=Bo(h.keyPressed,n)?f((0,m.A)({},h,{keyPressed:fn(h.keyPressed,n)})):p(h);if(D==null){s(null);return}t({activeSection:C,newSectionValue:D.sectionValue,shouldGoToNextSection:D.shouldGoToNextSection})}),resetCharacterQuery:u}},ei=e=>{const{internalProps:{disabled:t,readOnly:o=!1},forwardedProps:{sectionListRef:n,onBlur:s,onClick:a,onFocus:i,onInput:c,onPaste:l,focused:u,autoFocus:d=!1},fieldValueManager:p,applyCharacterEditing:f,resetCharacterQuery:A,setSelectedSections:h,parsedSelectedSections:C,state:g,clearActiveSection:D,clearValue:v,updateSectionValue:k,updateValueFromValueStr:P,sectionOrder:w,areAllSectionsEmpty:T,sectionsValueBoundaries:M}=e,x=b.useRef(null),R=(0,Se.A)(n,x),V=xe(),S=me(),N=(0,it.A)(),[j,F]=b.useState(!1),E=b.useMemo(()=>({syncSelectionToDOM:()=>{if(!x.current)return;const I=document.getSelection();if(!I)return;if(C==null){I.rangeCount>0&&x.current.getRoot().contains(I.getRangeAt(0).startContainer)&&I.removeAllRanges(),j&&x.current.getRoot().blur();return}if(!x.current.getRoot().contains(Te(document)))return;const K=new window.Range;let X;C==="all"?X=x.current.getRoot():g.sections[C].type==="empty"?X=x.current.getSectionContainer(C):X=x.current.getSectionContent(C),K.selectNodeContents(X),X.focus(),I.removeAllRanges(),I.addRange(K)},getActiveSectionIndexFromDOM:()=>{const I=Te(document);return!I||!x.current||!x.current.getRoot().contains(I)?null:x.current.getSectionIndexFromDOMElement(I)},focusField:(I=0)=>{if(!x.current)return;const K=bn(I,g.sections);F(!0),x.current.getSectionContent(K).focus()},setSelectedSections:I=>{if(!x.current)return;const K=bn(I,g.sections);F((K==="all"?0:K)!==null),h(I)},isFieldFocused:()=>{const I=Te(document);return!!x.current&&x.current.getRoot().contains(I)}}),[C,h,g.sections,j]),H=(0,oe.A)(I=>{if(!x.current)return;const K=g.sections[I];x.current.getSectionContent(I).innerHTML=K.value||K.placeholder,E.syncSelectionToDOM()}),_=(0,oe.A)((I,...K)=>{I.isDefaultPrevented()||!x.current||(F(!0),a==null||a(I,...K),C==="all"?setTimeout(()=>{const X=document.getSelection().getRangeAt(0).startOffset;if(X===0){h(w.startIndex);return}let $=0,Q=0;for(;Q{var $;if(c==null||c(I),!x.current||C!=="all")return;const X=($=I.target.textContent)!=null?$:"";x.current.getRoot().innerHTML=g.sections.map(Q=>`${Q.startSeparator}${Q.value||Q.placeholder}${Q.endSeparator}`).join(""),E.syncSelectionToDOM(),X.length===0||X.charCodeAt(0)===10?(A(),v(),h("all")):X.length>1?P(X):f({keyPressed:X,sectionIndex:0})}),Y=(0,oe.A)(I=>{if(l==null||l(I),o||C!=="all"){I.preventDefault();return}const K=I.clipboardData.getData("text");I.preventDefault(),A(),P(K)}),te=(0,oe.A)((...I)=>{if(i==null||i(...I),j||!x.current)return;F(!0),x.current.getSectionIndexFromDOMElement(Te(document))!=null||h(w.startIndex)}),se=(0,oe.A)((...I)=>{s==null||s(...I),setTimeout(()=>{if(!x.current)return;const K=Te(document);!x.current.getRoot().contains(K)&&(F(!1),h(null))})}),le=(0,oe.A)(I=>K=>{K.isDefaultPrevented()||h(I)}),de=(0,oe.A)(I=>{I.preventDefault()}),ce=(0,oe.A)(I=>()=>{h(I)}),U=(0,oe.A)(I=>{if(I.preventDefault(),o||t||typeof C!="number")return;const K=g.sections[C],X=I.clipboardData.getData("text"),$=/^[a-zA-Z]+$/.test(X),Q=/^[0-9]+$/.test(X),L=/^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(X);K.contentType==="letter"&&$||K.contentType==="digit"&&Q||K.contentType==="digit-with-letter"&&L?(A(),k({activeSection:K,newSectionValue:X,shouldGoToNextSection:!0})):!$&&!Q&&(A(),P(X))}),ne=(0,oe.A)(I=>{I.preventDefault(),I.dataTransfer.dropEffect="none"}),G=(0,oe.A)(I=>{var L;if(!x.current)return;const K=I.target,X=(L=K.textContent)!=null?L:"",$=x.current.getSectionIndexFromDOMElement(K),Q=g.sections[$];if(o||!x.current){H($);return}if(X.length===0){if(Q.value===""){H($);return}const z=I.nativeEvent.inputType;if(z==="insertParagraph"||z==="insertLineBreak"){H($);return}A(),D();return}f({keyPressed:X,sectionIndex:$}),H($)});(0,He.A)(()=>{if(!(!j||!x.current)){if(C==="all")x.current.getRoot().focus();else if(typeof C=="number"){const I=x.current.getSectionContent(C);I&&I.focus()}}},[C,j]);const O=b.useMemo(()=>g.sections.reduce((I,K)=>(I[K.type]=M[K.type]({currentDate:null,contentType:K.contentType,format:K.format}),I),{}),[M,g.sections]),B=C==="all",ae=b.useMemo(()=>g.sections.map((I,K)=>{const X=!B&&!t&&!o;return{container:{"data-sectionindex":K,onClick:le(K)},content:{tabIndex:B||K>0?-1:0,contentEditable:!B&&!t&&!o,role:"spinbutton",id:`${N}-${I.type}`,"aria-labelledby":`${N}-${I.type}`,"aria-readonly":o,"aria-valuenow":ba(I,S),"aria-valuemin":O[I.type].minimum,"aria-valuemax":O[I.type].maximum,"aria-valuetext":I.value?ha(I,S):V.empty,"aria-label":V[I.type],"aria-disabled":t,spellCheck:X?!1:void 0,autoCapitalize:X?"off":void 0,autoCorrect:X?"off":void 0,[parseInt(b.version,10)>=17?"enterKeyHint":"enterkeyhint"]:X?"next":void 0,children:I.value||I.placeholder,onInput:G,onPaste:U,onFocus:ce(K),onDragOver:ne,onMouseUp:de,inputMode:I.contentType==="letter"?"text":"numeric"},before:{children:I.startSeparator},after:{children:I.endSeparator}}}),[g.sections,ce,U,ne,G,le,de,t,o,B,V,S,O,N]),ee=(0,oe.A)(I=>{P(I.target.value)}),q=b.useMemo(()=>T?"":p.getV7HiddenInputValueFromSections(g.sections),[T,g.sections,p]);return b.useEffect(()=>{if(x.current==null)throw new Error(["MUI X: The `sectionListRef` prop has not been initialized by `PickersSectionList`","You probably tried to pass a component to the `textField` slot that contains an `` element instead of a `PickersSectionList`.","","If you want to keep using an `` HTML element for the editing, please remove the `enableAccessibleFieldDOMStructure` prop from your picker or field component:","","","","Learn more about the field accessible DOM structure on the MUI documentation: https://mui.com/x/react-date-pickers/fields/#fields-to-edit-a-single-element"].join(` +`));d&&x.current&&x.current.getSectionContent(w.startIndex).focus()},[]),{interactions:E,returnedValue:{autoFocus:d,readOnly:o,focused:u!=null?u:j,sectionListRef:R,onBlur:se,onClick:_,onFocus:te,onInput:Z,onPaste:Y,enableAccessibleFieldDOMStructure:!0,elements:ae,tabIndex:C===0?-1:0,contentEditable:B,value:q,onChange:ee,areAllSectionsEmpty:T}}},yt=e=>e.replace(/[\u2066\u2067\u2068\u2069]/g,""),ti=(e,t,o)=>{let n=0,s=o?1:0;const a=[];for(let i=0;i{const t=(0,we.I)(),o=b.useRef(),n=b.useRef(),{forwardedProps:{onFocus:s,onClick:a,onPaste:i,onBlur:c,inputRef:l,placeholder:u},internalProps:{readOnly:d=!1,disabled:p=!1},parsedSelectedSections:f,activeSectionIndex:A,state:h,fieldValueManager:C,valueManager:g,applyCharacterEditing:D,resetCharacterQuery:v,updateSectionValue:k,updateValueFromValueStr:P,clearActiveSection:w,clearValue:T,setTempAndroidValueStr:M,setSelectedSections:x,getSectionsFromValue:R,areAllSectionsEmpty:V,localizedDigits:S}=e,N=b.useRef(null),j=(0,Se.A)(l,N),F=b.useMemo(()=>ti(h.sections,S,t),[h.sections,S,t]),E=b.useMemo(()=>({syncSelectionToDOM:()=>{if(!N.current)return;if(f==null){N.current.scrollLeft&&(N.current.scrollLeft=0);return}if(N.current!==Te(document))return;const G=N.current.scrollTop;if(f==="all")N.current.select();else{const O=F[f],B=O.type==="empty"?O.startInInput-O.startSeparator.length:O.startInInput,ae=O.type==="empty"?O.endInInput+O.endSeparator.length:O.endInInput;(B!==N.current.selectionStart||ae!==N.current.selectionEnd)&&N.current===Te(document)&&N.current.setSelectionRange(B,ae),clearTimeout(n.current),n.current=setTimeout(()=>{N.current&&N.current===Te(document)&&N.current.selectionStart===N.current.selectionEnd&&(N.current.selectionStart!==B||N.current.selectionEnd!==ae)&&E.syncSelectionToDOM()})}N.current.scrollTop=G},getActiveSectionIndexFromDOM:()=>{var ae,ee;const G=(ae=N.current.selectionStart)!=null?ae:0,O=(ee=N.current.selectionEnd)!=null?ee:0;if(G===0&&O===0)return null;const B=G<=F[0].startInInput?1:F.findIndex(q=>q.startInInput-q.startSeparator.length>G);return B===-1?F.length-1:B-1},focusField:(G=0)=>{var O;(O=N.current)==null||O.focus(),x(G)},setSelectedSections:G=>x(G),isFieldFocused:()=>N.current===Te(document)}),[N,f,F,x]),H=()=>{var ae;const G=(ae=N.current.selectionStart)!=null?ae:0;let O;G<=F[0].startInInput||G>=F[F.length-1].endInInput?O=1:O=F.findIndex(ee=>ee.startInInput-ee.startSeparator.length>G);const B=O===-1?F.length-1:O-1;x(B)},_=(0,oe.A)((...G)=>{s==null||s(...G);const O=N.current;clearTimeout(o.current),o.current=setTimeout(()=>{!O||O!==N.current||A==null&&(O.value.length&&Number(O.selectionEnd)-Number(O.selectionStart)===O.value.length?x("all"):H())})}),Z=(0,oe.A)((G,...O)=>{G.isDefaultPrevented()||(a==null||a(G,...O),H())}),Y=(0,oe.A)(G=>{if(i==null||i(G),G.preventDefault(),d||p)return;const O=G.clipboardData.getData("text");if(typeof f=="number"){const B=h.sections[f],ae=/^[a-zA-Z]+$/.test(O),ee=/^[0-9]+$/.test(O),q=/^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(O);if(B.contentType==="letter"&&ae||B.contentType==="digit"&&ee||B.contentType==="digit-with-letter"&&q){v(),k({activeSection:B,newSectionValue:O,shouldGoToNextSection:!0});return}if(ae||ee)return}v(),P(O)}),te=(0,oe.A)((...G)=>{c==null||c(...G),x(null)}),se=(0,oe.A)(G=>{if(d)return;const O=G.target.value;if(O===""){v(),T();return}const B=G.nativeEvent.data,ae=B&&B.length>1,ee=ae?B:O,q=yt(ee);if(A==null||ae){P(ae?B:q);return}let I;if(f==="all"&&q.length===1)I=q;else{const K=yt(C.getV6InputValueFromSections(F,S,t));let X=-1,$=-1;for(let J=0;JQ.end)return;const z=q.length-K.length+Q.end-yt(Q.endSeparator||"").length;I=q.slice(Q.start+yt(Q.startSeparator||"").length,z)}if(I.length===0){ma()&&M(ee),v(),w();return}D({keyPressed:I,sectionIndex:A})}),le=b.useMemo(()=>u!==void 0?u:C.getV6InputValueFromSections(R(g.emptyValue),S,t),[u,C,R,g.emptyValue,S,t]),de=b.useMemo(()=>{var G;return(G=h.tempValueStrAndroid)!=null?G:C.getV6InputValueFromSections(h.sections,S,t)},[h.sections,C,h.tempValueStrAndroid,S,t]);b.useEffect(()=>(N.current&&N.current===Te(document)&&x("all"),()=>{clearTimeout(o.current),clearTimeout(n.current)}),[]);const ce=b.useMemo(()=>A==null||h.sections[A].contentType==="letter"?"text":"numeric",[A,h.sections]),ne=!(N.current&&N.current===Te(document))&&V;return{interactions:E,returnedValue:{readOnly:d,onBlur:te,onClick:Z,onFocus:_,onPaste:Y,inputRef:j,enableAccessibleFieldDOMStructure:!1,placeholder:le,inputMode:ce,autoComplete:"off",value:ne?"":de,onChange:se}}},Dn=e=>{const t=me(),{internalProps:o,internalProps:{unstableFieldRef:n,minutesStep:s,enableAccessibleFieldDOMStructure:a=!1,disabled:i=!1,readOnly:c=!1},forwardedProps:{onKeyDown:l,error:u,clearable:d,onClear:p},fieldValueManager:f,valueManager:A,validator:h}=e,C=(0,we.I)(),g=Ja(e),{state:D,activeSectionIndex:v,parsedSelectedSections:k,setSelectedSections:P,clearValue:w,clearActiveSection:T,updateSectionValue:M,setTempAndroidValueStr:x,sectionsValueBoundaries:R,localizedDigits:V,timezone:S}=g,N=_a({sections:D.sections,updateSectionValue:M,sectionsValueBoundaries:R,localizedDigits:V,setTempAndroidValueStr:x,timezone:S}),{resetCharacterQuery:j}=N,F=A.areValuesEqual(t,D.value,A.emptyValue),E=a?ei:ni,H=b.useMemo(()=>fa(D.sections,C&&!a),[D.sections,C,a]),{returnedValue:_,interactions:Z}=E((0,m.A)({},e,g,N,{areAllSectionsEmpty:F,sectionOrder:H})),Y=(0,oe.A)(U=>{if(l==null||l(U),!i)switch(!0){case((U.ctrlKey||U.metaKey)&&String.fromCharCode(U.keyCode)==="A"&&!U.shiftKey&&!U.altKey):{U.preventDefault(),P("all");break}case U.key==="ArrowRight":{if(U.preventDefault(),k==null)P(H.startIndex);else if(k==="all")P(H.endIndex);else{const ne=H.neighbors[k].rightIndex;ne!==null&&P(ne)}break}case U.key==="ArrowLeft":{if(U.preventDefault(),k==null)P(H.endIndex);else if(k==="all")P(H.startIndex);else{const ne=H.neighbors[k].leftIndex;ne!==null&&P(ne)}break}case U.key==="Delete":{if(U.preventDefault(),c)break;k==null||k==="all"?w():T(),j();break}case["ArrowUp","ArrowDown","Home","End","PageUp","PageDown"].includes(U.key):{if(U.preventDefault(),c||v==null)break;const ne=D.sections[v],G=f.getActiveDateManager(t,D,ne),O=ia(t,S,ne,U.key,R,V,G.date,{minutesStep:s});M({activeSection:ne,newSectionValue:O,shouldGoToNextSection:!1});break}}});(0,He.A)(()=>{Z.syncSelectionToDOM()});const{hasValidationError:te}=vn({props:o,validator:h,timezone:S,value:D.value,onError:o.onError}),se=b.useMemo(()=>u!==void 0?u:te,[te,u]);b.useEffect(()=>{!se&&v==null&&j()},[D.referenceValue,v,se]),b.useEffect(()=>{D.tempValueStrAndroid!=null&&v!=null&&(j(),T())},[D.sections]),b.useImperativeHandle(n,()=>({getSections:()=>D.sections,getActiveSectionIndex:Z.getActiveSectionIndexFromDOM,setSelectedSections:Z.setSelectedSections,focusField:Z.focusField,isFieldFocused:Z.isFieldFocused}));const le=(0,oe.A)((U,...ne)=>{U.preventDefault(),p==null||p(U,...ne),w(),Z.isFieldFocused()?P(H.startIndex):Z.focusField(0)}),de={onKeyDown:Y,onClear:le,error:se,clearable:!!(d&&!F&&!c&&!i)},ce={disabled:i,readOnly:c};return(0,m.A)({},e.forwardedProps,de,ce,_)},Ke=({props:e,value:t,timezone:o,adapter:n})=>{if(t===null)return null;const{shouldDisableDate:s,shouldDisableMonth:a,shouldDisableYear:i,disablePast:c,disableFuture:l}=e,u=n.utils.date(void 0,o),d=Pe(n.utils,e.minDate,n.defaultDates.minDate),p=Pe(n.utils,e.maxDate,n.defaultDates.maxDate);switch(!0){case!n.utils.isValid(t):return"invalidDate";case!!(s&&s(t)):return"shouldDisableDate";case!!(a&&a(t)):return"shouldDisableMonth";case!!(i&&i(t)):return"shouldDisableYear";case!!(l&&n.utils.isAfterDay(t,u)):return"disableFuture";case!!(c&&n.utils.isBeforeDay(t,u)):return"disablePast";case!!(d&&n.utils.isBeforeDay(t,d)):return"minDate";case!!(p&&n.utils.isAfterDay(t,p)):return"maxDate";default:return null}};Ke.valueManager=Ce;const kn=["disablePast","disableFuture","minDate","maxDate","shouldDisableDate","shouldDisableMonth","shouldDisableYear"],Pn=["disablePast","disableFuture","minTime","maxTime","shouldDisableTime","minutesStep","ampm","disableIgnoringDatePartForTimeValidation"],ls=["minDateTime","maxDateTime"],oi=[...kn,...Pn,...ls],nt=e=>oi.reduce((t,o)=>(e.hasOwnProperty(o)&&(t[o]=e[o]),t),{}),si=["value","defaultValue","referenceDate","format","formatDensity","onChange","timezone","onError","shouldRespectLeadingZeros","selectedSections","onSelectedSectionsChange","unstableFieldRef","enableAccessibleFieldDOMStructure","disabled","readOnly","dateSeparator"],Zt=(e,t)=>b.useMemo(()=>{const o=(0,m.A)({},e),n={},s=a=>{o.hasOwnProperty(a)&&(n[a]=o[a],delete o[a])};return si.forEach(s),t==="date"?kn.forEach(s):t==="time"?Pn.forEach(s):t==="date-time"&&(kn.forEach(s),Pn.forEach(s),ls.forEach(s)),{forwardedProps:o,internalProps:n}},[e,t]),ri=e=>{var n,s,a;const t=me(),o=Je();return(0,m.A)({},e,{disablePast:(n=e.disablePast)!=null?n:!1,disableFuture:(s=e.disableFuture)!=null?s:!1,format:(a=e.format)!=null?a:t.formats.keyboardDate,minDate:Pe(t,e.minDate,o.minDate),maxDate:Pe(t,e.maxDate,o.maxDate)})},ai=e=>{var s,a,i,c;const t=me(),n=((s=e.ampm)!=null?s:t.is12HourCycleInCurrentLocale())?t.formats.fullTime12h:t.formats.fullTime24h;return(0,m.A)({},e,{disablePast:(a=e.disablePast)!=null?a:!1,disableFuture:(i=e.disableFuture)!=null?i:!1,format:(c=e.format)!=null?c:n})},ii=e=>{var a,i,c,l,u,d,p,f;const t=me(),o=Je(),s=((a=e.ampm)!=null?a:t.is12HourCycleInCurrentLocale())?t.formats.keyboardDateTime12h:t.formats.keyboardDateTime24h;return(0,m.A)({},e,{disablePast:(i=e.disablePast)!=null?i:!1,disableFuture:(c=e.disableFuture)!=null?c:!1,format:(l=e.format)!=null?l:s,disableIgnoringDatePartForTimeValidation:!!(e.minDateTime||e.maxDateTime),minDate:Pe(t,(u=e.minDateTime)!=null?u:e.minDate,o.minDate),maxDate:Pe(t,(d=e.maxDateTime)!=null?d:e.maxDate,o.maxDate),minTime:(p=e.minDateTime)!=null?p:e.minTime,maxTime:(f=e.maxDateTime)!=null?f:e.maxTime})},cs=e=>{const t=ri(e),{forwardedProps:o,internalProps:n}=Zt(t,"date");return Dn({forwardedProps:o,internalProps:n,valueManager:Ce,fieldValueManager:yn,validator:Ke,valueType:"date"})};var us=re(2735);const li=["clearable","onClear","InputProps","sx","slots","slotProps"],ci=["ownerState"],Jt=e=>{var h,C;const t=xe(),{clearable:o,onClear:n,InputProps:s,sx:a,slots:i,slotProps:c}=e,l=(0,ie.A)(e,li),u=(h=i==null?void 0:i.clearButton)!=null?h:ct.A,d=(0,ge.A)({elementType:u,externalSlotProps:c==null?void 0:c.clearButton,ownerState:{},className:"clearButton",additionalProps:{title:t.fieldClearLabel}}),p=(0,ie.A)(d,ci),f=(C=i==null?void 0:i.clearIcon)!=null?C:xo,A=(0,ge.A)({elementType:f,externalSlotProps:c==null?void 0:c.clearIcon,ownerState:{}});return(0,m.A)({},l,{InputProps:(0,m.A)({},s,{endAdornment:(0,y.jsxs)(b.Fragment,{children:[o&&(0,y.jsx)(us.A,{position:"end",sx:{marginRight:s!=null&&s.endAdornment?-1:-1.5},children:(0,y.jsx)(u,(0,m.A)({},p,{onClick:n,children:(0,y.jsx)(f,(0,m.A)({fontSize:"small"},A))}))}),s==null?void 0:s.endAdornment]})}),sx:[{"& .clearButton":{opacity:1},"@media (pointer: fine)":{"& .clearButton":{opacity:0},"&:hover, &:focus-within":{".clearButton":{opacity:1}}}},...Array.isArray(a)?a:[a]]})};var ui=re(743),di=re(1085),pi=re(8845);function ds(e){return(0,be.Ay)("MuiPickersTextField",e)}const mi=(0,ye.A)("MuiPickersTextField",["root","focused","disabled","error","required"]);var qt=re(4186);function ps(e){return(0,be.Ay)("MuiPickersInputBase",e)}const ot=(0,ye.A)("MuiPickersInputBase",["root","focused","disabled","error","notchedOutline","sectionContent","sectionBefore","sectionAfter","adornedStart","adornedEnd","input"]);function ms(e){return(0,be.Ay)("MuiPickersOutlinedInput",e)}const Fe=(0,m.A)({},ot,(0,ye.A)("MuiPickersOutlinedInput",["root","notchedOutline","input"])),fi=["children","className","label","notched","shrink"],hi=(0,W.Ay)("fieldset",{name:"MuiPickersOutlinedInput",slot:"NotchedOutline",overridesResolver:(e,t)=>t.notchedOutline})(({theme:e})=>{const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%",borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}}),fs=(0,W.Ay)("span")(({theme:e})=>({fontFamily:e.typography.fontFamily,fontSize:"inherit"})),bi=(0,W.Ay)("legend")(({theme:e})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:{withLabel:!1},style:{padding:0,lineHeight:"11px",transition:e.transitions.create("width",{duration:150,easing:e.transitions.easing.easeOut})}},{props:{withLabel:!0},style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:e.transitions.create("max-width",{duration:50,easing:e.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}}},{props:{withLabel:!0,notched:!0},style:{maxWidth:"100%",transition:e.transitions.create("max-width",{duration:100,easing:e.transitions.easing.easeOut,delay:50})}}]}));function yi(e){const{className:t,label:o}=e,n=(0,ie.A)(e,fi),s=o!=null&&o!=="",a=(0,m.A)({},e,{withLabel:s});return(0,y.jsx)(hi,(0,m.A)({"aria-hidden":!0,className:t},n,{ownerState:a,children:(0,y.jsx)(bi,{ownerState:a,children:s?(0,y.jsx)(fs,{children:o}):(0,y.jsx)(fs,{className:"notranslate",children:"\u200B"})})}))}var gi=re(465),Ai=re(2343);function hs(e){return(0,be.Ay)("MuiPickersSectionList",e)}const gt=(0,ye.A)("MuiPickersSectionList",["root","section","sectionContent"]),Ci=["slots","slotProps","elements","sectionListRef"],wn=(0,W.Ay)("div",{name:"MuiPickersSectionList",slot:"Root",overridesResolver:(e,t)=>t.root})({direction:"ltr /*! @noflip */",outline:"none"}),Sn=(0,W.Ay)("span",{name:"MuiPickersSectionList",slot:"Section",overridesResolver:(e,t)=>t.section})({}),Tn=(0,W.Ay)("span",{name:"MuiPickersSectionList",slot:"SectionSeparator",overridesResolver:(e,t)=>t.sectionSeparator})({whiteSpace:"pre"}),Mn=(0,W.Ay)("span",{name:"MuiPickersSectionList",slot:"SectionContent",overridesResolver:(e,t)=>t.sectionContent})({outline:"none"}),vi=e=>{const{classes:t}=e,o={root:["root"],section:["section"],sectionContent:["sectionContent"]};return(0,he.A)(o,hs,t)};function xi(e){var f,A,h;const{slots:t,slotProps:o,element:n,classes:s}=e,a=(f=t==null?void 0:t.section)!=null?f:Sn,i=(0,ge.A)({elementType:a,externalSlotProps:o==null?void 0:o.section,externalForwardedProps:n.container,className:s.section,ownerState:{}}),c=(A=t==null?void 0:t.sectionContent)!=null?A:Mn,l=(0,ge.A)({elementType:c,externalSlotProps:o==null?void 0:o.sectionContent,externalForwardedProps:n.content,additionalProps:{suppressContentEditableWarning:!0},className:s.sectionContent,ownerState:{}}),u=(h=t==null?void 0:t.sectionSeparator)!=null?h:Tn,d=(0,ge.A)({elementType:u,externalSlotProps:o==null?void 0:o.sectionSeparator,externalForwardedProps:n.before,ownerState:{position:"before"}}),p=(0,ge.A)({elementType:u,externalSlotProps:o==null?void 0:o.sectionSeparator,externalForwardedProps:n.after,ownerState:{position:"after"}});return(0,y.jsxs)(a,(0,m.A)({},i,{children:[(0,y.jsx)(u,(0,m.A)({},d)),(0,y.jsx)(c,(0,m.A)({},l)),(0,y.jsx)(u,(0,m.A)({},p))]}))}const bs=b.forwardRef(function(t,o){var C;const n=(0,pe.A)({props:t,name:"MuiPickersSectionList"}),{slots:s,slotProps:a,elements:i,sectionListRef:c}=n,l=(0,ie.A)(n,Ci),u=vi(n),d=b.useRef(null),p=(0,Se.A)(o,d),f=g=>{if(!d.current)throw new Error(`MUI X: Cannot call sectionListRef.${g} before the mount of the component.`);return d.current};b.useImperativeHandle(c,()=>({getRoot(){return f("getRoot")},getSectionContainer(g){return f("getSectionContainer").querySelector(`.${gt.section}[data-sectionindex="${g}"]`)},getSectionContent(g){return f("getSectionContent").querySelector(`.${gt.section}[data-sectionindex="${g}"] .${gt.sectionContent}`)},getSectionIndexFromDOMElement(g){const D=f("getSectionIndexFromDOMElement");if(g==null||!D.contains(g))return null;let v=null;return g.classList.contains(gt.section)?v=g:g.classList.contains(gt.sectionContent)&&(v=g.parentElement),v==null?null:Number(v.dataset.sectionindex)}}));const A=(C=s==null?void 0:s.root)!=null?C:wn,h=(0,ge.A)({elementType:A,externalSlotProps:a==null?void 0:a.root,externalForwardedProps:l,additionalProps:{ref:p,suppressContentEditableWarning:!0},className:u.root,ownerState:{}});return(0,y.jsx)(A,(0,m.A)({},h,{children:h.contentEditable?i.map(({content:g,before:D,after:v})=>`${D.children}${g.children}${v.children}`).join(""):(0,y.jsx)(b.Fragment,{children:i.map((g,D)=>(0,y.jsx)(xi,{slots:s,slotProps:a,element:g,classes:u},D))})}))}),Di=["elements","areAllSectionsEmpty","defaultValue","label","value","onChange","id","autoFocus","endAdornment","startAdornment","renderSuffix","slots","slotProps","contentEditable","tabIndex","onInput","onPaste","onKeyDown","fullWidth","name","readOnly","inputProps","inputRef","sectionListRef"],ki=e=>Math.round(e*1e5)/1e5,_t=(0,W.Ay)("div",{name:"MuiPickersInputBase",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>(0,m.A)({},e.typography.body1,{color:(e.vars||e).palette.text.primary,cursor:"text",padding:0,display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",boxSizing:"border-box",letterSpacing:`${ki(.15/16)}em`,variants:[{props:{fullWidth:!0},style:{width:"100%"}}]})),In=(0,W.Ay)(wn,{name:"MuiPickersInputBase",slot:"SectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})(({theme:e})=>({padding:"4px 0 5px",fontFamily:e.typography.fontFamily,fontSize:"inherit",lineHeight:"1.4375em",flexGrow:1,outline:"none",display:"flex",flexWrap:"nowrap",overflow:"hidden",letterSpacing:"inherit",width:"182px",variants:[{props:{isRtl:!0},style:{textAlign:"right /*! @noflip */"}},{props:{size:"small"},style:{paddingTop:1}},{props:{adornedStart:!1,focused:!1,filled:!1},style:{color:"currentColor",opacity:0}},{props:({adornedStart:t,focused:o,filled:n,label:s})=>!t&&!o&&!n&&s==null,style:e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:e.palette.mode==="light"?.42:.5}}]})),Pi=(0,W.Ay)(Sn,{name:"MuiPickersInputBase",slot:"Section",overridesResolver:(e,t)=>t.section})(({theme:e})=>({fontFamily:e.typography.fontFamily,fontSize:"inherit",letterSpacing:"inherit",lineHeight:"1.4375em",display:"flex"})),wi=(0,W.Ay)(Mn,{name:"MuiPickersInputBase",slot:"SectionContent",overridesResolver:(e,t)=>t.content})(({theme:e})=>({fontFamily:e.typography.fontFamily,lineHeight:"1.4375em",letterSpacing:"inherit",width:"fit-content",outline:"none"})),Si=(0,W.Ay)(Tn,{name:"MuiPickersInputBase",slot:"Separator",overridesResolver:(e,t)=>t.separator})(()=>({whiteSpace:"pre",letterSpacing:"inherit"})),Ti=(0,W.Ay)("input",{name:"MuiPickersInputBase",slot:"Input",overridesResolver:(e,t)=>t.hiddenInput})((0,m.A)({},Ai.A)),Mi=e=>{const{focused:t,disabled:o,error:n,classes:s,fullWidth:a,readOnly:i,color:c,size:l,endAdornment:u,startAdornment:d}=e,p={root:["root",t&&!o&&"focused",o&&"disabled",i&&"readOnly",n&&"error",a&&"fullWidth",`color${(0,gi.A)(c)}`,l==="small"&&"inputSizeSmall",!!d&&"adornedStart",!!u&&"adornedEnd"],notchedOutline:["notchedOutline"],input:["input"],sectionsContainer:["sectionsContainer"],sectionContent:["sectionContent"],sectionBefore:["sectionBefore"],sectionAfter:["sectionAfter"]};return(0,he.A)(p,ps,s)},en=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiPickersInputBase"}),{elements:s,areAllSectionsEmpty:a,value:i,onChange:c,id:l,endAdornment:u,startAdornment:d,renderSuffix:p,slots:f,slotProps:A,contentEditable:h,tabIndex:C,onInput:g,onPaste:D,onKeyDown:v,name:k,readOnly:P,inputProps:w,inputRef:T,sectionListRef:M}=n,x=(0,ie.A)(n,Di),R=b.useRef(null),V=(0,Se.A)(o,R),S=(0,Se.A)(w==null?void 0:w.ref,T),N=(0,we.I)(),j=(0,qt.A)();if(!j)throw new Error("MUI X: PickersInputBase should always be used inside a PickersTextField component");const F=te=>{var se;if(j.disabled){te.stopPropagation();return}(se=j.onFocus)==null||se.call(j,te)};b.useEffect(()=>{j&&j.setAdornedStart(!!d)},[j,d]),b.useEffect(()=>{j&&(a?j.onEmpty():j.onFilled())},[j,a]);const E=(0,m.A)({},n,j,{isRtl:N}),H=Mi(E),_=(f==null?void 0:f.root)||_t,Z=(0,ge.A)({elementType:_,externalSlotProps:A==null?void 0:A.root,externalForwardedProps:x,additionalProps:{"aria-invalid":j.error,ref:V},className:H.root,ownerState:E}),Y=(f==null?void 0:f.input)||In;return(0,y.jsxs)(_,(0,m.A)({},Z,{children:[d,(0,y.jsx)(bs,{sectionListRef:M,elements:s,contentEditable:h,tabIndex:C,className:H.sectionsContainer,onFocus:F,onBlur:j.onBlur,onInput:g,onPaste:D,onKeyDown:v,slots:{root:Y,section:Pi,sectionContent:wi,sectionSeparator:Si},slotProps:{root:{ownerState:E},sectionContent:{className:ot.sectionContent},sectionSeparator:({position:te})=>({className:te==="before"?ot.sectionBefore:ot.sectionAfter})}}),u,p?p((0,m.A)({},j)):null,(0,y.jsx)(Ti,(0,m.A)({name:k,className:H.input,value:i,onChange:c,id:l,"aria-hidden":"true",tabIndex:-1,readOnly:P,required:j.required,disabled:j.disabled},w,{ref:S}))]}))}),Ii=["label","autoFocus","ownerState","notched"],Ri=(0,W.Ay)(_t,{name:"MuiPickersOutlinedInput",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>{var o;const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{padding:"0 14px",borderRadius:(e.vars||e).shape.borderRadius,[`&:hover .${Fe.notchedOutline}`]:{borderColor:(e.vars||e).palette.text.primary},"@media (hover: none)":{[`&:hover .${Fe.notchedOutline}`]:{borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}},[`&.${Fe.focused} .${Fe.notchedOutline}`]:{borderStyle:"solid",borderWidth:2},[`&.${Fe.disabled}`]:{[`& .${Fe.notchedOutline}`]:{borderColor:(e.vars||e).palette.action.disabled},"*":{color:(e.vars||e).palette.action.disabled}},[`&.${Fe.error} .${Fe.notchedOutline}`]:{borderColor:(e.vars||e).palette.error.main},variants:Object.keys(((o=e.vars)!=null?o:e).palette).filter(n=>{var s,a,i;return(i=(a=((s=e.vars)!=null?s:e).palette[n])==null?void 0:a.main)!=null?i:!1}).map(n=>({props:{color:n},style:{[`&.${Fe.focused}:not(.${Fe.error}) .${Fe.notchedOutline}`]:{borderColor:(e.vars||e).palette[n].main}}}))}}),Vi=(0,W.Ay)(In,{name:"MuiPickersOutlinedInput",slot:"SectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})({padding:"16.5px 0",variants:[{props:{size:"small"},style:{padding:"8.5px 0"}}]}),Fi=e=>{const{classes:t}=e,o={root:["root"],notchedOutline:["notchedOutline"],input:["input"]},n=(0,he.A)(o,ms,t);return(0,m.A)({},t,n)},Rn=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiPickersOutlinedInput"}),{label:s,ownerState:a,notched:i}=n,c=(0,ie.A)(n,Ii),l=(0,qt.A)(),u=(0,m.A)({},n,a,l,{color:(l==null?void 0:l.color)||"primary"}),d=Fi(u);return(0,y.jsx)(en,(0,m.A)({slots:{root:Ri,input:Vi},renderSuffix:p=>(0,y.jsx)(yi,{shrink:!!(i||p.adornedStart||p.focused||p.filled),notched:!!(i||p.adornedStart||p.focused||p.filled),className:d.notchedOutline,label:s!=null&&s!==""&&(l!=null&&l.required)?(0,y.jsxs)(b.Fragment,{children:[s,"\u2009","*"]}):s,ownerState:u})},c,{label:s,classes:d,ref:o}))});Rn.muiName="Input";var Oi=re(5873);function ys(e){return(0,be.Ay)("MuiPickersFilledInput",e)}const Ge=(0,m.A)({},ot,(0,ye.A)("MuiPickersFilledInput",["root","underline","input"])),Li=["label","autoFocus","disableUnderline","ownerState"],Ni=(0,W.Ay)(_t,{name:"MuiPickersFilledInput",slot:"Root",overridesResolver:(e,t)=>t.root,shouldForwardProp:e=>(0,Oi.MC)(e)&&e!=="disableUnderline"})(({theme:e})=>{var i;const t=e.palette.mode==="light",o=t?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",n=t?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",s=t?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",a=t?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:n,borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),"&:hover":{backgroundColor:e.vars?e.vars.palette.FilledInput.hoverBg:s,"@media (hover: none)":{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:n}},[`&.${Ge.focused}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:n},[`&.${Ge.disabled}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.disabledBg:a},variants:[...Object.keys(((i=e.vars)!=null?i:e).palette).filter(c=>{var l;return((l=e.vars)!=null?l:e).palette[c].main}).map(c=>{var l;return{props:{color:c,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(l=(e.vars||e).palette[c])==null?void 0:l.main}`}}}}),{props:{disableUnderline:!1},style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Ge.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Ge.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`:o}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Ge.disabled}, .${Ge.error}):before`]:{borderBottom:`1px solid ${(e.vars||e).palette.text.primary}`},[`&.${Ge.disabled}:before`]:{borderBottomStyle:"dotted"}}},{props:({startAdornment:c})=>!!c,style:{paddingLeft:12}},{props:({endAdornment:c})=>!!c,style:{paddingRight:12}}]}}),ji=(0,W.Ay)(In,{name:"MuiPickersFilledInput",slot:"sectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({startAdornment:e})=>!!e,style:{paddingLeft:0}},{props:({endAdornment:e})=>!!e,style:{paddingRight:0}},{props:{hiddenLabel:!0},style:{paddingTop:16,paddingBottom:17}},{props:{hiddenLabel:!0,size:"small"},style:{paddingTop:8,paddingBottom:9}}]}),Ei=e=>{const{classes:t,disableUnderline:o}=e,n={root:["root",!o&&"underline"],input:["input"]},s=(0,he.A)(n,ys,t);return(0,m.A)({},t,s)},Vn=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiPickersFilledInput"}),{label:s,disableUnderline:a=!1,ownerState:i}=n,c=(0,ie.A)(n,Li),l=(0,qt.A)(),u=(0,m.A)({},n,i,l,{color:(l==null?void 0:l.color)||"primary"}),d=Ei(u);return(0,y.jsx)(en,(0,m.A)({slots:{root:Ni,input:ji},slotProps:{root:{disableUnderline:a}}},c,{label:s,classes:d,ref:o}))});Vn.muiName="Input";function gs(e){return(0,be.Ay)("MuiPickersFilledInput",e)}const At=(0,m.A)({},ot,(0,ye.A)("MuiPickersInput",["root","input"])),Bi=["label","autoFocus","disableUnderline","ownerState"],$i=(0,W.Ay)(_t,{name:"MuiPickersInput",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>{var n;let o=e.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return e.vars&&(o=`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`),{"label + &":{marginTop:16},variants:[...Object.keys(((n=e.vars)!=null?n:e).palette).filter(s=>{var a;return((a=e.vars)!=null?a:e).palette[s].main}).map(s=>({props:{color:s},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[s].main}`}}})),{props:{disableUnderline:!1},style:{"&::after":{background:"red",left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${At.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${At.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${o}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${At.disabled}, .${At.error}):before`]:{borderBottom:`2px solid ${(e.vars||e).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${o}`}},[`&.${At.disabled}:before`]:{borderBottomStyle:"dotted"}}}]}}),Hi=e=>{const{classes:t,disableUnderline:o}=e,n={root:["root",!o&&"underline"],input:["input"]},s=(0,he.A)(n,gs,t);return(0,m.A)({},t,s)},Fn=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiPickersInput"}),{label:s,disableUnderline:a=!1,ownerState:i}=n,c=(0,ie.A)(n,Bi),l=(0,qt.A)(),u=(0,m.A)({},n,i,l,{disableUnderline:a,color:(l==null?void 0:l.color)||"primary"}),d=Hi(u);return(0,y.jsx)(en,(0,m.A)({slots:{root:$i}},c,{label:s,classes:d,ref:o}))});Fn.muiName="Input";const Wi=["onFocus","onBlur","className","color","disabled","error","variant","required","InputProps","inputProps","inputRef","sectionListRef","elements","areAllSectionsEmpty","onClick","onKeyDown","onKeyUp","onPaste","onInput","endAdornment","startAdornment","tabIndex","contentEditable","focused","value","onChange","fullWidth","id","name","helperText","FormHelperTextProps","label","InputLabelProps"],zi={standard:Fn,filled:Vn,outlined:Rn},Ui=(0,W.Ay)(pi.A,{name:"MuiPickersTextField",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Yi=e=>{const{focused:t,disabled:o,classes:n,required:s}=e,a={root:["root",t&&!o&&"focused",o&&"disabled",s&&"required"]};return(0,he.A)(a,ds,n)},tn=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiPickersTextField"}),{onFocus:s,onBlur:a,className:i,color:c="primary",disabled:l=!1,error:u=!1,variant:d="outlined",required:p=!1,InputProps:f,inputProps:A,inputRef:h,sectionListRef:C,elements:g,areAllSectionsEmpty:D,onClick:v,onKeyDown:k,onKeyUp:P,onPaste:w,onInput:T,endAdornment:M,startAdornment:x,tabIndex:R,contentEditable:V,focused:S,value:N,onChange:j,fullWidth:F,id:E,name:H,helperText:_,FormHelperTextProps:Z,label:Y,InputLabelProps:te}=n,se=(0,ie.A)(n,Wi),le=b.useRef(null),de=(0,Se.A)(o,le),ce=(0,it.A)(E),U=_&&ce?`${ce}-helper-text`:void 0,ne=Y&&ce?`${ce}-label`:void 0,G=(0,m.A)({},n,{color:c,disabled:l,error:u,focused:S,required:p,variant:d}),O=Yi(G),B=zi[d];return(0,y.jsxs)(Ui,(0,m.A)({className:(0,fe.A)(O.root,i),ref:de,focused:S,onFocus:s,onBlur:a,disabled:l,variant:d,error:u,color:c,fullWidth:F,required:p,ownerState:G},se,{children:[(0,y.jsx)(ui.A,(0,m.A)({htmlFor:ce,id:ne},te,{children:Y})),(0,y.jsx)(B,(0,m.A)({elements:g,areAllSectionsEmpty:D,onClick:v,onKeyDown:k,onKeyUp:P,onInput:T,onPaste:w,endAdornment:M,startAdornment:x,tabIndex:R,contentEditable:V,value:N,onChange:j,id:ce,fullWidth:F,inputProps:A,inputRef:h,sectionListRef:C,label:Y,name:H,role:"group","aria-labelledby":ne},f)),_&&(0,y.jsx)(di.A,(0,m.A)({id:U},Z,{children:_}))]}))}),Ki=["enableAccessibleFieldDOMStructure"],Gi=["InputProps","readOnly"],Xi=["onPaste","onKeyDown","inputMode","readOnly","InputProps","inputProps","inputRef"],On=e=>{let{enableAccessibleFieldDOMStructure:t}=e,o=(0,ie.A)(e,Ki);if(t){const{InputProps:p,readOnly:f}=o,A=(0,ie.A)(o,Gi);return(0,m.A)({},A,{InputProps:(0,m.A)({},p!=null?p:{},{readOnly:f})})}const{onPaste:n,onKeyDown:s,inputMode:a,readOnly:i,InputProps:c,inputProps:l,inputRef:u}=o,d=(0,ie.A)(o,Xi);return(0,m.A)({},d,{InputProps:(0,m.A)({},c!=null?c:{},{readOnly:i}),inputProps:(0,m.A)({},l!=null?l:{},{inputMode:a,onPaste:n,onKeyDown:s,ref:u})})},Qi=["slots","slotProps","InputProps","inputProps"],Ln=b.forwardRef(function(t,o){var C;const n=(0,pe.A)({props:t,name:"MuiDateField"}),{slots:s,slotProps:a,InputProps:i,inputProps:c}=n,l=(0,ie.A)(n,Qi),u=n,d=(C=s==null?void 0:s.textField)!=null?C:t.enableAccessibleFieldDOMStructure?tn:Cn.A,p=(0,ge.A)({elementType:d,externalSlotProps:a==null?void 0:a.textField,externalForwardedProps:l,additionalProps:{ref:o},ownerState:u});p.inputProps=(0,m.A)({},c,p.inputProps),p.InputProps=(0,m.A)({},i,p.InputProps);const f=cs(p),A=On(f),h=Jt((0,m.A)({},A,{slots:s,slotProps:a}));return(0,y.jsx)(d,(0,m.A)({},h))}),st=({adapter:e,value:t,timezone:o,props:n})=>{if(t===null)return null;const{minTime:s,maxTime:a,minutesStep:i,shouldDisableTime:c,disableIgnoringDatePartForTimeValidation:l=!1,disablePast:u,disableFuture:d}=n,p=e.utils.date(void 0,o),f=wt(l,e.utils);switch(!0){case!e.utils.isValid(t):return"invalidDate";case!!(s&&f(s,t)):return"minTime";case!!(a&&f(t,a)):return"maxTime";case!!(d&&e.utils.isAfter(t,p)):return"disableFuture";case!!(u&&e.utils.isBefore(t,p)):return"disablePast";case!!(c&&c(t,"hours")):return"shouldDisableTime-hours";case!!(c&&c(t,"minutes")):return"shouldDisableTime-minutes";case!!(c&&c(t,"seconds")):return"shouldDisableTime-seconds";case!!(i&&e.utils.getMinutes(t)%i!==0):return"minutesStep";default:return null}};st.valueManager=Ce;const As=e=>{const t=ai(e),{forwardedProps:o,internalProps:n}=Zt(t,"time");return Dn({forwardedProps:o,internalProps:n,valueManager:Ce,fieldValueManager:yn,validator:st,valueType:"time"})},Zi=["slots","slotProps","InputProps","inputProps"],Nn=b.forwardRef(function(t,o){var C;const n=(0,pe.A)({props:t,name:"MuiTimeField"}),{slots:s,slotProps:a,InputProps:i,inputProps:c}=n,l=(0,ie.A)(n,Zi),u=n,d=(C=s==null?void 0:s.textField)!=null?C:t.enableAccessibleFieldDOMStructure?tn:Cn.A,p=(0,ge.A)({elementType:d,externalSlotProps:a==null?void 0:a.textField,externalForwardedProps:l,ownerState:u,additionalProps:{ref:o}});p.inputProps=(0,m.A)({},c,p.inputProps),p.InputProps=(0,m.A)({},i,p.InputProps);const f=As(p),A=On(f),h=Jt((0,m.A)({},A,{slots:s,slotProps:a}));return(0,y.jsx)(d,(0,m.A)({},h))}),Ct=({adapter:e,value:t,timezone:o,props:n})=>{const s=Ke({adapter:e,value:t,timezone:o,props:n});return s!==null?s:st({adapter:e,value:t,timezone:o,props:n})};Ct.valueManager=Ce;const Cs=e=>{const t=ii(e),{forwardedProps:o,internalProps:n}=Zt(t,"date-time");return Dn({forwardedProps:o,internalProps:n,valueManager:Ce,fieldValueManager:yn,validator:Ct,valueType:"date-time"})},Ji=["slots","slotProps","InputProps","inputProps"],jn=b.forwardRef(function(t,o){var C;const n=(0,pe.A)({props:t,name:"MuiDateTimeField"}),{slots:s,slotProps:a,InputProps:i,inputProps:c}=n,l=(0,ie.A)(n,Ji),u=n,d=(C=s==null?void 0:s.textField)!=null?C:t.enableAccessibleFieldDOMStructure?tn:Cn.A,p=(0,ge.A)({elementType:d,externalSlotProps:a==null?void 0:a.textField,externalForwardedProps:l,ownerState:u,additionalProps:{ref:o}});p.inputProps=(0,m.A)({},c,p.inputProps),p.InputProps=(0,m.A)({},i,p.InputProps);const f=Cs(p),A=On(f),h=Jt((0,m.A)({},A,{slots:s,slotProps:a}));return(0,y.jsx)(d,(0,m.A)({},h))}),vs=({shouldDisableDate:e,shouldDisableMonth:t,shouldDisableYear:o,minDate:n,maxDate:s,disableFuture:a,disablePast:i,timezone:c})=>{const l=Ze();return b.useCallback(u=>Ke({adapter:l,value:u,timezone:c,props:{shouldDisableDate:e,shouldDisableMonth:t,shouldDisableYear:o,minDate:n,maxDate:s,disableFuture:a,disablePast:i}})!==null,[l,e,t,o,n,s,a,i,c])},qi=(e,t,o)=>(n,s)=>{switch(s.type){case"changeMonth":return(0,m.A)({},n,{slideDirection:s.direction,currentMonth:s.newMonth,isMonthSwitchingAnimating:!e});case"changeMonthTimezone":{const a=s.newTimezone;if(o.getTimezone(n.currentMonth)===a)return n;let i=o.setTimezone(n.currentMonth,a);return o.getMonth(i)!==o.getMonth(n.currentMonth)&&(i=o.setMonth(i,o.getMonth(n.currentMonth))),(0,m.A)({},n,{currentMonth:i})}case"finishMonthSwitchingAnimation":return(0,m.A)({},n,{isMonthSwitchingAnimating:!1});case"changeFocusedDay":{if(n.focusedDay!=null&&s.focusedDay!=null&&o.isSameDay(s.focusedDay,n.focusedDay))return n;const a=s.focusedDay!=null&&!t&&!o.isSameMonth(n.currentMonth,s.focusedDay);return(0,m.A)({},n,{focusedDay:s.focusedDay,isMonthSwitchingAnimating:a&&!e&&!s.withoutMonthSwitchingAnimation,currentMonth:a?o.startOfMonth(s.focusedDay):n.currentMonth,slideDirection:s.focusedDay!=null&&o.isAfterDay(s.focusedDay,n.currentMonth)?"left":"right"})}default:throw new Error("missing support")}},_i=e=>{const{value:t,referenceDate:o,disableFuture:n,disablePast:s,disableSwitchToMonthOnDayFocus:a=!1,maxDate:i,minDate:c,onMonthChange:l,reduceAnimations:u,shouldDisableDate:d,timezone:p}=e,f=me(),A=b.useRef(qi(!!u,a,f)).current,h=b.useMemo(()=>Ce.getInitialReferenceValue({value:t,utils:f,timezone:p,props:e,referenceDate:o,granularity:je.day}),[o,p]),[C,g]=b.useReducer(A,{isMonthSwitchingAnimating:!1,focusedDay:h,currentMonth:f.startOfMonth(h),slideDirection:"left"});b.useEffect(()=>{g({type:"changeMonthTimezone",newTimezone:f.getTimezone(h)})},[h,f]);const D=b.useCallback(T=>{g((0,m.A)({type:"changeMonth"},T)),l&&l(T.newMonth)},[l]),v=b.useCallback(T=>{const M=T;f.isSameMonth(M,C.currentMonth)||D({newMonth:f.startOfMonth(M),direction:f.isAfterDay(M,C.currentMonth)?"left":"right"})},[C.currentMonth,D,f]),k=vs({shouldDisableDate:d,minDate:c,maxDate:i,disableFuture:n,disablePast:s,timezone:p}),P=b.useCallback(()=>{g({type:"finishMonthSwitchingAnimation"})},[]),w=(0,oe.A)((T,M)=>{k(T)||g({type:"changeFocusedDay",focusedDay:T,withoutMonthSwitchingAnimation:M})});return{referenceDate:h,calendarState:C,changeMonth:v,changeFocusedDay:w,isDateDisabled:k,onMonthSwitchingAnimationEnd:P,handleChangeMonth:D}};var xs=re(4220),nn=re(7987),Ds=re(9437);const el=e=>(0,be.Ay)("MuiPickersFadeTransitionGroup",e),tl=(0,ye.A)("MuiPickersFadeTransitionGroup",["root"]),nl=e=>{const{classes:t}=e,o={root:["root"]};return(0,he.A)(o,el,t)},ol=(0,W.Ay)(xs.A,{name:"MuiPickersFadeTransitionGroup",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"block",position:"relative"});function ks(e){const t=(0,pe.A)({props:e,name:"MuiPickersFadeTransitionGroup"}),{children:o,className:n,reduceAnimations:s,transKey:a}=t,i=nl(t),c=(0,Ds.A)();return s?o:(0,y.jsx)(ol,{className:(0,fe.A)(i.root,n),children:(0,y.jsx)(nn.A,{appear:!1,mountOnEnter:!0,unmountOnExit:!0,timeout:{appear:c.transitions.duration.enteringScreen,enter:c.transitions.duration.enteringScreen,exit:0},children:o},a)})}var sl=re(5540);function rl(e,t){return e.classList?!!t&&e.classList.contains(t):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")!==-1}function al(e,t){e.classList?e.classList.add(t):rl(e,t)||(typeof e.className=="string"?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}function Ps(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function il(e,t){e.classList?e.classList.remove(t):typeof e.className=="string"?e.className=Ps(e.className,t):e.setAttribute("class",Ps(e.className&&e.className.baseVal||"",t))}var ll=re(9878),cl=re(4093),ul=function(t,o){return t&&o&&o.split(" ").forEach(function(n){return al(t,n)})},En=function(t,o){return t&&o&&o.split(" ").forEach(function(n){return il(t,n)})},Bn=function(e){(0,sl.A)(t,e);function t(){for(var n,s=arguments.length,a=new Array(s),i=0;i(0,be.Ay)("MuiPickersSlideTransition",e),Me=(0,ye.A)("MuiPickersSlideTransition",["root","slideEnter-left","slideEnter-right","slideEnterActive","slideExit","slideExitActiveLeft-left","slideExitActiveLeft-right"]),ml=["children","className","reduceAnimations","slideDirection","transKey","classes"],fl=e=>{const{classes:t,slideDirection:o}=e,n={root:["root"],exit:["slideExit"],enterActive:["slideEnterActive"],enter:[`slideEnter-${o}`],exitActive:[`slideExitActiveLeft-${o}`]};return(0,he.A)(n,pl,t)},hl=(0,W.Ay)(xs.A,{name:"MuiPickersSlideTransition",slot:"Root",overridesResolver:(e,t)=>[t.root,{[`.${Me["slideEnter-left"]}`]:t["slideEnter-left"]},{[`.${Me["slideEnter-right"]}`]:t["slideEnter-right"]},{[`.${Me.slideEnterActive}`]:t.slideEnterActive},{[`.${Me.slideExit}`]:t.slideExit},{[`.${Me["slideExitActiveLeft-left"]}`]:t["slideExitActiveLeft-left"]},{[`.${Me["slideExitActiveLeft-right"]}`]:t["slideExitActiveLeft-right"]}]})(({theme:e})=>{const t=e.transitions.create("transform",{duration:e.transitions.duration.complex,easing:"cubic-bezier(0.35, 0.8, 0.4, 1)"});return{display:"block",position:"relative",overflowX:"hidden","& > *":{position:"absolute",top:0,right:0,left:0},[`& .${Me["slideEnter-left"]}`]:{willChange:"transform",transform:"translate(100%)",zIndex:1},[`& .${Me["slideEnter-right"]}`]:{willChange:"transform",transform:"translate(-100%)",zIndex:1},[`& .${Me.slideEnterActive}`]:{transform:"translate(0%)",transition:t},[`& .${Me.slideExit}`]:{transform:"translate(0%)"},[`& .${Me["slideExitActiveLeft-left"]}`]:{willChange:"transform",transform:"translate(-100%)",transition:t,zIndex:0},[`& .${Me["slideExitActiveLeft-right"]}`]:{willChange:"transform",transform:"translate(100%)",transition:t,zIndex:0}}});function bl(e){const t=(0,pe.A)({props:e,name:"MuiPickersSlideTransition"}),{children:o,className:n,reduceAnimations:s,transKey:a}=t,i=(0,ie.A)(t,ml),c=fl(t),l=(0,Ds.A)();if(s)return(0,y.jsx)("div",{className:(0,fe.A)(c.root,n),children:o});const u={exit:c.exit,enterActive:c.enterActive,enter:c.enter,exitActive:c.exitActive};return(0,y.jsx)(hl,{className:(0,fe.A)(c.root,n),childFactory:d=>b.cloneElement(d,{classNames:u}),role:"presentation",children:(0,y.jsx)(dl,(0,m.A)({mountOnEnter:!0,unmountOnExit:!0,timeout:l.transitions.duration.complex,classNames:u},i,{children:o}),a)})}const yl=e=>(0,be.Ay)("MuiDayCalendar",e),gl=(0,ye.A)("MuiDayCalendar",["root","header","weekDayLabel","loadingContainer","slideTransition","monthContainer","weekContainer","weekNumberLabel","weekNumber"]),Al=["parentProps","day","focusableDay","selectedDays","isDateDisabled","currentMonthNumber","isViewFocused"],Cl=["ownerState"],vl=e=>{const{classes:t}=e,o={root:["root"],header:["header"],weekDayLabel:["weekDayLabel"],loadingContainer:["loadingContainer"],slideTransition:["slideTransition"],monthContainer:["monthContainer"],weekContainer:["weekContainer"],weekNumberLabel:["weekNumberLabel"],weekNumber:["weekNumber"]};return(0,he.A)(o,yl,t)},ws=(et+dt*2)*6,xl=(0,W.Ay)("div",{name:"MuiDayCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Dl=(0,W.Ay)("div",{name:"MuiDayCalendar",slot:"Header",overridesResolver:(e,t)=>t.header})({display:"flex",justifyContent:"center",alignItems:"center"}),kl=(0,W.Ay)(ze.A,{name:"MuiDayCalendar",slot:"WeekDayLabel",overridesResolver:(e,t)=>t.weekDayLabel})(({theme:e})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:(e.vars||e).palette.text.secondary})),Pl=(0,W.Ay)(ze.A,{name:"MuiDayCalendar",slot:"WeekNumberLabel",overridesResolver:(e,t)=>t.weekNumberLabel})(({theme:e})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:e.palette.text.disabled})),wl=(0,W.Ay)(ze.A,{name:"MuiDayCalendar",slot:"WeekNumber",overridesResolver:(e,t)=>t.weekNumber})(({theme:e})=>(0,m.A)({},e.typography.caption,{width:et,height:et,padding:0,margin:`0 ${dt}px`,color:e.palette.text.disabled,fontSize:"0.75rem",alignItems:"center",justifyContent:"center",display:"inline-flex"})),Sl=(0,W.Ay)("div",{name:"MuiDayCalendar",slot:"LoadingContainer",overridesResolver:(e,t)=>t.loadingContainer})({display:"flex",justifyContent:"center",alignItems:"center",minHeight:ws}),Tl=(0,W.Ay)(bl,{name:"MuiDayCalendar",slot:"SlideTransition",overridesResolver:(e,t)=>t.slideTransition})({minHeight:ws}),Ml=(0,W.Ay)("div",{name:"MuiDayCalendar",slot:"MonthContainer",overridesResolver:(e,t)=>t.monthContainer})({overflow:"hidden"}),Il=(0,W.Ay)("div",{name:"MuiDayCalendar",slot:"WeekContainer",overridesResolver:(e,t)=>t.weekContainer})({margin:`${dt}px 0`,display:"flex",justifyContent:"center"});function Rl(e){var N;let{parentProps:t,day:o,focusableDay:n,selectedDays:s,isDateDisabled:a,currentMonthNumber:i,isViewFocused:c}=e,l=(0,ie.A)(e,Al);const{disabled:u,disableHighlightToday:d,isMonthSwitchingAnimating:p,showDaysOutsideCurrentMonth:f,slots:A,slotProps:h,timezone:C}=t,g=me(),D=qe(C),v=n!==null&&g.isSameDay(o,n),k=s.some(j=>g.isSameDay(j,o)),P=g.isSameDay(o,D),w=(N=A==null?void 0:A.day)!=null?N:is,T=(0,ge.A)({elementType:w,externalSlotProps:h==null?void 0:h.day,additionalProps:(0,m.A)({disableHighlightToday:d,showDaysOutsideCurrentMonth:f,role:"gridcell",isAnimating:p,"data-timestamp":g.toJsDate(o).valueOf()},l),ownerState:(0,m.A)({},t,{day:o,selected:k})}),M=(0,ie.A)(T,Cl),x=b.useMemo(()=>u||a(o),[u,a,o]),R=b.useMemo(()=>g.getMonth(o)!==i,[g,o,i]),V=b.useMemo(()=>{const j=g.startOfMonth(g.setMonth(o,i));return f?g.isSameDay(o,g.startOfWeek(j)):g.isSameDay(o,j)},[i,o,f,g]),S=b.useMemo(()=>{const j=g.endOfMonth(g.setMonth(o,i));return f?g.isSameDay(o,g.endOfWeek(j)):g.isSameDay(o,j)},[i,o,f,g]);return(0,y.jsx)(w,(0,m.A)({},M,{day:o,disabled:x,autoFocus:c&&v,today:P,outsideCurrentMonth:R,isFirstVisibleCell:V,isLastVisibleCell:S,selected:k,tabIndex:v?0:-1,"aria-selected":k,"aria-current":P?"date":void 0}))}function Vl(e){const t=(0,pe.A)({props:e,name:"MuiDayCalendar"}),o=me(),{onFocusedDayChange:n,className:s,currentMonth:a,selectedDays:i,focusedDay:c,loading:l,onSelectedDaysChange:u,onMonthSwitchingAnimationEnd:d,readOnly:p,reduceAnimations:f,renderLoading:A=()=>(0,y.jsx)("span",{children:"..."}),slideDirection:h,TransitionProps:C,disablePast:g,disableFuture:D,minDate:v,maxDate:k,shouldDisableDate:P,shouldDisableMonth:w,shouldDisableYear:T,dayOfWeekFormatter:M=$=>o.format($,"weekdayShort").charAt(0).toUpperCase(),hasFocus:x,onFocusedViewChange:R,gridLabelId:V,displayWeekNumber:S,fixedWeekNumber:N,autoFocus:j,timezone:F}=t,E=qe(F),H=vl(t),_=(0,we.I)(),Z=vs({shouldDisableDate:P,shouldDisableMonth:w,shouldDisableYear:T,minDate:v,maxDate:k,disablePast:g,disableFuture:D,timezone:F}),Y=xe(),[te,se]=(0,_e.A)({name:"DayCalendar",state:"hasFocus",controlled:x,default:j!=null?j:!1}),[le,de]=b.useState(()=>c||E),ce=(0,oe.A)($=>{p||u($)}),U=$=>{Z($)||(n($),de($),R==null||R(!0),se(!0))},ne=(0,oe.A)(($,Q)=>{switch($.key){case"ArrowUp":U(o.addDays(Q,-7)),$.preventDefault();break;case"ArrowDown":U(o.addDays(Q,7)),$.preventDefault();break;case"ArrowLeft":{const L=o.addDays(Q,_?1:-1),z=o.addMonths(Q,_?1:-1),J=Rt({utils:o,date:L,minDate:_?L:o.startOfMonth(z),maxDate:_?o.endOfMonth(z):L,isDateDisabled:Z,timezone:F});U(J||L),$.preventDefault();break}case"ArrowRight":{const L=o.addDays(Q,_?-1:1),z=o.addMonths(Q,_?-1:1),J=Rt({utils:o,date:L,minDate:_?o.startOfMonth(z):L,maxDate:_?L:o.endOfMonth(z),isDateDisabled:Z,timezone:F});U(J||L),$.preventDefault();break}case"Home":U(o.startOfWeek(Q)),$.preventDefault();break;case"End":U(o.endOfWeek(Q)),$.preventDefault();break;case"PageUp":U(o.addMonths(Q,1)),$.preventDefault();break;case"PageDown":U(o.addMonths(Q,-1)),$.preventDefault();break;default:break}}),G=(0,oe.A)(($,Q)=>U(Q)),O=(0,oe.A)(($,Q)=>{te&&o.isSameDay(le,Q)&&(R==null||R(!1))}),B=o.getMonth(a),ae=o.getYear(a),ee=b.useMemo(()=>i.filter($=>!!$).map($=>o.startOfDay($)),[o,i]),q=`${ae}-${B}`,I=b.useMemo(()=>b.createRef(),[q]),K=b.useMemo(()=>{const $=o.startOfMonth(a),Q=o.endOfMonth(a);return Z(le)||o.isAfterDay(le,Q)||o.isBeforeDay(le,$)?Rt({utils:o,date:le,minDate:$,maxDate:Q,disablePast:g,disableFuture:D,isDateDisabled:Z,timezone:F}):le},[a,D,g,le,Z,o,F]),X=b.useMemo(()=>{const $=o.getWeekArray(a);let Q=o.addMonths(a,1);for(;N&&$.length{$.length(0,y.jsx)(kl,{variant:"caption",role:"columnheader","aria-label":o.format($,"weekday"),className:H.weekDayLabel,children:M($)},Q.toString()))]}),l?(0,y.jsx)(Sl,{className:H.loadingContainer,children:A()}):(0,y.jsx)(Tl,(0,m.A)({transKey:q,onExited:d,reduceAnimations:f,slideDirection:h,className:(0,fe.A)(s,H.slideTransition)},C,{nodeRef:I,children:(0,y.jsx)(Ml,{ref:I,role:"rowgroup",className:H.monthContainer,children:X.map(($,Q)=>(0,y.jsxs)(Il,{role:"row",className:H.weekContainer,"aria-rowindex":Q+1,children:[S&&(0,y.jsx)(wl,{className:H.weekNumber,role:"rowheader","aria-label":Y.calendarWeekNumberAriaLabelText(o.getWeekNumber($[0])),children:Y.calendarWeekNumberText(o.getWeekNumber($[0]))}),$.map((L,z)=>(0,y.jsx)(Rl,{parentProps:t,day:L,selectedDays:ee,focusableDay:K,onKeyDown:ne,onFocus:G,onBlur:O,onDaySelect:ce,isDateDisabled:Z,currentMonthNumber:B,isViewFocused:te,"aria-colindex":z+1},L.toString()))]},`week-${$[0]}`))})}))]})}function Fl(e){return(0,be.Ay)("MuiPickersMonth",e)}const Nt=(0,ye.A)("MuiPickersMonth",["root","monthButton","disabled","selected"]),Ol=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","aria-label","monthsPerRow","slots","slotProps"],Ll=e=>{const{disabled:t,selected:o,classes:n}=e,s={root:["root"],monthButton:["monthButton",t&&"disabled",o&&"selected"]};return(0,he.A)(s,Fl,n)},Nl=(0,W.Ay)("div",{name:"MuiPickersMonth",slot:"Root",overridesResolver:(e,t)=>[t.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{monthsPerRow:4},style:{flexBasis:"25%"}}]}),jl=(0,W.Ay)("button",{name:"MuiPickersMonth",slot:"MonthButton",overridesResolver:(e,t)=>[t.monthButton,{[`&.${Nt.disabled}`]:t.disabled},{[`&.${Nt.selected}`]:t.selected}]})(({theme:e})=>(0,m.A)({color:"unset",backgroundColor:"transparent",border:0,outline:0},e.typography.subtitle1,{margin:"8px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,Be.X4)(e.palette.action.active,e.palette.action.hoverOpacity)},"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,Be.X4)(e.palette.action.active,e.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${Nt.disabled}`]:{color:(e.vars||e).palette.text.secondary},[`&.${Nt.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,"&:focus, &:hover":{backgroundColor:(e.vars||e).palette.primary.dark}}})),El=b.memo(function(t){var M;const o=(0,pe.A)({props:t,name:"MuiPickersMonth"}),{autoFocus:n,className:s,children:a,disabled:i,selected:c,value:l,tabIndex:u,onClick:d,onKeyDown:p,onFocus:f,onBlur:A,"aria-current":h,"aria-label":C,slots:g,slotProps:D}=o,v=(0,ie.A)(o,Ol),k=b.useRef(null),P=Ll(o);(0,He.A)(()=>{var x;n&&((x=k.current)==null||x.focus())},[n]);const w=(M=g==null?void 0:g.monthButton)!=null?M:jl,T=(0,ge.A)({elementType:w,externalSlotProps:D==null?void 0:D.monthButton,additionalProps:{children:a,disabled:i,tabIndex:u,ref:k,type:"button",role:"radio","aria-current":h,"aria-checked":c,"aria-label":C,onClick:x=>d(x,l),onKeyDown:x=>p(x,l),onFocus:x=>f(x,l),onBlur:x=>A(x,l)},ownerState:o,className:P.monthButton});return(0,y.jsx)(Nl,(0,m.A)({className:(0,fe.A)(P.root,s),ownerState:o},v,{children:(0,y.jsx)(w,(0,m.A)({},T))}))});function Ss(e){return(0,be.Ay)("MuiMonthCalendar",e)}const Bl=(0,ye.A)("MuiMonthCalendar",["root"]),$l=["className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","shouldDisableMonth","readOnly","disableHighlightToday","autoFocus","onMonthFocus","hasFocus","onFocusedViewChange","monthsPerRow","timezone","gridLabelId","slots","slotProps"],Hl=e=>{const{classes:t}=e,o={root:["root"]};return(0,he.A)(o,Ss,t)};function Wl(e,t){const o=me(),n=Je(),s=(0,pe.A)({props:e,name:t});return(0,m.A)({disableFuture:!1,disablePast:!1},s,{minDate:Pe(o,s.minDate,n.minDate),maxDate:Pe(o,s.maxDate,n.maxDate)})}const zl=(0,W.Ay)("div",{name:"MuiMonthCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexWrap:"wrap",alignContent:"stretch",padding:"0 4px",width:Tt,boxSizing:"border-box"}),Ts=b.forwardRef(function(t,o){const n=Wl(t,"MuiMonthCalendar"),{className:s,value:a,defaultValue:i,referenceDate:c,disabled:l,disableFuture:u,disablePast:d,maxDate:p,minDate:f,onChange:A,shouldDisableMonth:h,readOnly:C,autoFocus:g=!1,onMonthFocus:D,hasFocus:v,onFocusedViewChange:k,monthsPerRow:P=3,timezone:w,gridLabelId:T,slots:M,slotProps:x}=n,R=(0,ie.A)(n,$l),{value:V,handleValueChange:S,timezone:N}=ft({name:"MonthCalendar",timezone:w,value:a,defaultValue:i,referenceDate:c,onChange:A,valueManager:Ce}),j=qe(N),F=(0,we.I)(),E=me(),H=b.useMemo(()=>Ce.getInitialReferenceValue({value:V,utils:E,props:n,timezone:N,referenceDate:c,granularity:je.month}),[]),_=n,Z=Hl(_),Y=b.useMemo(()=>E.getMonth(j),[E,j]),te=b.useMemo(()=>V!=null?E.getMonth(V):null,[V,E]),[se,le]=b.useState(()=>te||E.getMonth(H)),[de,ce]=(0,_e.A)({name:"MonthCalendar",state:"hasFocus",controlled:v,default:g!=null?g:!1}),U=(0,oe.A)(q=>{ce(q),k&&k(q)}),ne=b.useCallback(q=>{const I=E.startOfMonth(d&&E.isAfter(j,f)?j:f),K=E.startOfMonth(u&&E.isBefore(j,p)?j:p),X=E.startOfMonth(q);return E.isBefore(X,I)||E.isAfter(X,K)?!0:h?h(X):!1},[u,d,p,f,j,h,E]),G=(0,oe.A)((q,I)=>{if(C)return;const K=E.setMonth(V!=null?V:H,I);S(K)}),O=(0,oe.A)(q=>{ne(E.setMonth(V!=null?V:H,q))||(le(q),U(!0),D&&D(q))});b.useEffect(()=>{le(q=>te!==null&&q!==te?te:q)},[te]);const B=(0,oe.A)((q,I)=>{switch(q.key){case"ArrowUp":O((12+I-3)%12),q.preventDefault();break;case"ArrowDown":O((12+I+3)%12),q.preventDefault();break;case"ArrowLeft":O((12+I+(F?1:-1))%12),q.preventDefault();break;case"ArrowRight":O((12+I+(F?-1:1))%12),q.preventDefault();break;default:break}}),ae=(0,oe.A)((q,I)=>{O(I)}),ee=(0,oe.A)((q,I)=>{se===I&&U(!1)});return(0,y.jsx)(zl,(0,m.A)({ref:o,className:(0,fe.A)(Z.root,s),ownerState:_,role:"radiogroup","aria-labelledby":T},R,{children:dn(E,V!=null?V:H).map(q=>{const I=E.getMonth(q),K=E.format(q,"monthShort"),X=E.format(q,"month"),$=I===te,Q=l||ne(q);return(0,y.jsx)(El,{selected:$,value:I,onClick:G,onKeyDown:B,autoFocus:de&&I===se,disabled:Q,tabIndex:I===se&&!Q?0:-1,onFocus:ae,onBlur:ee,"aria-current":Y===I?"date":void 0,"aria-label":X,monthsPerRow:P,slots:M,slotProps:x,children:K},K)})}))});function Ul(e){return(0,be.Ay)("MuiPickersYear",e)}const jt=(0,ye.A)("MuiPickersYear",["root","yearButton","selected","disabled"]),Yl=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","yearsPerRow","slots","slotProps"],Kl=e=>{const{disabled:t,selected:o,classes:n}=e,s={root:["root"],yearButton:["yearButton",t&&"disabled",o&&"selected"]};return(0,he.A)(s,Ul,n)},Gl=(0,W.Ay)("div",{name:"MuiPickersYear",slot:"Root",overridesResolver:(e,t)=>[t.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{yearsPerRow:4},style:{flexBasis:"25%"}}]}),Xl=(0,W.Ay)("button",{name:"MuiPickersYear",slot:"YearButton",overridesResolver:(e,t)=>[t.yearButton,{[`&.${jt.disabled}`]:t.disabled},{[`&.${jt.selected}`]:t.selected}]})(({theme:e})=>(0,m.A)({color:"unset",backgroundColor:"transparent",border:0,outline:0},e.typography.subtitle1,{margin:"6px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.focusOpacity})`:(0,Be.X4)(e.palette.action.active,e.palette.action.focusOpacity)},"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,Be.X4)(e.palette.action.active,e.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${jt.disabled}`]:{color:(e.vars||e).palette.text.secondary},[`&.${jt.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,"&:focus, &:hover":{backgroundColor:(e.vars||e).palette.primary.dark}}})),Ql=b.memo(function(t){var T;const o=(0,pe.A)({props:t,name:"MuiPickersYear"}),{autoFocus:n,className:s,children:a,disabled:i,selected:c,value:l,tabIndex:u,onClick:d,onKeyDown:p,onFocus:f,onBlur:A,"aria-current":h,slots:C,slotProps:g}=o,D=(0,ie.A)(o,Yl),v=b.useRef(null),k=Kl(o);(0,He.A)(()=>{var M;n&&((M=v.current)==null||M.focus())},[n]);const P=(T=C==null?void 0:C.yearButton)!=null?T:Xl,w=(0,ge.A)({elementType:P,externalSlotProps:g==null?void 0:g.yearButton,additionalProps:{children:a,disabled:i,tabIndex:u,ref:v,type:"button",role:"radio","aria-current":h,"aria-checked":c,onClick:M=>d(M,l),onKeyDown:M=>p(M,l),onFocus:M=>f(M,l),onBlur:M=>A(M,l)},ownerState:o,className:k.yearButton});return(0,y.jsx)(Gl,(0,m.A)({className:(0,fe.A)(k.root,s),ownerState:o},D,{children:(0,y.jsx)(P,(0,m.A)({},w))}))});function Ms(e){return(0,be.Ay)("MuiYearCalendar",e)}const Zl=(0,ye.A)("MuiYearCalendar",["root"]),Jl=["autoFocus","className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","readOnly","shouldDisableYear","disableHighlightToday","onYearFocus","hasFocus","onFocusedViewChange","yearsOrder","yearsPerRow","timezone","gridLabelId","slots","slotProps"],ql=e=>{const{classes:t}=e,o={root:["root"]};return(0,he.A)(o,Ms,t)};function _l(e,t){var a;const o=me(),n=Je(),s=(0,pe.A)({props:e,name:t});return(0,m.A)({disablePast:!1,disableFuture:!1},s,{yearsPerRow:(a=s.yearsPerRow)!=null?a:3,minDate:Pe(o,s.minDate,n.minDate),maxDate:Pe(o,s.maxDate,n.maxDate)})}const ec=(0,W.Ay)("div",{name:"MuiYearCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexDirection:"row",flexWrap:"wrap",overflowY:"auto",height:"100%",padding:"0 4px",width:Tt,maxHeight:Dr,boxSizing:"border-box",position:"relative"}),Is=b.forwardRef(function(t,o){const n=_l(t,"MuiYearCalendar"),{autoFocus:s,className:a,value:i,defaultValue:c,referenceDate:l,disabled:u,disableFuture:d,disablePast:p,maxDate:f,minDate:A,onChange:h,readOnly:C,shouldDisableYear:g,onYearFocus:D,hasFocus:v,onFocusedViewChange:k,yearsOrder:P="asc",yearsPerRow:w,timezone:T,gridLabelId:M,slots:x,slotProps:R}=n,V=(0,ie.A)(n,Jl),{value:S,handleValueChange:N,timezone:j}=ft({name:"YearCalendar",timezone:T,value:i,defaultValue:c,referenceDate:l,onChange:h,valueManager:Ce}),F=qe(j),E=(0,we.I)(),H=me(),_=b.useMemo(()=>Ce.getInitialReferenceValue({value:S,utils:H,props:n,timezone:j,referenceDate:l,granularity:je.year}),[]),Z=n,Y=ql(Z),te=b.useMemo(()=>H.getYear(F),[H,F]),se=b.useMemo(()=>S!=null?H.getYear(S):null,[S,H]),[le,de]=b.useState(()=>se||H.getYear(_)),[ce,U]=(0,_e.A)({name:"YearCalendar",state:"hasFocus",controlled:v,default:s!=null?s:!1}),ne=(0,oe.A)(L=>{U(L),k&&k(L)}),G=b.useCallback(L=>{if(p&&H.isBeforeYear(L,F)||d&&H.isAfterYear(L,F)||A&&H.isBeforeYear(L,A)||f&&H.isAfterYear(L,f))return!0;if(!g)return!1;const z=H.startOfYear(L);return g(z)},[d,p,f,A,F,g,H]),O=(0,oe.A)((L,z)=>{if(C)return;const J=H.setYear(S!=null?S:_,z);N(J)}),B=(0,oe.A)(L=>{G(H.setYear(S!=null?S:_,L))||(de(L),ne(!0),D==null||D(L))});b.useEffect(()=>{de(L=>se!==null&&L!==se?se:L)},[se]);const ae=P!=="desc"?w*1:w*-1,ee=E&&P==="asc"||!E&&P==="desc"?-1:1,q=(0,oe.A)((L,z)=>{switch(L.key){case"ArrowUp":B(z-ae),L.preventDefault();break;case"ArrowDown":B(z+ae),L.preventDefault();break;case"ArrowLeft":B(z-ee),L.preventDefault();break;case"ArrowRight":B(z+ee),L.preventDefault();break;default:break}}),I=(0,oe.A)((L,z)=>{B(z)}),K=(0,oe.A)((L,z)=>{le===z&&ne(!1)}),X=b.useRef(null),$=(0,Se.A)(o,X);b.useEffect(()=>{if(s||X.current===null)return;const L=X.current.querySelector('[tabindex="0"]');if(!L)return;const z=L.offsetHeight,J=L.offsetTop,ue=X.current.clientHeight,Ae=X.current.scrollTop,Le=J+z;z>ue||J{const z=H.getYear(L),J=z===se,ue=u||G(L);return(0,y.jsx)(Ql,{selected:J,value:z,onClick:O,onKeyDown:q,autoFocus:ce&&z===le,disabled:ue,tabIndex:z===le&&!ue?0:-1,onFocus:I,onBlur:K,"aria-current":te===z?"date":void 0,yearsPerRow:w,slots:x,slotProps:R,children:H.format(L,"year")},H.format(L,"year"))})}))}),tc=e=>(0,be.Ay)("MuiPickersCalendarHeader",e),Rs=(0,ye.A)("MuiPickersCalendarHeader",["root","labelContainer","label","switchViewButton","switchViewIcon"]),nc=["slots","slotProps","currentMonth","disabled","disableFuture","disablePast","maxDate","minDate","onMonthChange","onViewChange","view","reduceAnimations","views","labelId","className","timezone","format"],oc=["ownerState"],sc=e=>{const{classes:t}=e,o={root:["root"],labelContainer:["labelContainer"],label:["label"],switchViewButton:["switchViewButton"],switchViewIcon:["switchViewIcon"]};return(0,he.A)(o,tc,t)},rc=(0,W.Ay)("div",{name:"MuiPickersCalendarHeader",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",alignItems:"center",marginTop:12,marginBottom:4,paddingLeft:24,paddingRight:12,maxHeight:40,minHeight:40}),ac=(0,W.Ay)("div",{name:"MuiPickersCalendarHeader",slot:"LabelContainer",overridesResolver:(e,t)=>t.labelContainer})(({theme:e})=>(0,m.A)({display:"flex",overflow:"hidden",alignItems:"center",cursor:"pointer",marginRight:"auto"},e.typography.body1,{fontWeight:e.typography.fontWeightMedium})),ic=(0,W.Ay)("div",{name:"MuiPickersCalendarHeader",slot:"Label",overridesResolver:(e,t)=>t.label})({marginRight:6}),lc=(0,W.Ay)(ct.A,{name:"MuiPickersCalendarHeader",slot:"SwitchViewButton",overridesResolver:(e,t)=>t.switchViewButton})({marginRight:"auto",variants:[{props:{view:"year"},style:{[`.${Rs.switchViewIcon}`]:{transform:"rotate(180deg)"}}}]}),cc=(0,W.Ay)(bo,{name:"MuiPickersCalendarHeader",slot:"SwitchViewIcon",overridesResolver:(e,t)=>t.switchViewIcon})(({theme:e})=>({willChange:"transform",transition:e.transitions.create("transform"),transform:"rotate(0deg)"})),Vs=b.forwardRef(function(t,o){var se,le;const n=xe(),s=me(),a=(0,pe.A)({props:t,name:"MuiPickersCalendarHeader"}),{slots:i,slotProps:c,currentMonth:l,disabled:u,disableFuture:d,disablePast:p,maxDate:f,minDate:A,onMonthChange:h,onViewChange:C,view:g,reduceAnimations:D,views:v,labelId:k,className:P,timezone:w,format:T=`${s.formats.month} ${s.formats.year}`}=a,M=(0,ie.A)(a,nc),x=a,R=sc(a),V=(se=i==null?void 0:i.switchViewButton)!=null?se:lc,S=(0,ge.A)({elementType:V,externalSlotProps:c==null?void 0:c.switchViewButton,additionalProps:{size:"small","aria-label":n.calendarViewSwitchingButtonAriaLabel(g)},ownerState:x,className:R.switchViewButton}),N=(le=i==null?void 0:i.switchViewIcon)!=null?le:cc,j=(0,ge.A)({elementType:N,externalSlotProps:c==null?void 0:c.switchViewIcon,ownerState:x,className:R.switchViewIcon}),F=(0,ie.A)(j,oc),E=()=>h(s.addMonths(l,1),"left"),H=()=>h(s.addMonths(l,-1),"right"),_=vr(l,{disableFuture:d,maxDate:f,timezone:w}),Z=xr(l,{disablePast:p,minDate:A,timezone:w}),Y=()=>{if(!(v.length===1||!C||u))if(v.length===2)C(v.find(de=>de!==g)||v[0]);else{const de=v.indexOf(g)!==0?0:1;C(v[de])}};if(v.length===1&&v[0]==="year")return null;const te=s.formatByString(l,T);return(0,y.jsxs)(rc,(0,m.A)({},M,{ownerState:x,className:(0,fe.A)(R.root,P),ref:o,children:[(0,y.jsxs)(ac,{role:"presentation",onClick:Y,ownerState:x,"aria-live":"polite",className:R.labelContainer,children:[(0,y.jsx)(ks,{reduceAnimations:D,transKey:te,children:(0,y.jsx)(ic,{id:k,ownerState:x,className:R.label,children:te})}),v.length>1&&!u&&(0,y.jsx)(V,(0,m.A)({},S,{children:(0,y.jsx)(N,(0,m.A)({},F))}))]}),(0,y.jsx)(nn.A,{in:g==="day",children:(0,y.jsx)(ko,{slots:i,slotProps:c,onGoToPrevious:H,isPreviousDisabled:Z,previousLabel:n.previousMonth,onGoToNext:E,isNextDisabled:_,nextLabel:n.nextMonth})})]}))});var on=re(7544);const uc="@media (prefers-reduced-motion: reduce)",vt=typeof navigator!="undefined"&&navigator.userAgent.match(/android\s(\d+)|OS\s(\d+)/i),Fs=vt&&vt[1]?parseInt(vt[1],10):null,Os=vt&&vt[2]?parseInt(vt[2],10):null,dc=Fs&&Fs<10||Os&&Os<13||!1,Ls=()=>(0,on.A)(uc,{defaultMatches:!1})||dc,Ns=e=>(0,be.Ay)("MuiDateCalendar",e),pc=(0,ye.A)("MuiDateCalendar",["root","viewTransitionContainer"]),mc=["autoFocus","onViewChange","value","defaultValue","referenceDate","disableFuture","disablePast","onChange","onYearChange","onMonthChange","reduceAnimations","shouldDisableDate","shouldDisableMonth","shouldDisableYear","view","views","openTo","className","disabled","readOnly","minDate","maxDate","disableHighlightToday","focusedView","onFocusedViewChange","showDaysOutsideCurrentMonth","fixedWeekNumber","dayOfWeekFormatter","slots","slotProps","loading","renderLoading","displayWeekNumber","yearsOrder","yearsPerRow","monthsPerRow","timezone"],fc=e=>{const{classes:t}=e,o={root:["root"],viewTransitionContainer:["viewTransitionContainer"]};return(0,he.A)(o,Ns,t)};function hc(e,t){var i,c,l,u,d,p,f;const o=me(),n=Je(),s=Ls(),a=(0,pe.A)({props:e,name:t});return(0,m.A)({},a,{loading:(i=a.loading)!=null?i:!1,disablePast:(c=a.disablePast)!=null?c:!1,disableFuture:(l=a.disableFuture)!=null?l:!1,openTo:(u=a.openTo)!=null?u:"day",views:(d=a.views)!=null?d:["year","day"],reduceAnimations:(p=a.reduceAnimations)!=null?p:s,renderLoading:(f=a.renderLoading)!=null?f:()=>(0,y.jsx)("span",{children:"..."}),minDate:Pe(o,a.minDate,n.minDate),maxDate:Pe(o,a.maxDate,n.maxDate)})}const bc=(0,W.Ay)(Yt,{name:"MuiDateCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexDirection:"column",height:Ut}),yc=(0,W.Ay)(ks,{name:"MuiDateCalendar",slot:"ViewTransitionContainer",overridesResolver:(e,t)=>t.viewTransitionContainer})({}),js=b.forwardRef(function(t,o){var ir;const n=me(),s=(0,it.A)(),a=hc(t,"MuiDateCalendar"),{autoFocus:i,onViewChange:c,value:l,defaultValue:u,referenceDate:d,disableFuture:p,disablePast:f,onChange:A,onYearChange:h,onMonthChange:C,reduceAnimations:g,shouldDisableDate:D,shouldDisableMonth:v,shouldDisableYear:k,view:P,views:w,openTo:T,className:M,disabled:x,readOnly:R,minDate:V,maxDate:S,disableHighlightToday:N,focusedView:j,onFocusedViewChange:F,showDaysOutsideCurrentMonth:E,fixedWeekNumber:H,dayOfWeekFormatter:_,slots:Z,slotProps:Y,loading:te,renderLoading:se,displayWeekNumber:le,yearsOrder:de,yearsPerRow:ce,monthsPerRow:U,timezone:ne}=a,G=(0,ie.A)(a,mc),{value:O,handleValueChange:B,timezone:ae}=ft({name:"DateCalendar",timezone:ne,value:l,defaultValue:u,referenceDate:d,onChange:A,valueManager:Ce}),{view:ee,setView:q,focusedView:I,setFocusedView:K,goToNextView:X,setValueAndGoToNextView:$}=St({view:P,views:w,openTo:T,onChange:B,onViewChange:c,autoFocus:i,focusedView:j,onFocusedViewChange:F}),{referenceDate:Q,calendarState:L,changeFocusedDay:z,changeMonth:J,handleChangeMonth:ue,isDateDisabled:Ae,onMonthSwitchingAnimationEnd:Le}=_i({value:O,referenceDate:d,reduceAnimations:g,onMonthChange:C,minDate:V,maxDate:S,shouldDisableDate:D,disablePast:f,disableFuture:p,timezone:ae}),at=x&&O||V,ke=x&&O||S,Ve=`${s}-grid-label`,Xe=I!==null,an=(ir=Z==null?void 0:Z.calendarHeader)!=null?ir:Vs,yd=(0,ge.A)({elementType:an,externalSlotProps:Y==null?void 0:Y.calendarHeader,additionalProps:{views:w,view:ee,currentMonth:L.currentMonth,onViewChange:q,onMonthChange:(ve,$e)=>ue({newMonth:ve,direction:$e}),minDate:at,maxDate:ke,disabled:x,disablePast:f,disableFuture:p,reduceAnimations:g,timezone:ae,labelId:Ve},ownerState:a}),gd=(0,oe.A)(ve=>{const $e=n.startOfMonth(ve),$t=n.endOfMonth(ve),Qe=Ae(ve)?Rt({utils:n,date:ve,minDate:n.isBefore(V,$e)?$e:V,maxDate:n.isAfter(S,$t)?$t:S,disablePast:f,disableFuture:p,isDateDisabled:Ae,timezone:ae}):ve;Qe?($(Qe,"finish"),C==null||C($e)):(X(),J($e)),z(Qe,!0)}),Ad=(0,oe.A)(ve=>{const $e=n.startOfYear(ve),$t=n.endOfYear(ve),Qe=Ae(ve)?Rt({utils:n,date:ve,minDate:n.isBefore(V,$e)?$e:V,maxDate:n.isAfter(S,$t)?$t:S,disablePast:f,disableFuture:p,isDateDisabled:Ae,timezone:ae}):ve;Qe?($(Qe,"finish"),h==null||h(Qe)):(X(),J($e)),z(Qe,!0)}),Cd=(0,oe.A)(ve=>B(ve&&Kt(n,ve,O!=null?O:Q),"finish",ee));b.useEffect(()=>{O!=null&&n.isValid(O)&&J(O)},[O]);const io=a,ar=fc(io),lo={disablePast:f,disableFuture:p,maxDate:S,minDate:V},co={disableHighlightToday:N,readOnly:R,disabled:x,timezone:ae,gridLabelId:Ve,slots:Z,slotProps:Y},uo=b.useRef(ee);b.useEffect(()=>{uo.current!==ee&&(I===uo.current&&K(ee,!0),uo.current=ee)},[I,K,ee]);const vd=b.useMemo(()=>[O],[O]);return(0,y.jsxs)(bc,(0,m.A)({ref:o,className:(0,fe.A)(ar.root,M),ownerState:io},G,{children:[(0,y.jsx)(an,(0,m.A)({},yd,{slots:Z,slotProps:Y})),(0,y.jsx)(yc,{reduceAnimations:g,className:ar.viewTransitionContainer,transKey:ee,ownerState:io,children:(0,y.jsxs)("div",{children:[ee==="year"&&(0,y.jsx)(Is,(0,m.A)({},lo,co,{value:O,onChange:Ad,shouldDisableYear:k,hasFocus:Xe,onFocusedViewChange:ve=>K("year",ve),yearsOrder:de,yearsPerRow:ce,referenceDate:Q})),ee==="month"&&(0,y.jsx)(Ts,(0,m.A)({},lo,co,{hasFocus:Xe,className:M,value:O,onChange:gd,shouldDisableMonth:v,onFocusedViewChange:ve=>K("month",ve),monthsPerRow:U,referenceDate:Q})),ee==="day"&&(0,y.jsx)(Vl,(0,m.A)({},L,lo,co,{onMonthSwitchingAnimationEnd:Le,onFocusedDayChange:z,reduceAnimations:g,selectedDays:vd,onSelectedDaysChange:Cd,shouldDisableDate:D,shouldDisableMonth:v,shouldDisableYear:k,hasFocus:Xe,onFocusedViewChange:ve=>K("day",ve),showDaysOutsideCurrentMonth:E,fixedWeekNumber:H,dayOfWeekFormatter:_,displayWeekNumber:le,loading:te,renderLoading:se}))]})})]}))});var gc=re(7417);const Es=e=>(0,be.Ay)("MuiDayCalendarSkeleton",e),Ac=(0,ye.A)("MuiDayCalendarSkeleton",["root","week","daySkeleton"]),Cc=["className"],vc=e=>{const{classes:t}=e,o={root:["root"],week:["week"],daySkeleton:["daySkeleton"]};return(0,he.A)(o,Es,t)},xc=(0,W.Ay)("div",{name:"MuiDayCalendarSkeleton",slot:"Root",overridesResolver:(e,t)=>t.root})({alignSelf:"start"}),Dc=(0,W.Ay)("div",{name:"MuiDayCalendarSkeleton",slot:"Week",overridesResolver:(e,t)=>t.week})({margin:`${dt}px 0`,display:"flex",justifyContent:"center"}),kc=(0,W.Ay)(gc.A,{name:"MuiDayCalendarSkeleton",slot:"DaySkeleton",overridesResolver:(e,t)=>t.daySkeleton})({margin:`0 ${dt}px`,variants:[{props:{day:0},style:{visibility:"hidden"}}]}),Pc=[[0,1,1,1,1,1,1],[1,1,1,1,1,1,1],[1,1,1,1,1,1,1],[1,1,1,1,1,1,1],[1,1,1,1,0,0,0]];function wc(e){const t=(0,pe.A)({props:e,name:"MuiDayCalendarSkeleton"}),{className:o}=t,n=(0,ie.A)(t,Cc),s=vc(n);return(0,y.jsx)(xc,(0,m.A)({className:(0,fe.A)(s.root,o)},n,{children:Pc.map((a,i)=>(0,y.jsx)(Dc,{className:s.week,children:a.map((c,l)=>(0,y.jsx)(kc,{variant:"circular",width:et,height:et,className:s.daySkeleton,ownerState:{day:c}},l))},i))}))}var rt=re(1511);const xt=r().oneOfType([r().func,r().object]);function Bs(e){return(0,be.Ay)("MuiPickersToolbar",e)}const Sc=(0,ye.A)("MuiPickersToolbar",["root","content"]),Tc=["children","className","toolbarTitle","hidden","titleId","isLandscape","classes","landscapeDirection"],Mc=e=>{const{classes:t}=e,o={root:["root"],content:["content"]};return(0,he.A)(o,Bs,t)},Ic=(0,W.Ay)("div",{name:"MuiPickersToolbar",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({display:"flex",flexDirection:"column",alignItems:"flex-start",justifyContent:"space-between",padding:e.spacing(2,3),variants:[{props:{isLandscape:!0},style:{height:"auto",maxWidth:160,padding:16,justifyContent:"flex-start",flexWrap:"wrap"}}]})),Rc=(0,W.Ay)("div",{name:"MuiPickersToolbar",slot:"Content",overridesResolver:(e,t)=>t.content})({display:"flex",flexWrap:"wrap",width:"100%",flex:1,justifyContent:"space-between",alignItems:"center",flexDirection:"row",variants:[{props:{isLandscape:!0},style:{justifyContent:"flex-start",alignItems:"flex-start",flexDirection:"column"}},{props:{isLandscape:!0,landscapeDirection:"row"},style:{flexDirection:"row"}}]}),$n=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiPickersToolbar"}),{children:s,className:a,toolbarTitle:i,hidden:c,titleId:l}=n,u=(0,ie.A)(n,Tc),d=n,p=Mc(d);return c?null:(0,y.jsxs)(Ic,(0,m.A)({ref:o,className:(0,fe.A)(p.root,a),ownerState:d},u,{children:[(0,y.jsx)(ze.A,{color:"text.secondary",variant:"overline",id:l,children:i}),(0,y.jsx)(Rc,{className:p.content,ownerState:d,children:s})]}))});function Vc(e){return(0,be.Ay)("MuiDatePickerToolbar",e)}const Fc=(0,ye.A)("MuiDatePickerToolbar",["root","title"]),Oc=["value","isLandscape","onChange","toolbarFormat","toolbarPlaceholder","views","className","onViewChange","view"],Lc=e=>{const{classes:t}=e,o={root:["root"],title:["title"]};return(0,he.A)(o,Vc,t)},Nc=(0,W.Ay)($n,{name:"MuiDatePickerToolbar",slot:"Root",overridesResolver:(e,t)=>t.root})({}),jc=(0,W.Ay)(ze.A,{name:"MuiDatePickerToolbar",slot:"Title",overridesResolver:(e,t)=>t.title})({variants:[{props:{isLandscape:!0},style:{margin:"auto 16px auto auto"}}]}),$s=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiDatePickerToolbar"}),{value:s,isLandscape:a,toolbarFormat:i,toolbarPlaceholder:c="\u2013\u2013",views:l,className:u}=n,d=(0,ie.A)(n,Oc),p=me(),f=xe(),A=Lc(n),h=b.useMemo(()=>{if(!s)return c;const g=Vt(p,{format:i,views:l},!0);return p.formatByString(s,g)},[s,i,c,p,l]),C=n;return(0,y.jsx)(Nc,(0,m.A)({ref:o,toolbarTitle:f.datePickerToolbarTitle,isLandscape:a,className:(0,fe.A)(A.root,u)},d,{children:(0,y.jsx)(jc,{variant:"h4",align:a?"left":"center",ownerState:C,className:A.title,children:h})}))});function Hn(e,t){var i,c;const o=me(),n=Je(),s=(0,pe.A)({props:e,name:t}),a=b.useMemo(()=>{var l;return((l=s.localeText)==null?void 0:l.toolbarTitle)==null?s.localeText:(0,m.A)({},s.localeText,{datePickerToolbarTitle:s.localeText.toolbarTitle})},[s.localeText]);return(0,m.A)({},s,{localeText:a},un({views:s.views,openTo:s.openTo,defaultViews:["year","day"],defaultOpenTo:"day"}),{disableFuture:(i=s.disableFuture)!=null?i:!1,disablePast:(c=s.disablePast)!=null?c:!1,minDate:Pe(o,s.minDate,n.minDate),maxDate:Pe(o,s.maxDate,n.maxDate),slots:(0,m.A)({toolbar:$s},s.slots)})}var Ec=re(6193),Bc=re(1593),$c=re(4712),Hc=re(5814),Wn=re(271);function Wc(e){return(0,be.Ay)("MuiPickersPopper",e)}const Md=(0,ye.A)("MuiPickersPopper",["root","paper"]),zc=["PaperComponent","popperPlacement","ownerState","children","paperSlotProps","paperClasses","onPaperClick","onPaperTouchStart"],Uc=e=>{const{classes:t}=e,o={root:["root"],paper:["paper"]};return(0,he.A)(o,Wc,t)},Yc=(0,W.Ay)($c.A,{name:"MuiPickersPopper",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({zIndex:e.zIndex.modal})),Kc=(0,W.Ay)(Bc.A,{name:"MuiPickersPopper",slot:"Paper",overridesResolver:(e,t)=>t.paper})({outline:0,transformOrigin:"top center",variants:[{props:({placement:e})=>["top","top-start","top-end"].includes(e),style:{transformOrigin:"bottom center"}}]});function Gc(e,t){return t.documentElement.clientWidth{if(!e)return;function l(){a.current=!0}return document.addEventListener("mousedown",l,!0),document.addEventListener("touchstart",l,!0),()=>{document.removeEventListener("mousedown",l,!0),document.removeEventListener("touchstart",l,!0),a.current=!1}},[e]);const i=(0,oe.A)(l=>{if(!a.current)return;const u=n.current;n.current=!1;const d=(0,Wn.A)(s.current);if(!s.current||"clientX"in l&&Gc(l,d))return;if(o.current){o.current=!1;return}let p;l.composedPath?p=l.composedPath().indexOf(s.current)>-1:p=!d.documentElement.contains(l.target)||s.current.contains(l.target),!p&&!u&&t(l)}),c=()=>{n.current=!0};return b.useEffect(()=>{if(e){const l=(0,Wn.A)(s.current),u=()=>{o.current=!0};return l.addEventListener("touchstart",i),l.addEventListener("touchmove",u),()=>{l.removeEventListener("touchstart",i),l.removeEventListener("touchmove",u)}}},[e,i]),b.useEffect(()=>{if(e){const l=(0,Wn.A)(s.current);return l.addEventListener("click",i),()=>{l.removeEventListener("click",i),n.current=!1}}},[e,i]),[s,c,c]}const Qc=b.forwardRef((e,t)=>{const{PaperComponent:o,popperPlacement:n,ownerState:s,children:a,paperSlotProps:i,paperClasses:c,onPaperClick:l,onPaperTouchStart:u}=e,d=(0,ie.A)(e,zc),p=(0,m.A)({},s,{placement:n}),f=(0,ge.A)({elementType:o,externalSlotProps:i,additionalProps:{tabIndex:-1,elevation:8,ref:t},className:c,ownerState:p});return(0,y.jsx)(o,(0,m.A)({},d,f,{onClick:A=>{var h;l(A),(h=f.onClick)==null||h.call(f,A)},onTouchStart:A=>{var h;u(A),(h=f.onTouchStart)==null||h.call(f,A)},ownerState:p,children:a}))});function Zc(e){var E,H,_,Z;const t=(0,pe.A)({props:e,name:"MuiPickersPopper"}),{anchorEl:o,children:n,containerRef:s=null,shouldRestoreFocus:a,onBlur:i,onDismiss:c,open:l,role:u,placement:d,slots:p,slotProps:f,reduceAnimations:A}=t;b.useEffect(()=>{function Y(te){l&&te.key==="Escape"&&c()}return document.addEventListener("keydown",Y),()=>{document.removeEventListener("keydown",Y)}},[c,l]);const h=b.useRef(null);b.useEffect(()=>{u==="tooltip"||a&&!a()||(l?h.current=Te(document):h.current&&h.current instanceof HTMLElement&&setTimeout(()=>{h.current instanceof HTMLElement&&h.current.focus()}))},[l,u,a]);const[C,g,D]=Xc(l,i!=null?i:c),v=b.useRef(null),k=(0,Se.A)(v,s),P=(0,Se.A)(k,C),w=t,T=Uc(w),M=Ls(),x=A!=null?A:M,R=Y=>{Y.key==="Escape"&&(Y.stopPropagation(),c())},V=((E=p==null?void 0:p.desktopTransition)!=null?E:x)?nn.A:Ec.A,S=(H=p==null?void 0:p.desktopTrapFocus)!=null?H:Hc.A,N=(_=p==null?void 0:p.desktopPaper)!=null?_:Kc,j=(Z=p==null?void 0:p.popper)!=null?Z:Yc,F=(0,ge.A)({elementType:j,externalSlotProps:f==null?void 0:f.popper,additionalProps:{transition:!0,role:u,open:l,anchorEl:o,placement:d,onKeyDown:R},className:T.root,ownerState:t});return(0,y.jsx)(j,(0,m.A)({},F,{children:({TransitionProps:Y,placement:te})=>(0,y.jsx)(S,(0,m.A)({open:l,disableAutoFocus:!0,disableRestoreFocus:!0,disableEnforceFocus:u==="tooltip",isEnabled:()=>!0},f==null?void 0:f.desktopTrapFocus,{children:(0,y.jsx)(V,(0,m.A)({},Y,f==null?void 0:f.desktopTransition,{children:(0,y.jsx)(Qc,{PaperComponent:N,ownerState:w,popperPlacement:te,ref:P,onPaperClick:g,onPaperTouchStart:D,paperClasses:T.paper,paperSlotProps:f==null?void 0:f.desktopPaper,children:n})}))}))}))}const Jc=({open:e,onOpen:t,onClose:o})=>{const n=b.useRef(typeof e=="boolean").current,[s,a]=b.useState(!1);b.useEffect(()=>{if(n){if(typeof e!="boolean")throw new Error("You must not mix controlling and uncontrolled mode for `open` prop");a(e)}},[n,e]);const i=b.useCallback(c=>{n||a(c),c&&t&&t(),!c&&o&&o()},[n,t,o]);return{isOpen:s,setIsOpen:i}},qc=e=>{const{action:t,hasChanged:o,dateState:n,isControlled:s}=e,a=!s&&!n.hasBeenModifiedSinceMount;return t.name==="setValueFromField"?!0:t.name==="setValueFromAction"?a&&["accept","today","clear"].includes(t.pickerAction)?!0:o(n.lastPublishedValue):t.name==="setValueFromView"&&t.selectionState!=="shallow"||t.name==="setValueFromShortcut"?a?!0:o(n.lastPublishedValue):!1},_c=e=>{const{action:t,hasChanged:o,dateState:n,isControlled:s,closeOnSelect:a}=e,i=!s&&!n.hasBeenModifiedSinceMount;return t.name==="setValueFromAction"?i&&["accept","today","clear"].includes(t.pickerAction)?!0:o(n.lastCommittedValue):t.name==="setValueFromView"&&t.selectionState==="finish"&&a?i?!0:o(n.lastCommittedValue):t.name==="setValueFromShortcut"?t.changeImportance==="accept"&&o(n.lastCommittedValue):!1},eu=e=>{const{action:t,closeOnSelect:o}=e;return t.name==="setValueFromAction"?!0:t.name==="setValueFromView"?t.selectionState==="finish"&&o:t.name==="setValueFromShortcut"?t.changeImportance==="accept":!1},tu=({props:e,valueManager:t,valueType:o,wrapperVariant:n,validator:s})=>{const{onAccept:a,onChange:i,value:c,defaultValue:l,closeOnSelect:u=n==="desktop",timezone:d,referenceDate:p}=e,{current:f}=b.useRef(l),{current:A}=b.useRef(c!==void 0),[h,C]=b.useState(d),g=me(),D=Ze(),{isOpen:v,setIsOpen:k}=Jc(e),{timezone:P,value:w,handleValueChange:T}=mn({timezone:d,value:c,defaultValue:f,referenceDate:p,onChange:i,valueManager:t}),[M,x]=b.useState(()=>{let B;return w!==void 0?B=w:f!==void 0?B=f:B=t.emptyValue,{draft:B,lastPublishedValue:B,lastCommittedValue:B,lastControlledValue:c,hasBeenModifiedSinceMount:!1}}),R=t.getTimezone(g,M.draft);h!==d&&(C(d),d&&R&&d!==R&&x(B=>(0,m.A)({},B,{draft:t.setTimezone(g,d,B.draft)})));const{getValidationErrorForNewValue:V}=vn({props:e,validator:s,timezone:P,value:M.draft,onError:e.onError}),S=(0,oe.A)(B=>{const ae={action:B,dateState:M,hasChanged:$=>!t.areValuesEqual(g,B.value,$),isControlled:A,closeOnSelect:u},ee=qc(ae),q=_c(ae),I=eu(ae);x($=>(0,m.A)({},$,{draft:B.value,lastPublishedValue:ee?B.value:$.lastPublishedValue,lastCommittedValue:q?B.value:$.lastCommittedValue,hasBeenModifiedSinceMount:!0}));let K=null;const X=()=>(K||(K={validationError:B.name==="setValueFromField"?B.context.validationError:V(B.value)},B.name==="setValueFromShortcut"&&(K.shortcut=B.shortcut)),K);ee&&T(B.value,X()),q&&a&&a(B.value,X()),I&&k(!1)});if(M.lastControlledValue!==c){const B=t.areValuesEqual(g,M.draft,w);x(ae=>(0,m.A)({},ae,{lastControlledValue:c},B?{}:{lastCommittedValue:w,lastPublishedValue:w,draft:w,hasBeenModifiedSinceMount:!0}))}const N=(0,oe.A)(()=>{S({value:t.emptyValue,name:"setValueFromAction",pickerAction:"clear"})}),j=(0,oe.A)(()=>{S({value:M.lastPublishedValue,name:"setValueFromAction",pickerAction:"accept"})}),F=(0,oe.A)(()=>{S({value:M.lastPublishedValue,name:"setValueFromAction",pickerAction:"dismiss"})}),E=(0,oe.A)(()=>{S({value:M.lastCommittedValue,name:"setValueFromAction",pickerAction:"cancel"})}),H=(0,oe.A)(()=>{S({value:t.getTodayValue(g,P,o),name:"setValueFromAction",pickerAction:"today"})}),_=(0,oe.A)(B=>{B.preventDefault(),k(!0)}),Z=(0,oe.A)(B=>{B==null||B.preventDefault(),k(!1)}),Y=(0,oe.A)((B,ae="partial")=>S({name:"setValueFromView",value:B,selectionState:ae})),te=(0,oe.A)((B,ae,ee)=>S({name:"setValueFromShortcut",value:B,changeImportance:ae,shortcut:ee})),se=(0,oe.A)((B,ae)=>S({name:"setValueFromField",value:B,context:ae})),le={onClear:N,onAccept:j,onDismiss:F,onCancel:E,onSetToday:H,onOpen:_,onClose:Z},de={value:M.draft,onChange:se},ce=b.useMemo(()=>t.cleanValue(g,M.draft),[g,t,M.draft]),U={value:ce,onChange:Y,onClose:Z,open:v},ne=B=>{const ae=s({adapter:D,value:B,timezone:P,props:e});return!t.hasError(ae)},G=(0,m.A)({},le,{value:ce,onChange:Y,onSelectShortcut:te,isValid:ne}),O=b.useMemo(()=>({onOpen:_,onClose:Z,open:v}),[v,Z,_]);return{open:v,fieldProps:de,viewProps:U,layoutProps:G,actions:le,contextValue:O}},nu=["className","sx"],ou=({props:e,propsFromPickerValue:t,additionalViewProps:o,autoFocusView:n,rendererInterceptor:s,fieldRef:a})=>{const{onChange:i,open:c,onClose:l}=t,{view:u,views:d,openTo:p,onViewChange:f,viewRenderers:A,timezone:h}=e,C=(0,ie.A)(e,nu),{view:g,setView:D,defaultView:v,focusedView:k,setFocusedView:P,setValueAndGoToNextView:w}=St({view:u,views:d,openTo:p,onChange:i,onViewChange:f,autoFocus:n}),{hasUIView:T,viewModeLookup:M}=b.useMemo(()=>d.reduce((F,E)=>{let H;return A[E]!=null?H="UI":H="field",F.viewModeLookup[E]=H,H==="UI"&&(F.hasUIView=!0),F},{hasUIView:!1,viewModeLookup:{}}),[A,d]),x=b.useMemo(()=>d.reduce((F,E)=>A[E]!=null&&ut(E)?F+1:F,0),[A,d]),R=M[g],V=(0,oe.A)(()=>R==="UI"),[S,N]=b.useState(R==="UI"?g:null);return S!==g&&M[g]==="UI"&&N(g),(0,He.A)(()=>{R==="field"&&c&&(l(),setTimeout(()=>{var F,E;(F=a==null?void 0:a.current)==null||F.setSelectedSections(g),(E=a==null?void 0:a.current)==null||E.focusField(g)}))},[g]),(0,He.A)(()=>{if(!c)return;let F=g;R==="field"&&S!=null&&(F=S),F!==v&&M[F]==="UI"&&M[v]==="UI"&&(F=v),F!==g&&D(F),P(F,!0)},[c]),{hasUIView:T,shouldRestoreFocus:V,layoutProps:{views:d,view:S,onViewChange:D},renderCurrentView:()=>{if(S==null)return null;const F=A[S];if(F==null)return null;const E=(0,m.A)({},C,o,t,{views:d,timezone:h,onChange:w,view:S,onViewChange:D,focusedView:k,onFocusedViewChange:P,showViewSwitcher:x>1,timeViewsCount:x});return s?s(A,S,E):F(E)}}};function Hs(){return typeof window=="undefined"?"portrait":window.screen&&window.screen.orientation&&window.screen.orientation.angle?Math.abs(window.screen.orientation.angle)===90?"landscape":"portrait":window.orientation&&Math.abs(Number(window.orientation))===90?"landscape":"portrait"}const su=(e,t)=>{const[o,n]=b.useState(Hs);return(0,He.A)(()=>{const a=()=>{n(Hs())};return window.addEventListener("orientationchange",a),()=>{window.removeEventListener("orientationchange",a)}},[]),ht(e,["hours","minutes","seconds"])?!1:(t||o)==="landscape"},ru=({props:e,propsFromPickerValue:t,propsFromPickerViews:o,wrapperVariant:n})=>{const{orientation:s}=e,a=su(o.views,s),i=(0,we.I)();return{layoutProps:(0,m.A)({},o,t,{isLandscape:a,isRtl:i,wrapperVariant:n,disabled:e.disabled,readOnly:e.readOnly})}};function au(e){const{props:t,pickerValueResponse:o}=e;return b.useMemo(()=>{var n,s;return{value:o.viewProps.value,open:o.open,disabled:(n=t.disabled)!=null?n:!1,readOnly:(s=t.readOnly)!=null?s:!1}},[o.viewProps.value,o.open,t.disabled,t.readOnly])}const zn=({props:e,valueManager:t,valueType:o,wrapperVariant:n,additionalViewProps:s,validator:a,autoFocusView:i,rendererInterceptor:c,fieldRef:l})=>{const u=tu({props:e,valueManager:t,valueType:o,wrapperVariant:n,validator:a}),d=ou({props:e,additionalViewProps:s,autoFocusView:i,fieldRef:l,propsFromPickerValue:u.viewProps,rendererInterceptor:c}),p=ru({props:e,wrapperVariant:n,propsFromPickerValue:u.layoutProps,propsFromPickerViews:d.layoutProps}),f=au({props:e,pickerValueResponse:u});return{open:u.open,actions:u.actions,fieldProps:u.fieldProps,renderCurrentView:d.renderCurrentView,hasUIView:d.hasUIView,shouldRestoreFocus:d.shouldRestoreFocus,layoutProps:p.layoutProps,contextValue:u.contextValue,ownerState:f}};function Ws(e){return(0,be.Ay)("MuiPickersLayout",e)}const Oe=(0,ye.A)("MuiPickersLayout",["root","landscape","contentWrapper","toolbar","actionBar","tabs","shortcuts"]);var Et=re(2811),iu=re(9589);const lu=["onAccept","onClear","onCancel","onSetToday","actions"];function zs(e){const{onAccept:t,onClear:o,onCancel:n,onSetToday:s,actions:a}=e,i=(0,ie.A)(e,lu),c=xe();if(a==null||a.length===0)return null;const l=a==null?void 0:a.map(u=>{switch(u){case"clear":return(0,y.jsx)(Et.A,{onClick:o,children:c.clearButtonLabel},u);case"cancel":return(0,y.jsx)(Et.A,{onClick:n,children:c.cancelButtonLabel},u);case"accept":return(0,y.jsx)(Et.A,{onClick:t,children:c.okButtonLabel},u);case"today":return(0,y.jsx)(Et.A,{onClick:s,children:c.todayButtonLabel},u);default:return null}});return(0,y.jsx)(iu.A,(0,m.A)({},i,{children:l}))}var cu=re(6319),uu=re(8677),du=re(9813);const pu=["items","changeImportance","isLandscape","onChange","isValid"],mu=["getValue"];function Us(e){const{items:t,changeImportance:o="accept",onChange:n,isValid:s}=e,a=(0,ie.A)(e,pu);if(t==null||t.length===0)return null;const i=t.map(c=>{let{getValue:l}=c,u=(0,ie.A)(c,mu);const d=l({isValid:s});return(0,m.A)({},u,{label:u.label,onClick:()=>{n(d,o,u)},disabled:!s(d)})});return(0,y.jsx)(cu.A,(0,m.A)({dense:!0,sx:[{maxHeight:Ut,maxWidth:200,overflow:"auto"},...Array.isArray(a.sx)?a.sx:[a.sx]]},a,{children:i.map(c=>{var l;return(0,y.jsx)(uu.Ay,{children:(0,y.jsx)(du.A,(0,m.A)({},c))},(l=c.id)!=null?l:c.label)})}))}function fu(e){return e.view!==null}const hu=e=>{const{classes:t,isLandscape:o}=e,n={root:["root",o&&"landscape"],contentWrapper:["contentWrapper"],toolbar:["toolbar"],actionBar:["actionBar"],tabs:["tabs"],landscape:["landscape"],shortcuts:["shortcuts"]};return(0,he.A)(n,Ws,t)},Un=e=>{var H,_;const{wrapperVariant:t,onAccept:o,onClear:n,onCancel:s,onSetToday:a,view:i,views:c,onViewChange:l,value:u,onChange:d,onSelectShortcut:p,isValid:f,isLandscape:A,disabled:h,readOnly:C,children:g,slots:D,slotProps:v}=e,k=hu(e),P=(H=D==null?void 0:D.actionBar)!=null?H:zs,w=(0,ge.A)({elementType:P,externalSlotProps:v==null?void 0:v.actionBar,additionalProps:{onAccept:o,onClear:n,onCancel:s,onSetToday:a,actions:t==="desktop"?[]:["cancel","accept"]},className:k.actionBar,ownerState:(0,m.A)({},e,{wrapperVariant:t})}),T=(0,y.jsx)(P,(0,m.A)({},w)),M=D==null?void 0:D.toolbar,x=(0,ge.A)({elementType:M,externalSlotProps:v==null?void 0:v.toolbar,additionalProps:{isLandscape:A,onChange:d,value:u,view:i,onViewChange:l,views:c,disabled:h,readOnly:C},className:k.toolbar,ownerState:(0,m.A)({},e,{wrapperVariant:t})}),R=fu(x)&&M?(0,y.jsx)(M,(0,m.A)({},x)):null,V=g,S=D==null?void 0:D.tabs,N=i&&S?(0,y.jsx)(S,(0,m.A)({view:i,onViewChange:l,className:k.tabs},v==null?void 0:v.tabs)):null,j=(_=D==null?void 0:D.shortcuts)!=null?_:Us,F=(0,ge.A)({elementType:j,externalSlotProps:v==null?void 0:v.shortcuts,additionalProps:{isValid:f,isLandscape:A,onChange:p},className:k.shortcuts,ownerState:{isValid:f,isLandscape:A,onChange:p,wrapperVariant:t}}),E=i&&j?(0,y.jsx)(j,(0,m.A)({},F)):null;return{toolbar:R,content:V,tabs:N,actionBar:T,shortcuts:E}},bu=e=>{const{isLandscape:t,classes:o}=e,n={root:["root",t&&"landscape"],contentWrapper:["contentWrapper"]};return(0,he.A)(n,Ws,o)},Yn=(0,W.Ay)("div",{name:"MuiPickersLayout",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"grid",gridAutoColumns:"max-content auto max-content",gridAutoRows:"max-content auto max-content",[`& .${Oe.actionBar}`]:{gridColumn:"1 / 4",gridRow:3},variants:[{props:{isLandscape:!0},style:{[`& .${Oe.toolbar}`]:{gridColumn:1,gridRow:"2 / 3"},[`.${Oe.shortcuts}`]:{gridColumn:"2 / 4",gridRow:1}}},{props:{isLandscape:!0,isRtl:!0},style:{[`& .${Oe.toolbar}`]:{gridColumn:3}}},{props:{isLandscape:!1},style:{[`& .${Oe.toolbar}`]:{gridColumn:"2 / 4",gridRow:1},[`& .${Oe.shortcuts}`]:{gridColumn:1,gridRow:"2 / 3"}}},{props:{isLandscape:!1,isRtl:!0},style:{[`& .${Oe.shortcuts}`]:{gridColumn:3}}}]}),Kn=(0,W.Ay)("div",{name:"MuiPickersLayout",slot:"ContentWrapper",overridesResolver:(e,t)=>t.contentWrapper})({gridColumn:2,gridRow:2,display:"flex",flexDirection:"column"}),sn=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiPickersLayout"}),{toolbar:s,content:a,tabs:i,actionBar:c,shortcuts:l}=Un(n),{sx:u,className:d,isLandscape:p,wrapperVariant:f}=n,A=bu(n);return(0,y.jsxs)(Yn,{ref:o,sx:u,className:(0,fe.A)(A.root,d),ownerState:n,children:[p?l:s,p?s:l,(0,y.jsx)(Kn,{className:A.contentWrapper,children:f==="desktop"?(0,y.jsxs)(b.Fragment,{children:[a,i]}):(0,y.jsxs)(b.Fragment,{children:[i,a]})}),c]})}),Ys=b.createContext(null);function Ks(e){const{contextValue:t,localeText:o,children:n}=e;return(0,y.jsx)(Ys.Provider,{value:t,children:(0,y.jsx)(ln,{localeText:o,children:n})})}const yu=["props","getOpenDialogAriaText"],gu=["ownerState"],Au=["ownerState"],Gn=e=>{var X,$,Q,L,z;let{props:t,getOpenDialogAriaText:o}=e,n=(0,ie.A)(e,yu);const{slots:s,slotProps:a,className:i,sx:c,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:d,selectedSections:p,onSelectedSectionsChange:f,timezone:A,name:h,label:C,inputRef:g,readOnly:D,disabled:v,autoFocus:k,localeText:P,reduceAnimations:w}=t,T=b.useRef(null),M=b.useRef(null),x=(0,it.A)(),R=($=(X=a==null?void 0:a.toolbar)==null?void 0:X.hidden)!=null?$:!1,{open:V,actions:S,hasUIView:N,layoutProps:j,renderCurrentView:F,shouldRestoreFocus:E,fieldProps:H,contextValue:_,ownerState:Z}=zn((0,m.A)({},n,{props:t,fieldRef:M,autoFocusView:!0,additionalViewProps:{},wrapperVariant:"desktop"})),Y=(Q=s.inputAdornment)!=null?Q:us.A,te=(0,ge.A)({elementType:Y,externalSlotProps:a==null?void 0:a.inputAdornment,additionalProps:{position:"end"},ownerState:t}),se=(0,ie.A)(te,gu),le=(L=s.openPickerButton)!=null?L:ct.A,de=(0,ge.A)({elementType:le,externalSlotProps:a==null?void 0:a.openPickerButton,additionalProps:{disabled:v||D,onClick:V?S.onClose:S.onOpen,"aria-label":o(H.value),edge:se.position},ownerState:t}),ce=(0,ie.A)(de,Au),U=s.openPickerIcon,ne=(0,ge.A)({elementType:U,externalSlotProps:a==null?void 0:a.openPickerIcon,ownerState:Z}),G=s.field,O=(0,ge.A)({elementType:G,externalSlotProps:a==null?void 0:a.field,additionalProps:(0,m.A)({},H,R&&{id:x},{readOnly:D,disabled:v,className:i,sx:c,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:d,selectedSections:p,onSelectedSectionsChange:f,timezone:A,label:C,name:h,autoFocus:k&&!t.open,focused:V?!0:void 0},g?{inputRef:g}:{}),ownerState:t});N&&(O.InputProps=(0,m.A)({},O.InputProps,{ref:T},!t.disableOpenPicker&&{[`${se.position}Adornment`]:(0,y.jsx)(Y,(0,m.A)({},se,{children:(0,y.jsx)(le,(0,m.A)({},ce,{children:(0,y.jsx)(U,(0,m.A)({},ne))}))}))}));const B=(0,m.A)({textField:s.textField,clearIcon:s.clearIcon,clearButton:s.clearButton},O.slots),ae=(z=s.layout)!=null?z:sn;let ee=x;R&&(C?ee=`${x}-label`:ee=void 0);const q=(0,m.A)({},a,{toolbar:(0,m.A)({},a==null?void 0:a.toolbar,{titleId:x}),popper:(0,m.A)({"aria-labelledby":ee},a==null?void 0:a.popper)}),I=(0,Se.A)(M,O.unstableFieldRef);return{renderPicker:()=>(0,y.jsxs)(Ks,{contextValue:_,localeText:P,children:[(0,y.jsx)(G,(0,m.A)({},O,{slots:B,slotProps:q,unstableFieldRef:I})),(0,y.jsx)(Zc,(0,m.A)({role:"dialog",placement:"bottom-start",anchorEl:T.current},S,{open:V,slots:s,slotProps:q,shouldRestoreFocus:E,reduceAnimations:w,children:(0,y.jsx)(ae,(0,m.A)({},j,q==null?void 0:q.layout,{slots:s,slotProps:q,children:F()}))}))]})}},De=({view:e,onViewChange:t,views:o,focusedView:n,onFocusedViewChange:s,value:a,defaultValue:i,referenceDate:c,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minDate:A,maxDate:h,shouldDisableDate:C,shouldDisableMonth:g,shouldDisableYear:D,reduceAnimations:v,onMonthChange:k,monthsPerRow:P,onYearChange:w,yearsOrder:T,yearsPerRow:M,slots:x,slotProps:R,loading:V,renderLoading:S,disableHighlightToday:N,readOnly:j,disabled:F,showDaysOutsideCurrentMonth:E,dayOfWeekFormatter:H,sx:_,autoFocus:Z,fixedWeekNumber:Y,displayWeekNumber:te,timezone:se})=>(0,y.jsx)(js,{view:e,onViewChange:t,views:o.filter(mt),focusedView:n&&mt(n)?n:null,onFocusedViewChange:s,value:a,defaultValue:i,referenceDate:c,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minDate:A,maxDate:h,shouldDisableDate:C,shouldDisableMonth:g,shouldDisableYear:D,reduceAnimations:v,onMonthChange:k,monthsPerRow:P,onYearChange:w,yearsOrder:T,yearsPerRow:M,slots:x,slotProps:R,loading:V,renderLoading:S,disableHighlightToday:N,readOnly:j,disabled:F,showDaysOutsideCurrentMonth:E,dayOfWeekFormatter:H,sx:_,autoFocus:Z,fixedWeekNumber:Y,displayWeekNumber:te,timezone:se}),Xn=b.forwardRef(function(t,o){var u,d,p;const n=xe(),s=me(),a=Hn(t,"MuiDesktopDatePicker"),i=(0,m.A)({day:De,month:De,year:De},a.viewRenderers),c=(0,m.A)({},a,{viewRenderers:i,format:Vt(s,a,!1),yearsPerRow:(u=a.yearsPerRow)!=null?u:4,slots:(0,m.A)({openPickerIcon:cn,field:Ln},a.slots),slotProps:(0,m.A)({},a.slotProps,{field:f=>{var A;return(0,m.A)({},(0,rt.A)((A=a.slotProps)==null?void 0:A.field,f),nt(a),{ref:o})},toolbar:(0,m.A)({hidden:!0},(d=a.slotProps)==null?void 0:d.toolbar)})}),{renderPicker:l}=Gn({props:c,valueManager:Ce,valueType:"date",getOpenDialogAriaText:lt({utils:s,formatKey:"fullDate",contextTranslation:n.openDatePickerDialogue,propsTranslation:(p=c.localeText)==null?void 0:p.openDatePickerDialogue}),validator:Ke});return l()});Xn.propTypes={autoFocus:r().bool,className:r().string,closeOnSelect:r().bool,dayOfWeekFormatter:r().func,defaultValue:r().object,disabled:r().bool,disableFuture:r().bool,disableHighlightToday:r().bool,disableOpenPicker:r().bool,disablePast:r().bool,displayWeekNumber:r().bool,enableAccessibleFieldDOMStructure:r().any,fixedWeekNumber:r().number,format:r().string,formatDensity:r().oneOf(["dense","spacious"]),inputRef:xt,label:r().node,loading:r().bool,localeText:r().object,maxDate:r().object,minDate:r().object,monthsPerRow:r().oneOf([3,4]),name:r().string,onAccept:r().func,onChange:r().func,onClose:r().func,onError:r().func,onMonthChange:r().func,onOpen:r().func,onSelectedSectionsChange:r().func,onViewChange:r().func,onYearChange:r().func,open:r().bool,openTo:r().oneOf(["day","month","year"]),orientation:r().oneOf(["landscape","portrait"]),readOnly:r().bool,reduceAnimations:r().bool,referenceDate:r().object,renderLoading:r().func,selectedSections:r().oneOfType([r().oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),r().number]),shouldDisableDate:r().func,shouldDisableMonth:r().func,shouldDisableYear:r().func,showDaysOutsideCurrentMonth:r().bool,slotProps:r().object,slots:r().object,sx:r().oneOfType([r().arrayOf(r().oneOfType([r().func,r().object,r().bool])),r().func,r().object]),timezone:r().string,value:r().object,view:r().oneOf(["day","month","year"]),viewRenderers:r().shape({day:r().func,month:r().func,year:r().func}),views:r().arrayOf(r().oneOf(["day","month","year"]).isRequired),yearsOrder:r().oneOf(["asc","desc"]),yearsPerRow:r().oneOf([3,4])};var Cu=re(3437),vu=re(5747),Gs=re(311);const xu=(0,W.Ay)(vu.A)({[`& .${Gs.A.container}`]:{outline:0},[`& .${Gs.A.paper}`]:{outline:0,minWidth:Tt}}),Du=(0,W.Ay)(Cu.A)({"&:first-of-type":{padding:0}});function ku(e){var l,u;const{children:t,onDismiss:o,open:n,slots:s,slotProps:a}=e,i=(l=s==null?void 0:s.dialog)!=null?l:xu,c=(u=s==null?void 0:s.mobileTransition)!=null?u:nn.A;return(0,y.jsx)(i,(0,m.A)({open:n,onClose:o},a==null?void 0:a.dialog,{TransitionComponent:c,TransitionProps:a==null?void 0:a.mobileTransition,PaperComponent:s==null?void 0:s.mobilePaper,PaperProps:a==null?void 0:a.mobilePaper,children:(0,y.jsx)(Du,{children:t})}))}const Pu=["props","getOpenDialogAriaText"],Qn=e=>{var se,le,de;let{props:t,getOpenDialogAriaText:o}=e,n=(0,ie.A)(e,Pu);const{slots:s,slotProps:a,className:i,sx:c,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:d,selectedSections:p,onSelectedSectionsChange:f,timezone:A,name:h,label:C,inputRef:g,readOnly:D,disabled:v,localeText:k}=t,P=b.useRef(null),w=(0,it.A)(),T=(le=(se=a==null?void 0:a.toolbar)==null?void 0:se.hidden)!=null?le:!1,{open:M,actions:x,layoutProps:R,renderCurrentView:V,fieldProps:S,contextValue:N}=zn((0,m.A)({},n,{props:t,fieldRef:P,autoFocusView:!0,additionalViewProps:{},wrapperVariant:"mobile"})),j=s.field,F=(0,ge.A)({elementType:j,externalSlotProps:a==null?void 0:a.field,additionalProps:(0,m.A)({},S,T&&{id:w},!(v||D)&&{onClick:x.onOpen,onKeyDown:Da(x.onOpen)},{readOnly:D!=null?D:!0,disabled:v,className:i,sx:c,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:d,selectedSections:p,onSelectedSectionsChange:f,timezone:A,label:C,name:h},g?{inputRef:g}:{}),ownerState:t});F.inputProps=(0,m.A)({},F.inputProps,{"aria-label":o(S.value)});const E=(0,m.A)({textField:s.textField},F.slots),H=(de=s.layout)!=null?de:sn;let _=w;T&&(C?_=`${w}-label`:_=void 0);const Z=(0,m.A)({},a,{toolbar:(0,m.A)({},a==null?void 0:a.toolbar,{titleId:w}),mobilePaper:(0,m.A)({"aria-labelledby":_},a==null?void 0:a.mobilePaper)}),Y=(0,Se.A)(P,F.unstableFieldRef);return{renderPicker:()=>(0,y.jsxs)(Ks,{contextValue:N,localeText:k,children:[(0,y.jsx)(j,(0,m.A)({},F,{slots:E,slotProps:Z,unstableFieldRef:Y})),(0,y.jsx)(ku,(0,m.A)({},x,{open:M,slots:s,slotProps:Z,children:(0,y.jsx)(H,(0,m.A)({},R,Z==null?void 0:Z.layout,{slots:s,slotProps:Z,children:V()}))}))]})}},Zn=b.forwardRef(function(t,o){var u,d;const n=xe(),s=me(),a=Hn(t,"MuiMobileDatePicker"),i=(0,m.A)({day:De,month:De,year:De},a.viewRenderers),c=(0,m.A)({},a,{viewRenderers:i,format:Vt(s,a,!1),slots:(0,m.A)({field:Ln},a.slots),slotProps:(0,m.A)({},a.slotProps,{field:p=>{var f;return(0,m.A)({},(0,rt.A)((f=a.slotProps)==null?void 0:f.field,p),nt(a),{ref:o})},toolbar:(0,m.A)({hidden:!1},(u=a.slotProps)==null?void 0:u.toolbar)})}),{renderPicker:l}=Qn({props:c,valueManager:Ce,valueType:"date",getOpenDialogAriaText:lt({utils:s,formatKey:"fullDate",contextTranslation:n.openDatePickerDialogue,propsTranslation:(d=c.localeText)==null?void 0:d.openDatePickerDialogue}),validator:Ke});return l()});Zn.propTypes={autoFocus:r().bool,className:r().string,closeOnSelect:r().bool,dayOfWeekFormatter:r().func,defaultValue:r().object,disabled:r().bool,disableFuture:r().bool,disableHighlightToday:r().bool,disableOpenPicker:r().bool,disablePast:r().bool,displayWeekNumber:r().bool,enableAccessibleFieldDOMStructure:r().any,fixedWeekNumber:r().number,format:r().string,formatDensity:r().oneOf(["dense","spacious"]),inputRef:xt,label:r().node,loading:r().bool,localeText:r().object,maxDate:r().object,minDate:r().object,monthsPerRow:r().oneOf([3,4]),name:r().string,onAccept:r().func,onChange:r().func,onClose:r().func,onError:r().func,onMonthChange:r().func,onOpen:r().func,onSelectedSectionsChange:r().func,onViewChange:r().func,onYearChange:r().func,open:r().bool,openTo:r().oneOf(["day","month","year"]),orientation:r().oneOf(["landscape","portrait"]),readOnly:r().bool,reduceAnimations:r().bool,referenceDate:r().object,renderLoading:r().func,selectedSections:r().oneOfType([r().oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),r().number]),shouldDisableDate:r().func,shouldDisableMonth:r().func,shouldDisableYear:r().func,showDaysOutsideCurrentMonth:r().bool,slotProps:r().object,slots:r().object,sx:r().oneOfType([r().arrayOf(r().oneOfType([r().func,r().object,r().bool])),r().func,r().object]),timezone:r().string,value:r().object,view:r().oneOf(["day","month","year"]),viewRenderers:r().shape({day:r().func,month:r().func,year:r().func}),views:r().arrayOf(r().oneOf(["day","month","year"]).isRequired),yearsOrder:r().oneOf(["asc","desc"]),yearsPerRow:r().oneOf([3,4])};const wu=["desktopModeMediaQuery"],Su=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiDatePicker"}),{desktopModeMediaQuery:s=Qt}=n,a=(0,ie.A)(n,wu);return(0,on.A)(s,{defaultMatches:!0})?(0,y.jsx)(Xn,(0,m.A)({ref:o},a)):(0,y.jsx)(Zn,(0,m.A)({ref:o},a))}),Tu=["props","ref"],Mu=(0,W.Ay)(sn)(({theme:e})=>({overflow:"hidden",minWidth:Tt,backgroundColor:(e.vars||e).palette.background.paper})),Jn=e=>{var C;let{props:t,ref:o}=e,n=(0,ie.A)(e,Tu);const{localeText:s,slots:a,slotProps:i,className:c,sx:l,displayStaticWrapperAs:u,autoFocus:d}=t,{layoutProps:p,renderCurrentView:f}=zn((0,m.A)({},n,{props:t,autoFocusView:d!=null?d:!1,fieldRef:void 0,additionalViewProps:{},wrapperVariant:u})),A=(C=a==null?void 0:a.layout)!=null?C:Mu;return{renderPicker:()=>{var g,D,v;return(0,y.jsx)(ln,{localeText:s,children:(0,y.jsx)(A,(0,m.A)({},p,i==null?void 0:i.layout,{slots:a,slotProps:i,sx:[...Array.isArray(l)?l:[l],...Array.isArray((g=i==null?void 0:i.layout)==null?void 0:g.sx)?i.layout.sx:[(D=i==null?void 0:i.layout)==null?void 0:D.sx]],className:(0,fe.A)(c,(v=i==null?void 0:i.layout)==null?void 0:v.className),ref:o,children:f()}))})}}},Xs=b.forwardRef(function(t,o){var l,u,d;const n=Hn(t,"MuiStaticDatePicker"),s=(l=n.displayStaticWrapperAs)!=null?l:"mobile",a=(0,m.A)({day:De,month:De,year:De},n.viewRenderers),i=(0,m.A)({},n,{viewRenderers:a,displayStaticWrapperAs:s,yearsPerRow:(u=n.yearsPerRow)!=null?u:s==="mobile"?3:4,slotProps:(0,m.A)({},n.slotProps,{toolbar:(0,m.A)({hidden:s==="desktop"},(d=n.slotProps)==null?void 0:d.toolbar)})}),{renderPicker:c}=Jn({props:i,valueManager:Ce,valueType:"date",validator:Ke,ref:o});return c()});Xs.propTypes={autoFocus:r().bool,className:r().string,dayOfWeekFormatter:r().func,defaultValue:r().object,disabled:r().bool,disableFuture:r().bool,disableHighlightToday:r().bool,disablePast:r().bool,displayStaticWrapperAs:r().oneOf(["desktop","mobile"]),displayWeekNumber:r().bool,fixedWeekNumber:r().number,loading:r().bool,localeText:r().object,maxDate:r().object,minDate:r().object,monthsPerRow:r().oneOf([3,4]),onAccept:r().func,onChange:r().func,onClose:r().func,onError:r().func,onMonthChange:r().func,onViewChange:r().func,onYearChange:r().func,openTo:r().oneOf(["day","month","year"]),orientation:r().oneOf(["landscape","portrait"]),readOnly:r().bool,reduceAnimations:r().bool,referenceDate:r().object,renderLoading:r().func,shouldDisableDate:r().func,shouldDisableMonth:r().func,shouldDisableYear:r().func,showDaysOutsideCurrentMonth:r().bool,slotProps:r().object,slots:r().object,sx:r().oneOfType([r().arrayOf(r().oneOfType([r().func,r().object,r().bool])),r().func,r().object]),timezone:r().string,value:r().object,view:r().oneOf(["day","month","year"]),viewRenderers:r().shape({day:r().func,month:r().func,year:r().func}),views:r().arrayOf(r().oneOf(["day","month","year"]).isRequired),yearsOrder:r().oneOf(["asc","desc"]),yearsPerRow:r().oneOf([3,4])};function Iu(e){return(0,be.Ay)("MuiPickersToolbarText",e)}const qn=(0,ye.A)("MuiPickersToolbarText",["root","selected"]),Ru=["className","selected","value"],Vu=e=>{const{classes:t,selected:o}=e,n={root:["root",o&&"selected"]};return(0,he.A)(n,Iu,t)},Fu=(0,W.Ay)(ze.A,{name:"MuiPickersToolbarText",slot:"Root",overridesResolver:(e,t)=>[t.root,{[`&.${qn.selected}`]:t.selected}]})(({theme:e})=>({transition:e.transitions.create("color"),color:(e.vars||e).palette.text.secondary,[`&.${qn.selected}`]:{color:(e.vars||e).palette.text.primary}})),_n=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiPickersToolbarText"}),{className:s,value:a}=n,i=(0,ie.A)(n,Ru),c=Vu(n);return(0,y.jsx)(Fu,(0,m.A)({ref:o,className:(0,fe.A)(c.root,s),component:"span"},i,{children:a}))}),Ou=["align","className","selected","typographyClassName","value","variant","width"],Lu=e=>{const{classes:t}=e,o={root:["root"]};return(0,he.A)(o,Bs,t)},Nu=(0,W.Ay)(Et.A,{name:"MuiPickersToolbarButton",slot:"Root",overridesResolver:(e,t)=>t.root})({padding:0,minWidth:16,textTransform:"none"}),Ie=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiPickersToolbarButton"}),{align:s,className:a,selected:i,typographyClassName:c,value:l,variant:u,width:d}=n,p=(0,ie.A)(n,Ou),f=Lu(n);return(0,y.jsx)(Nu,(0,m.A)({variant:"text",ref:o,className:(0,fe.A)(f.root,a)},d?{sx:{width:d}}:{},p,{children:(0,y.jsx)(_n,{align:s,className:c,variant:u,value:l,selected:i})}))});function ju(e){return(0,be.Ay)("MuiTimePickerToolbar",e)}const Dt=(0,ye.A)("MuiTimePickerToolbar",["root","separator","hourMinuteLabel","hourMinuteLabelLandscape","hourMinuteLabelReverse","ampmSelection","ampmLandscape","ampmLabel"]),Eu=["ampm","ampmInClock","value","isLandscape","onChange","view","onViewChange","views","disabled","readOnly","className"],Bu=e=>{const{isLandscape:t,classes:o,isRtl:n}=e,s={root:["root"],separator:["separator"],hourMinuteLabel:["hourMinuteLabel",t&&"hourMinuteLabelLandscape",n&&"hourMinuteLabelReverse"],ampmSelection:["ampmSelection",t&&"ampmLandscape"],ampmLabel:["ampmLabel"]};return(0,he.A)(s,ju,o)},$u=(0,W.Ay)($n,{name:"MuiTimePickerToolbar",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Hu=(0,W.Ay)(_n,{name:"MuiTimePickerToolbar",slot:"Separator",overridesResolver:(e,t)=>t.separator})({outline:0,margin:"0 4px 0 2px",cursor:"default"}),Wu=(0,W.Ay)("div",{name:"MuiTimePickerToolbar",slot:"HourMinuteLabel",overridesResolver:(e,t)=>[{[`&.${Dt.hourMinuteLabelLandscape}`]:t.hourMinuteLabelLandscape,[`&.${Dt.hourMinuteLabelReverse}`]:t.hourMinuteLabelReverse},t.hourMinuteLabel]})({display:"flex",justifyContent:"flex-end",alignItems:"flex-end",variants:[{props:{isRtl:!0},style:{flexDirection:"row-reverse"}},{props:{isLandscape:!0},style:{marginTop:"auto"}}]}),zu=(0,W.Ay)("div",{name:"MuiTimePickerToolbar",slot:"AmPmSelection",overridesResolver:(e,t)=>[{[`.${Dt.ampmLabel}`]:t.ampmLabel},{[`&.${Dt.ampmLandscape}`]:t.ampmLandscape},t.ampmSelection]})({display:"flex",flexDirection:"column",marginRight:"auto",marginLeft:12,[`& .${Dt.ampmLabel}`]:{fontSize:17},variants:[{props:{isLandscape:!0},style:{margin:"4px 0 auto",flexDirection:"row",justifyContent:"space-around",flexBasis:"100%"}}]});function Qs(e){const t=(0,pe.A)({props:e,name:"MuiTimePickerToolbar"}),{ampm:o,ampmInClock:n,value:s,isLandscape:a,onChange:i,view:c,onViewChange:l,views:u,disabled:d,readOnly:p,className:f}=t,A=(0,ie.A)(t,Eu),h=me(),C=xe(),g=(0,we.I)(),D=!!(o&&!n&&u.includes("hours")),{meridiemMode:v,handleMeridiemChange:k}=zt(s,o,i),P=x=>o?h.format(x,"hours12h"):h.format(x,"hours24h"),w=(0,m.A)({},t,{isRtl:g}),T=Bu(w),M=(0,y.jsx)(Hu,{tabIndex:-1,value:":",variant:"h3",selected:!1,className:T.separator});return(0,y.jsxs)($u,(0,m.A)({landscapeDirection:"row",toolbarTitle:C.timePickerToolbarTitle,isLandscape:a,ownerState:w,className:(0,fe.A)(T.root,f)},A,{children:[(0,y.jsxs)(Wu,{className:T.hourMinuteLabel,ownerState:w,children:[ht(u,"hours")&&(0,y.jsx)(Ie,{tabIndex:-1,variant:"h3",onClick:()=>l("hours"),selected:c==="hours",value:s?P(s):"--"}),ht(u,["hours","minutes"])&&M,ht(u,"minutes")&&(0,y.jsx)(Ie,{tabIndex:-1,variant:"h3",onClick:()=>l("minutes"),selected:c==="minutes",value:s?h.format(s,"minutes"):"--"}),ht(u,["minutes","seconds"])&&M,ht(u,"seconds")&&(0,y.jsx)(Ie,{variant:"h3",onClick:()=>l("seconds"),selected:c==="seconds",value:s?h.format(s,"seconds"):"--"})]}),D&&(0,y.jsxs)(zu,{className:T.ampmSelection,ownerState:w,children:[(0,y.jsx)(Ie,{disableRipple:!0,variant:"subtitle2",selected:v==="am",typographyClassName:T.ampmLabel,value:Ne(h,"am"),onClick:p?void 0:()=>k("am"),disabled:d}),(0,y.jsx)(Ie,{disableRipple:!0,variant:"subtitle2",selected:v==="pm",typographyClassName:T.ampmLabel,value:Ne(h,"pm"),onClick:p?void 0:()=>k("pm"),disabled:d})]})]}))}function eo(e,t){var i,c,l,u;const o=me(),n=(0,pe.A)({props:e,name:t}),s=(i=n.ampm)!=null?i:o.is12HourCycleInCurrentLocale(),a=b.useMemo(()=>{var d;return((d=n.localeText)==null?void 0:d.toolbarTitle)==null?n.localeText:(0,m.A)({},n.localeText,{timePickerToolbarTitle:n.localeText.toolbarTitle})},[n.localeText]);return(0,m.A)({},n,{ampm:s,localeText:a},un({views:n.views,openTo:n.openTo,defaultViews:["hours","minutes"],defaultOpenTo:"hours"}),{disableFuture:(c=n.disableFuture)!=null?c:!1,disablePast:(l=n.disablePast)!=null?l:!1,slots:(0,m.A)({toolbar:Qs},n.slots),slotProps:(0,m.A)({},n.slotProps,{toolbar:(0,m.A)({ampm:s,ampmInClock:n.ampmInClock},(u=n.slotProps)==null?void 0:u.toolbar)})})}const Re=({view:e,onViewChange:t,focusedView:o,onFocusedViewChange:n,views:s,value:a,defaultValue:i,referenceDate:c,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minTime:A,maxTime:h,shouldDisableTime:C,minutesStep:g,ampm:D,ampmInClock:v,slots:k,slotProps:P,readOnly:w,disabled:T,sx:M,autoFocus:x,showViewSwitcher:R,disableIgnoringDatePartForTimeValidation:V,timezone:S})=>(0,y.jsx)(Xo,{view:e,onViewChange:t,focusedView:o&&ut(o)?o:null,onFocusedViewChange:n,views:s.filter(ut),value:a,defaultValue:i,referenceDate:c,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minTime:A,maxTime:h,shouldDisableTime:C,minutesStep:g,ampm:D,ampmInClock:v,slots:k,slotProps:P,readOnly:w,disabled:T,sx:M,autoFocus:x,showViewSwitcher:R,disableIgnoringDatePartForTimeValidation:V,timezone:S}),to=({view:e,onViewChange:t,focusedView:o,onFocusedViewChange:n,views:s,value:a,defaultValue:i,referenceDate:c,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minTime:A,maxTime:h,shouldDisableTime:C,minutesStep:g,ampm:D,slots:v,slotProps:k,readOnly:P,disabled:w,sx:T,autoFocus:M,disableIgnoringDatePartForTimeValidation:x,timeSteps:R,skipDisabled:V,timezone:S})=>(0,y.jsx)(_o,{view:e,onViewChange:t,focusedView:o,onFocusedViewChange:n,views:s.filter(ut),value:a,defaultValue:i,referenceDate:c,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minTime:A,maxTime:h,shouldDisableTime:C,minutesStep:g,ampm:D,slots:v,slotProps:k,readOnly:P,disabled:w,sx:T,autoFocus:M,disableIgnoringDatePartForTimeValidation:x,timeStep:R==null?void 0:R.minutes,skipDisabled:V,timezone:S}),Bt=({view:e,onViewChange:t,focusedView:o,onFocusedViewChange:n,views:s,value:a,defaultValue:i,referenceDate:c,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minTime:A,maxTime:h,shouldDisableTime:C,minutesStep:g,ampm:D,slots:v,slotProps:k,readOnly:P,disabled:w,sx:T,autoFocus:M,disableIgnoringDatePartForTimeValidation:x,timeSteps:R,skipDisabled:V,timezone:S})=>(0,y.jsx)(os,{view:e,onViewChange:t,focusedView:o,onFocusedViewChange:n,views:s.filter(ut),value:a,defaultValue:i,referenceDate:c,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minTime:A,maxTime:h,shouldDisableTime:C,minutesStep:g,ampm:D,slots:v,slotProps:k,readOnly:P,disabled:w,sx:T,autoFocus:M,disableIgnoringDatePartForTimeValidation:x,timeSteps:R,skipDisabled:V,timezone:S}),Uu=["views","format"],Zs=(e,t,o)=>{let{views:n,format:s}=t,a=(0,ie.A)(t,Uu);if(s)return s;const i=[],c=[];if(n.forEach(d=>{ut(d)?c.push(d):mt(d)&&i.push(d)}),c.length===0)return Vt(e,(0,m.A)({views:i},a),!1);if(i.length===0)return Wt(e,(0,m.A)({views:c},a));const l=Wt(e,(0,m.A)({views:c},a));return`${o?e.formats.keyboardDate:Vt(e,(0,m.A)({views:i},a),!1)} ${l}`},Yu=(e,t,o)=>o?t.filter(n=>!kt(n)||n==="hours"):e?[...t,"meridiem"]:t,Ku=(e,t)=>{var o,n;return 24*60/(((o=e.hours)!=null?o:1)*((n=e.minutes)!=null?n:5))<=t};function Js({thresholdToRenderTimeInASingleColumn:e,ampm:t,timeSteps:o,views:n}){const s=e!=null?e:24,a=(0,m.A)({hours:1,minutes:5,seconds:5},o),i=Ku(a,s);return{thresholdToRenderTimeInASingleColumn:s,timeSteps:a,shouldRenderTimeInASingleColumn:i,views:Yu(t,n,i)}}const no=b.forwardRef(function(t,o){var D,v,k,P,w;const n=xe(),s=me(),a=eo(t,"MuiDesktopTimePicker"),{shouldRenderTimeInASingleColumn:i,views:c,timeSteps:l}=Js(a),u=i?to:Bt,d=(0,m.A)({hours:u,minutes:u,seconds:u,meridiem:u},a.viewRenderers),p=(D=a.ampmInClock)!=null?D:!0,f=i?[]:["accept"],h=((v=d.hours)==null?void 0:v.name)===Bt.name?c:c.filter(T=>T!=="meridiem"),C=(0,m.A)({},a,{ampmInClock:p,timeSteps:l,viewRenderers:d,format:Wt(s,a),views:i?["hours"]:h,slots:(0,m.A)({field:Nn,openPickerIcon:Ao},a.slots),slotProps:(0,m.A)({},a.slotProps,{field:T=>{var M;return(0,m.A)({},(0,rt.A)((M=a.slotProps)==null?void 0:M.field,T),nt(a),{ref:o})},toolbar:(0,m.A)({hidden:!0,ampmInClock:p},(k=a.slotProps)==null?void 0:k.toolbar),actionBar:(0,m.A)({actions:f},(P=a.slotProps)==null?void 0:P.actionBar)})}),{renderPicker:g}=Gn({props:C,valueManager:Ce,valueType:"time",getOpenDialogAriaText:lt({utils:s,formatKey:"fullTime",contextTranslation:n.openTimePickerDialogue,propsTranslation:(w=C.localeText)==null?void 0:w.openTimePickerDialogue}),validator:st});return g()});no.propTypes={ampm:r().bool,ampmInClock:r().bool,autoFocus:r().bool,className:r().string,closeOnSelect:r().bool,defaultValue:r().object,disabled:r().bool,disableFuture:r().bool,disableIgnoringDatePartForTimeValidation:r().bool,disableOpenPicker:r().bool,disablePast:r().bool,enableAccessibleFieldDOMStructure:r().any,format:r().string,formatDensity:r().oneOf(["dense","spacious"]),inputRef:xt,label:r().node,localeText:r().object,maxTime:r().object,minTime:r().object,minutesStep:r().number,name:r().string,onAccept:r().func,onChange:r().func,onClose:r().func,onError:r().func,onOpen:r().func,onSelectedSectionsChange:r().func,onViewChange:r().func,open:r().bool,openTo:r().oneOf(["hours","meridiem","minutes","seconds"]),orientation:r().oneOf(["landscape","portrait"]),readOnly:r().bool,reduceAnimations:r().bool,referenceDate:r().object,selectedSections:r().oneOfType([r().oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),r().number]),shouldDisableTime:r().func,skipDisabled:r().bool,slotProps:r().object,slots:r().object,sx:r().oneOfType([r().arrayOf(r().oneOfType([r().func,r().object,r().bool])),r().func,r().object]),thresholdToRenderTimeInASingleColumn:r().number,timeSteps:r().shape({hours:r().number,minutes:r().number,seconds:r().number}),timezone:r().string,value:r().object,view:r().oneOf(["hours","meridiem","minutes","seconds"]),viewRenderers:r().shape({hours:r().func,meridiem:r().func,minutes:r().func,seconds:r().func}),views:r().arrayOf(r().oneOf(["hours","minutes","seconds"]).isRequired)};const oo=b.forwardRef(function(t,o){var d,p,f;const n=xe(),s=me(),a=eo(t,"MuiMobileTimePicker"),i=(0,m.A)({hours:Re,minutes:Re,seconds:Re},a.viewRenderers),c=(d=a.ampmInClock)!=null?d:!1,l=(0,m.A)({},a,{ampmInClock:c,viewRenderers:i,format:Wt(s,a),slots:(0,m.A)({field:Nn},a.slots),slotProps:(0,m.A)({},a.slotProps,{field:A=>{var h;return(0,m.A)({},(0,rt.A)((h=a.slotProps)==null?void 0:h.field,A),nt(a),{ref:o})},toolbar:(0,m.A)({hidden:!1,ampmInClock:c},(p=a.slotProps)==null?void 0:p.toolbar)})}),{renderPicker:u}=Qn({props:l,valueManager:Ce,valueType:"time",getOpenDialogAriaText:lt({utils:s,formatKey:"fullTime",contextTranslation:n.openTimePickerDialogue,propsTranslation:(f=l.localeText)==null?void 0:f.openTimePickerDialogue}),validator:st});return u()});oo.propTypes={ampm:r().bool,ampmInClock:r().bool,autoFocus:r().bool,className:r().string,closeOnSelect:r().bool,defaultValue:r().object,disabled:r().bool,disableFuture:r().bool,disableIgnoringDatePartForTimeValidation:r().bool,disableOpenPicker:r().bool,disablePast:r().bool,enableAccessibleFieldDOMStructure:r().any,format:r().string,formatDensity:r().oneOf(["dense","spacious"]),inputRef:xt,label:r().node,localeText:r().object,maxTime:r().object,minTime:r().object,minutesStep:r().number,name:r().string,onAccept:r().func,onChange:r().func,onClose:r().func,onError:r().func,onOpen:r().func,onSelectedSectionsChange:r().func,onViewChange:r().func,open:r().bool,openTo:r().oneOf(["hours","minutes","seconds"]),orientation:r().oneOf(["landscape","portrait"]),readOnly:r().bool,reduceAnimations:r().bool,referenceDate:r().object,selectedSections:r().oneOfType([r().oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),r().number]),shouldDisableTime:r().func,slotProps:r().object,slots:r().object,sx:r().oneOfType([r().arrayOf(r().oneOfType([r().func,r().object,r().bool])),r().func,r().object]),timezone:r().string,value:r().object,view:r().oneOf(["hours","minutes","seconds"]),viewRenderers:r().shape({hours:r().func,minutes:r().func,seconds:r().func}),views:r().arrayOf(r().oneOf(["hours","minutes","seconds"]).isRequired)};const Gu=["desktopModeMediaQuery"],Xu=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiTimePicker"}),{desktopModeMediaQuery:s=Qt}=n,a=(0,ie.A)(n,Gu);return(0,on.A)(s,{defaultMatches:!0})?(0,y.jsx)(no,(0,m.A)({ref:o},a)):(0,y.jsx)(oo,(0,m.A)({ref:o},a))}),qs=b.forwardRef(function(t,o){var u,d,p;const n=eo(t,"MuiStaticTimePicker"),s=(u=n.displayStaticWrapperAs)!=null?u:"mobile",a=(d=n.ampmInClock)!=null?d:s==="desktop",i=(0,m.A)({hours:Re,minutes:Re,seconds:Re},n.viewRenderers),c=(0,m.A)({},n,{viewRenderers:i,displayStaticWrapperAs:s,ampmInClock:a,slotProps:(0,m.A)({},n.slotProps,{toolbar:(0,m.A)({hidden:s==="desktop",ampmInClock:a},(p=n.slotProps)==null?void 0:p.toolbar)})}),{renderPicker:l}=Jn({props:c,valueManager:Ce,valueType:"time",validator:st,ref:o});return l()});qs.propTypes={ampm:r().bool,ampmInClock:r().bool,autoFocus:r().bool,className:r().string,defaultValue:r().object,disabled:r().bool,disableFuture:r().bool,disableIgnoringDatePartForTimeValidation:r().bool,disablePast:r().bool,displayStaticWrapperAs:r().oneOf(["desktop","mobile"]),localeText:r().object,maxTime:r().object,minTime:r().object,minutesStep:r().number,onAccept:r().func,onChange:r().func,onClose:r().func,onError:r().func,onViewChange:r().func,openTo:r().oneOf(["hours","minutes","seconds"]),orientation:r().oneOf(["landscape","portrait"]),readOnly:r().bool,reduceAnimations:r().bool,referenceDate:r().object,shouldDisableTime:r().func,slotProps:r().object,slots:r().object,sx:r().oneOfType([r().arrayOf(r().oneOfType([r().func,r().object,r().bool])),r().func,r().object]),timezone:r().string,value:r().object,view:r().oneOf(["hours","minutes","seconds"]),viewRenderers:r().shape({hours:r().func,minutes:r().func,seconds:r().func}),views:r().arrayOf(r().oneOf(["hours","minutes","seconds"]).isRequired)};var _s=re(725),er=re(9877),Qu=re(7198),Zu=re(28);function Ju(e){return(0,be.Ay)("MuiDateTimePickerTabs",e)}const qu=(0,ye.A)("MuiDateTimePickerTabs",["root"]),_u=e=>mt(e)?"date":"time",ed=e=>e==="date"?"day":"hours",td=e=>{const{classes:t}=e,o={root:["root"]};return(0,he.A)(o,Ju,t)},nd=(0,W.Ay)(Qu.A,{name:"MuiDateTimePickerTabs",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({boxShadow:`0 -1px 0 0 inset ${(e.vars||e).palette.divider}`,"&:last-child":{boxShadow:`0 1px 0 0 inset ${(e.vars||e).palette.divider}`,[`& .${Zu.A.indicator}`]:{bottom:"auto",top:0}}})),tr=function(t){const o=(0,pe.A)({props:t,name:"MuiDateTimePickerTabs"}),{dateIcon:n=(0,y.jsx)(Co,{}),onViewChange:s,timeIcon:a=(0,y.jsx)(vo,{}),view:i,hidden:c=typeof window=="undefined"||window.innerHeight<667,className:l,sx:u}=o,d=xe(),p=td(o),f=(A,h)=>{s(ed(h))};return c?null:(0,y.jsxs)(nd,{ownerState:o,variant:"fullWidth",value:_u(i),onChange:f,className:(0,fe.A)(l,p.root),sx:u,children:[(0,y.jsx)(er.A,{value:"date","aria-label":d.dateTableLabel,icon:(0,y.jsx)(b.Fragment,{children:n})}),(0,y.jsx)(er.A,{value:"time","aria-label":d.timeTableLabel,icon:(0,y.jsx)(b.Fragment,{children:a})})]})};function od(e){return(0,be.Ay)("MuiDateTimePickerToolbar",e)}const rn=(0,ye.A)("MuiDateTimePickerToolbar",["root","dateContainer","timeContainer","timeDigitsContainer","separator","timeLabelReverse","ampmSelection","ampmLandscape","ampmLabel"]),sd=["ampm","ampmInClock","value","onChange","view","isLandscape","onViewChange","toolbarFormat","toolbarPlaceholder","views","disabled","readOnly","toolbarVariant","toolbarTitle","className"],rd=e=>{const{classes:t,isLandscape:o,isRtl:n}=e,s={root:["root"],dateContainer:["dateContainer"],timeContainer:["timeContainer",n&&"timeLabelReverse"],timeDigitsContainer:["timeDigitsContainer",n&&"timeLabelReverse"],separator:["separator"],ampmSelection:["ampmSelection",o&&"ampmLandscape"],ampmLabel:["ampmLabel"]};return(0,he.A)(s,od,t)},ad=(0,W.Ay)($n,{name:"MuiDateTimePickerToolbar",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({paddingLeft:16,paddingRight:16,justifyContent:"space-around",position:"relative",variants:[{props:{toolbarVariant:"desktop"},style:{borderBottom:`1px solid ${(e.vars||e).palette.divider}`,[`& .${Sc.content} .${qn.selected}`]:{color:(e.vars||e).palette.primary.main,fontWeight:e.typography.fontWeightBold}}},{props:{toolbarVariant:"desktop",isLandscape:!0},style:{borderRight:`1px solid ${(e.vars||e).palette.divider}`}},{props:{toolbarVariant:"desktop",isLandscape:!1},style:{paddingLeft:24,paddingRight:0}}]})),id=(0,W.Ay)("div",{name:"MuiDateTimePickerToolbar",slot:"DateContainer",overridesResolver:(e,t)=>t.dateContainer})({display:"flex",flexDirection:"column",alignItems:"flex-start"}),ld=(0,W.Ay)("div",{name:"MuiDateTimePickerToolbar",slot:"TimeContainer",overridesResolver:(e,t)=>t.timeContainer})({display:"flex",flexDirection:"row",variants:[{props:{isRtl:!0},style:{flexDirection:"row-reverse"}},{props:{toolbarVariant:"desktop",isLandscape:!1},style:{gap:9,marginRight:4,alignSelf:"flex-end"}},{props:({isLandscape:e,toolbarVariant:t})=>e&&t!=="desktop",style:{flexDirection:"column"}},{props:({isLandscape:e,toolbarVariant:t,isRtl:o})=>e&&t!=="desktop"&&o,style:{flexDirection:"column-reverse"}}]}),cd=(0,W.Ay)("div",{name:"MuiDateTimePickerToolbar",slot:"TimeDigitsContainer",overridesResolver:(e,t)=>t.timeDigitsContainer})({display:"flex",variants:[{props:{isRtl:!0},style:{flexDirection:"row-reverse"}},{props:{toolbarVariant:"desktop"},style:{gap:1.5}}]}),nr=(0,W.Ay)(_n,{name:"MuiDateTimePickerToolbar",slot:"Separator",overridesResolver:(e,t)=>t.separator})({margin:"0 4px 0 2px",cursor:"default",variants:[{props:{toolbarVariant:"desktop"},style:{margin:0}}]}),ud=(0,W.Ay)("div",{name:"MuiDateTimePickerToolbar",slot:"AmPmSelection",overridesResolver:(e,t)=>[{[`.${rn.ampmLabel}`]:t.ampmLabel},{[`&.${rn.ampmLandscape}`]:t.ampmLandscape},t.ampmSelection]})({display:"flex",flexDirection:"column",marginRight:"auto",marginLeft:12,[`& .${rn.ampmLabel}`]:{fontSize:17},variants:[{props:{isLandscape:!0},style:{margin:"4px 0 auto",flexDirection:"row",justifyContent:"space-around",width:"100%"}}]});function or(e){const t=(0,pe.A)({props:e,name:"MuiDateTimePickerToolbar"}),{ampm:o,ampmInClock:n,value:s,onChange:a,view:i,isLandscape:c,onViewChange:l,toolbarFormat:u,toolbarPlaceholder:d="\u2013\u2013",views:p,disabled:f,readOnly:A,toolbarVariant:h="mobile",toolbarTitle:C,className:g}=t,D=(0,ie.A)(t,sd),v=(0,we.I)(),k=(0,m.A)({},t,{isRtl:v}),P=me(),{meridiemMode:w,handleMeridiemChange:T}=zt(s,o,a),M=!!(o&&!n),x=h==="desktop",R=xe(),V=rd(k),S=C!=null?C:R.dateTimePickerToolbarTitle,N=F=>o?P.format(F,"hours12h"):P.format(F,"hours24h"),j=b.useMemo(()=>s?u?P.formatByString(s,u):P.format(s,"shortDate"):d,[s,u,d,P]);return(0,y.jsxs)(ad,(0,m.A)({isLandscape:c,className:(0,fe.A)(V.root,g),toolbarTitle:S},D,{ownerState:k,children:[(0,y.jsxs)(id,{className:V.dateContainer,ownerState:k,children:[p.includes("year")&&(0,y.jsx)(Ie,{tabIndex:-1,variant:"subtitle1",onClick:()=>l("year"),selected:i==="year",value:s?P.format(s,"year"):"\u2013"}),p.includes("day")&&(0,y.jsx)(Ie,{tabIndex:-1,variant:x?"h5":"h4",onClick:()=>l("day"),selected:i==="day",value:j})]}),(0,y.jsxs)(ld,{className:V.timeContainer,ownerState:k,children:[(0,y.jsxs)(cd,{className:V.timeDigitsContainer,ownerState:k,children:[p.includes("hours")&&(0,y.jsxs)(b.Fragment,{children:[(0,y.jsx)(Ie,{variant:x?"h5":"h3",width:x&&!c?Mt:void 0,onClick:()=>l("hours"),selected:i==="hours",value:s?N(s):"--"}),(0,y.jsx)(nr,{variant:x?"h5":"h3",value:":",className:V.separator,ownerState:k}),(0,y.jsx)(Ie,{variant:x?"h5":"h3",width:x&&!c?Mt:void 0,onClick:()=>l("minutes"),selected:i==="minutes"||!p.includes("minutes")&&i==="hours",value:s?P.format(s,"minutes"):"--",disabled:!p.includes("minutes")})]}),p.includes("seconds")&&(0,y.jsxs)(b.Fragment,{children:[(0,y.jsx)(nr,{variant:x?"h5":"h3",value:":",className:V.separator,ownerState:k}),(0,y.jsx)(Ie,{variant:x?"h5":"h3",width:x&&!c?Mt:void 0,onClick:()=>l("seconds"),selected:i==="seconds",value:s?P.format(s,"seconds"):"--"})]})]}),M&&!x&&(0,y.jsxs)(ud,{className:V.ampmSelection,ownerState:k,children:[(0,y.jsx)(Ie,{variant:"subtitle2",selected:w==="am",typographyClassName:V.ampmLabel,value:Ne(P,"am"),onClick:A?void 0:()=>T("am"),disabled:f}),(0,y.jsx)(Ie,{variant:"subtitle2",selected:w==="pm",typographyClassName:V.ampmLabel,value:Ne(P,"pm"),onClick:A?void 0:()=>T("pm"),disabled:f})]}),o&&x&&(0,y.jsx)(Ie,{variant:"h5",onClick:()=>l("meridiem"),selected:i==="meridiem",value:s&&w?Ne(P,w):"--",width:Mt})]})]}))}function so(e,t){var c,l,u,d,p,f,A,h,C,g;const o=me(),n=Je(),s=(0,pe.A)({props:e,name:t}),a=(c=s.ampm)!=null?c:o.is12HourCycleInCurrentLocale(),i=b.useMemo(()=>{var D;return((D=s.localeText)==null?void 0:D.toolbarTitle)==null?s.localeText:(0,m.A)({},s.localeText,{dateTimePickerToolbarTitle:s.localeText.toolbarTitle})},[s.localeText]);return(0,m.A)({},s,un({views:s.views,openTo:s.openTo,defaultViews:["year","day","hours","minutes"],defaultOpenTo:"day"}),{ampm:a,localeText:i,orientation:(l=s.orientation)!=null?l:"portrait",disableIgnoringDatePartForTimeValidation:(u=s.disableIgnoringDatePartForTimeValidation)!=null?u:!!(s.minDateTime||s.maxDateTime||s.disablePast||s.disableFuture),disableFuture:(d=s.disableFuture)!=null?d:!1,disablePast:(p=s.disablePast)!=null?p:!1,minDate:Pe(o,(f=s.minDateTime)!=null?f:s.minDate,n.minDate),maxDate:Pe(o,(A=s.maxDateTime)!=null?A:s.maxDate,n.maxDate),minTime:(h=s.minDateTime)!=null?h:s.minTime,maxTime:(C=s.maxDateTime)!=null?C:s.maxTime,slots:(0,m.A)({toolbar:or,tabs:tr},s.slots),slotProps:(0,m.A)({},s.slotProps,{toolbar:(0,m.A)({ampm:a},(g=s.slotProps)==null?void 0:g.toolbar)})})}const sr=b.forwardRef(function(t,o){var C,g;const n=(0,we.I)(),{toolbar:s,tabs:a,content:i,actionBar:c,shortcuts:l}=Un(t),{sx:u,className:d,isLandscape:p,classes:f}=t,A=c&&((g=(C=c.props.actions)==null?void 0:C.length)!=null?g:0)>0,h=(0,m.A)({},t,{isRtl:n});return(0,y.jsxs)(Yn,{ref:o,className:(0,fe.A)(Oe.root,f==null?void 0:f.root,d),sx:[{[`& .${Oe.tabs}`]:{gridRow:4,gridColumn:"1 / 4"},[`& .${Oe.actionBar}`]:{gridRow:5}},...Array.isArray(u)?u:[u]],ownerState:h,children:[p?l:s,p?s:l,(0,y.jsxs)(Kn,{className:(0,fe.A)(Oe.contentWrapper,f==null?void 0:f.contentWrapper),sx:{display:"grid"},children:[i,a,A&&(0,y.jsx)(_s.A,{sx:{gridRow:3,gridColumn:"1 / 4"}})]}),c]})}),dd=["openTo","focusedView","timeViewsCount"],pd=function(t,o,n){var d,p;const{openTo:s,focusedView:a,timeViewsCount:i}=n,c=(0,ie.A)(n,dd),l=(0,m.A)({},c,{focusedView:null,sx:[{[`&.${An.root}`]:{borderBottom:0},[`&.${An.root}, .${ts.root}, &.${qo.root}`]:{maxHeight:Ut}}]}),u=kt(o);return(0,y.jsxs)(b.Fragment,{children:[(d=t[u?"day":o])==null?void 0:d.call(t,(0,m.A)({},n,{view:u?"day":o,focusedView:a&&mt(a)?a:null,views:n.views.filter(mt),sx:[{gridColumn:1},...l.sx]})),i>0&&(0,y.jsxs)(b.Fragment,{children:[(0,y.jsx)(_s.A,{orientation:"vertical",sx:{gridColumn:2}}),(p=t[u?o:"hours"])==null?void 0:p.call(t,(0,m.A)({},l,{view:u?o:"hours",focusedView:a&&kt(a)?a:null,openTo:kt(s)?s:"hours",views:n.views.filter(kt),sx:[{gridColumn:3},...l.sx]}))]})]})},ro=b.forwardRef(function(t,o){var v,k,P,w,T,M;const n=xe(),s=me(),a=so(t,"MuiDesktopDateTimePicker"),{shouldRenderTimeInASingleColumn:i,thresholdToRenderTimeInASingleColumn:c,views:l,timeSteps:u}=Js(a),d=i?to:Bt,p=(0,m.A)({day:De,month:De,year:De,hours:d,minutes:d,seconds:d,meridiem:d},a.viewRenderers),f=(v=a.ampmInClock)!=null?v:!0,h=((k=p.hours)==null?void 0:k.name)===Bt.name?l:l.filter(x=>x!=="meridiem"),C=i?[]:["accept"],g=(0,m.A)({},a,{viewRenderers:p,format:Zs(s,a),views:h,yearsPerRow:(P=a.yearsPerRow)!=null?P:4,ampmInClock:f,timeSteps:u,thresholdToRenderTimeInASingleColumn:c,shouldRenderTimeInASingleColumn:i,slots:(0,m.A)({field:jn,layout:sr,openPickerIcon:cn},a.slots),slotProps:(0,m.A)({},a.slotProps,{field:x=>{var R;return(0,m.A)({},(0,rt.A)((R=a.slotProps)==null?void 0:R.field,x),nt(a),{ref:o})},toolbar:(0,m.A)({hidden:!0,ampmInClock:f,toolbarVariant:"desktop"},(w=a.slotProps)==null?void 0:w.toolbar),tabs:(0,m.A)({hidden:!0},(T=a.slotProps)==null?void 0:T.tabs),actionBar:x=>{var R;return(0,m.A)({actions:C},(0,rt.A)((R=a.slotProps)==null?void 0:R.actionBar,x))}})}),{renderPicker:D}=Gn({props:g,valueManager:Ce,valueType:"date-time",getOpenDialogAriaText:lt({utils:s,formatKey:"fullDate",contextTranslation:n.openDatePickerDialogue,propsTranslation:(M=g.localeText)==null?void 0:M.openDatePickerDialogue}),validator:Ct,rendererInterceptor:pd});return D()});ro.propTypes={ampm:r().bool,ampmInClock:r().bool,autoFocus:r().bool,className:r().string,closeOnSelect:r().bool,dayOfWeekFormatter:r().func,defaultValue:r().object,disabled:r().bool,disableFuture:r().bool,disableHighlightToday:r().bool,disableIgnoringDatePartForTimeValidation:r().bool,disableOpenPicker:r().bool,disablePast:r().bool,displayWeekNumber:r().bool,enableAccessibleFieldDOMStructure:r().any,fixedWeekNumber:r().number,format:r().string,formatDensity:r().oneOf(["dense","spacious"]),inputRef:xt,label:r().node,loading:r().bool,localeText:r().object,maxDate:r().object,maxDateTime:r().object,maxTime:r().object,minDate:r().object,minDateTime:r().object,minTime:r().object,minutesStep:r().number,monthsPerRow:r().oneOf([3,4]),name:r().string,onAccept:r().func,onChange:r().func,onClose:r().func,onError:r().func,onMonthChange:r().func,onOpen:r().func,onSelectedSectionsChange:r().func,onViewChange:r().func,onYearChange:r().func,open:r().bool,openTo:r().oneOf(["day","hours","meridiem","minutes","month","seconds","year"]),orientation:r().oneOf(["landscape","portrait"]),readOnly:r().bool,reduceAnimations:r().bool,referenceDate:r().object,renderLoading:r().func,selectedSections:r().oneOfType([r().oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),r().number]),shouldDisableDate:r().func,shouldDisableMonth:r().func,shouldDisableTime:r().func,shouldDisableYear:r().func,showDaysOutsideCurrentMonth:r().bool,skipDisabled:r().bool,slotProps:r().object,slots:r().object,sx:r().oneOfType([r().arrayOf(r().oneOfType([r().func,r().object,r().bool])),r().func,r().object]),thresholdToRenderTimeInASingleColumn:r().number,timeSteps:r().shape({hours:r().number,minutes:r().number,seconds:r().number}),timezone:r().string,value:r().object,view:r().oneOf(["day","hours","meridiem","minutes","month","seconds","year"]),viewRenderers:r().shape({day:r().func,hours:r().func,meridiem:r().func,minutes:r().func,month:r().func,seconds:r().func,year:r().func}),views:r().arrayOf(r().oneOf(["day","hours","minutes","month","seconds","year"]).isRequired),yearsOrder:r().oneOf(["asc","desc"]),yearsPerRow:r().oneOf([3,4])};const ao=b.forwardRef(function(t,o){var d,p,f,A;const n=xe(),s=me(),a=so(t,"MuiMobileDateTimePicker"),i=(0,m.A)({day:De,month:De,year:De,hours:Re,minutes:Re,seconds:Re},a.viewRenderers),c=(d=a.ampmInClock)!=null?d:!1,l=(0,m.A)({},a,{viewRenderers:i,format:Zs(s,a),ampmInClock:c,slots:(0,m.A)({field:jn},a.slots),slotProps:(0,m.A)({},a.slotProps,{field:h=>{var C;return(0,m.A)({},(0,rt.A)((C=a.slotProps)==null?void 0:C.field,h),nt(a),{ref:o})},toolbar:(0,m.A)({hidden:!1,ampmInClock:c},(p=a.slotProps)==null?void 0:p.toolbar),tabs:(0,m.A)({hidden:!1},(f=a.slotProps)==null?void 0:f.tabs)})}),{renderPicker:u}=Qn({props:l,valueManager:Ce,valueType:"date-time",getOpenDialogAriaText:lt({utils:s,formatKey:"fullDate",contextTranslation:n.openDatePickerDialogue,propsTranslation:(A=l.localeText)==null?void 0:A.openDatePickerDialogue}),validator:Ct});return u()});ao.propTypes={ampm:r().bool,ampmInClock:r().bool,autoFocus:r().bool,className:r().string,closeOnSelect:r().bool,dayOfWeekFormatter:r().func,defaultValue:r().object,disabled:r().bool,disableFuture:r().bool,disableHighlightToday:r().bool,disableIgnoringDatePartForTimeValidation:r().bool,disableOpenPicker:r().bool,disablePast:r().bool,displayWeekNumber:r().bool,enableAccessibleFieldDOMStructure:r().any,fixedWeekNumber:r().number,format:r().string,formatDensity:r().oneOf(["dense","spacious"]),inputRef:xt,label:r().node,loading:r().bool,localeText:r().object,maxDate:r().object,maxDateTime:r().object,maxTime:r().object,minDate:r().object,minDateTime:r().object,minTime:r().object,minutesStep:r().number,monthsPerRow:r().oneOf([3,4]),name:r().string,onAccept:r().func,onChange:r().func,onClose:r().func,onError:r().func,onMonthChange:r().func,onOpen:r().func,onSelectedSectionsChange:r().func,onViewChange:r().func,onYearChange:r().func,open:r().bool,openTo:r().oneOf(["day","hours","minutes","month","seconds","year"]),orientation:r().oneOf(["landscape","portrait"]),readOnly:r().bool,reduceAnimations:r().bool,referenceDate:r().object,renderLoading:r().func,selectedSections:r().oneOfType([r().oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),r().number]),shouldDisableDate:r().func,shouldDisableMonth:r().func,shouldDisableTime:r().func,shouldDisableYear:r().func,showDaysOutsideCurrentMonth:r().bool,slotProps:r().object,slots:r().object,sx:r().oneOfType([r().arrayOf(r().oneOfType([r().func,r().object,r().bool])),r().func,r().object]),timezone:r().string,value:r().object,view:r().oneOf(["day","hours","minutes","month","seconds","year"]),viewRenderers:r().shape({day:r().func,hours:r().func,minutes:r().func,month:r().func,seconds:r().func,year:r().func}),views:r().arrayOf(r().oneOf(["day","hours","minutes","month","seconds","year"]).isRequired),yearsOrder:r().oneOf(["asc","desc"]),yearsPerRow:r().oneOf([3,4])};const md=["desktopModeMediaQuery"],fd=b.forwardRef(function(t,o){const n=(0,pe.A)({props:t,name:"MuiDateTimePicker"}),{desktopModeMediaQuery:s=Qt}=n,a=(0,ie.A)(n,md);return(0,on.A)(s,{defaultMatches:!0})?(0,y.jsx)(ro,(0,m.A)({ref:o},a)):(0,y.jsx)(ao,(0,m.A)({ref:o},a))}),rr=b.forwardRef(function(t,o){var u,d,p,f,A;const n=so(t,"MuiStaticDateTimePicker"),s=(u=n.displayStaticWrapperAs)!=null?u:"mobile",a=(d=n.ampmInClock)!=null?d:s==="desktop",i=(0,m.A)({day:De,month:De,year:De,hours:Re,minutes:Re,seconds:Re},n.viewRenderers),c=(0,m.A)({},n,{viewRenderers:i,displayStaticWrapperAs:s,ampmInClock:a,yearsPerRow:(p=n.yearsPerRow)!=null?p:s==="mobile"?3:4,slotProps:(0,m.A)({},n.slotProps,{tabs:(0,m.A)({hidden:s==="desktop"},(f=n.slotProps)==null?void 0:f.tabs),toolbar:(0,m.A)({hidden:s==="desktop",ampmInClock:a},(A=n.slotProps)==null?void 0:A.toolbar)})}),{renderPicker:l}=Jn({props:c,valueManager:Ce,valueType:"date-time",validator:Ct,ref:o});return l()});rr.propTypes={ampm:r().bool,ampmInClock:r().bool,autoFocus:r().bool,className:r().string,dayOfWeekFormatter:r().func,defaultValue:r().object,disabled:r().bool,disableFuture:r().bool,disableHighlightToday:r().bool,disableIgnoringDatePartForTimeValidation:r().bool,disablePast:r().bool,displayStaticWrapperAs:r().oneOf(["desktop","mobile"]),displayWeekNumber:r().bool,fixedWeekNumber:r().number,loading:r().bool,localeText:r().object,maxDate:r().object,maxDateTime:r().object,maxTime:r().object,minDate:r().object,minDateTime:r().object,minTime:r().object,minutesStep:r().number,monthsPerRow:r().oneOf([3,4]),onAccept:r().func,onChange:r().func,onClose:r().func,onError:r().func,onMonthChange:r().func,onViewChange:r().func,onYearChange:r().func,openTo:r().oneOf(["day","hours","minutes","month","seconds","year"]),orientation:r().oneOf(["landscape","portrait"]),readOnly:r().bool,reduceAnimations:r().bool,referenceDate:r().object,renderLoading:r().func,shouldDisableDate:r().func,shouldDisableMonth:r().func,shouldDisableTime:r().func,shouldDisableYear:r().func,showDaysOutsideCurrentMonth:r().bool,slotProps:r().object,slots:r().object,sx:r().oneOfType([r().arrayOf(r().oneOfType([r().func,r().object,r().bool])),r().func,r().object]),timezone:r().string,value:r().object,view:r().oneOf(["day","hours","minutes","month","seconds","year"]),viewRenderers:r().shape({day:r().func,hours:r().func,minutes:r().func,month:r().func,seconds:r().func,year:r().func}),views:r().arrayOf(r().oneOf(["day","hours","minutes","month","seconds","year"]).isRequired),yearsOrder:r().oneOf(["asc","desc"]),yearsPerRow:r().oneOf([3,4])};const hd=e=>{const{format:t,formatDensity:o="dense",shouldRespectLeadingZeros:n=!1}=e,s=me(),a=(0,we.I)(),i=xe(),c=b.useMemo(()=>Eo(s),[s]);return b.useMemo(()=>xn({utils:s,format:t,formatDensity:o,isRtl:a,shouldRespectLeadingZeros:n,localeText:i,localizedDigits:c,date:null,enableAccessibleFieldDOMStructure:!1}).map(u=>`${u.startSeparator}${u.placeholder}${u.endSeparator}`).join(""),[s,a,i,c,t,o,n])},bd=()=>{const e=b.useContext(Ys);if(e==null)throw new Error(["MUI X: The `usePickersContext` can only be called in fields that are used as a slot of a picker component"].join(` +`));return e};/** + * @mui/x-date-pickers v7.23.1 + * + * @license MIT + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */}}]); + +//# sourceMappingURL=vendors-node_modules_mui_x-date-pickers_index_js.e89ab137.chunk.js.map \ No newline at end of file diff --git a/admin/custom/static/js/vendors-node_modules_mui_x-date-pickers_index_js.e89ab137.chunk.js.map b/admin/custom/static/js/vendors-node_modules_mui_x-date-pickers_index_js.e89ab137.chunk.js.map new file mode 100644 index 0000000..01c7116 --- /dev/null +++ b/admin/custom/static/js/vendors-node_modules_mui_x-date-pickers_index_js.e89ab137.chunk.js.map @@ -0,0 +1 @@ +{"version":3,"file":"static/js/vendors-node_modules_mui_x-date-pickers_index_js.e89ab137.chunk.js","mappings":"yoHAIA,MAAMA,GAAY,CAAC,YAAY,EAKlBC,GAAwC,gBAAoB,IAAI,EAgBhEC,GAAuB,SAA8BC,EAAS,C,MACzE,KAAM,CACF,WAAYC,CACd,EAAID,EACJE,KAAe,MAA8BF,EAASH,EAAS,EAC3D,CACJ,MAAOM,EACP,WAAYC,CACd,GAAI,eAAiBN,EAAwB,IAAzC,OAA8C,CAChD,MAAO,OACP,WAAY,MACd,EACMO,KAAQC,GAAA,GAAc,CAG1B,MAAOJ,EACP,KAAM,yBACR,CAAC,EACK,CACJ,SAAAK,EACA,YAAaC,EACb,YAAAC,EACA,gBAAAC,EACA,cAAAC,EACA,WAAYC,CACd,EAAIP,EACEQ,EAAa,UAAc,OAAM,KAAS,CAAC,EAAGD,EAAiBR,EAAkBH,CAAY,EAAG,CAACW,EAAiBR,EAAkBH,CAAY,CAAC,EACjJa,EAAQ,UAAc,IAAM,CAChC,GAAI,CAACN,EACH,OAAIL,GAGG,KAET,MAAMY,EAAU,IAAIP,EAAY,CAC9B,OAAQG,EACR,QAASF,EACT,SAAUC,CACZ,CAAC,EACD,GAAI,CAACK,EAAQ,aACX,MAAM,IAAI,MAAM,CAAC,0HAA2H,wIAAyI,wHAAwH,EAAE,KAAK;AAAA,CAAI,CAAC,EAE3Z,OAAOA,CACT,EAAG,CAACP,EAAaG,EAAeF,EAAaC,EAAiB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AAW,GAAGA,EAAQ,YAAY,EAAE,EAAE,KAAK,EAAE,EAC/G,CAAC7T,EAAO6D,EAAOmM,EAAcsF,EAAiBnO,EAAQ6f,EAAerB,CAAyB,CAAC,CACpG,EClCak4B,GAAoB,IAAM,CACrC,MAAMl9C,EAAQ,aAAiB61C,EAAc,EAC7C,GAAI71C,GAAS,KACX,MAAM,IAAI,MAAM,CAAC,2GAA2G,EAAE,KAAK;AAAA,CAAI,CAAC,EAE1I,OAAOA,CACT,ECdA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,G","sources":["../node_modules/@mui/x-date-pickers/LocalizationProvider/LocalizationProvider.js","../node_modules/@mui/x-date-pickers/locales/utils/getPickersLocalization.js","../node_modules/@mui/x-date-pickers/locales/enUS.js","../node_modules/@mui/x-date-pickers/internals/hooks/useUtils.js","../node_modules/@mui/x-date-pickers/hooks/usePickersTranslations.js","../node_modules/@mui/x-date-pickers/icons/index.js","../node_modules/@mui/x-date-pickers/internals/components/PickersArrowSwitcher/pickersArrowSwitcherClasses.js","../node_modules/@mui/x-date-pickers/internals/components/PickersArrowSwitcher/PickersArrowSwitcher.js","../node_modules/@mui/x-date-pickers/internals/utils/views.js","../node_modules/@mui/x-date-pickers/internals/utils/time-utils.js","../node_modules/@mui/x-date-pickers/internals/hooks/useViews.js","../node_modules/@mui/x-date-pickers/internals/hooks/date-helpers-hooks.js","../node_modules/@mui/x-date-pickers/internals/constants/dimensions.js","../node_modules/@mui/x-date-pickers/internals/components/PickerViewRoot/PickerViewRoot.js","../node_modules/@mui/x-date-pickers/TimeClock/timeClockClasses.js","../node_modules/@mui/x-date-pickers/TimeClock/shared.js","../node_modules/@mui/x-date-pickers/TimeClock/clockPointerClasses.js","../node_modules/@mui/x-date-pickers/TimeClock/ClockPointer.js","../node_modules/@mui/x-date-pickers/TimeClock/clockClasses.js","../node_modules/@mui/x-date-pickers/internals/utils/date-utils.js","../node_modules/@mui/x-date-pickers/TimeClock/Clock.js","../node_modules/@mui/x-date-pickers/TimeClock/clockNumberClasses.js","../node_modules/@mui/x-date-pickers/TimeClock/ClockNumber.js","../node_modules/@mui/x-date-pickers/TimeClock/ClockNumbers.js","../node_modules/@mui/x-date-pickers/internals/hooks/useValueWithTimezone.js","../node_modules/@mui/x-date-pickers/internals/utils/getDefaultReferenceDate.js","../node_modules/@mui/x-date-pickers/internals/hooks/useField/useField.utils.js","../node_modules/@mui/x-date-pickers/internals/utils/valueManagers.js","../node_modules/@mui/x-date-pickers/internals/hooks/useClockReferenceDate.js","../node_modules/@mui/x-date-pickers/TimeClock/TimeClock.js","../node_modules/@mui/x-date-pickers/DigitalClock/digitalClockClasses.js","../node_modules/@mui/x-date-pickers/internals/utils/utils.js","../node_modules/@mui/x-date-pickers/DigitalClock/DigitalClock.js","../node_modules/@mui/x-date-pickers/MultiSectionDigitalClock/multiSectionDigitalClockClasses.js","../node_modules/@mui/x-date-pickers/MultiSectionDigitalClock/multiSectionDigitalClockSectionClasses.js","../node_modules/@mui/x-date-pickers/MultiSectionDigitalClock/MultiSectionDigitalClockSection.js","../node_modules/@mui/x-date-pickers/MultiSectionDigitalClock/MultiSectionDigitalClock.utils.js","../node_modules/@mui/x-date-pickers/MultiSectionDigitalClock/MultiSectionDigitalClock.js","../node_modules/@mui/x-date-pickers/PickersDay/pickersDayClasses.js","../node_modules/@mui/x-date-pickers/PickersDay/PickersDay.js","../node_modules/@mui/x-date-pickers/validation/useValidation.js","../node_modules/@mui/x-date-pickers/internals/hooks/useField/buildSectionsFromFormat.js","../node_modules/@mui/x-date-pickers/internals/hooks/useField/useFieldState.js","../node_modules/@mui/x-date-pickers/internals/hooks/useField/useFieldCharacterEditing.js","../node_modules/@mui/x-date-pickers/internals/hooks/useField/useFieldV7TextField.js","../node_modules/@mui/x-date-pickers/internals/hooks/useField/useFieldV6TextField.js","../node_modules/@mui/x-date-pickers/internals/hooks/useField/useField.js","../node_modules/@mui/x-date-pickers/validation/validateDate.js","../node_modules/@mui/x-date-pickers/validation/extractValidationProps.js","../node_modules/@mui/x-date-pickers/hooks/useSplitFieldProps.js","../node_modules/@mui/x-date-pickers/internals/hooks/defaultizedFieldProps.js","../node_modules/@mui/x-date-pickers/DateField/useDateField.js","../node_modules/@mui/x-date-pickers/hooks/useClearableField.js","../node_modules/@mui/x-date-pickers/PickersTextField/pickersTextFieldClasses.js","../node_modules/@mui/x-date-pickers/PickersTextField/PickersInputBase/pickersInputBaseClasses.js","../node_modules/@mui/x-date-pickers/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.js","../node_modules/@mui/x-date-pickers/PickersTextField/PickersOutlinedInput/Outline.js","../node_modules/@mui/x-date-pickers/PickersSectionList/pickersSectionListClasses.js","../node_modules/@mui/x-date-pickers/PickersSectionList/PickersSectionList.js","../node_modules/@mui/x-date-pickers/PickersTextField/PickersInputBase/PickersInputBase.js","../node_modules/@mui/x-date-pickers/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.js","../node_modules/@mui/x-date-pickers/PickersTextField/PickersFilledInput/pickersFilledInputClasses.js","../node_modules/@mui/x-date-pickers/PickersTextField/PickersFilledInput/PickersFilledInput.js","../node_modules/@mui/x-date-pickers/PickersTextField/PickersInput/pickersInputClasses.js","../node_modules/@mui/x-date-pickers/PickersTextField/PickersInput/PickersInput.js","../node_modules/@mui/x-date-pickers/PickersTextField/PickersTextField.js","../node_modules/@mui/x-date-pickers/internals/utils/convertFieldResponseIntoMuiTextFieldProps.js","../node_modules/@mui/x-date-pickers/DateField/DateField.js","../node_modules/@mui/x-date-pickers/validation/validateTime.js","../node_modules/@mui/x-date-pickers/TimeField/useTimeField.js","../node_modules/@mui/x-date-pickers/TimeField/TimeField.js","../node_modules/@mui/x-date-pickers/validation/validateDateTime.js","../node_modules/@mui/x-date-pickers/DateTimeField/useDateTimeField.js","../node_modules/@mui/x-date-pickers/DateTimeField/DateTimeField.js","../node_modules/@mui/x-date-pickers/DateCalendar/useIsDateDisabled.js","../node_modules/@mui/x-date-pickers/DateCalendar/useCalendarState.js","../node_modules/@mui/x-date-pickers/DateCalendar/pickersFadeTransitionGroupClasses.js","../node_modules/@mui/x-date-pickers/DateCalendar/PickersFadeTransitionGroup.js","../node_modules/dom-helpers/esm/hasClass.js","../node_modules/dom-helpers/esm/addClass.js","../node_modules/dom-helpers/esm/removeClass.js","../node_modules/react-transition-group/esm/CSSTransition.js","../node_modules/@mui/x-date-pickers/DateCalendar/pickersSlideTransitionClasses.js","../node_modules/@mui/x-date-pickers/DateCalendar/PickersSlideTransition.js","../node_modules/@mui/x-date-pickers/DateCalendar/dayCalendarClasses.js","../node_modules/@mui/x-date-pickers/DateCalendar/DayCalendar.js","../node_modules/@mui/x-date-pickers/MonthCalendar/pickersMonthClasses.js","../node_modules/@mui/x-date-pickers/MonthCalendar/PickersMonth.js","../node_modules/@mui/x-date-pickers/MonthCalendar/monthCalendarClasses.js","../node_modules/@mui/x-date-pickers/MonthCalendar/MonthCalendar.js","../node_modules/@mui/x-date-pickers/YearCalendar/pickersYearClasses.js","../node_modules/@mui/x-date-pickers/YearCalendar/PickersYear.js","../node_modules/@mui/x-date-pickers/YearCalendar/yearCalendarClasses.js","../node_modules/@mui/x-date-pickers/YearCalendar/YearCalendar.js","../node_modules/@mui/x-date-pickers/PickersCalendarHeader/pickersCalendarHeaderClasses.js","../node_modules/@mui/x-date-pickers/PickersCalendarHeader/PickersCalendarHeader.js","../node_modules/@mui/x-date-pickers/internals/hooks/useDefaultReduceAnimations.js","../node_modules/@mui/x-date-pickers/DateCalendar/dateCalendarClasses.js","../node_modules/@mui/x-date-pickers/DateCalendar/DateCalendar.js","../node_modules/@mui/x-date-pickers/DayCalendarSkeleton/dayCalendarSkeletonClasses.js","../node_modules/@mui/x-date-pickers/DayCalendarSkeleton/DayCalendarSkeleton.js","../node_modules/@mui/utils/esm/refType/refType.js","../node_modules/@mui/x-date-pickers/internals/components/pickersToolbarClasses.js","../node_modules/@mui/x-date-pickers/internals/components/PickersToolbar.js","../node_modules/@mui/x-date-pickers/DatePicker/datePickerToolbarClasses.js","../node_modules/@mui/x-date-pickers/DatePicker/DatePickerToolbar.js","../node_modules/@mui/x-date-pickers/DatePicker/shared.js","../node_modules/@mui/x-date-pickers/internals/components/pickersPopperClasses.js","../node_modules/@mui/x-date-pickers/internals/components/PickersPopper.js","../node_modules/@mui/x-date-pickers/internals/hooks/useOpenState.js","../node_modules/@mui/x-date-pickers/internals/hooks/usePicker/usePickerValue.js","../node_modules/@mui/x-date-pickers/internals/hooks/usePicker/usePickerViews.js","../node_modules/@mui/x-date-pickers/internals/hooks/useIsLandscape.js","../node_modules/@mui/x-date-pickers/internals/hooks/usePicker/usePickerLayoutProps.js","../node_modules/@mui/x-date-pickers/internals/hooks/usePicker/usePickerOwnerState.js","../node_modules/@mui/x-date-pickers/internals/hooks/usePicker/usePicker.js","../node_modules/@mui/x-date-pickers/PickersLayout/pickersLayoutClasses.js","../node_modules/@mui/x-date-pickers/PickersActionBar/PickersActionBar.js","../node_modules/@mui/x-date-pickers/PickersShortcuts/PickersShortcuts.js","../node_modules/@mui/x-date-pickers/PickersLayout/usePickerLayout.js","../node_modules/@mui/x-date-pickers/PickersLayout/PickersLayout.js","../node_modules/@mui/x-date-pickers/internals/components/PickersProvider.js","../node_modules/@mui/x-date-pickers/internals/hooks/useDesktopPicker/useDesktopPicker.js","../node_modules/@mui/x-date-pickers/dateViewRenderers/dateViewRenderers.js","../node_modules/@mui/x-date-pickers/DesktopDatePicker/DesktopDatePicker.js","../node_modules/@mui/x-date-pickers/internals/components/PickersModalDialog.js","../node_modules/@mui/x-date-pickers/internals/hooks/useMobilePicker/useMobilePicker.js","../node_modules/@mui/x-date-pickers/MobileDatePicker/MobileDatePicker.js","../node_modules/@mui/x-date-pickers/DatePicker/DatePicker.js","../node_modules/@mui/x-date-pickers/internals/hooks/useStaticPicker/useStaticPicker.js","../node_modules/@mui/x-date-pickers/StaticDatePicker/StaticDatePicker.js","../node_modules/@mui/x-date-pickers/internals/components/pickersToolbarTextClasses.js","../node_modules/@mui/x-date-pickers/internals/components/PickersToolbarText.js","../node_modules/@mui/x-date-pickers/internals/components/PickersToolbarButton.js","../node_modules/@mui/x-date-pickers/TimePicker/timePickerToolbarClasses.js","../node_modules/@mui/x-date-pickers/TimePicker/TimePickerToolbar.js","../node_modules/@mui/x-date-pickers/TimePicker/shared.js","../node_modules/@mui/x-date-pickers/timeViewRenderers/timeViewRenderers.js","../node_modules/@mui/x-date-pickers/internals/utils/date-time-utils.js","../node_modules/@mui/x-date-pickers/DesktopTimePicker/DesktopTimePicker.js","../node_modules/@mui/x-date-pickers/MobileTimePicker/MobileTimePicker.js","../node_modules/@mui/x-date-pickers/TimePicker/TimePicker.js","../node_modules/@mui/x-date-pickers/StaticTimePicker/StaticTimePicker.js","../node_modules/@mui/x-date-pickers/DateTimePicker/dateTimePickerTabsClasses.js","../node_modules/@mui/x-date-pickers/DateTimePicker/DateTimePickerTabs.js","../node_modules/@mui/x-date-pickers/DateTimePicker/dateTimePickerToolbarClasses.js","../node_modules/@mui/x-date-pickers/DateTimePicker/DateTimePickerToolbar.js","../node_modules/@mui/x-date-pickers/DateTimePicker/shared.js","../node_modules/@mui/x-date-pickers/DesktopDateTimePicker/DesktopDateTimePickerLayout.js","../node_modules/@mui/x-date-pickers/DesktopDateTimePicker/DesktopDateTimePicker.js","../node_modules/@mui/x-date-pickers/MobileDateTimePicker/MobileDateTimePicker.js","../node_modules/@mui/x-date-pickers/DateTimePicker/DateTimePicker.js","../node_modules/@mui/x-date-pickers/StaticDateTimePicker/StaticDateTimePicker.js","../node_modules/@mui/x-date-pickers/hooks/useParsedFormat.js","../node_modules/@mui/x-date-pickers/hooks/usePickersContext.js","../node_modules/@mui/x-date-pickers/index.js"],"sourcesContent":["'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"localeText\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { useThemeProps } from '@mui/material/styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport const MuiPickersAdapterContext = /*#__PURE__*/React.createContext(null);\nif (process.env.NODE_ENV !== 'production') {\n MuiPickersAdapterContext.displayName = 'MuiPickersAdapterContext';\n}\n/**\n * Demos:\n *\n * - [Date format and localization](https://mui.com/x/react-date-pickers/adapters-locale/)\n * - [Calendar systems](https://mui.com/x/react-date-pickers/calendar-systems/)\n * - [Translated components](https://mui.com/x/react-date-pickers/localization/)\n * - [UTC and timezones](https://mui.com/x/react-date-pickers/timezone/)\n *\n * API:\n *\n * - [LocalizationProvider API](https://mui.com/x/api/date-pickers/localization-provider/)\n */\nexport const LocalizationProvider = function LocalizationProvider(inProps) {\n const {\n localeText: inLocaleText\n } = inProps,\n otherInProps = _objectWithoutPropertiesLoose(inProps, _excluded);\n const {\n utils: parentUtils,\n localeText: parentLocaleText\n } = React.useContext(MuiPickersAdapterContext) ?? {\n utils: undefined,\n localeText: undefined\n };\n const props = useThemeProps({\n // We don't want to pass the `localeText` prop to the theme, that way it will always return the theme value,\n // We will then merge this theme value with our value manually\n props: otherInProps,\n name: 'MuiLocalizationProvider'\n });\n const {\n children,\n dateAdapter: DateAdapter,\n dateFormats,\n dateLibInstance,\n adapterLocale,\n localeText: themeLocaleText\n } = props;\n const localeText = React.useMemo(() => _extends({}, themeLocaleText, parentLocaleText, inLocaleText), [themeLocaleText, parentLocaleText, inLocaleText]);\n const utils = React.useMemo(() => {\n if (!DateAdapter) {\n if (parentUtils) {\n return parentUtils;\n }\n return null;\n }\n const adapter = new DateAdapter({\n locale: adapterLocale,\n formats: dateFormats,\n instance: dateLibInstance\n });\n if (!adapter.isMUIAdapter) {\n throw new Error(['MUI X: The date adapter should be imported from `@mui/x-date-pickers` or `@mui/x-date-pickers-pro`, not from `@date-io`', \"For example, `import { AdapterDayjs } from '@mui/x-date-pickers/AdapterDayjs'` instead of `import AdapterDayjs from '@date-io/dayjs'`\", 'More information on the installation documentation: https://mui.com/x/react-date-pickers/getting-started/#installation'].join(`\\n`));\n }\n return adapter;\n }, [DateAdapter, adapterLocale, dateFormats, dateLibInstance, parentUtils]);\n const defaultDates = React.useMemo(() => {\n if (!utils) {\n return null;\n }\n return {\n minDate: utils.date('1900-01-01T00:00:00.000'),\n maxDate: utils.date('2099-12-31T00:00:00.000')\n };\n }, [utils]);\n const contextValue = React.useMemo(() => {\n return {\n utils,\n defaultDates,\n localeText\n };\n }, [defaultDates, utils, localeText]);\n return /*#__PURE__*/_jsx(MuiPickersAdapterContext.Provider, {\n value: contextValue,\n children: children\n });\n};\nprocess.env.NODE_ENV !== \"production\" ? LocalizationProvider.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Locale for the date library you are using\n */\n adapterLocale: PropTypes.any,\n children: PropTypes.node,\n /**\n * Date library adapter class function.\n * @see See the localization provider {@link https://mui.com/x/react-date-pickers/getting-started/#setup-your-date-library-adapter date adapter setup section} for more details.\n */\n dateAdapter: PropTypes.func,\n /**\n * Formats that are used for any child pickers\n */\n dateFormats: PropTypes.shape({\n dayOfMonth: PropTypes.string,\n dayOfMonthFull: PropTypes.string,\n fullDate: PropTypes.string,\n fullTime: PropTypes.string,\n fullTime12h: PropTypes.string,\n fullTime24h: PropTypes.string,\n hours12h: PropTypes.string,\n hours24h: PropTypes.string,\n keyboardDate: PropTypes.string,\n keyboardDateTime: PropTypes.string,\n keyboardDateTime12h: PropTypes.string,\n keyboardDateTime24h: PropTypes.string,\n meridiem: PropTypes.string,\n minutes: PropTypes.string,\n month: PropTypes.string,\n monthShort: PropTypes.string,\n normalDate: PropTypes.string,\n normalDateWithWeekday: PropTypes.string,\n seconds: PropTypes.string,\n shortDate: PropTypes.string,\n weekday: PropTypes.string,\n weekdayShort: PropTypes.string,\n year: PropTypes.string\n }),\n /**\n * Date library instance you are using, if it has some global overrides\n * ```jsx\n * dateLibInstance={momentTimeZone}\n * ```\n */\n dateLibInstance: PropTypes.any,\n /**\n * Locale for components texts\n */\n localeText: PropTypes.object\n} : void 0;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport const getPickersLocalization = pickersTranslations => {\n return {\n components: {\n MuiLocalizationProvider: {\n defaultProps: {\n localeText: _extends({}, pickersTranslations)\n }\n }\n }\n };\n};\nexport const buildGetOpenDialogAriaText = params => {\n const {\n utils,\n formatKey,\n contextTranslation,\n propsTranslation\n } = params;\n return value => {\n const formattedValue = value !== null && utils.isValid(value) ? utils.format(value, formatKey) : null;\n const translation = propsTranslation ?? contextTranslation;\n return translation(value, utils, formattedValue);\n };\n};","import { getPickersLocalization } from \"./utils/getPickersLocalization.js\";\n\n// This object is not Partial because it is the default values\n\nconst enUSPickers = {\n // Calendar navigation\n previousMonth: 'Previous month',\n nextMonth: 'Next month',\n // View navigation\n openPreviousView: 'Open previous view',\n openNextView: 'Open next view',\n calendarViewSwitchingButtonAriaLabel: view => view === 'year' ? 'year view is open, switch to calendar view' : 'calendar view is open, switch to year view',\n // DateRange labels\n start: 'Start',\n end: 'End',\n startDate: 'Start date',\n startTime: 'Start time',\n endDate: 'End date',\n endTime: 'End time',\n // Action bar\n cancelButtonLabel: 'Cancel',\n clearButtonLabel: 'Clear',\n okButtonLabel: 'OK',\n todayButtonLabel: 'Today',\n // Toolbar titles\n datePickerToolbarTitle: 'Select date',\n dateTimePickerToolbarTitle: 'Select date & time',\n timePickerToolbarTitle: 'Select time',\n dateRangePickerToolbarTitle: 'Select date range',\n // Clock labels\n clockLabelText: (view, time, utils, formattedTime) => `Select ${view}. ${!formattedTime && (time === null || !utils.isValid(time)) ? 'No time selected' : `Selected time is ${formattedTime ?? utils.format(time, 'fullTime')}`}`,\n hoursClockNumberText: hours => `${hours} hours`,\n minutesClockNumberText: minutes => `${minutes} minutes`,\n secondsClockNumberText: seconds => `${seconds} seconds`,\n // Digital clock labels\n selectViewText: view => `Select ${view}`,\n // Calendar labels\n calendarWeekNumberHeaderLabel: 'Week number',\n calendarWeekNumberHeaderText: '#',\n calendarWeekNumberAriaLabelText: weekNumber => `Week ${weekNumber}`,\n calendarWeekNumberText: weekNumber => `${weekNumber}`,\n // Open picker labels\n openDatePickerDialogue: (value, utils, formattedDate) => formattedDate || value !== null && utils.isValid(value) ? `Choose date, selected date is ${formattedDate ?? utils.format(value, 'fullDate')}` : 'Choose date',\n openTimePickerDialogue: (value, utils, formattedTime) => formattedTime || value !== null && utils.isValid(value) ? `Choose time, selected time is ${formattedTime ?? utils.format(value, 'fullTime')}` : 'Choose time',\n fieldClearLabel: 'Clear',\n // Table labels\n timeTableLabel: 'pick time',\n dateTableLabel: 'pick date',\n // Field section placeholders\n fieldYearPlaceholder: params => 'Y'.repeat(params.digitAmount),\n fieldMonthPlaceholder: params => params.contentType === 'letter' ? 'MMMM' : 'MM',\n fieldDayPlaceholder: () => 'DD',\n fieldWeekDayPlaceholder: params => params.contentType === 'letter' ? 'EEEE' : 'EE',\n fieldHoursPlaceholder: () => 'hh',\n fieldMinutesPlaceholder: () => 'mm',\n fieldSecondsPlaceholder: () => 'ss',\n fieldMeridiemPlaceholder: () => 'aa',\n // View names\n year: 'Year',\n month: 'Month',\n day: 'Day',\n weekDay: 'Week day',\n hours: 'Hours',\n minutes: 'Minutes',\n seconds: 'Seconds',\n meridiem: 'Meridiem',\n // Common\n empty: 'Empty'\n};\nexport const DEFAULT_LOCALE = enUSPickers;\nexport const enUS = getPickersLocalization(enUSPickers);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport { MuiPickersAdapterContext } from \"../../LocalizationProvider/LocalizationProvider.js\";\nimport { DEFAULT_LOCALE } from \"../../locales/enUS.js\";\nexport const useLocalizationContext = () => {\n const localization = React.useContext(MuiPickersAdapterContext);\n if (localization === null) {\n throw new Error(['MUI X: Can not find the date and time pickers localization context.', 'It looks like you forgot to wrap your component in LocalizationProvider.', 'This can also happen if you are bundling multiple versions of the `@mui/x-date-pickers` package'].join('\\n'));\n }\n if (localization.utils === null) {\n throw new Error(['MUI X: Can not find the date and time pickers adapter from its localization context.', 'It looks like you forgot to pass a `dateAdapter` to your LocalizationProvider.'].join('\\n'));\n }\n const localeText = React.useMemo(() => _extends({}, DEFAULT_LOCALE, localization.localeText), [localization.localeText]);\n return React.useMemo(() => _extends({}, localization, {\n localeText\n }), [localization, localeText]);\n};\nexport const useUtils = () => useLocalizationContext().utils;\nexport const useDefaultDates = () => useLocalizationContext().defaultDates;\nexport const useNow = timezone => {\n const utils = useUtils();\n const now = React.useRef();\n if (now.current === undefined) {\n now.current = utils.date(undefined, timezone);\n }\n return now.current;\n};","'use client';\n\nimport { useLocalizationContext } from \"../internals/hooks/useUtils.js\";\nexport const usePickersTranslations = () => useLocalizationContext().localeText;","import { createSvgIcon } from '@mui/material/utils';\nimport * as React from 'react';\n\n/**\n * @ignore - internal component.\n */\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nexport const ArrowDropDownIcon = createSvgIcon(/*#__PURE__*/_jsx(\"path\", {\n d: \"M7 10l5 5 5-5z\"\n}), 'ArrowDropDown');\n\n/**\n * @ignore - internal component.\n */\nexport const ArrowLeftIcon = createSvgIcon(/*#__PURE__*/_jsx(\"path\", {\n d: \"M15.41 16.59L10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z\"\n}), 'ArrowLeft');\n\n/**\n * @ignore - internal component.\n */\nexport const ArrowRightIcon = createSvgIcon(/*#__PURE__*/_jsx(\"path\", {\n d: \"M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z\"\n}), 'ArrowRight');\n\n/**\n * @ignore - internal component.\n */\nexport const CalendarIcon = createSvgIcon(/*#__PURE__*/_jsx(\"path\", {\n d: \"M17 12h-5v5h5v-5zM16 1v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2h-1V1h-2zm3 18H5V8h14v11z\"\n}), 'Calendar');\n\n/**\n * @ignore - internal component.\n */\nexport const ClockIcon = createSvgIcon(/*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/_jsx(\"path\", {\n d: \"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z\"\n }), /*#__PURE__*/_jsx(\"path\", {\n d: \"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z\"\n })]\n}), 'Clock');\n\n/**\n * @ignore - internal component.\n */\nexport const DateRangeIcon = createSvgIcon(/*#__PURE__*/_jsx(\"path\", {\n d: \"M9 11H7v2h2v-2zm4 0h-2v2h2v-2zm4 0h-2v2h2v-2zm2-7h-1V2h-2v2H8V2H6v2H5c-1.11 0-1.99.9-1.99 2L3 20c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H5V9h14v11z\"\n}), 'DateRange');\n\n/**\n * @ignore - internal component.\n */\nexport const TimeIcon = createSvgIcon(/*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/_jsx(\"path\", {\n d: \"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z\"\n }), /*#__PURE__*/_jsx(\"path\", {\n d: \"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z\"\n })]\n}), 'Time');\n\n/**\n * @ignore - internal component.\n */\nexport const ClearIcon = createSvgIcon(/*#__PURE__*/_jsx(\"path\", {\n d: \"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z\"\n}), 'Clear');","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getPickersArrowSwitcherUtilityClass(slot) {\n return generateUtilityClass('MuiPickersArrowSwitcher', slot);\n}\nexport const pickersArrowSwitcherClasses = generateUtilityClasses('MuiPickersArrowSwitcher', ['root', 'spacer', 'button', 'previousIconButton', 'nextIconButton', 'leftArrowIcon', 'rightArrowIcon']);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"slots\", \"slotProps\", \"isNextDisabled\", \"isNextHidden\", \"onGoToNext\", \"nextLabel\", \"isPreviousDisabled\", \"isPreviousHidden\", \"onGoToPrevious\", \"previousLabel\", \"labelId\"],\n _excluded2 = [\"ownerState\"],\n _excluded3 = [\"ownerState\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport Typography from '@mui/material/Typography';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport IconButton from '@mui/material/IconButton';\nimport { ArrowLeftIcon, ArrowRightIcon } from \"../../../icons/index.js\";\nimport { getPickersArrowSwitcherUtilityClass } from \"./pickersArrowSwitcherClasses.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst PickersArrowSwitcherRoot = styled('div', {\n name: 'MuiPickersArrowSwitcher',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({\n display: 'flex'\n});\nconst PickersArrowSwitcherSpacer = styled('div', {\n name: 'MuiPickersArrowSwitcher',\n slot: 'Spacer',\n overridesResolver: (props, styles) => styles.spacer\n})(({\n theme\n}) => ({\n width: theme.spacing(3)\n}));\nconst PickersArrowSwitcherButton = styled(IconButton, {\n name: 'MuiPickersArrowSwitcher',\n slot: 'Button',\n overridesResolver: (props, styles) => styles.button\n})({\n variants: [{\n props: {\n hidden: true\n },\n style: {\n visibility: 'hidden'\n }\n }]\n});\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n spacer: ['spacer'],\n button: ['button'],\n previousIconButton: ['previousIconButton'],\n nextIconButton: ['nextIconButton'],\n leftArrowIcon: ['leftArrowIcon'],\n rightArrowIcon: ['rightArrowIcon']\n };\n return composeClasses(slots, getPickersArrowSwitcherUtilityClass, classes);\n};\nexport const PickersArrowSwitcher = /*#__PURE__*/React.forwardRef(function PickersArrowSwitcher(inProps, ref) {\n const isRtl = useRtl();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersArrowSwitcher'\n });\n const {\n children,\n className,\n slots,\n slotProps,\n isNextDisabled,\n isNextHidden,\n onGoToNext,\n nextLabel,\n isPreviousDisabled,\n isPreviousHidden,\n onGoToPrevious,\n previousLabel,\n labelId\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const ownerState = props;\n const classes = useUtilityClasses(ownerState);\n const nextProps = {\n isDisabled: isNextDisabled,\n isHidden: isNextHidden,\n goTo: onGoToNext,\n label: nextLabel\n };\n const previousProps = {\n isDisabled: isPreviousDisabled,\n isHidden: isPreviousHidden,\n goTo: onGoToPrevious,\n label: previousLabel\n };\n const PreviousIconButton = slots?.previousIconButton ?? PickersArrowSwitcherButton;\n const previousIconButtonProps = useSlotProps({\n elementType: PreviousIconButton,\n externalSlotProps: slotProps?.previousIconButton,\n additionalProps: {\n size: 'medium',\n title: previousProps.label,\n 'aria-label': previousProps.label,\n disabled: previousProps.isDisabled,\n edge: 'end',\n onClick: previousProps.goTo\n },\n ownerState: _extends({}, ownerState, {\n hidden: previousProps.isHidden\n }),\n className: clsx(classes.button, classes.previousIconButton)\n });\n const NextIconButton = slots?.nextIconButton ?? PickersArrowSwitcherButton;\n const nextIconButtonProps = useSlotProps({\n elementType: NextIconButton,\n externalSlotProps: slotProps?.nextIconButton,\n additionalProps: {\n size: 'medium',\n title: nextProps.label,\n 'aria-label': nextProps.label,\n disabled: nextProps.isDisabled,\n edge: 'start',\n onClick: nextProps.goTo\n },\n ownerState: _extends({}, ownerState, {\n hidden: nextProps.isHidden\n }),\n className: clsx(classes.button, classes.nextIconButton)\n });\n const LeftArrowIcon = slots?.leftArrowIcon ?? ArrowLeftIcon;\n // The spread is here to avoid this bug mui/material-ui#34056\n const _useSlotProps = useSlotProps({\n elementType: LeftArrowIcon,\n externalSlotProps: slotProps?.leftArrowIcon,\n additionalProps: {\n fontSize: 'inherit'\n },\n ownerState,\n className: classes.leftArrowIcon\n }),\n leftArrowIconProps = _objectWithoutPropertiesLoose(_useSlotProps, _excluded2);\n const RightArrowIcon = slots?.rightArrowIcon ?? ArrowRightIcon;\n // The spread is here to avoid this bug mui/material-ui#34056\n const _useSlotProps2 = useSlotProps({\n elementType: RightArrowIcon,\n externalSlotProps: slotProps?.rightArrowIcon,\n additionalProps: {\n fontSize: 'inherit'\n },\n ownerState,\n className: classes.rightArrowIcon\n }),\n rightArrowIconProps = _objectWithoutPropertiesLoose(_useSlotProps2, _excluded3);\n return /*#__PURE__*/_jsxs(PickersArrowSwitcherRoot, _extends({\n ref: ref,\n className: clsx(classes.root, className),\n ownerState: ownerState\n }, other, {\n children: [/*#__PURE__*/_jsx(PreviousIconButton, _extends({}, previousIconButtonProps, {\n children: isRtl ? /*#__PURE__*/_jsx(RightArrowIcon, _extends({}, rightArrowIconProps)) : /*#__PURE__*/_jsx(LeftArrowIcon, _extends({}, leftArrowIconProps))\n })), children ? /*#__PURE__*/_jsx(Typography, {\n variant: \"subtitle1\",\n component: \"span\",\n id: labelId,\n children: children\n }) : /*#__PURE__*/_jsx(PickersArrowSwitcherSpacer, {\n className: classes.spacer,\n ownerState: ownerState\n }), /*#__PURE__*/_jsx(NextIconButton, _extends({}, nextIconButtonProps, {\n children: isRtl ? /*#__PURE__*/_jsx(LeftArrowIcon, _extends({}, leftArrowIconProps)) : /*#__PURE__*/_jsx(RightArrowIcon, _extends({}, rightArrowIconProps))\n }))]\n }));\n});","export const areViewsEqual = (views, expectedViews) => {\n if (views.length !== expectedViews.length) {\n return false;\n }\n return expectedViews.every(expectedView => views.includes(expectedView));\n};\nexport const applyDefaultViewProps = ({\n openTo,\n defaultOpenTo,\n views,\n defaultViews\n}) => {\n const viewsWithDefault = views ?? defaultViews;\n let openToWithDefault;\n if (openTo != null) {\n openToWithDefault = openTo;\n } else if (viewsWithDefault.includes(defaultOpenTo)) {\n openToWithDefault = defaultOpenTo;\n } else if (viewsWithDefault.length > 0) {\n openToWithDefault = viewsWithDefault[0];\n } else {\n throw new Error('MUI X: The `views` prop must contain at least one view.');\n }\n return {\n views: viewsWithDefault,\n openTo: openToWithDefault\n };\n};","import { areViewsEqual } from \"./views.js\";\nconst timeViews = ['hours', 'minutes', 'seconds'];\nexport const isTimeView = view => timeViews.includes(view);\nexport const isInternalTimeView = view => timeViews.includes(view) || view === 'meridiem';\nexport const getMeridiem = (date, utils) => {\n if (!date) {\n return null;\n }\n return utils.getHours(date) >= 12 ? 'pm' : 'am';\n};\nexport const convertValueToMeridiem = (value, meridiem, ampm) => {\n if (ampm) {\n const currentMeridiem = value >= 12 ? 'pm' : 'am';\n if (currentMeridiem !== meridiem) {\n return meridiem === 'am' ? value - 12 : value + 12;\n }\n }\n return value;\n};\nexport const convertToMeridiem = (time, meridiem, ampm, utils) => {\n const newHoursAmount = convertValueToMeridiem(utils.getHours(time), meridiem, ampm);\n return utils.setHours(time, newHoursAmount);\n};\nexport const getSecondsInDay = (date, utils) => {\n return utils.getHours(date) * 3600 + utils.getMinutes(date) * 60 + utils.getSeconds(date);\n};\nexport const createIsAfterIgnoreDatePart = (disableIgnoringDatePartForTimeValidation, utils) => (dateLeft, dateRight) => {\n if (disableIgnoringDatePartForTimeValidation) {\n return utils.isAfter(dateLeft, dateRight);\n }\n return getSecondsInDay(dateLeft, utils) > getSecondsInDay(dateRight, utils);\n};\nexport const resolveTimeFormat = (utils, {\n format,\n views,\n ampm\n}) => {\n if (format != null) {\n return format;\n }\n const formats = utils.formats;\n if (areViewsEqual(views, ['hours'])) {\n return ampm ? `${formats.hours12h} ${formats.meridiem}` : formats.hours24h;\n }\n if (areViewsEqual(views, ['minutes'])) {\n return formats.minutes;\n }\n if (areViewsEqual(views, ['seconds'])) {\n return formats.seconds;\n }\n if (areViewsEqual(views, ['minutes', 'seconds'])) {\n return `${formats.minutes}:${formats.seconds}`;\n }\n if (areViewsEqual(views, ['hours', 'minutes', 'seconds'])) {\n return ampm ? `${formats.hours12h}:${formats.minutes}:${formats.seconds} ${formats.meridiem}` : `${formats.hours24h}:${formats.minutes}:${formats.seconds}`;\n }\n return ampm ? `${formats.hours12h}:${formats.minutes} ${formats.meridiem}` : `${formats.hours24h}:${formats.minutes}`;\n};","import * as React from 'react';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport { unstable_useControlled as useControlled } from '@mui/utils';\nlet warnedOnceNotValidView = false;\nexport function useViews({\n onChange,\n onViewChange,\n openTo,\n view: inView,\n views,\n autoFocus,\n focusedView: inFocusedView,\n onFocusedViewChange\n}) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnceNotValidView) {\n if (inView != null && !views.includes(inView)) {\n console.warn(`MUI X: \\`view=\"${inView}\"\\` is not a valid prop.`, `It must be an element of \\`views=[\"${views.join('\", \"')}\"]\\`.`);\n warnedOnceNotValidView = true;\n }\n if (inView == null && openTo != null && !views.includes(openTo)) {\n console.warn(`MUI X: \\`openTo=\"${openTo}\"\\` is not a valid prop.`, `It must be an element of \\`views=[\"${views.join('\", \"')}\"]\\`.`);\n warnedOnceNotValidView = true;\n }\n }\n }\n const previousOpenTo = React.useRef(openTo);\n const previousViews = React.useRef(views);\n const defaultView = React.useRef(views.includes(openTo) ? openTo : views[0]);\n const [view, setView] = useControlled({\n name: 'useViews',\n state: 'view',\n controlled: inView,\n default: defaultView.current\n });\n const defaultFocusedView = React.useRef(autoFocus ? view : null);\n const [focusedView, setFocusedView] = useControlled({\n name: 'useViews',\n state: 'focusedView',\n controlled: inFocusedView,\n default: defaultFocusedView.current\n });\n React.useEffect(() => {\n // Update the current view when `openTo` or `views` props change\n if (previousOpenTo.current && previousOpenTo.current !== openTo || previousViews.current && previousViews.current.some(previousView => !views.includes(previousView))) {\n setView(views.includes(openTo) ? openTo : views[0]);\n previousViews.current = views;\n previousOpenTo.current = openTo;\n }\n }, [openTo, setView, view, views]);\n const viewIndex = views.indexOf(view);\n const previousView = views[viewIndex - 1] ?? null;\n const nextView = views[viewIndex + 1] ?? null;\n const handleFocusedViewChange = useEventCallback((viewToFocus, hasFocus) => {\n if (hasFocus) {\n // Focus event\n setFocusedView(viewToFocus);\n } else {\n // Blur event\n setFocusedView(prevFocusedView => viewToFocus === prevFocusedView ? null : prevFocusedView // If false the blur is due to view switching\n );\n }\n onFocusedViewChange?.(viewToFocus, hasFocus);\n });\n const handleChangeView = useEventCallback(newView => {\n // always keep the focused view in sync\n handleFocusedViewChange(newView, true);\n if (newView === view) {\n return;\n }\n setView(newView);\n if (onViewChange) {\n onViewChange(newView);\n }\n });\n const goToNextView = useEventCallback(() => {\n if (nextView) {\n handleChangeView(nextView);\n }\n });\n const setValueAndGoToNextView = useEventCallback((value, currentViewSelectionState, selectedView) => {\n const isSelectionFinishedOnCurrentView = currentViewSelectionState === 'finish';\n const hasMoreViews = selectedView ?\n // handles case like `DateTimePicker`, where a view might return a `finish` selection state\n // but when it's not the final view given all `views` -> overall selection state should be `partial`.\n views.indexOf(selectedView) < views.length - 1 : Boolean(nextView);\n const globalSelectionState = isSelectionFinishedOnCurrentView && hasMoreViews ? 'partial' : currentViewSelectionState;\n onChange(value, globalSelectionState, selectedView);\n // Detects if the selected view is not the active one.\n // Can happen if multiple views are displayed, like in `DesktopDateTimePicker` or `MultiSectionDigitalClock`.\n if (selectedView && selectedView !== view) {\n const nextViewAfterSelected = views[views.indexOf(selectedView) + 1];\n if (nextViewAfterSelected) {\n // move to next view after the selected one\n handleChangeView(nextViewAfterSelected);\n }\n } else if (isSelectionFinishedOnCurrentView) {\n goToNextView();\n }\n });\n return {\n view,\n setView: handleChangeView,\n focusedView,\n setFocusedView: handleFocusedViewChange,\n nextView,\n previousView,\n // Always return up-to-date default view instead of the initial one (i.e. defaultView.current)\n defaultView: views.includes(openTo) ? openTo : views[0],\n goToNextView,\n setValueAndGoToNextView\n };\n}","import * as React from 'react';\nimport { useUtils } from \"./useUtils.js\";\nimport { getMeridiem, convertToMeridiem } from \"../utils/time-utils.js\";\nexport function useNextMonthDisabled(month, {\n disableFuture,\n maxDate,\n timezone\n}) {\n const utils = useUtils();\n return React.useMemo(() => {\n const now = utils.date(undefined, timezone);\n const lastEnabledMonth = utils.startOfMonth(disableFuture && utils.isBefore(now, maxDate) ? now : maxDate);\n return !utils.isAfter(lastEnabledMonth, month);\n }, [disableFuture, maxDate, month, utils, timezone]);\n}\nexport function usePreviousMonthDisabled(month, {\n disablePast,\n minDate,\n timezone\n}) {\n const utils = useUtils();\n return React.useMemo(() => {\n const now = utils.date(undefined, timezone);\n const firstEnabledMonth = utils.startOfMonth(disablePast && utils.isAfter(now, minDate) ? now : minDate);\n return !utils.isBefore(firstEnabledMonth, month);\n }, [disablePast, minDate, month, utils, timezone]);\n}\nexport function useMeridiemMode(date, ampm, onChange, selectionState) {\n const utils = useUtils();\n const meridiemMode = getMeridiem(date, utils);\n const handleMeridiemChange = React.useCallback(mode => {\n const timeWithMeridiem = date == null ? null : convertToMeridiem(date, mode, Boolean(ampm), utils);\n onChange(timeWithMeridiem, selectionState ?? 'partial');\n }, [ampm, date, onChange, selectionState, utils]);\n return {\n meridiemMode,\n handleMeridiemChange\n };\n}","export const DAY_SIZE = 36;\nexport const DAY_MARGIN = 2;\nexport const DIALOG_WIDTH = 320;\nexport const MAX_CALENDAR_HEIGHT = 280;\nexport const VIEW_HEIGHT = 336;\nexport const DIGITAL_CLOCK_VIEW_HEIGHT = 232;\nexport const MULTI_SECTION_CLOCK_SECTION_WIDTH = 48;","import { styled } from '@mui/material/styles';\nimport { DIALOG_WIDTH, VIEW_HEIGHT } from \"../../constants/dimensions.js\";\nexport const PickerViewRoot = styled('div')({\n overflow: 'hidden',\n width: DIALOG_WIDTH,\n maxHeight: VIEW_HEIGHT,\n display: 'flex',\n flexDirection: 'column',\n margin: '0 auto'\n});","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getTimeClockUtilityClass(slot) {\n return generateUtilityClass('MuiTimeClock', slot);\n}\nexport const timeClockClasses = generateUtilityClasses('MuiTimeClock', ['root', 'arrowSwitcher']);","export const CLOCK_WIDTH = 220;\nexport const CLOCK_HOUR_WIDTH = 36;\nconst clockCenter = {\n x: CLOCK_WIDTH / 2,\n y: CLOCK_WIDTH / 2\n};\nconst baseClockPoint = {\n x: clockCenter.x,\n y: 0\n};\nconst cx = baseClockPoint.x - clockCenter.x;\nconst cy = baseClockPoint.y - clockCenter.y;\nconst rad2deg = rad => rad * (180 / Math.PI);\nconst getAngleValue = (step, offsetX, offsetY) => {\n const x = offsetX - clockCenter.x;\n const y = offsetY - clockCenter.y;\n const atan = Math.atan2(cx, cy) - Math.atan2(x, y);\n let deg = rad2deg(atan);\n deg = Math.round(deg / step) * step;\n deg %= 360;\n const value = Math.floor(deg / step) || 0;\n const delta = x ** 2 + y ** 2;\n const distance = Math.sqrt(delta);\n return {\n value,\n distance\n };\n};\nexport const getMinutes = (offsetX, offsetY, step = 1) => {\n const angleStep = step * 6;\n let {\n value\n } = getAngleValue(angleStep, offsetX, offsetY);\n value = value * step % 60;\n return value;\n};\nexport const getHours = (offsetX, offsetY, ampm) => {\n const {\n value,\n distance\n } = getAngleValue(30, offsetX, offsetY);\n let hour = value || 12;\n if (!ampm) {\n if (distance < CLOCK_WIDTH / 2 - CLOCK_HOUR_WIDTH) {\n hour += 12;\n hour %= 24;\n }\n } else {\n hour %= 12;\n }\n return hour;\n};","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getClockPointerUtilityClass(slot) {\n return generateUtilityClass('MuiClockPointer', slot);\n}\nexport const clockPointerClasses = generateUtilityClasses('MuiClockPointer', ['root', 'thumb']);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"className\", \"hasSelected\", \"isInner\", \"type\", \"viewValue\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { CLOCK_WIDTH, CLOCK_HOUR_WIDTH } from \"./shared.js\";\nimport { getClockPointerUtilityClass } from \"./clockPointerClasses.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n thumb: ['thumb']\n };\n return composeClasses(slots, getClockPointerUtilityClass, classes);\n};\nconst ClockPointerRoot = styled('div', {\n name: 'MuiClockPointer',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})(({\n theme\n}) => ({\n width: 2,\n backgroundColor: (theme.vars || theme).palette.primary.main,\n position: 'absolute',\n left: 'calc(50% - 1px)',\n bottom: '50%',\n transformOrigin: 'center bottom 0px',\n variants: [{\n props: {\n shouldAnimate: true\n },\n style: {\n transition: theme.transitions.create(['transform', 'height'])\n }\n }]\n}));\nconst ClockPointerThumb = styled('div', {\n name: 'MuiClockPointer',\n slot: 'Thumb',\n overridesResolver: (_, styles) => styles.thumb\n})(({\n theme\n}) => ({\n width: 4,\n height: 4,\n backgroundColor: (theme.vars || theme).palette.primary.contrastText,\n borderRadius: '50%',\n position: 'absolute',\n top: -21,\n left: `calc(50% - ${CLOCK_HOUR_WIDTH / 2}px)`,\n border: `${(CLOCK_HOUR_WIDTH - 4) / 2}px solid ${(theme.vars || theme).palette.primary.main}`,\n boxSizing: 'content-box',\n variants: [{\n props: {\n hasSelected: true\n },\n style: {\n backgroundColor: (theme.vars || theme).palette.primary.main\n }\n }]\n}));\n\n/**\n * @ignore - internal component.\n */\nexport function ClockPointer(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiClockPointer'\n });\n const {\n className,\n isInner,\n type,\n viewValue\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const previousType = React.useRef(type);\n React.useEffect(() => {\n previousType.current = type;\n }, [type]);\n const ownerState = _extends({}, props, {\n shouldAnimate: previousType.current !== type\n });\n const classes = useUtilityClasses(ownerState);\n const getAngleStyle = () => {\n const max = type === 'hours' ? 12 : 60;\n let angle = 360 / max * viewValue;\n if (type === 'hours' && viewValue > 12) {\n angle -= 360; // round up angle to max 360 degrees\n }\n return {\n height: Math.round((isInner ? 0.26 : 0.4) * CLOCK_WIDTH),\n transform: `rotateZ(${angle}deg)`\n };\n };\n return /*#__PURE__*/_jsx(ClockPointerRoot, _extends({\n style: getAngleStyle(),\n className: clsx(classes.root, className),\n ownerState: ownerState\n }, other, {\n children: /*#__PURE__*/_jsx(ClockPointerThumb, {\n ownerState: ownerState,\n className: classes.thumb\n })\n }));\n}","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getClockUtilityClass(slot) {\n return generateUtilityClass('MuiClock', slot);\n}\nexport const clockClasses = generateUtilityClasses('MuiClock', ['root', 'clock', 'wrapper', 'squareMask', 'pin', 'amButton', 'pmButton', 'meridiemText', 'selected']);","import { areViewsEqual } from \"./views.js\";\nexport const mergeDateAndTime = (utils, dateParam, timeParam) => {\n let mergedDate = dateParam;\n mergedDate = utils.setHours(mergedDate, utils.getHours(timeParam));\n mergedDate = utils.setMinutes(mergedDate, utils.getMinutes(timeParam));\n mergedDate = utils.setSeconds(mergedDate, utils.getSeconds(timeParam));\n mergedDate = utils.setMilliseconds(mergedDate, utils.getMilliseconds(timeParam));\n return mergedDate;\n};\nexport const findClosestEnabledDate = ({\n date,\n disableFuture,\n disablePast,\n maxDate,\n minDate,\n isDateDisabled,\n utils,\n timezone\n}) => {\n const today = mergeDateAndTime(utils, utils.date(undefined, timezone), date);\n if (disablePast && utils.isBefore(minDate, today)) {\n minDate = today;\n }\n if (disableFuture && utils.isAfter(maxDate, today)) {\n maxDate = today;\n }\n let forward = date;\n let backward = date;\n if (utils.isBefore(date, minDate)) {\n forward = minDate;\n backward = null;\n }\n if (utils.isAfter(date, maxDate)) {\n if (backward) {\n backward = maxDate;\n }\n forward = null;\n }\n while (forward || backward) {\n if (forward && utils.isAfter(forward, maxDate)) {\n forward = null;\n }\n if (backward && utils.isBefore(backward, minDate)) {\n backward = null;\n }\n if (forward) {\n if (!isDateDisabled(forward)) {\n return forward;\n }\n forward = utils.addDays(forward, 1);\n }\n if (backward) {\n if (!isDateDisabled(backward)) {\n return backward;\n }\n backward = utils.addDays(backward, -1);\n }\n }\n return null;\n};\nexport const replaceInvalidDateByNull = (utils, value) => value == null || !utils.isValid(value) ? null : value;\nexport const applyDefaultDate = (utils, value, defaultValue) => {\n if (value == null || !utils.isValid(value)) {\n return defaultValue;\n }\n return value;\n};\nexport const areDatesEqual = (utils, a, b) => {\n if (!utils.isValid(a) && a != null && !utils.isValid(b) && b != null) {\n return true;\n }\n return utils.isEqual(a, b);\n};\nexport const getMonthsInYear = (utils, year) => {\n const firstMonth = utils.startOfYear(year);\n const months = [firstMonth];\n while (months.length < 12) {\n const prevMonth = months[months.length - 1];\n months.push(utils.addMonths(prevMonth, 1));\n }\n return months;\n};\nexport const getTodayDate = (utils, timezone, valueType) => valueType === 'date' ? utils.startOfDay(utils.date(undefined, timezone)) : utils.date(undefined, timezone);\nexport const formatMeridiem = (utils, meridiem) => {\n const date = utils.setHours(utils.date(), meridiem === 'am' ? 2 : 14);\n return utils.format(date, 'meridiem');\n};\nconst dateViews = ['year', 'month', 'day'];\nexport const isDatePickerView = view => dateViews.includes(view);\nexport const resolveDateFormat = (utils, {\n format,\n views\n}, isInToolbar) => {\n if (format != null) {\n return format;\n }\n const formats = utils.formats;\n if (areViewsEqual(views, ['year'])) {\n return formats.year;\n }\n if (areViewsEqual(views, ['month'])) {\n return formats.month;\n }\n if (areViewsEqual(views, ['day'])) {\n return formats.dayOfMonth;\n }\n if (areViewsEqual(views, ['month', 'year'])) {\n return `${formats.month} ${formats.year}`;\n }\n if (areViewsEqual(views, ['day', 'month'])) {\n return `${formats.month} ${formats.dayOfMonth}`;\n }\n if (isInToolbar) {\n // Little localization hack (Google is doing the same for android native pickers):\n // For english localization it is convenient to include weekday into the date \"Mon, Jun 1\".\n // For other locales using strings like \"June 1\", without weekday.\n return /en/.test(utils.getCurrentLocaleCode()) ? formats.normalDateWithWeekday : formats.normalDate;\n }\n return formats.keyboardDate;\n};\nexport const getWeekdays = (utils, date) => {\n const start = utils.startOfWeek(date);\n return [0, 1, 2, 3, 4, 5, 6].map(diff => utils.addDays(start, diff));\n};","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport IconButton from '@mui/material/IconButton';\nimport Typography from '@mui/material/Typography';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { unstable_useEnhancedEffect as useEnhancedEffect, unstable_composeClasses as composeClasses } from '@mui/utils';\nimport { ClockPointer } from \"./ClockPointer.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { CLOCK_HOUR_WIDTH, getHours, getMinutes } from \"./shared.js\";\nimport { getClockUtilityClass } from \"./clockClasses.js\";\nimport { formatMeridiem } from \"../internals/utils/date-utils.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n meridiemMode\n } = ownerState;\n const slots = {\n root: ['root'],\n clock: ['clock'],\n wrapper: ['wrapper'],\n squareMask: ['squareMask'],\n pin: ['pin'],\n amButton: ['amButton', meridiemMode === 'am' && 'selected'],\n pmButton: ['pmButton', meridiemMode === 'pm' && 'selected'],\n meridiemText: ['meridiemText']\n };\n return composeClasses(slots, getClockUtilityClass, classes);\n};\nconst ClockRoot = styled('div', {\n name: 'MuiClock',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})(({\n theme\n}) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n margin: theme.spacing(2)\n}));\nconst ClockClock = styled('div', {\n name: 'MuiClock',\n slot: 'Clock',\n overridesResolver: (_, styles) => styles.clock\n})({\n backgroundColor: 'rgba(0,0,0,.07)',\n borderRadius: '50%',\n height: 220,\n width: 220,\n flexShrink: 0,\n position: 'relative',\n pointerEvents: 'none'\n});\nconst ClockWrapper = styled('div', {\n name: 'MuiClock',\n slot: 'Wrapper',\n overridesResolver: (_, styles) => styles.wrapper\n})({\n '&:focus': {\n outline: 'none'\n }\n});\nconst ClockSquareMask = styled('div', {\n name: 'MuiClock',\n slot: 'SquareMask',\n overridesResolver: (_, styles) => styles.squareMask\n})({\n width: '100%',\n height: '100%',\n position: 'absolute',\n pointerEvents: 'auto',\n outline: 0,\n // Disable scroll capabilities.\n touchAction: 'none',\n userSelect: 'none',\n variants: [{\n props: {\n disabled: false\n },\n style: {\n '@media (pointer: fine)': {\n cursor: 'pointer',\n borderRadius: '50%'\n },\n '&:active': {\n cursor: 'move'\n }\n }\n }]\n});\nconst ClockPin = styled('div', {\n name: 'MuiClock',\n slot: 'Pin',\n overridesResolver: (_, styles) => styles.pin\n})(({\n theme\n}) => ({\n width: 6,\n height: 6,\n borderRadius: '50%',\n backgroundColor: (theme.vars || theme).palette.primary.main,\n position: 'absolute',\n top: '50%',\n left: '50%',\n transform: 'translate(-50%, -50%)'\n}));\nconst meridiemButtonCommonStyles = (theme, meridiemMode) => ({\n zIndex: 1,\n bottom: 8,\n paddingLeft: 4,\n paddingRight: 4,\n width: CLOCK_HOUR_WIDTH,\n variants: [{\n props: {\n meridiemMode\n },\n style: {\n backgroundColor: (theme.vars || theme).palette.primary.main,\n color: (theme.vars || theme).palette.primary.contrastText,\n '&:hover': {\n backgroundColor: (theme.vars || theme).palette.primary.light\n }\n }\n }]\n});\nconst ClockAmButton = styled(IconButton, {\n name: 'MuiClock',\n slot: 'AmButton',\n overridesResolver: (_, styles) => styles.amButton\n})(({\n theme\n}) => _extends({}, meridiemButtonCommonStyles(theme, 'am'), {\n // keeping it here to make TS happy\n position: 'absolute',\n left: 8\n}));\nconst ClockPmButton = styled(IconButton, {\n name: 'MuiClock',\n slot: 'PmButton',\n overridesResolver: (_, styles) => styles.pmButton\n})(({\n theme\n}) => _extends({}, meridiemButtonCommonStyles(theme, 'pm'), {\n // keeping it here to make TS happy\n position: 'absolute',\n right: 8\n}));\nconst ClockMeridiemText = styled(Typography, {\n name: 'MuiClock',\n slot: 'meridiemText',\n overridesResolver: (_, styles) => styles.meridiemText\n})({\n overflow: 'hidden',\n whiteSpace: 'nowrap',\n textOverflow: 'ellipsis'\n});\n\n/**\n * @ignore - internal component.\n */\nexport function Clock(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiClock'\n });\n const {\n ampm,\n ampmInClock,\n autoFocus,\n children,\n value,\n handleMeridiemChange,\n isTimeDisabled,\n meridiemMode,\n minutesStep = 1,\n onChange,\n selectedId,\n type,\n viewValue,\n disabled = false,\n readOnly,\n className\n } = props;\n const ownerState = props;\n const utils = useUtils();\n const translations = usePickersTranslations();\n const isMoving = React.useRef(false);\n const classes = useUtilityClasses(ownerState);\n const isSelectedTimeDisabled = isTimeDisabled(viewValue, type);\n const isPointerInner = !ampm && type === 'hours' && (viewValue < 1 || viewValue > 12);\n const handleValueChange = (newValue, isFinish) => {\n if (disabled || readOnly) {\n return;\n }\n if (isTimeDisabled(newValue, type)) {\n return;\n }\n onChange(newValue, isFinish);\n };\n const setTime = (event, isFinish) => {\n let {\n offsetX,\n offsetY\n } = event;\n if (offsetX === undefined) {\n const rect = event.target.getBoundingClientRect();\n offsetX = event.changedTouches[0].clientX - rect.left;\n offsetY = event.changedTouches[0].clientY - rect.top;\n }\n const newSelectedValue = type === 'seconds' || type === 'minutes' ? getMinutes(offsetX, offsetY, minutesStep) : getHours(offsetX, offsetY, Boolean(ampm));\n handleValueChange(newSelectedValue, isFinish);\n };\n const handleTouchSelection = event => {\n isMoving.current = true;\n setTime(event, 'shallow');\n };\n const handleTouchEnd = event => {\n if (isMoving.current) {\n setTime(event, 'finish');\n isMoving.current = false;\n }\n event.preventDefault();\n };\n const handleMouseMove = event => {\n // event.buttons & PRIMARY_MOUSE_BUTTON\n if (event.buttons > 0) {\n setTime(event.nativeEvent, 'shallow');\n }\n };\n const handleMouseUp = event => {\n if (isMoving.current) {\n isMoving.current = false;\n }\n setTime(event.nativeEvent, 'finish');\n };\n const hasSelected = React.useMemo(() => {\n if (type === 'hours') {\n return true;\n }\n return viewValue % 5 === 0;\n }, [type, viewValue]);\n const keyboardControlStep = type === 'minutes' ? minutesStep : 1;\n const listboxRef = React.useRef(null);\n // Since this is rendered when a Popper is opened we can't use passive effects.\n // Focusing in passive effects in Popper causes scroll jump.\n useEnhancedEffect(() => {\n if (autoFocus) {\n // The ref not being resolved would be a bug in MUI.\n listboxRef.current.focus();\n }\n }, [autoFocus]);\n const handleKeyDown = event => {\n // TODO: Why this early exit?\n if (isMoving.current) {\n return;\n }\n switch (event.key) {\n case 'Home':\n // reset both hours and minutes\n handleValueChange(0, 'partial');\n event.preventDefault();\n break;\n case 'End':\n handleValueChange(type === 'minutes' ? 59 : 23, 'partial');\n event.preventDefault();\n break;\n case 'ArrowUp':\n handleValueChange(viewValue + keyboardControlStep, 'partial');\n event.preventDefault();\n break;\n case 'ArrowDown':\n handleValueChange(viewValue - keyboardControlStep, 'partial');\n event.preventDefault();\n break;\n case 'PageUp':\n handleValueChange(viewValue + 5, 'partial');\n event.preventDefault();\n break;\n case 'PageDown':\n handleValueChange(viewValue - 5, 'partial');\n event.preventDefault();\n break;\n case 'Enter':\n case ' ':\n handleValueChange(viewValue, 'finish');\n event.preventDefault();\n break;\n default:\n // do nothing\n }\n };\n return /*#__PURE__*/_jsxs(ClockRoot, {\n className: clsx(classes.root, className),\n children: [/*#__PURE__*/_jsxs(ClockClock, {\n className: classes.clock,\n children: [/*#__PURE__*/_jsx(ClockSquareMask, {\n onTouchMove: handleTouchSelection,\n onTouchStart: handleTouchSelection,\n onTouchEnd: handleTouchEnd,\n onMouseUp: handleMouseUp,\n onMouseMove: handleMouseMove,\n ownerState: {\n disabled\n },\n className: classes.squareMask\n }), !isSelectedTimeDisabled && /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/_jsx(ClockPin, {\n className: classes.pin\n }), value != null && /*#__PURE__*/_jsx(ClockPointer, {\n type: type,\n viewValue: viewValue,\n isInner: isPointerInner,\n hasSelected: hasSelected\n })]\n }), /*#__PURE__*/_jsx(ClockWrapper, {\n \"aria-activedescendant\": selectedId,\n \"aria-label\": translations.clockLabelText(type, value, utils, value == null ? null : utils.format(value, 'fullTime')),\n ref: listboxRef,\n role: \"listbox\",\n onKeyDown: handleKeyDown,\n tabIndex: 0,\n className: classes.wrapper,\n children: children\n })]\n }), ampm && ampmInClock && /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/_jsx(ClockAmButton, {\n onClick: readOnly ? undefined : () => handleMeridiemChange('am'),\n disabled: disabled || meridiemMode === null,\n ownerState: ownerState,\n className: classes.amButton,\n title: formatMeridiem(utils, 'am'),\n children: /*#__PURE__*/_jsx(ClockMeridiemText, {\n variant: \"caption\",\n className: classes.meridiemText,\n children: formatMeridiem(utils, 'am')\n })\n }), /*#__PURE__*/_jsx(ClockPmButton, {\n disabled: disabled || meridiemMode === null,\n onClick: readOnly ? undefined : () => handleMeridiemChange('pm'),\n ownerState: ownerState,\n className: classes.pmButton,\n title: formatMeridiem(utils, 'pm'),\n children: /*#__PURE__*/_jsx(ClockMeridiemText, {\n variant: \"caption\",\n className: classes.meridiemText,\n children: formatMeridiem(utils, 'pm')\n })\n })]\n })]\n });\n}","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getClockNumberUtilityClass(slot) {\n return generateUtilityClass('MuiClockNumber', slot);\n}\nexport const clockNumberClasses = generateUtilityClasses('MuiClockNumber', ['root', 'selected', 'disabled']);","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"className\", \"disabled\", \"index\", \"inner\", \"label\", \"selected\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { CLOCK_WIDTH, CLOCK_HOUR_WIDTH } from \"./shared.js\";\nimport { getClockNumberUtilityClass, clockNumberClasses } from \"./clockNumberClasses.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n selected,\n disabled\n } = ownerState;\n const slots = {\n root: ['root', selected && 'selected', disabled && 'disabled']\n };\n return composeClasses(slots, getClockNumberUtilityClass, classes);\n};\nconst ClockNumberRoot = styled('span', {\n name: 'MuiClockNumber',\n slot: 'Root',\n overridesResolver: (_, styles) => [styles.root, {\n [`&.${clockNumberClasses.disabled}`]: styles.disabled\n }, {\n [`&.${clockNumberClasses.selected}`]: styles.selected\n }]\n})(({\n theme\n}) => ({\n height: CLOCK_HOUR_WIDTH,\n width: CLOCK_HOUR_WIDTH,\n position: 'absolute',\n left: `calc((100% - ${CLOCK_HOUR_WIDTH}px) / 2)`,\n display: 'inline-flex',\n justifyContent: 'center',\n alignItems: 'center',\n borderRadius: '50%',\n color: (theme.vars || theme).palette.text.primary,\n fontFamily: theme.typography.fontFamily,\n '&:focused': {\n backgroundColor: (theme.vars || theme).palette.background.paper\n },\n [`&.${clockNumberClasses.selected}`]: {\n color: (theme.vars || theme).palette.primary.contrastText\n },\n [`&.${clockNumberClasses.disabled}`]: {\n pointerEvents: 'none',\n color: (theme.vars || theme).palette.text.disabled\n },\n variants: [{\n props: {\n inner: true\n },\n style: _extends({}, theme.typography.body2, {\n color: (theme.vars || theme).palette.text.secondary\n })\n }]\n}));\n\n/**\n * @ignore - internal component.\n */\nexport function ClockNumber(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiClockNumber'\n });\n const {\n className,\n disabled,\n index,\n inner,\n label,\n selected\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const ownerState = props;\n const classes = useUtilityClasses(ownerState);\n const angle = index % 12 / 12 * Math.PI * 2 - Math.PI / 2;\n const length = (CLOCK_WIDTH - CLOCK_HOUR_WIDTH - 2) / 2 * (inner ? 0.65 : 1);\n const x = Math.round(Math.cos(angle) * length);\n const y = Math.round(Math.sin(angle) * length);\n return /*#__PURE__*/_jsx(ClockNumberRoot, _extends({\n className: clsx(classes.root, className),\n \"aria-disabled\": disabled ? true : undefined,\n \"aria-selected\": selected ? true : undefined,\n role: \"option\",\n style: {\n transform: `translate(${x}px, ${y + (CLOCK_WIDTH - CLOCK_HOUR_WIDTH) / 2}px`\n },\n ownerState: ownerState\n }, other, {\n children: label\n }));\n}","import * as React from 'react';\nimport { ClockNumber } from \"./ClockNumber.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\n/**\n * @ignore - internal component.\n */\nexport const getHourNumbers = ({\n ampm,\n value,\n getClockNumberText,\n isDisabled,\n selectedId,\n utils\n}) => {\n const currentHours = value ? utils.getHours(value) : null;\n const hourNumbers = [];\n const startHour = ampm ? 1 : 0;\n const endHour = ampm ? 12 : 23;\n const isSelected = hour => {\n if (currentHours === null) {\n return false;\n }\n if (ampm) {\n if (hour === 12) {\n return currentHours === 12 || currentHours === 0;\n }\n return currentHours === hour || currentHours - 12 === hour;\n }\n return currentHours === hour;\n };\n for (let hour = startHour; hour <= endHour; hour += 1) {\n let label = hour.toString();\n if (hour === 0) {\n label = '00';\n }\n const inner = !ampm && (hour === 0 || hour > 12);\n label = utils.formatNumber(label);\n const selected = isSelected(hour);\n hourNumbers.push(/*#__PURE__*/_jsx(ClockNumber, {\n id: selected ? selectedId : undefined,\n index: hour,\n inner: inner,\n selected: selected,\n disabled: isDisabled(hour),\n label: label,\n \"aria-label\": getClockNumberText(label)\n }, hour));\n }\n return hourNumbers;\n};\nexport const getMinutesNumbers = ({\n utils,\n value,\n isDisabled,\n getClockNumberText,\n selectedId\n}) => {\n const f = utils.formatNumber;\n return [[5, f('05')], [10, f('10')], [15, f('15')], [20, f('20')], [25, f('25')], [30, f('30')], [35, f('35')], [40, f('40')], [45, f('45')], [50, f('50')], [55, f('55')], [0, f('00')]].map(([numberValue, label], index) => {\n const selected = numberValue === value;\n return /*#__PURE__*/_jsx(ClockNumber, {\n label: label,\n id: selected ? selectedId : undefined,\n index: index + 1,\n inner: false,\n disabled: isDisabled(numberValue),\n selected: selected,\n \"aria-label\": getClockNumberText(label)\n }, numberValue);\n });\n};","import * as React from 'react';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport useControlled from '@mui/utils/useControlled';\nimport { useUtils } from \"./useUtils.js\";\n/**\n * Hooks making sure that:\n * - The value returned by `onChange` always have the timezone of `props.value` or `props.defaultValue` if defined\n * - The value rendered is always the one from `props.timezone` if defined\n */\nexport const useValueWithTimezone = ({\n timezone: timezoneProp,\n value: valueProp,\n defaultValue,\n referenceDate,\n onChange,\n valueManager\n}) => {\n const utils = useUtils();\n const firstDefaultValue = React.useRef(defaultValue);\n const inputValue = valueProp ?? firstDefaultValue.current ?? valueManager.emptyValue;\n const inputTimezone = React.useMemo(() => valueManager.getTimezone(utils, inputValue), [utils, valueManager, inputValue]);\n const setInputTimezone = useEventCallback(newValue => {\n if (inputTimezone == null) {\n return newValue;\n }\n return valueManager.setTimezone(utils, inputTimezone, newValue);\n });\n let timezoneToRender;\n if (timezoneProp) {\n timezoneToRender = timezoneProp;\n } else if (inputTimezone) {\n timezoneToRender = inputTimezone;\n } else if (referenceDate) {\n timezoneToRender = utils.getTimezone(referenceDate);\n } else {\n timezoneToRender = 'default';\n }\n const valueWithTimezoneToRender = React.useMemo(() => valueManager.setTimezone(utils, timezoneToRender, inputValue), [valueManager, utils, timezoneToRender, inputValue]);\n const handleValueChange = useEventCallback((newValue, ...otherParams) => {\n const newValueWithInputTimezone = setInputTimezone(newValue);\n onChange?.(newValueWithInputTimezone, ...otherParams);\n });\n return {\n value: valueWithTimezoneToRender,\n handleValueChange,\n timezone: timezoneToRender\n };\n};\n\n/**\n * Wrapper around `useControlled` and `useValueWithTimezone`\n */\nexport const useControlledValueWithTimezone = ({\n name,\n timezone: timezoneProp,\n value: valueProp,\n defaultValue,\n referenceDate,\n onChange: onChangeProp,\n valueManager\n}) => {\n const [valueWithInputTimezone, setValue] = useControlled({\n name,\n state: 'value',\n controlled: valueProp,\n default: defaultValue ?? valueManager.emptyValue\n });\n const onChange = useEventCallback((newValue, ...otherParams) => {\n setValue(newValue);\n onChangeProp?.(newValue, ...otherParams);\n });\n return useValueWithTimezone({\n timezone: timezoneProp,\n value: valueWithInputTimezone,\n defaultValue: undefined,\n referenceDate,\n onChange,\n valueManager\n });\n};","import { createIsAfterIgnoreDatePart } from \"./time-utils.js\";\nimport { mergeDateAndTime, getTodayDate } from \"./date-utils.js\";\nexport const SECTION_TYPE_GRANULARITY = {\n year: 1,\n month: 2,\n day: 3,\n hours: 4,\n minutes: 5,\n seconds: 6,\n milliseconds: 7\n};\nexport const getSectionTypeGranularity = sections => Math.max(...sections.map(section => SECTION_TYPE_GRANULARITY[section.type] ?? 1));\nconst roundDate = (utils, granularity, date) => {\n if (granularity === SECTION_TYPE_GRANULARITY.year) {\n return utils.startOfYear(date);\n }\n if (granularity === SECTION_TYPE_GRANULARITY.month) {\n return utils.startOfMonth(date);\n }\n if (granularity === SECTION_TYPE_GRANULARITY.day) {\n return utils.startOfDay(date);\n }\n\n // We don't have startOfHour / startOfMinute / startOfSecond\n let roundedDate = date;\n if (granularity < SECTION_TYPE_GRANULARITY.minutes) {\n roundedDate = utils.setMinutes(roundedDate, 0);\n }\n if (granularity < SECTION_TYPE_GRANULARITY.seconds) {\n roundedDate = utils.setSeconds(roundedDate, 0);\n }\n if (granularity < SECTION_TYPE_GRANULARITY.milliseconds) {\n roundedDate = utils.setMilliseconds(roundedDate, 0);\n }\n return roundedDate;\n};\nexport const getDefaultReferenceDate = ({\n props,\n utils,\n granularity,\n timezone,\n getTodayDate: inGetTodayDate\n}) => {\n let referenceDate = inGetTodayDate ? inGetTodayDate() : roundDate(utils, granularity, getTodayDate(utils, timezone));\n if (props.minDate != null && utils.isAfterDay(props.minDate, referenceDate)) {\n referenceDate = roundDate(utils, granularity, props.minDate);\n }\n if (props.maxDate != null && utils.isBeforeDay(props.maxDate, referenceDate)) {\n referenceDate = roundDate(utils, granularity, props.maxDate);\n }\n const isAfter = createIsAfterIgnoreDatePart(props.disableIgnoringDatePartForTimeValidation ?? false, utils);\n if (props.minTime != null && isAfter(props.minTime, referenceDate)) {\n referenceDate = roundDate(utils, granularity, props.disableIgnoringDatePartForTimeValidation ? props.minTime : mergeDateAndTime(utils, referenceDate, props.minTime));\n }\n if (props.maxTime != null && isAfter(referenceDate, props.maxTime)) {\n referenceDate = roundDate(utils, granularity, props.disableIgnoringDatePartForTimeValidation ? props.maxTime : mergeDateAndTime(utils, referenceDate, props.maxTime));\n }\n return referenceDate;\n};","import { getMonthsInYear } from \"../../utils/date-utils.js\";\nexport const getDateSectionConfigFromFormatToken = (utils, formatToken) => {\n const config = utils.formatTokenMap[formatToken];\n if (config == null) {\n throw new Error([`MUI X: The token \"${formatToken}\" is not supported by the Date and Time Pickers.`, 'Please try using another token or open an issue on https://github.com/mui/mui-x/issues/new/choose if you think it should be supported.'].join('\\n'));\n }\n if (typeof config === 'string') {\n return {\n type: config,\n contentType: config === 'meridiem' ? 'letter' : 'digit',\n maxLength: undefined\n };\n }\n return {\n type: config.sectionType,\n contentType: config.contentType,\n maxLength: config.maxLength\n };\n};\nconst getDeltaFromKeyCode = keyCode => {\n switch (keyCode) {\n case 'ArrowUp':\n return 1;\n case 'ArrowDown':\n return -1;\n case 'PageUp':\n return 5;\n case 'PageDown':\n return -5;\n default:\n return 0;\n }\n};\nexport const getDaysInWeekStr = (utils, format) => {\n const elements = [];\n const now = utils.date(undefined, 'default');\n const startDate = utils.startOfWeek(now);\n const endDate = utils.endOfWeek(now);\n let current = startDate;\n while (utils.isBefore(current, endDate)) {\n elements.push(current);\n current = utils.addDays(current, 1);\n }\n return elements.map(weekDay => utils.formatByString(weekDay, format));\n};\nexport const getLetterEditingOptions = (utils, timezone, sectionType, format) => {\n switch (sectionType) {\n case 'month':\n {\n return getMonthsInYear(utils, utils.date(undefined, timezone)).map(month => utils.formatByString(month, format));\n }\n case 'weekDay':\n {\n return getDaysInWeekStr(utils, format);\n }\n case 'meridiem':\n {\n const now = utils.date(undefined, timezone);\n return [utils.startOfDay(now), utils.endOfDay(now)].map(date => utils.formatByString(date, format));\n }\n default:\n {\n return [];\n }\n }\n};\n\n// This format should be the same on all the adapters\n// If some adapter does not respect this convention, then we will need to hardcode the format on each adapter.\nexport const FORMAT_SECONDS_NO_LEADING_ZEROS = 's';\nconst NON_LOCALIZED_DIGITS = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'];\nexport const getLocalizedDigits = utils => {\n const today = utils.date(undefined);\n const formattedZero = utils.formatByString(utils.setSeconds(today, 0), FORMAT_SECONDS_NO_LEADING_ZEROS);\n if (formattedZero === '0') {\n return NON_LOCALIZED_DIGITS;\n }\n return Array.from({\n length: 10\n }).map((_, index) => utils.formatByString(utils.setSeconds(today, index), FORMAT_SECONDS_NO_LEADING_ZEROS));\n};\nexport const removeLocalizedDigits = (valueStr, localizedDigits) => {\n if (localizedDigits[0] === '0') {\n return valueStr;\n }\n const digits = [];\n let currentFormattedDigit = '';\n for (let i = 0; i < valueStr.length; i += 1) {\n currentFormattedDigit += valueStr[i];\n const matchingDigitIndex = localizedDigits.indexOf(currentFormattedDigit);\n if (matchingDigitIndex > -1) {\n digits.push(matchingDigitIndex.toString());\n currentFormattedDigit = '';\n }\n }\n return digits.join('');\n};\nexport const applyLocalizedDigits = (valueStr, localizedDigits) => {\n if (localizedDigits[0] === '0') {\n return valueStr;\n }\n return valueStr.split('').map(char => localizedDigits[Number(char)]).join('');\n};\nexport const isStringNumber = (valueStr, localizedDigits) => {\n const nonLocalizedValueStr = removeLocalizedDigits(valueStr, localizedDigits);\n // `Number(' ')` returns `0` even if ' ' is not a valid number.\n return nonLocalizedValueStr !== ' ' && !Number.isNaN(Number(nonLocalizedValueStr));\n};\n\n/**\n * Remove the leading zeroes to a digit section value.\n * E.g.: `03` => `3`\n * Warning: Should only be called with non-localized digits. Call `removeLocalizedDigits` with your value if needed.\n */\nexport const cleanLeadingZeros = (valueStr, size) => {\n let cleanValueStr = valueStr;\n\n // Remove the leading zeros\n cleanValueStr = Number(cleanValueStr).toString();\n\n // Add enough leading zeros to fill the section\n while (cleanValueStr.length < size) {\n cleanValueStr = `0${cleanValueStr}`;\n }\n return cleanValueStr;\n};\nexport const cleanDigitSectionValue = (utils, value, sectionBoundaries, localizedDigits, section) => {\n if (process.env.NODE_ENV !== 'production') {\n if (section.type !== 'day' && section.contentType === 'digit-with-letter') {\n throw new Error([`MUI X: The token \"${section.format}\" is a digit format with letter in it.'\n This type of format is only supported for 'day' sections`].join('\\n'));\n }\n }\n if (section.type === 'day' && section.contentType === 'digit-with-letter') {\n const date = utils.setDate(sectionBoundaries.longestMonth, value);\n return utils.formatByString(date, section.format);\n }\n\n // queryValue without leading `0` (`01` => `1`)\n let valueStr = value.toString();\n if (section.hasLeadingZerosInInput) {\n valueStr = cleanLeadingZeros(valueStr, section.maxLength);\n }\n return applyLocalizedDigits(valueStr, localizedDigits);\n};\nexport const adjustSectionValue = (utils, timezone, section, keyCode, sectionsValueBoundaries, localizedDigits, activeDate, stepsAttributes) => {\n const delta = getDeltaFromKeyCode(keyCode);\n const isStart = keyCode === 'Home';\n const isEnd = keyCode === 'End';\n const shouldSetAbsolute = section.value === '' || isStart || isEnd;\n const adjustDigitSection = () => {\n const sectionBoundaries = sectionsValueBoundaries[section.type]({\n currentDate: activeDate,\n format: section.format,\n contentType: section.contentType\n });\n const getCleanValue = value => cleanDigitSectionValue(utils, value, sectionBoundaries, localizedDigits, section);\n const step = section.type === 'minutes' && stepsAttributes?.minutesStep ? stepsAttributes.minutesStep : 1;\n const currentSectionValue = parseInt(removeLocalizedDigits(section.value, localizedDigits), 10);\n let newSectionValueNumber = currentSectionValue + delta * step;\n if (shouldSetAbsolute) {\n if (section.type === 'year' && !isEnd && !isStart) {\n return utils.formatByString(utils.date(undefined, timezone), section.format);\n }\n if (delta > 0 || isStart) {\n newSectionValueNumber = sectionBoundaries.minimum;\n } else {\n newSectionValueNumber = sectionBoundaries.maximum;\n }\n }\n if (newSectionValueNumber % step !== 0) {\n if (delta < 0 || isStart) {\n newSectionValueNumber += step - (step + newSectionValueNumber) % step; // for JS -3 % 5 = -3 (should be 2)\n }\n if (delta > 0 || isEnd) {\n newSectionValueNumber -= newSectionValueNumber % step;\n }\n }\n if (newSectionValueNumber > sectionBoundaries.maximum) {\n return getCleanValue(sectionBoundaries.minimum + (newSectionValueNumber - sectionBoundaries.maximum - 1) % (sectionBoundaries.maximum - sectionBoundaries.minimum + 1));\n }\n if (newSectionValueNumber < sectionBoundaries.minimum) {\n return getCleanValue(sectionBoundaries.maximum - (sectionBoundaries.minimum - newSectionValueNumber - 1) % (sectionBoundaries.maximum - sectionBoundaries.minimum + 1));\n }\n return getCleanValue(newSectionValueNumber);\n };\n const adjustLetterSection = () => {\n const options = getLetterEditingOptions(utils, timezone, section.type, section.format);\n if (options.length === 0) {\n return section.value;\n }\n if (shouldSetAbsolute) {\n if (delta > 0 || isStart) {\n return options[0];\n }\n return options[options.length - 1];\n }\n const currentOptionIndex = options.indexOf(section.value);\n const newOptionIndex = (currentOptionIndex + delta) % options.length;\n const clampedIndex = (newOptionIndex + options.length) % options.length;\n return options[clampedIndex];\n };\n if (section.contentType === 'digit' || section.contentType === 'digit-with-letter') {\n return adjustDigitSection();\n }\n return adjustLetterSection();\n};\nexport const getSectionVisibleValue = (section, target, localizedDigits) => {\n let value = section.value || section.placeholder;\n const hasLeadingZeros = target === 'non-input' ? section.hasLeadingZerosInFormat : section.hasLeadingZerosInInput;\n if (target === 'non-input' && section.hasLeadingZerosInInput && !section.hasLeadingZerosInFormat) {\n value = Number(removeLocalizedDigits(value, localizedDigits)).toString();\n }\n\n // In the input, we add an empty character at the end of each section without leading zeros.\n // This makes sure that `onChange` will always be fired.\n // Otherwise, when your input value equals `1/dd/yyyy` (format `M/DD/YYYY` on DayJs),\n // If you press `1`, on the first section, the new value is also `1/dd/yyyy`,\n // So the browser will not fire the input `onChange`.\n const shouldAddInvisibleSpace = ['input-rtl', 'input-ltr'].includes(target) && section.contentType === 'digit' && !hasLeadingZeros && value.length === 1;\n if (shouldAddInvisibleSpace) {\n value = `${value}\\u200e`;\n }\n if (target === 'input-rtl') {\n value = `\\u2068${value}\\u2069`;\n }\n return value;\n};\nexport const changeSectionValueFormat = (utils, valueStr, currentFormat, newFormat) => {\n if (process.env.NODE_ENV !== 'production') {\n if (getDateSectionConfigFromFormatToken(utils, currentFormat).type === 'weekDay') {\n throw new Error(\"changeSectionValueFormat doesn't support week day formats\");\n }\n }\n return utils.formatByString(utils.parse(valueStr, currentFormat), newFormat);\n};\nconst isFourDigitYearFormat = (utils, format) => utils.formatByString(utils.date(undefined, 'system'), format).length === 4;\nexport const doesSectionFormatHaveLeadingZeros = (utils, contentType, sectionType, format) => {\n if (contentType !== 'digit') {\n return false;\n }\n const now = utils.date(undefined, 'default');\n switch (sectionType) {\n // We can't use `changeSectionValueFormat`, because `utils.parse('1', 'YYYY')` returns `1971` instead of `1`.\n case 'year':\n {\n if (isFourDigitYearFormat(utils, format)) {\n const formatted0001 = utils.formatByString(utils.setYear(now, 1), format);\n return formatted0001 === '0001';\n }\n const formatted2001 = utils.formatByString(utils.setYear(now, 2001), format);\n return formatted2001 === '01';\n }\n case 'month':\n {\n return utils.formatByString(utils.startOfYear(now), format).length > 1;\n }\n case 'day':\n {\n return utils.formatByString(utils.startOfMonth(now), format).length > 1;\n }\n case 'weekDay':\n {\n return utils.formatByString(utils.startOfWeek(now), format).length > 1;\n }\n case 'hours':\n {\n return utils.formatByString(utils.setHours(now, 1), format).length > 1;\n }\n case 'minutes':\n {\n return utils.formatByString(utils.setMinutes(now, 1), format).length > 1;\n }\n case 'seconds':\n {\n return utils.formatByString(utils.setSeconds(now, 1), format).length > 1;\n }\n default:\n {\n throw new Error('Invalid section type');\n }\n }\n};\n\n/**\n * Some date libraries like `dayjs` don't support parsing from date with escaped characters.\n * To make sure that the parsing works, we are building a format and a date without any separator.\n */\nexport const getDateFromDateSections = (utils, sections, localizedDigits) => {\n // If we have both a day and a weekDay section,\n // Then we skip the weekDay in the parsing because libraries like dayjs can't parse complicated formats containing a weekDay.\n // dayjs(dayjs().format('dddd MMMM D YYYY'), 'dddd MMMM D YYYY')) // returns `Invalid Date` even if the format is valid.\n const shouldSkipWeekDays = sections.some(section => section.type === 'day');\n const sectionFormats = [];\n const sectionValues = [];\n for (let i = 0; i < sections.length; i += 1) {\n const section = sections[i];\n const shouldSkip = shouldSkipWeekDays && section.type === 'weekDay';\n if (!shouldSkip) {\n sectionFormats.push(section.format);\n sectionValues.push(getSectionVisibleValue(section, 'non-input', localizedDigits));\n }\n }\n const formatWithoutSeparator = sectionFormats.join(' ');\n const dateWithoutSeparatorStr = sectionValues.join(' ');\n return utils.parse(dateWithoutSeparatorStr, formatWithoutSeparator);\n};\nexport const createDateStrForV7HiddenInputFromSections = sections => sections.map(section => {\n return `${section.startSeparator}${section.value || section.placeholder}${section.endSeparator}`;\n}).join('');\nexport const createDateStrForV6InputFromSections = (sections, localizedDigits, isRtl) => {\n const formattedSections = sections.map(section => {\n const dateValue = getSectionVisibleValue(section, isRtl ? 'input-rtl' : 'input-ltr', localizedDigits);\n return `${section.startSeparator}${dateValue}${section.endSeparator}`;\n });\n const dateStr = formattedSections.join('');\n if (!isRtl) {\n return dateStr;\n }\n\n // \\u2066: start left-to-right isolation\n // \\u2067: start right-to-left isolation\n // \\u2068: start first strong character isolation\n // \\u2069: pop isolation\n // wrap into an isolated group such that separators can split the string in smaller ones by adding \\u2069\\u2068\n return `\\u2066${dateStr}\\u2069`;\n};\nexport const getSectionsBoundaries = (utils, localizedDigits, timezone) => {\n const today = utils.date(undefined, timezone);\n const endOfYear = utils.endOfYear(today);\n const endOfDay = utils.endOfDay(today);\n const {\n maxDaysInMonth,\n longestMonth\n } = getMonthsInYear(utils, today).reduce((acc, month) => {\n const daysInMonth = utils.getDaysInMonth(month);\n if (daysInMonth > acc.maxDaysInMonth) {\n return {\n maxDaysInMonth: daysInMonth,\n longestMonth: month\n };\n }\n return acc;\n }, {\n maxDaysInMonth: 0,\n longestMonth: null\n });\n return {\n year: ({\n format\n }) => ({\n minimum: 0,\n maximum: isFourDigitYearFormat(utils, format) ? 9999 : 99\n }),\n month: () => ({\n minimum: 1,\n // Assumption: All years have the same amount of months\n maximum: utils.getMonth(endOfYear) + 1\n }),\n day: ({\n currentDate\n }) => ({\n minimum: 1,\n maximum: currentDate != null && utils.isValid(currentDate) ? utils.getDaysInMonth(currentDate) : maxDaysInMonth,\n longestMonth: longestMonth\n }),\n weekDay: ({\n format,\n contentType\n }) => {\n if (contentType === 'digit') {\n const daysInWeek = getDaysInWeekStr(utils, format).map(Number);\n return {\n minimum: Math.min(...daysInWeek),\n maximum: Math.max(...daysInWeek)\n };\n }\n return {\n minimum: 1,\n maximum: 7\n };\n },\n hours: ({\n format\n }) => {\n const lastHourInDay = utils.getHours(endOfDay);\n const hasMeridiem = removeLocalizedDigits(utils.formatByString(utils.endOfDay(today), format), localizedDigits) !== lastHourInDay.toString();\n if (hasMeridiem) {\n return {\n minimum: 1,\n maximum: Number(removeLocalizedDigits(utils.formatByString(utils.startOfDay(today), format), localizedDigits))\n };\n }\n return {\n minimum: 0,\n maximum: lastHourInDay\n };\n },\n minutes: () => ({\n minimum: 0,\n // Assumption: All years have the same amount of minutes\n maximum: utils.getMinutes(endOfDay)\n }),\n seconds: () => ({\n minimum: 0,\n // Assumption: All years have the same amount of seconds\n maximum: utils.getSeconds(endOfDay)\n }),\n meridiem: () => ({\n minimum: 0,\n maximum: 1\n }),\n empty: () => ({\n minimum: 0,\n maximum: 0\n })\n };\n};\nlet warnedOnceInvalidSection = false;\nexport const validateSections = (sections, valueType) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnceInvalidSection) {\n const supportedSections = ['empty'];\n if (['date', 'date-time'].includes(valueType)) {\n supportedSections.push('weekDay', 'day', 'month', 'year');\n }\n if (['time', 'date-time'].includes(valueType)) {\n supportedSections.push('hours', 'minutes', 'seconds', 'meridiem');\n }\n const invalidSection = sections.find(section => !supportedSections.includes(section.type));\n if (invalidSection) {\n console.warn(`MUI X: The field component you are using is not compatible with the \"${invalidSection.type}\" date section.`, `The supported date sections are [\"${supportedSections.join('\", \"')}\"]\\`.`);\n warnedOnceInvalidSection = true;\n }\n }\n }\n};\nconst transferDateSectionValue = (utils, section, dateToTransferFrom, dateToTransferTo) => {\n switch (section.type) {\n case 'year':\n {\n return utils.setYear(dateToTransferTo, utils.getYear(dateToTransferFrom));\n }\n case 'month':\n {\n return utils.setMonth(dateToTransferTo, utils.getMonth(dateToTransferFrom));\n }\n case 'weekDay':\n {\n const formattedDaysInWeek = getDaysInWeekStr(utils, section.format);\n const dayInWeekStrOfActiveDate = utils.formatByString(dateToTransferFrom, section.format);\n const dayInWeekOfActiveDate = formattedDaysInWeek.indexOf(dayInWeekStrOfActiveDate);\n const dayInWeekOfNewSectionValue = formattedDaysInWeek.indexOf(section.value);\n const diff = dayInWeekOfNewSectionValue - dayInWeekOfActiveDate;\n return utils.addDays(dateToTransferFrom, diff);\n }\n case 'day':\n {\n return utils.setDate(dateToTransferTo, utils.getDate(dateToTransferFrom));\n }\n case 'meridiem':\n {\n const isAM = utils.getHours(dateToTransferFrom) < 12;\n const mergedDateHours = utils.getHours(dateToTransferTo);\n if (isAM && mergedDateHours >= 12) {\n return utils.addHours(dateToTransferTo, -12);\n }\n if (!isAM && mergedDateHours < 12) {\n return utils.addHours(dateToTransferTo, 12);\n }\n return dateToTransferTo;\n }\n case 'hours':\n {\n return utils.setHours(dateToTransferTo, utils.getHours(dateToTransferFrom));\n }\n case 'minutes':\n {\n return utils.setMinutes(dateToTransferTo, utils.getMinutes(dateToTransferFrom));\n }\n case 'seconds':\n {\n return utils.setSeconds(dateToTransferTo, utils.getSeconds(dateToTransferFrom));\n }\n default:\n {\n return dateToTransferTo;\n }\n }\n};\nconst reliableSectionModificationOrder = {\n year: 1,\n month: 2,\n day: 3,\n weekDay: 4,\n hours: 5,\n minutes: 6,\n seconds: 7,\n meridiem: 8,\n empty: 9\n};\nexport const mergeDateIntoReferenceDate = (utils, dateToTransferFrom, sections, referenceDate, shouldLimitToEditedSections) =>\n// cloning sections before sort to avoid mutating it\n[...sections].sort((a, b) => reliableSectionModificationOrder[a.type] - reliableSectionModificationOrder[b.type]).reduce((mergedDate, section) => {\n if (!shouldLimitToEditedSections || section.modified) {\n return transferDateSectionValue(utils, section, dateToTransferFrom, mergedDate);\n }\n return mergedDate;\n}, referenceDate);\nexport const isAndroid = () => navigator.userAgent.toLowerCase().includes('android');\n\n// TODO v8: Remove if we drop the v6 TextField approach.\nexport const getSectionOrder = (sections, shouldApplyRTL) => {\n const neighbors = {};\n if (!shouldApplyRTL) {\n sections.forEach((_, index) => {\n const leftIndex = index === 0 ? null : index - 1;\n const rightIndex = index === sections.length - 1 ? null : index + 1;\n neighbors[index] = {\n leftIndex,\n rightIndex\n };\n });\n return {\n neighbors,\n startIndex: 0,\n endIndex: sections.length - 1\n };\n }\n const rtl2ltr = {};\n const ltr2rtl = {};\n let groupedSectionsStart = 0;\n let groupedSectionsEnd = 0;\n let RTLIndex = sections.length - 1;\n while (RTLIndex >= 0) {\n groupedSectionsEnd = sections.findIndex(\n // eslint-disable-next-line @typescript-eslint/no-loop-func\n (section, index) => index >= groupedSectionsStart && section.endSeparator?.includes(' ') &&\n // Special case where the spaces were not there in the initial input\n section.endSeparator !== ' / ');\n if (groupedSectionsEnd === -1) {\n groupedSectionsEnd = sections.length - 1;\n }\n for (let i = groupedSectionsEnd; i >= groupedSectionsStart; i -= 1) {\n ltr2rtl[i] = RTLIndex;\n rtl2ltr[RTLIndex] = i;\n RTLIndex -= 1;\n }\n groupedSectionsStart = groupedSectionsEnd + 1;\n }\n sections.forEach((_, index) => {\n const rtlIndex = ltr2rtl[index];\n const leftIndex = rtlIndex === 0 ? null : rtl2ltr[rtlIndex - 1];\n const rightIndex = rtlIndex === sections.length - 1 ? null : rtl2ltr[rtlIndex + 1];\n neighbors[index] = {\n leftIndex,\n rightIndex\n };\n });\n return {\n neighbors,\n startIndex: rtl2ltr[0],\n endIndex: rtl2ltr[sections.length - 1]\n };\n};\nexport const parseSelectedSections = (selectedSections, sections) => {\n if (selectedSections == null) {\n return null;\n }\n if (selectedSections === 'all') {\n return 'all';\n }\n if (typeof selectedSections === 'string') {\n const index = sections.findIndex(section => section.type === selectedSections);\n return index === -1 ? null : index;\n }\n return selectedSections;\n};\nexport const getSectionValueText = (section, utils) => {\n if (!section.value) {\n return undefined;\n }\n switch (section.type) {\n case 'month':\n {\n if (section.contentType === 'digit') {\n return utils.format(utils.setMonth(utils.date(), Number(section.value) - 1), 'month');\n }\n const parsedDate = utils.parse(section.value, section.format);\n return parsedDate ? utils.format(parsedDate, 'month') : undefined;\n }\n case 'day':\n return section.contentType === 'digit' ? utils.format(utils.setDate(utils.startOfYear(utils.date()), Number(section.value)), 'dayOfMonthFull') : section.value;\n case 'weekDay':\n // TODO: improve by providing the label of the week day\n return undefined;\n default:\n return undefined;\n }\n};\nexport const getSectionValueNow = (section, utils) => {\n if (!section.value) {\n return undefined;\n }\n switch (section.type) {\n case 'weekDay':\n {\n if (section.contentType === 'letter') {\n // TODO: improve by resolving the week day number from a letter week day\n return undefined;\n }\n return Number(section.value);\n }\n case 'meridiem':\n {\n const parsedDate = utils.parse(`01:00 ${section.value}`, `${utils.formats.hours12h}:${utils.formats.minutes} ${section.format}`);\n if (parsedDate) {\n return utils.getHours(parsedDate) >= 12 ? 1 : 0;\n }\n return undefined;\n }\n case 'day':\n return section.contentType === 'digit-with-letter' ? parseInt(section.value, 10) : Number(section.value);\n case 'month':\n {\n if (section.contentType === 'digit') {\n return Number(section.value);\n }\n const parsedDate = utils.parse(section.value, section.format);\n return parsedDate ? utils.getMonth(parsedDate) + 1 : undefined;\n }\n default:\n return section.contentType !== 'letter' ? Number(section.value) : undefined;\n }\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"value\", \"referenceDate\"];\nimport { areDatesEqual, getTodayDate, replaceInvalidDateByNull } from \"./date-utils.js\";\nimport { getDefaultReferenceDate } from \"./getDefaultReferenceDate.js\";\nimport { createDateStrForV7HiddenInputFromSections, createDateStrForV6InputFromSections } from \"../hooks/useField/useField.utils.js\";\nexport const singleItemValueManager = {\n emptyValue: null,\n getTodayValue: getTodayDate,\n getInitialReferenceValue: _ref => {\n let {\n value,\n referenceDate\n } = _ref,\n params = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (value != null && params.utils.isValid(value)) {\n return value;\n }\n if (referenceDate != null) {\n return referenceDate;\n }\n return getDefaultReferenceDate(params);\n },\n cleanValue: replaceInvalidDateByNull,\n areValuesEqual: areDatesEqual,\n isSameError: (a, b) => a === b,\n hasError: error => error != null,\n defaultErrorState: null,\n getTimezone: (utils, value) => value == null || !utils.isValid(value) ? null : utils.getTimezone(value),\n setTimezone: (utils, timezone, value) => value == null ? null : utils.setTimezone(value, timezone)\n};\nexport const singleItemFieldValueManager = {\n updateReferenceValue: (utils, value, prevReferenceValue) => value == null || !utils.isValid(value) ? prevReferenceValue : value,\n getSectionsFromValue: (utils, date, prevSections, getSectionsFromDate) => {\n const shouldReUsePrevDateSections = !utils.isValid(date) && !!prevSections;\n if (shouldReUsePrevDateSections) {\n return prevSections;\n }\n return getSectionsFromDate(date);\n },\n getV7HiddenInputValueFromSections: createDateStrForV7HiddenInputFromSections,\n getV6InputValueFromSections: createDateStrForV6InputFromSections,\n getActiveDateManager: (utils, state) => ({\n date: state.value,\n referenceDate: state.referenceValue,\n getSections: sections => sections,\n getNewValuesFromNewActiveDate: newActiveDate => ({\n value: newActiveDate,\n referenceValue: newActiveDate == null || !utils.isValid(newActiveDate) ? state.referenceValue : newActiveDate\n })\n }),\n parseValueStr: (valueStr, referenceValue, parseDate) => parseDate(valueStr.trim(), referenceValue)\n};","import * as React from 'react';\nimport { singleItemValueManager } from \"../utils/valueManagers.js\";\nimport { getTodayDate } from \"../utils/date-utils.js\";\nimport { SECTION_TYPE_GRANULARITY } from \"../utils/getDefaultReferenceDate.js\";\nexport const useClockReferenceDate = ({\n value,\n referenceDate: referenceDateProp,\n utils,\n props,\n timezone\n}) => {\n const referenceDate = React.useMemo(() => singleItemValueManager.getInitialReferenceValue({\n value,\n utils,\n props,\n referenceDate: referenceDateProp,\n granularity: SECTION_TYPE_GRANULARITY.day,\n timezone,\n getTodayDate: () => getTodayDate(utils, timezone, 'date')\n }),\n // We only want to compute the reference date on mount.\n [] // eslint-disable-line react-hooks/exhaustive-deps\n );\n return value ?? referenceDate;\n};","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ampm\", \"ampmInClock\", \"autoFocus\", \"slots\", \"slotProps\", \"value\", \"defaultValue\", \"referenceDate\", \"disableIgnoringDatePartForTimeValidation\", \"maxTime\", \"minTime\", \"disableFuture\", \"disablePast\", \"minutesStep\", \"shouldDisableTime\", \"showViewSwitcher\", \"onChange\", \"view\", \"views\", \"openTo\", \"onViewChange\", \"focusedView\", \"onFocusedViewChange\", \"className\", \"disabled\", \"readOnly\", \"timezone\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport PropTypes from 'prop-types';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { unstable_composeClasses as composeClasses, unstable_useId as useId } from '@mui/utils';\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils, useNow } from \"../internals/hooks/useUtils.js\";\nimport { PickersArrowSwitcher } from \"../internals/components/PickersArrowSwitcher/index.js\";\nimport { convertValueToMeridiem, createIsAfterIgnoreDatePart } from \"../internals/utils/time-utils.js\";\nimport { useViews } from \"../internals/hooks/useViews.js\";\nimport { useMeridiemMode } from \"../internals/hooks/date-helpers-hooks.js\";\nimport { PickerViewRoot } from \"../internals/components/PickerViewRoot/index.js\";\nimport { getTimeClockUtilityClass } from \"./timeClockClasses.js\";\nimport { Clock } from \"./Clock.js\";\nimport { getHourNumbers, getMinutesNumbers } from \"./ClockNumbers.js\";\nimport { useControlledValueWithTimezone } from \"../internals/hooks/useValueWithTimezone.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { useClockReferenceDate } from \"../internals/hooks/useClockReferenceDate.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n arrowSwitcher: ['arrowSwitcher']\n };\n return composeClasses(slots, getTimeClockUtilityClass, classes);\n};\nconst TimeClockRoot = styled(PickerViewRoot, {\n name: 'MuiTimeClock',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({\n display: 'flex',\n flexDirection: 'column',\n position: 'relative'\n});\nconst TimeClockArrowSwitcher = styled(PickersArrowSwitcher, {\n name: 'MuiTimeClock',\n slot: 'ArrowSwitcher',\n overridesResolver: (props, styles) => styles.arrowSwitcher\n})({\n position: 'absolute',\n right: 12,\n top: 15\n});\nconst TIME_CLOCK_DEFAULT_VIEWS = ['hours', 'minutes'];\n\n/**\n * Demos:\n *\n * - [TimePicker](https://mui.com/x/react-date-pickers/time-picker/)\n * - [TimeClock](https://mui.com/x/react-date-pickers/time-clock/)\n *\n * API:\n *\n * - [TimeClock API](https://mui.com/x/api/date-pickers/time-clock/)\n */\nexport const TimeClock = /*#__PURE__*/React.forwardRef(function TimeClock(inProps, ref) {\n const utils = useUtils();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTimeClock'\n });\n const {\n ampm = utils.is12HourCycleInCurrentLocale(),\n ampmInClock = false,\n autoFocus,\n slots,\n slotProps,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n disableIgnoringDatePartForTimeValidation = false,\n maxTime,\n minTime,\n disableFuture,\n disablePast,\n minutesStep = 1,\n shouldDisableTime,\n showViewSwitcher,\n onChange,\n view: inView,\n views = TIME_CLOCK_DEFAULT_VIEWS,\n openTo,\n onViewChange,\n focusedView,\n onFocusedViewChange,\n className,\n disabled,\n readOnly,\n timezone: timezoneProp\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const {\n value,\n handleValueChange,\n timezone\n } = useControlledValueWithTimezone({\n name: 'TimeClock',\n timezone: timezoneProp,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n onChange,\n valueManager: singleItemValueManager\n });\n const valueOrReferenceDate = useClockReferenceDate({\n value,\n referenceDate: referenceDateProp,\n utils,\n props,\n timezone\n });\n const translations = usePickersTranslations();\n const now = useNow(timezone);\n const {\n view,\n setView,\n previousView,\n nextView,\n setValueAndGoToNextView\n } = useViews({\n view: inView,\n views,\n openTo,\n onViewChange,\n onChange: handleValueChange,\n focusedView,\n onFocusedViewChange\n });\n const {\n meridiemMode,\n handleMeridiemChange\n } = useMeridiemMode(valueOrReferenceDate, ampm, setValueAndGoToNextView);\n const isTimeDisabled = React.useCallback((rawValue, viewType) => {\n const isAfter = createIsAfterIgnoreDatePart(disableIgnoringDatePartForTimeValidation, utils);\n const shouldCheckPastEnd = viewType === 'hours' || viewType === 'minutes' && views.includes('seconds');\n const containsValidTime = ({\n start,\n end\n }) => {\n if (minTime && isAfter(minTime, end)) {\n return false;\n }\n if (maxTime && isAfter(start, maxTime)) {\n return false;\n }\n if (disableFuture && isAfter(start, now)) {\n return false;\n }\n if (disablePast && isAfter(now, shouldCheckPastEnd ? end : start)) {\n return false;\n }\n return true;\n };\n const isValidValue = (timeValue, step = 1) => {\n if (timeValue % step !== 0) {\n return false;\n }\n if (shouldDisableTime) {\n switch (viewType) {\n case 'hours':\n return !shouldDisableTime(utils.setHours(valueOrReferenceDate, timeValue), 'hours');\n case 'minutes':\n return !shouldDisableTime(utils.setMinutes(valueOrReferenceDate, timeValue), 'minutes');\n case 'seconds':\n return !shouldDisableTime(utils.setSeconds(valueOrReferenceDate, timeValue), 'seconds');\n default:\n return false;\n }\n }\n return true;\n };\n switch (viewType) {\n case 'hours':\n {\n const valueWithMeridiem = convertValueToMeridiem(rawValue, meridiemMode, ampm);\n const dateWithNewHours = utils.setHours(valueOrReferenceDate, valueWithMeridiem);\n const start = utils.setSeconds(utils.setMinutes(dateWithNewHours, 0), 0);\n const end = utils.setSeconds(utils.setMinutes(dateWithNewHours, 59), 59);\n return !containsValidTime({\n start,\n end\n }) || !isValidValue(valueWithMeridiem);\n }\n case 'minutes':\n {\n const dateWithNewMinutes = utils.setMinutes(valueOrReferenceDate, rawValue);\n const start = utils.setSeconds(dateWithNewMinutes, 0);\n const end = utils.setSeconds(dateWithNewMinutes, 59);\n return !containsValidTime({\n start,\n end\n }) || !isValidValue(rawValue, minutesStep);\n }\n case 'seconds':\n {\n const dateWithNewSeconds = utils.setSeconds(valueOrReferenceDate, rawValue);\n const start = dateWithNewSeconds;\n const end = dateWithNewSeconds;\n return !containsValidTime({\n start,\n end\n }) || !isValidValue(rawValue);\n }\n default:\n throw new Error('not supported');\n }\n }, [ampm, valueOrReferenceDate, disableIgnoringDatePartForTimeValidation, maxTime, meridiemMode, minTime, minutesStep, shouldDisableTime, utils, disableFuture, disablePast, now, views]);\n const selectedId = useId();\n const viewProps = React.useMemo(() => {\n switch (view) {\n case 'hours':\n {\n const handleHoursChange = (hourValue, isFinish) => {\n const valueWithMeridiem = convertValueToMeridiem(hourValue, meridiemMode, ampm);\n setValueAndGoToNextView(utils.setHours(valueOrReferenceDate, valueWithMeridiem), isFinish, 'hours');\n };\n return {\n onChange: handleHoursChange,\n viewValue: utils.getHours(valueOrReferenceDate),\n children: getHourNumbers({\n value,\n utils,\n ampm,\n onChange: handleHoursChange,\n getClockNumberText: translations.hoursClockNumberText,\n isDisabled: hourValue => disabled || isTimeDisabled(hourValue, 'hours'),\n selectedId\n })\n };\n }\n case 'minutes':\n {\n const minutesValue = utils.getMinutes(valueOrReferenceDate);\n const handleMinutesChange = (minuteValue, isFinish) => {\n setValueAndGoToNextView(utils.setMinutes(valueOrReferenceDate, minuteValue), isFinish, 'minutes');\n };\n return {\n viewValue: minutesValue,\n onChange: handleMinutesChange,\n children: getMinutesNumbers({\n utils,\n value: minutesValue,\n onChange: handleMinutesChange,\n getClockNumberText: translations.minutesClockNumberText,\n isDisabled: minuteValue => disabled || isTimeDisabled(minuteValue, 'minutes'),\n selectedId\n })\n };\n }\n case 'seconds':\n {\n const secondsValue = utils.getSeconds(valueOrReferenceDate);\n const handleSecondsChange = (secondValue, isFinish) => {\n setValueAndGoToNextView(utils.setSeconds(valueOrReferenceDate, secondValue), isFinish, 'seconds');\n };\n return {\n viewValue: secondsValue,\n onChange: handleSecondsChange,\n children: getMinutesNumbers({\n utils,\n value: secondsValue,\n onChange: handleSecondsChange,\n getClockNumberText: translations.secondsClockNumberText,\n isDisabled: secondValue => disabled || isTimeDisabled(secondValue, 'seconds'),\n selectedId\n })\n };\n }\n default:\n throw new Error('You must provide the type for ClockView');\n }\n }, [view, utils, value, ampm, translations.hoursClockNumberText, translations.minutesClockNumberText, translations.secondsClockNumberText, meridiemMode, setValueAndGoToNextView, valueOrReferenceDate, isTimeDisabled, selectedId, disabled]);\n const ownerState = props;\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(TimeClockRoot, _extends({\n ref: ref,\n className: clsx(classes.root, className),\n ownerState: ownerState\n }, other, {\n children: [/*#__PURE__*/_jsx(Clock, _extends({\n autoFocus: autoFocus ?? !!focusedView,\n ampmInClock: ampmInClock && views.includes('hours'),\n value: value,\n type: view,\n ampm: ampm,\n minutesStep: minutesStep,\n isTimeDisabled: isTimeDisabled,\n meridiemMode: meridiemMode,\n handleMeridiemChange: handleMeridiemChange,\n selectedId: selectedId,\n disabled: disabled,\n readOnly: readOnly\n }, viewProps)), showViewSwitcher && /*#__PURE__*/_jsx(TimeClockArrowSwitcher, {\n className: classes.arrowSwitcher,\n slots: slots,\n slotProps: slotProps,\n onGoToPrevious: () => setView(previousView),\n isPreviousDisabled: !previousView,\n previousLabel: translations.openPreviousView,\n onGoToNext: () => setView(nextView),\n isNextDisabled: !nextView,\n nextLabel: translations.openNextView,\n ownerState: ownerState\n })]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? TimeClock.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * Display ampm controls under the clock (instead of in the toolbar).\n * @default false\n */\n ampmInClock: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n /**\n * The default selected value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker views and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * Controlled focused view.\n */\n focusedView: PropTypes.oneOf(['hours', 'minutes', 'seconds']),\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TView The view type. Will be one of date or time views.\n * @param {TValue} value The new value.\n * @param {PickerSelectionState | undefined} selectionState Indicates if the date selection is complete.\n * @param {TView | undefined} selectedView Indicates the view in which the selection has been made.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired on focused view change.\n * @template TView\n * @param {TView} view The new view to focus or not.\n * @param {boolean} hasFocus `true` if the view should be focused.\n */\n onFocusedViewChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['hours', 'minutes', 'seconds']),\n /**\n * If `true`, the picker views and text field are read-only.\n * @default false\n */\n readOnly: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid time using the validation props, except callbacks such as `shouldDisableTime`.\n */\n referenceDate: PropTypes.object,\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n showViewSwitcher: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['hours', 'minutes', 'seconds']),\n /**\n * Available views.\n * @default ['hours', 'minutes']\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['hours', 'minutes', 'seconds']).isRequired)\n} : void 0;","import generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nexport function getDigitalClockUtilityClass(slot) {\n return generateUtilityClass('MuiDigitalClock', slot);\n}\nexport const digitalClockClasses = generateUtilityClasses('MuiDigitalClock', ['root', 'list', 'item']);","/* Use it instead of .includes method for IE support */\nexport function arrayIncludes(array, itemOrItems) {\n if (Array.isArray(itemOrItems)) {\n return itemOrItems.every(item => array.indexOf(item) !== -1);\n }\n return array.indexOf(itemOrItems) !== -1;\n}\nexport const onSpaceOrEnter = (innerFn, externalEvent) => event => {\n if (event.key === 'Enter' || event.key === ' ') {\n innerFn(event);\n\n // prevent any side effects\n event.preventDefault();\n event.stopPropagation();\n }\n if (externalEvent) {\n externalEvent(event);\n }\n};\nexport const executeInTheNextEventLoopTick = fn => {\n setTimeout(fn, 0);\n};\n\n// https://www.abeautifulsite.net/posts/finding-the-active-element-in-a-shadow-root/\nexport const getActiveElement = (root = document) => {\n const activeEl = root.activeElement;\n if (!activeEl) {\n return null;\n }\n if (activeEl.shadowRoot) {\n return getActiveElement(activeEl.shadowRoot);\n }\n return activeEl;\n};\n\n/**\n * Gets the index of the focused list item in a given ul list element.\n *\n * @param {HTMLUListElement} listElement - The list element to search within.\n * @returns {number} The index of the focused list item, or -1 if none is focused.\n */\nexport const getFocusedListItemIndex = listElement => {\n const children = Array.from(listElement.children);\n return children.indexOf(getActiveElement(document));\n};\nexport const DEFAULT_DESKTOP_MODE_MEDIA_QUERY = '@media (pointer: fine)';","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ampm\", \"timeStep\", \"autoFocus\", \"slots\", \"slotProps\", \"value\", \"defaultValue\", \"referenceDate\", \"disableIgnoringDatePartForTimeValidation\", \"maxTime\", \"minTime\", \"disableFuture\", \"disablePast\", \"minutesStep\", \"shouldDisableTime\", \"onChange\", \"view\", \"openTo\", \"onViewChange\", \"focusedView\", \"onFocusedViewChange\", \"className\", \"disabled\", \"readOnly\", \"views\", \"skipDisabled\", \"timezone\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport PropTypes from 'prop-types';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport { alpha, styled, useThemeProps } from '@mui/material/styles';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport composeClasses from '@mui/utils/composeClasses';\nimport MenuItem from '@mui/material/MenuItem';\nimport MenuList from '@mui/material/MenuList';\nimport useForkRef from '@mui/utils/useForkRef';\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils, useNow } from \"../internals/hooks/useUtils.js\";\nimport { createIsAfterIgnoreDatePart } from \"../internals/utils/time-utils.js\";\nimport { PickerViewRoot } from \"../internals/components/PickerViewRoot/index.js\";\nimport { getDigitalClockUtilityClass } from \"./digitalClockClasses.js\";\nimport { useViews } from \"../internals/hooks/useViews.js\";\nimport { DIGITAL_CLOCK_VIEW_HEIGHT } from \"../internals/constants/dimensions.js\";\nimport { useControlledValueWithTimezone } from \"../internals/hooks/useValueWithTimezone.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { useClockReferenceDate } from \"../internals/hooks/useClockReferenceDate.js\";\nimport { getFocusedListItemIndex } from \"../internals/utils/utils.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n list: ['list'],\n item: ['item']\n };\n return composeClasses(slots, getDigitalClockUtilityClass, classes);\n};\nconst DigitalClockRoot = styled(PickerViewRoot, {\n name: 'MuiDigitalClock',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({\n overflowY: 'auto',\n width: '100%',\n '@media (prefers-reduced-motion: no-preference)': {\n scrollBehavior: 'auto'\n },\n maxHeight: DIGITAL_CLOCK_VIEW_HEIGHT,\n variants: [{\n props: {\n alreadyRendered: true\n },\n style: {\n '@media (prefers-reduced-motion: no-preference)': {\n scrollBehavior: 'smooth'\n }\n }\n }]\n});\nconst DigitalClockList = styled(MenuList, {\n name: 'MuiDigitalClock',\n slot: 'List',\n overridesResolver: (props, styles) => styles.list\n})({\n padding: 0\n});\nconst DigitalClockItem = styled(MenuItem, {\n name: 'MuiDigitalClock',\n slot: 'Item',\n overridesResolver: (props, styles) => styles.item\n})(({\n theme\n}) => ({\n padding: '8px 16px',\n margin: '2px 4px',\n '&:first-of-type': {\n marginTop: 4\n },\n '&:hover': {\n backgroundColor: theme.vars ? `rgba(${theme.vars.palette.primary.mainChannel} / ${theme.vars.palette.action.hoverOpacity})` : alpha(theme.palette.primary.main, theme.palette.action.hoverOpacity)\n },\n '&.Mui-selected': {\n backgroundColor: (theme.vars || theme).palette.primary.main,\n color: (theme.vars || theme).palette.primary.contrastText,\n '&:focus-visible, &:hover': {\n backgroundColor: (theme.vars || theme).palette.primary.dark\n }\n },\n '&.Mui-focusVisible': {\n backgroundColor: theme.vars ? `rgba(${theme.vars.palette.primary.mainChannel} / ${theme.vars.palette.action.focusOpacity})` : alpha(theme.palette.primary.main, theme.palette.action.focusOpacity)\n }\n}));\n/**\n * Demos:\n *\n * - [TimePicker](https://mui.com/x/react-date-pickers/time-picker/)\n * - [DigitalClock](https://mui.com/x/react-date-pickers/digital-clock/)\n *\n * API:\n *\n * - [DigitalClock API](https://mui.com/x/api/date-pickers/digital-clock/)\n */\nexport const DigitalClock = /*#__PURE__*/React.forwardRef(function DigitalClock(inProps, ref) {\n const utils = useUtils();\n const containerRef = React.useRef(null);\n const handleRef = useForkRef(ref, containerRef);\n const listRef = React.useRef(null);\n const props = useThemeProps({\n props: inProps,\n name: 'MuiDigitalClock'\n });\n const {\n ampm = utils.is12HourCycleInCurrentLocale(),\n timeStep = 30,\n autoFocus,\n slots,\n slotProps,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n disableIgnoringDatePartForTimeValidation = false,\n maxTime,\n minTime,\n disableFuture,\n disablePast,\n minutesStep = 1,\n shouldDisableTime,\n onChange,\n view: inView,\n openTo,\n onViewChange,\n focusedView,\n onFocusedViewChange,\n className,\n disabled,\n readOnly,\n views = ['hours'],\n skipDisabled = false,\n timezone: timezoneProp\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const {\n value,\n handleValueChange: handleRawValueChange,\n timezone\n } = useControlledValueWithTimezone({\n name: 'DigitalClock',\n timezone: timezoneProp,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n onChange,\n valueManager: singleItemValueManager\n });\n const translations = usePickersTranslations();\n const now = useNow(timezone);\n const ownerState = React.useMemo(() => _extends({}, props, {\n alreadyRendered: !!containerRef.current\n }), [props]);\n const classes = useUtilityClasses(ownerState);\n const ClockItem = slots?.digitalClockItem ?? DigitalClockItem;\n const clockItemProps = useSlotProps({\n elementType: ClockItem,\n externalSlotProps: slotProps?.digitalClockItem,\n ownerState: {},\n className: classes.item\n });\n const valueOrReferenceDate = useClockReferenceDate({\n value,\n referenceDate: referenceDateProp,\n utils,\n props,\n timezone\n });\n const handleValueChange = useEventCallback(newValue => handleRawValueChange(newValue, 'finish', 'hours'));\n const {\n setValueAndGoToNextView\n } = useViews({\n view: inView,\n views,\n openTo,\n onViewChange,\n onChange: handleValueChange,\n focusedView,\n onFocusedViewChange\n });\n const handleItemSelect = useEventCallback(newValue => {\n setValueAndGoToNextView(newValue, 'finish');\n });\n React.useEffect(() => {\n if (containerRef.current === null) {\n return;\n }\n const activeItem = containerRef.current.querySelector('[role=\"listbox\"] [role=\"option\"][tabindex=\"0\"], [role=\"listbox\"] [role=\"option\"][aria-selected=\"true\"]');\n if (!activeItem) {\n return;\n }\n const offsetTop = activeItem.offsetTop;\n if (autoFocus || !!focusedView) {\n activeItem.focus();\n }\n\n // Subtracting the 4px of extra margin intended for the first visible section item\n containerRef.current.scrollTop = offsetTop - 4;\n });\n const isTimeDisabled = React.useCallback(valueToCheck => {\n const isAfter = createIsAfterIgnoreDatePart(disableIgnoringDatePartForTimeValidation, utils);\n const containsValidTime = () => {\n if (minTime && isAfter(minTime, valueToCheck)) {\n return false;\n }\n if (maxTime && isAfter(valueToCheck, maxTime)) {\n return false;\n }\n if (disableFuture && isAfter(valueToCheck, now)) {\n return false;\n }\n if (disablePast && isAfter(now, valueToCheck)) {\n return false;\n }\n return true;\n };\n const isValidValue = () => {\n if (utils.getMinutes(valueToCheck) % minutesStep !== 0) {\n return false;\n }\n if (shouldDisableTime) {\n return !shouldDisableTime(valueToCheck, 'hours');\n }\n return true;\n };\n return !containsValidTime() || !isValidValue();\n }, [disableIgnoringDatePartForTimeValidation, utils, minTime, maxTime, disableFuture, now, disablePast, minutesStep, shouldDisableTime]);\n const timeOptions = React.useMemo(() => {\n const result = [];\n const startOfDay = utils.startOfDay(valueOrReferenceDate);\n let nextTimeStepOption = startOfDay;\n while (utils.isSameDay(valueOrReferenceDate, nextTimeStepOption)) {\n result.push(nextTimeStepOption);\n nextTimeStepOption = utils.addMinutes(nextTimeStepOption, timeStep);\n }\n return result;\n }, [valueOrReferenceDate, timeStep, utils]);\n const focusedOptionIndex = timeOptions.findIndex(option => utils.isEqual(option, valueOrReferenceDate));\n const handleKeyDown = event => {\n switch (event.key) {\n case 'PageUp':\n {\n const newIndex = getFocusedListItemIndex(listRef.current) - 5;\n const children = listRef.current.children;\n const newFocusedIndex = Math.max(0, newIndex);\n const childToFocus = children[newFocusedIndex];\n if (childToFocus) {\n childToFocus.focus();\n }\n event.preventDefault();\n break;\n }\n case 'PageDown':\n {\n const newIndex = getFocusedListItemIndex(listRef.current) + 5;\n const children = listRef.current.children;\n const newFocusedIndex = Math.min(children.length - 1, newIndex);\n const childToFocus = children[newFocusedIndex];\n if (childToFocus) {\n childToFocus.focus();\n }\n event.preventDefault();\n break;\n }\n default:\n }\n };\n return /*#__PURE__*/_jsx(DigitalClockRoot, _extends({\n ref: handleRef,\n className: clsx(classes.root, className),\n ownerState: ownerState\n }, other, {\n children: /*#__PURE__*/_jsx(DigitalClockList, {\n ref: listRef,\n role: \"listbox\",\n \"aria-label\": translations.timePickerToolbarTitle,\n className: classes.list,\n onKeyDown: handleKeyDown,\n children: timeOptions.map((option, index) => {\n if (skipDisabled && isTimeDisabled(option)) {\n return null;\n }\n const isSelected = utils.isEqual(option, value);\n const formattedValue = utils.format(option, ampm ? 'fullTime12h' : 'fullTime24h');\n const tabIndex = focusedOptionIndex === index || focusedOptionIndex === -1 && index === 0 ? 0 : -1;\n return /*#__PURE__*/_jsx(ClockItem, _extends({\n onClick: () => !readOnly && handleItemSelect(option),\n selected: isSelected,\n disabled: disabled || isTimeDisabled(option),\n disableRipple: readOnly,\n role: \"option\"\n // aria-readonly is not supported here and does not have any effect\n ,\n \"aria-disabled\": readOnly,\n \"aria-selected\": isSelected,\n tabIndex: tabIndex\n }, clockItemProps, {\n children: formattedValue\n }), `${option.valueOf()}-${formattedValue}`);\n })\n })\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? DigitalClock.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n /**\n * The default selected value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker views and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * Controlled focused view.\n */\n focusedView: PropTypes.oneOf(['hours']),\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TView The view type. Will be one of date or time views.\n * @param {TValue} value The new value.\n * @param {PickerSelectionState | undefined} selectionState Indicates if the date selection is complete.\n * @param {TView | undefined} selectedView Indicates the view in which the selection has been made.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired on focused view change.\n * @template TView\n * @param {TView} view The new view to focus or not.\n * @param {boolean} hasFocus `true` if the view should be focused.\n */\n onFocusedViewChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['hours']),\n /**\n * If `true`, the picker views and text field are read-only.\n * @default false\n */\n readOnly: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid time using the validation props, except callbacks such as `shouldDisableTime`.\n */\n referenceDate: PropTypes.object,\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * If `true`, disabled digital clock items will not be rendered.\n * @default false\n */\n skipDisabled: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overrideable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * The time steps between two time options.\n * For example, if `timeStep = 45`, then the available time options will be `[00:00, 00:45, 01:30, 02:15, 03:00, etc.]`.\n * @default 30\n */\n timeStep: PropTypes.number,\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['hours']),\n /**\n * Available views.\n * @default ['hours']\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['hours']))\n} : void 0;","import generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nexport function getMultiSectionDigitalClockUtilityClass(slot) {\n return generateUtilityClass('MuiMultiSectionDigitalClock', slot);\n}\nexport const multiSectionDigitalClockClasses = generateUtilityClasses('MuiMultiSectionDigitalClock', ['root']);","import generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nexport function getMultiSectionDigitalClockSectionUtilityClass(slot) {\n return generateUtilityClass('MuiMultiSectionDigitalClockSection', slot);\n}\nexport const multiSectionDigitalClockSectionClasses = generateUtilityClasses('MuiMultiSectionDigitalClockSection', ['root', 'item']);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"autoFocus\", \"onChange\", \"className\", \"disabled\", \"readOnly\", \"items\", \"active\", \"slots\", \"slotProps\", \"skipDisabled\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport { alpha, styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport MenuList from '@mui/material/MenuList';\nimport MenuItem from '@mui/material/MenuItem';\nimport useForkRef from '@mui/utils/useForkRef';\nimport { getMultiSectionDigitalClockSectionUtilityClass } from \"./multiSectionDigitalClockSectionClasses.js\";\nimport { DIGITAL_CLOCK_VIEW_HEIGHT, MULTI_SECTION_CLOCK_SECTION_WIDTH } from \"../internals/constants/dimensions.js\";\nimport { getFocusedListItemIndex } from \"../internals/utils/utils.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n item: ['item']\n };\n return composeClasses(slots, getMultiSectionDigitalClockSectionUtilityClass, classes);\n};\nconst MultiSectionDigitalClockSectionRoot = styled(MenuList, {\n name: 'MuiMultiSectionDigitalClockSection',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})(({\n theme\n}) => ({\n maxHeight: DIGITAL_CLOCK_VIEW_HEIGHT,\n width: 56,\n padding: 0,\n overflow: 'hidden',\n '@media (prefers-reduced-motion: no-preference)': {\n scrollBehavior: 'auto'\n },\n '@media (pointer: fine)': {\n '&:hover': {\n overflowY: 'auto'\n }\n },\n '@media (pointer: none), (pointer: coarse)': {\n overflowY: 'auto'\n },\n '&:not(:first-of-type)': {\n borderLeft: `1px solid ${(theme.vars || theme).palette.divider}`\n },\n '&::after': {\n display: 'block',\n content: '\"\"',\n // subtracting the height of one item, extra margin and borders to make sure the max height is correct\n height: 'calc(100% - 40px - 6px)'\n },\n variants: [{\n props: {\n alreadyRendered: true\n },\n style: {\n '@media (prefers-reduced-motion: no-preference)': {\n scrollBehavior: 'smooth'\n }\n }\n }]\n}));\nconst MultiSectionDigitalClockSectionItem = styled(MenuItem, {\n name: 'MuiMultiSectionDigitalClockSection',\n slot: 'Item',\n overridesResolver: (_, styles) => styles.item\n})(({\n theme\n}) => ({\n padding: 8,\n margin: '2px 4px',\n width: MULTI_SECTION_CLOCK_SECTION_WIDTH,\n justifyContent: 'center',\n '&:first-of-type': {\n marginTop: 4\n },\n '&:hover': {\n backgroundColor: theme.vars ? `rgba(${theme.vars.palette.primary.mainChannel} / ${theme.vars.palette.action.hoverOpacity})` : alpha(theme.palette.primary.main, theme.palette.action.hoverOpacity)\n },\n '&.Mui-selected': {\n backgroundColor: (theme.vars || theme).palette.primary.main,\n color: (theme.vars || theme).palette.primary.contrastText,\n '&:focus-visible, &:hover': {\n backgroundColor: (theme.vars || theme).palette.primary.dark\n }\n },\n '&.Mui-focusVisible': {\n backgroundColor: theme.vars ? `rgba(${theme.vars.palette.primary.mainChannel} / ${theme.vars.palette.action.focusOpacity})` : alpha(theme.palette.primary.main, theme.palette.action.focusOpacity)\n }\n}));\n/**\n * @ignore - internal component.\n */\nexport const MultiSectionDigitalClockSection = /*#__PURE__*/React.forwardRef(function MultiSectionDigitalClockSection(inProps, ref) {\n const containerRef = React.useRef(null);\n const handleRef = useForkRef(ref, containerRef);\n const previousActive = React.useRef(null);\n const props = useThemeProps({\n props: inProps,\n name: 'MuiMultiSectionDigitalClockSection'\n });\n const {\n autoFocus,\n onChange,\n className,\n disabled,\n readOnly,\n items,\n active,\n slots,\n slotProps,\n skipDisabled\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const ownerState = React.useMemo(() => _extends({}, props, {\n alreadyRendered: !!containerRef.current\n }), [props]);\n const classes = useUtilityClasses(ownerState);\n const DigitalClockSectionItem = slots?.digitalClockSectionItem ?? MultiSectionDigitalClockSectionItem;\n React.useEffect(() => {\n if (containerRef.current === null) {\n return;\n }\n const activeItem = containerRef.current.querySelector('[role=\"option\"][tabindex=\"0\"], [role=\"option\"][aria-selected=\"true\"]');\n if (active && autoFocus && activeItem) {\n activeItem.focus();\n }\n if (!activeItem || previousActive.current === activeItem) {\n return;\n }\n previousActive.current = activeItem;\n const offsetTop = activeItem.offsetTop;\n\n // Subtracting the 4px of extra margin intended for the first visible section item\n containerRef.current.scrollTop = offsetTop - 4;\n });\n const focusedOptionIndex = items.findIndex(item => item.isFocused(item.value));\n const handleKeyDown = event => {\n switch (event.key) {\n case 'PageUp':\n {\n const newIndex = getFocusedListItemIndex(containerRef.current) - 5;\n const children = containerRef.current.children;\n const newFocusedIndex = Math.max(0, newIndex);\n const childToFocus = children[newFocusedIndex];\n if (childToFocus) {\n childToFocus.focus();\n }\n event.preventDefault();\n break;\n }\n case 'PageDown':\n {\n const newIndex = getFocusedListItemIndex(containerRef.current) + 5;\n const children = containerRef.current.children;\n const newFocusedIndex = Math.min(children.length - 1, newIndex);\n const childToFocus = children[newFocusedIndex];\n if (childToFocus) {\n childToFocus.focus();\n }\n event.preventDefault();\n break;\n }\n default:\n }\n };\n return /*#__PURE__*/_jsx(MultiSectionDigitalClockSectionRoot, _extends({\n ref: handleRef,\n className: clsx(classes.root, className),\n ownerState: ownerState,\n autoFocusItem: autoFocus && active,\n role: \"listbox\",\n onKeyDown: handleKeyDown\n }, other, {\n children: items.map((option, index) => {\n const isItemDisabled = option.isDisabled?.(option.value);\n const isDisabled = disabled || isItemDisabled;\n if (skipDisabled && isDisabled) {\n return null;\n }\n const isSelected = option.isSelected(option.value);\n const tabIndex = focusedOptionIndex === index || focusedOptionIndex === -1 && index === 0 ? 0 : -1;\n return /*#__PURE__*/_jsx(DigitalClockSectionItem, _extends({\n onClick: () => !readOnly && onChange(option.value),\n selected: isSelected,\n disabled: isDisabled,\n disableRipple: readOnly,\n role: \"option\"\n // aria-readonly is not supported here and does not have any effect\n ,\n \"aria-disabled\": readOnly || isDisabled || undefined,\n \"aria-label\": option.ariaLabel,\n \"aria-selected\": isSelected,\n tabIndex: tabIndex,\n className: classes.item\n }, slotProps?.digitalClockSectionItem, {\n children: option.label\n }), option.label);\n })\n }));\n});","export const getHourSectionOptions = ({\n now,\n value,\n utils,\n ampm,\n isDisabled,\n resolveAriaLabel,\n timeStep,\n valueOrReferenceDate\n}) => {\n const currentHours = value ? utils.getHours(value) : null;\n const result = [];\n const isSelected = (hour, overriddenCurrentHours) => {\n const resolvedCurrentHours = overriddenCurrentHours ?? currentHours;\n if (resolvedCurrentHours === null) {\n return false;\n }\n if (ampm) {\n if (hour === 12) {\n return resolvedCurrentHours === 12 || resolvedCurrentHours === 0;\n }\n return resolvedCurrentHours === hour || resolvedCurrentHours - 12 === hour;\n }\n return resolvedCurrentHours === hour;\n };\n const isFocused = hour => {\n return isSelected(hour, utils.getHours(valueOrReferenceDate));\n };\n const endHour = ampm ? 11 : 23;\n for (let hour = 0; hour <= endHour; hour += timeStep) {\n let label = utils.format(utils.setHours(now, hour), ampm ? 'hours12h' : 'hours24h');\n const ariaLabel = resolveAriaLabel(parseInt(label, 10).toString());\n label = utils.formatNumber(label);\n result.push({\n value: hour,\n label,\n isSelected,\n isDisabled,\n isFocused,\n ariaLabel\n });\n }\n return result;\n};\nexport const getTimeSectionOptions = ({\n value,\n utils,\n isDisabled,\n timeStep,\n resolveLabel,\n resolveAriaLabel,\n hasValue = true\n}) => {\n const isSelected = timeValue => {\n if (value === null) {\n return false;\n }\n return hasValue && value === timeValue;\n };\n const isFocused = timeValue => {\n return value === timeValue;\n };\n return [...Array.from({\n length: Math.ceil(60 / timeStep)\n }, (_, index) => {\n const timeValue = timeStep * index;\n return {\n value: timeValue,\n label: utils.formatNumber(resolveLabel(timeValue)),\n isDisabled,\n isSelected,\n isFocused,\n ariaLabel: resolveAriaLabel(timeValue.toString())\n };\n })];\n};","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ampm\", \"timeSteps\", \"autoFocus\", \"slots\", \"slotProps\", \"value\", \"defaultValue\", \"referenceDate\", \"disableIgnoringDatePartForTimeValidation\", \"maxTime\", \"minTime\", \"disableFuture\", \"disablePast\", \"minutesStep\", \"shouldDisableTime\", \"onChange\", \"view\", \"views\", \"openTo\", \"onViewChange\", \"focusedView\", \"onFocusedViewChange\", \"className\", \"disabled\", \"readOnly\", \"skipDisabled\", \"timezone\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport PropTypes from 'prop-types';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils, useNow } from \"../internals/hooks/useUtils.js\";\nimport { convertValueToMeridiem, createIsAfterIgnoreDatePart } from \"../internals/utils/time-utils.js\";\nimport { useViews } from \"../internals/hooks/useViews.js\";\nimport { useMeridiemMode } from \"../internals/hooks/date-helpers-hooks.js\";\nimport { PickerViewRoot } from \"../internals/components/PickerViewRoot/index.js\";\nimport { getMultiSectionDigitalClockUtilityClass } from \"./multiSectionDigitalClockClasses.js\";\nimport { MultiSectionDigitalClockSection } from \"./MultiSectionDigitalClockSection.js\";\nimport { getHourSectionOptions, getTimeSectionOptions } from \"./MultiSectionDigitalClock.utils.js\";\nimport { useControlledValueWithTimezone } from \"../internals/hooks/useValueWithTimezone.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { useClockReferenceDate } from \"../internals/hooks/useClockReferenceDate.js\";\nimport { formatMeridiem } from \"../internals/utils/date-utils.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, getMultiSectionDigitalClockUtilityClass, classes);\n};\nconst MultiSectionDigitalClockRoot = styled(PickerViewRoot, {\n name: 'MuiMultiSectionDigitalClock',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})(({\n theme\n}) => ({\n display: 'flex',\n flexDirection: 'row',\n width: '100%',\n borderBottom: `1px solid ${(theme.vars || theme).palette.divider}`\n}));\n/**\n * Demos:\n *\n * - [TimePicker](https://mui.com/x/react-date-pickers/time-picker/)\n * - [DigitalClock](https://mui.com/x/react-date-pickers/digital-clock/)\n *\n * API:\n *\n * - [MultiSectionDigitalClock API](https://mui.com/x/api/date-pickers/multi-section-digital-clock/)\n */\nexport const MultiSectionDigitalClock = /*#__PURE__*/React.forwardRef(function MultiSectionDigitalClock(inProps, ref) {\n const utils = useUtils();\n const isRtl = useRtl();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiMultiSectionDigitalClock'\n });\n const {\n ampm = utils.is12HourCycleInCurrentLocale(),\n timeSteps: inTimeSteps,\n autoFocus,\n slots,\n slotProps,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n disableIgnoringDatePartForTimeValidation = false,\n maxTime,\n minTime,\n disableFuture,\n disablePast,\n minutesStep = 1,\n shouldDisableTime,\n onChange,\n view: inView,\n views: inViews = ['hours', 'minutes'],\n openTo,\n onViewChange,\n focusedView: inFocusedView,\n onFocusedViewChange,\n className,\n disabled,\n readOnly,\n skipDisabled = false,\n timezone: timezoneProp\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const {\n value,\n handleValueChange: handleRawValueChange,\n timezone\n } = useControlledValueWithTimezone({\n name: 'MultiSectionDigitalClock',\n timezone: timezoneProp,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n onChange,\n valueManager: singleItemValueManager\n });\n const translations = usePickersTranslations();\n const now = useNow(timezone);\n const timeSteps = React.useMemo(() => _extends({\n hours: 1,\n minutes: 5,\n seconds: 5\n }, inTimeSteps), [inTimeSteps]);\n const valueOrReferenceDate = useClockReferenceDate({\n value,\n referenceDate: referenceDateProp,\n utils,\n props,\n timezone\n });\n const handleValueChange = useEventCallback((newValue, selectionState, selectedView) => handleRawValueChange(newValue, selectionState, selectedView));\n const views = React.useMemo(() => {\n if (!ampm || !inViews.includes('hours')) {\n return inViews;\n }\n return inViews.includes('meridiem') ? inViews : [...inViews, 'meridiem'];\n }, [ampm, inViews]);\n const {\n view,\n setValueAndGoToNextView,\n focusedView\n } = useViews({\n view: inView,\n views,\n openTo,\n onViewChange,\n onChange: handleValueChange,\n focusedView: inFocusedView,\n onFocusedViewChange\n });\n const handleMeridiemValueChange = useEventCallback(newValue => {\n setValueAndGoToNextView(newValue, 'finish', 'meridiem');\n });\n const {\n meridiemMode,\n handleMeridiemChange\n } = useMeridiemMode(valueOrReferenceDate, ampm, handleMeridiemValueChange, 'finish');\n const isTimeDisabled = React.useCallback((rawValue, viewType) => {\n const isAfter = createIsAfterIgnoreDatePart(disableIgnoringDatePartForTimeValidation, utils);\n const shouldCheckPastEnd = viewType === 'hours' || viewType === 'minutes' && views.includes('seconds');\n const containsValidTime = ({\n start,\n end\n }) => {\n if (minTime && isAfter(minTime, end)) {\n return false;\n }\n if (maxTime && isAfter(start, maxTime)) {\n return false;\n }\n if (disableFuture && isAfter(start, now)) {\n return false;\n }\n if (disablePast && isAfter(now, shouldCheckPastEnd ? end : start)) {\n return false;\n }\n return true;\n };\n const isValidValue = (timeValue, step = 1) => {\n if (timeValue % step !== 0) {\n return false;\n }\n if (shouldDisableTime) {\n switch (viewType) {\n case 'hours':\n return !shouldDisableTime(utils.setHours(valueOrReferenceDate, timeValue), 'hours');\n case 'minutes':\n return !shouldDisableTime(utils.setMinutes(valueOrReferenceDate, timeValue), 'minutes');\n case 'seconds':\n return !shouldDisableTime(utils.setSeconds(valueOrReferenceDate, timeValue), 'seconds');\n default:\n return false;\n }\n }\n return true;\n };\n switch (viewType) {\n case 'hours':\n {\n const valueWithMeridiem = convertValueToMeridiem(rawValue, meridiemMode, ampm);\n const dateWithNewHours = utils.setHours(valueOrReferenceDate, valueWithMeridiem);\n const start = utils.setSeconds(utils.setMinutes(dateWithNewHours, 0), 0);\n const end = utils.setSeconds(utils.setMinutes(dateWithNewHours, 59), 59);\n return !containsValidTime({\n start,\n end\n }) || !isValidValue(valueWithMeridiem);\n }\n case 'minutes':\n {\n const dateWithNewMinutes = utils.setMinutes(valueOrReferenceDate, rawValue);\n const start = utils.setSeconds(dateWithNewMinutes, 0);\n const end = utils.setSeconds(dateWithNewMinutes, 59);\n return !containsValidTime({\n start,\n end\n }) || !isValidValue(rawValue, minutesStep);\n }\n case 'seconds':\n {\n const dateWithNewSeconds = utils.setSeconds(valueOrReferenceDate, rawValue);\n const start = dateWithNewSeconds;\n const end = dateWithNewSeconds;\n return !containsValidTime({\n start,\n end\n }) || !isValidValue(rawValue);\n }\n default:\n throw new Error('not supported');\n }\n }, [ampm, valueOrReferenceDate, disableIgnoringDatePartForTimeValidation, maxTime, meridiemMode, minTime, minutesStep, shouldDisableTime, utils, disableFuture, disablePast, now, views]);\n const buildViewProps = React.useCallback(viewToBuild => {\n switch (viewToBuild) {\n case 'hours':\n {\n return {\n onChange: hours => {\n const valueWithMeridiem = convertValueToMeridiem(hours, meridiemMode, ampm);\n setValueAndGoToNextView(utils.setHours(valueOrReferenceDate, valueWithMeridiem), 'finish', 'hours');\n },\n items: getHourSectionOptions({\n now,\n value,\n ampm,\n utils,\n isDisabled: hours => isTimeDisabled(hours, 'hours'),\n timeStep: timeSteps.hours,\n resolveAriaLabel: translations.hoursClockNumberText,\n valueOrReferenceDate\n })\n };\n }\n case 'minutes':\n {\n return {\n onChange: minutes => {\n setValueAndGoToNextView(utils.setMinutes(valueOrReferenceDate, minutes), 'finish', 'minutes');\n },\n items: getTimeSectionOptions({\n value: utils.getMinutes(valueOrReferenceDate),\n utils,\n isDisabled: minutes => isTimeDisabled(minutes, 'minutes'),\n resolveLabel: minutes => utils.format(utils.setMinutes(now, minutes), 'minutes'),\n timeStep: timeSteps.minutes,\n hasValue: !!value,\n resolveAriaLabel: translations.minutesClockNumberText\n })\n };\n }\n case 'seconds':\n {\n return {\n onChange: seconds => {\n setValueAndGoToNextView(utils.setSeconds(valueOrReferenceDate, seconds), 'finish', 'seconds');\n },\n items: getTimeSectionOptions({\n value: utils.getSeconds(valueOrReferenceDate),\n utils,\n isDisabled: seconds => isTimeDisabled(seconds, 'seconds'),\n resolveLabel: seconds => utils.format(utils.setSeconds(now, seconds), 'seconds'),\n timeStep: timeSteps.seconds,\n hasValue: !!value,\n resolveAriaLabel: translations.secondsClockNumberText\n })\n };\n }\n case 'meridiem':\n {\n const amLabel = formatMeridiem(utils, 'am');\n const pmLabel = formatMeridiem(utils, 'pm');\n return {\n onChange: handleMeridiemChange,\n items: [{\n value: 'am',\n label: amLabel,\n isSelected: () => !!value && meridiemMode === 'am',\n isFocused: () => !!valueOrReferenceDate && meridiemMode === 'am',\n ariaLabel: amLabel\n }, {\n value: 'pm',\n label: pmLabel,\n isSelected: () => !!value && meridiemMode === 'pm',\n isFocused: () => !!valueOrReferenceDate && meridiemMode === 'pm',\n ariaLabel: pmLabel\n }]\n };\n }\n default:\n throw new Error(`Unknown view: ${viewToBuild} found.`);\n }\n }, [now, value, ampm, utils, timeSteps.hours, timeSteps.minutes, timeSteps.seconds, translations.hoursClockNumberText, translations.minutesClockNumberText, translations.secondsClockNumberText, meridiemMode, setValueAndGoToNextView, valueOrReferenceDate, isTimeDisabled, handleMeridiemChange]);\n const viewsToRender = React.useMemo(() => {\n if (!isRtl) {\n return views;\n }\n const digitViews = views.filter(v => v !== 'meridiem');\n digitViews.reverse();\n if (views.includes('meridiem')) {\n digitViews.push('meridiem');\n }\n return digitViews;\n }, [isRtl, views]);\n const viewTimeOptions = React.useMemo(() => {\n return views.reduce((result, currentView) => {\n return _extends({}, result, {\n [currentView]: buildViewProps(currentView)\n });\n }, {});\n }, [views, buildViewProps]);\n const ownerState = props;\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsx(MultiSectionDigitalClockRoot, _extends({\n ref: ref,\n className: clsx(classes.root, className),\n ownerState: ownerState,\n role: \"group\"\n }, other, {\n children: viewsToRender.map(timeView => /*#__PURE__*/_jsx(MultiSectionDigitalClockSection, {\n items: viewTimeOptions[timeView].items,\n onChange: viewTimeOptions[timeView].onChange,\n active: view === timeView,\n autoFocus: autoFocus ?? focusedView === timeView,\n disabled: disabled,\n readOnly: readOnly,\n slots: slots,\n slotProps: slotProps,\n skipDisabled: skipDisabled,\n \"aria-label\": translations.selectViewText(timeView)\n }, timeView))\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? MultiSectionDigitalClock.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n /**\n * The default selected value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker views and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * Controlled focused view.\n */\n focusedView: PropTypes.oneOf(['hours', 'meridiem', 'minutes', 'seconds']),\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TView The view type. Will be one of date or time views.\n * @param {TValue} value The new value.\n * @param {PickerSelectionState | undefined} selectionState Indicates if the date selection is complete.\n * @param {TView | undefined} selectedView Indicates the view in which the selection has been made.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired on focused view change.\n * @template TView\n * @param {TView} view The new view to focus or not.\n * @param {boolean} hasFocus `true` if the view should be focused.\n */\n onFocusedViewChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['hours', 'meridiem', 'minutes', 'seconds']),\n /**\n * If `true`, the picker views and text field are read-only.\n * @default false\n */\n readOnly: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid time using the validation props, except callbacks such as `shouldDisableTime`.\n */\n referenceDate: PropTypes.object,\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * If `true`, disabled digital clock items will not be rendered.\n * @default false\n */\n skipDisabled: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overrideable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * The time steps between two time unit options.\n * For example, if `timeStep.minutes = 8`, then the available minute options will be `[0, 8, 16, 24, 32, 40, 48, 56]`.\n * @default{ hours: 1, minutes: 5, seconds: 5 }\n */\n timeSteps: PropTypes.shape({\n hours: PropTypes.number,\n minutes: PropTypes.number,\n seconds: PropTypes.number\n }),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['hours', 'meridiem', 'minutes', 'seconds']),\n /**\n * Available views.\n * @default ['hours', 'minutes']\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['hours', 'meridiem', 'minutes', 'seconds']).isRequired)\n} : void 0;","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getPickersDayUtilityClass(slot) {\n return generateUtilityClass('MuiPickersDay', slot);\n}\nexport const pickersDayClasses = generateUtilityClasses('MuiPickersDay', ['root', 'dayWithMargin', 'dayOutsideMonth', 'hiddenDaySpacingFiller', 'today', 'selected', 'disabled']);","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"autoFocus\", \"className\", \"day\", \"disabled\", \"disableHighlightToday\", \"disableMargin\", \"hidden\", \"isAnimating\", \"onClick\", \"onDaySelect\", \"onFocus\", \"onBlur\", \"onKeyDown\", \"onMouseDown\", \"onMouseEnter\", \"outsideCurrentMonth\", \"selected\", \"showDaysOutsideCurrentMonth\", \"children\", \"today\", \"isFirstVisibleCell\", \"isLastVisibleCell\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport ButtonBase from '@mui/material/ButtonBase';\nimport { unstable_useEnhancedEffect as useEnhancedEffect, unstable_composeClasses as composeClasses, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { alpha, styled, useThemeProps } from '@mui/material/styles';\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { DAY_SIZE, DAY_MARGIN } from \"../internals/constants/dimensions.js\";\nimport { getPickersDayUtilityClass, pickersDayClasses } from \"./pickersDayClasses.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n selected,\n disableMargin,\n disableHighlightToday,\n today,\n disabled,\n outsideCurrentMonth,\n showDaysOutsideCurrentMonth,\n classes\n } = ownerState;\n const isHiddenDaySpacingFiller = outsideCurrentMonth && !showDaysOutsideCurrentMonth;\n const slots = {\n root: ['root', selected && !isHiddenDaySpacingFiller && 'selected', disabled && 'disabled', !disableMargin && 'dayWithMargin', !disableHighlightToday && today && 'today', outsideCurrentMonth && showDaysOutsideCurrentMonth && 'dayOutsideMonth', isHiddenDaySpacingFiller && 'hiddenDaySpacingFiller'],\n hiddenDaySpacingFiller: ['hiddenDaySpacingFiller']\n };\n return composeClasses(slots, getPickersDayUtilityClass, classes);\n};\nconst styleArg = ({\n theme\n}) => _extends({}, theme.typography.caption, {\n width: DAY_SIZE,\n height: DAY_SIZE,\n borderRadius: '50%',\n padding: 0,\n // explicitly setting to `transparent` to avoid potentially getting impacted by change from the overridden component\n backgroundColor: 'transparent',\n transition: theme.transitions.create('background-color', {\n duration: theme.transitions.duration.short\n }),\n color: (theme.vars || theme).palette.text.primary,\n '@media (pointer: fine)': {\n '&:hover': {\n backgroundColor: theme.vars ? `rgba(${theme.vars.palette.primary.mainChannel} / ${theme.vars.palette.action.hoverOpacity})` : alpha(theme.palette.primary.main, theme.palette.action.hoverOpacity)\n }\n },\n '&:focus': {\n backgroundColor: theme.vars ? `rgba(${theme.vars.palette.primary.mainChannel} / ${theme.vars.palette.action.focusOpacity})` : alpha(theme.palette.primary.main, theme.palette.action.focusOpacity),\n [`&.${pickersDayClasses.selected}`]: {\n willChange: 'background-color',\n backgroundColor: (theme.vars || theme).palette.primary.dark\n }\n },\n [`&.${pickersDayClasses.selected}`]: {\n color: (theme.vars || theme).palette.primary.contrastText,\n backgroundColor: (theme.vars || theme).palette.primary.main,\n fontWeight: theme.typography.fontWeightMedium,\n '&:hover': {\n willChange: 'background-color',\n backgroundColor: (theme.vars || theme).palette.primary.dark\n }\n },\n [`&.${pickersDayClasses.disabled}:not(.${pickersDayClasses.selected})`]: {\n color: (theme.vars || theme).palette.text.disabled\n },\n [`&.${pickersDayClasses.disabled}&.${pickersDayClasses.selected}`]: {\n opacity: 0.6\n },\n variants: [{\n props: {\n disableMargin: false\n },\n style: {\n margin: `0 ${DAY_MARGIN}px`\n }\n }, {\n props: {\n outsideCurrentMonth: true,\n showDaysOutsideCurrentMonth: true\n },\n style: {\n color: (theme.vars || theme).palette.text.secondary\n }\n }, {\n props: {\n disableHighlightToday: false,\n today: true\n },\n style: {\n [`&:not(.${pickersDayClasses.selected})`]: {\n border: `1px solid ${(theme.vars || theme).palette.text.secondary}`\n }\n }\n }]\n});\nconst overridesResolver = (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, !ownerState.disableMargin && styles.dayWithMargin, !ownerState.disableHighlightToday && ownerState.today && styles.today, !ownerState.outsideCurrentMonth && ownerState.showDaysOutsideCurrentMonth && styles.dayOutsideMonth, ownerState.outsideCurrentMonth && !ownerState.showDaysOutsideCurrentMonth && styles.hiddenDaySpacingFiller];\n};\nconst PickersDayRoot = styled(ButtonBase, {\n name: 'MuiPickersDay',\n slot: 'Root',\n overridesResolver\n})(styleArg);\nconst PickersDayFiller = styled('div', {\n name: 'MuiPickersDay',\n slot: 'Root',\n overridesResolver\n})(({\n theme\n}) => _extends({}, styleArg({\n theme\n}), {\n // visibility: 'hidden' does not work here as it hides the element from screen readers as well\n opacity: 0,\n pointerEvents: 'none'\n}));\nconst noop = () => {};\nconst PickersDayRaw = /*#__PURE__*/React.forwardRef(function PickersDay(inProps, forwardedRef) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersDay'\n });\n const {\n autoFocus = false,\n className,\n day,\n disabled = false,\n disableHighlightToday = false,\n disableMargin = false,\n isAnimating,\n onClick,\n onDaySelect,\n onFocus = noop,\n onBlur = noop,\n onKeyDown = noop,\n onMouseDown = noop,\n onMouseEnter = noop,\n outsideCurrentMonth,\n selected = false,\n showDaysOutsideCurrentMonth = false,\n children,\n today: isToday = false\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const ownerState = _extends({}, props, {\n autoFocus,\n disabled,\n disableHighlightToday,\n disableMargin,\n selected,\n showDaysOutsideCurrentMonth,\n today: isToday\n });\n const classes = useUtilityClasses(ownerState);\n const utils = useUtils();\n const ref = React.useRef(null);\n const handleRef = useForkRef(ref, forwardedRef);\n\n // Since this is rendered when a Popper is opened we can't use passive effects.\n // Focusing in passive effects in Popper causes scroll jump.\n useEnhancedEffect(() => {\n if (autoFocus && !disabled && !isAnimating && !outsideCurrentMonth) {\n // ref.current being null would be a bug in MUI\n ref.current.focus();\n }\n }, [autoFocus, disabled, isAnimating, outsideCurrentMonth]);\n\n // For a day outside the current month, move the focus from mouseDown to mouseUp\n // Goal: have the onClick ends before sliding to the new month\n const handleMouseDown = event => {\n onMouseDown(event);\n if (outsideCurrentMonth) {\n event.preventDefault();\n }\n };\n const handleClick = event => {\n if (!disabled) {\n onDaySelect(day);\n }\n if (outsideCurrentMonth) {\n event.currentTarget.focus();\n }\n if (onClick) {\n onClick(event);\n }\n };\n if (outsideCurrentMonth && !showDaysOutsideCurrentMonth) {\n return /*#__PURE__*/_jsx(PickersDayFiller, {\n className: clsx(classes.root, classes.hiddenDaySpacingFiller, className),\n ownerState: ownerState,\n role: other.role\n });\n }\n return /*#__PURE__*/_jsx(PickersDayRoot, _extends({\n className: clsx(classes.root, className),\n ref: handleRef,\n centerRipple: true,\n disabled: disabled,\n tabIndex: selected ? 0 : -1,\n onKeyDown: event => onKeyDown(event, day),\n onFocus: event => onFocus(event, day),\n onBlur: event => onBlur(event, day),\n onMouseEnter: event => onMouseEnter(event, day),\n onClick: handleClick,\n onMouseDown: handleMouseDown\n }, other, {\n ownerState: ownerState,\n children: !children ? utils.format(day, 'dayOfMonth') : children\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? PickersDayRaw.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * A ref for imperative actions.\n * It currently only supports `focusVisible()` action.\n */\n action: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({\n current: PropTypes.shape({\n focusVisible: PropTypes.func.isRequired\n })\n })]),\n /**\n * If `true`, the ripples are centered.\n * They won't start at the cursor interaction position.\n * @default false\n */\n centerRipple: PropTypes.bool,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n component: PropTypes.elementType,\n /**\n * The date to show.\n */\n day: PropTypes.object.isRequired,\n /**\n * If `true`, renders as disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * If `true`, days are rendering without margin. Useful for displaying linked range of days.\n * @default false\n */\n disableMargin: PropTypes.bool,\n /**\n * If `true`, the ripple effect is disabled.\n *\n * ⚠️ Without a ripple there is no styling for :focus-visible by default. Be sure\n * to highlight the element by applying separate styles with the `.Mui-focusVisible` class.\n * @default false\n */\n disableRipple: PropTypes.bool,\n /**\n * If `true`, the touch ripple effect is disabled.\n * @default false\n */\n disableTouchRipple: PropTypes.bool,\n /**\n * If `true`, the base button will have a keyboard focus ripple.\n * @default false\n */\n focusRipple: PropTypes.bool,\n /**\n * This prop can help identify which element has keyboard focus.\n * The class name will be applied when the element gains the focus through keyboard interaction.\n * It's a polyfill for the [CSS :focus-visible selector](https://drafts.csswg.org/selectors-4/#the-focus-visible-pseudo).\n * The rationale for using this feature [is explained here](https://github.com/WICG/focus-visible/blob/HEAD/explainer.md).\n * A [polyfill can be used](https://github.com/WICG/focus-visible) to apply a `focus-visible` class to other components\n * if needed.\n */\n focusVisibleClassName: PropTypes.string,\n isAnimating: PropTypes.bool,\n /**\n * If `true`, day is the first visible cell of the month.\n * Either the first day of the month or the first day of the week depending on `showDaysOutsideCurrentMonth`.\n */\n isFirstVisibleCell: PropTypes.bool.isRequired,\n /**\n * If `true`, day is the last visible cell of the month.\n * Either the last day of the month or the last day of the week depending on `showDaysOutsideCurrentMonth`.\n */\n isLastVisibleCell: PropTypes.bool.isRequired,\n onBlur: PropTypes.func,\n onDaySelect: PropTypes.func.isRequired,\n onFocus: PropTypes.func,\n /**\n * Callback fired when the component is focused with a keyboard.\n * We trigger a `onFocus` callback too.\n */\n onFocusVisible: PropTypes.func,\n onKeyDown: PropTypes.func,\n onMouseEnter: PropTypes.func,\n /**\n * If `true`, day is outside of month and will be hidden.\n */\n outsideCurrentMonth: PropTypes.bool.isRequired,\n /**\n * If `true`, renders as selected.\n * @default false\n */\n selected: PropTypes.bool,\n /**\n * If `true`, days outside the current month are rendered:\n *\n * - if `fixedWeekNumber` is defined, renders days to have the weeks requested.\n *\n * - if `fixedWeekNumber` is not defined, renders day to fill the first and last week of the current month.\n *\n * - ignored if `calendars` equals more than `1` on range pickers.\n * @default false\n */\n showDaysOutsideCurrentMonth: PropTypes.bool,\n style: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * @default 0\n */\n tabIndex: PropTypes.number,\n /**\n * If `true`, renders as today date.\n * @default false\n */\n today: PropTypes.bool,\n /**\n * Props applied to the `TouchRipple` element.\n */\n TouchRippleProps: PropTypes.object,\n /**\n * A ref that points to the `TouchRipple` element.\n */\n touchRippleRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({\n current: PropTypes.shape({\n pulsate: PropTypes.func.isRequired,\n start: PropTypes.func.isRequired,\n stop: PropTypes.func.isRequired\n })\n })])\n} : void 0;\n\n/**\n * Demos:\n *\n * - [DateCalendar](https://mui.com/x/react-date-pickers/date-calendar/)\n * API:\n *\n * - [PickersDay API](https://mui.com/x/api/date-pickers/pickers-day/)\n */\nexport const PickersDay = /*#__PURE__*/React.memo(PickersDayRaw);","'use client';\n\nimport * as React from 'react';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport { useLocalizationContext } from \"../internals/hooks/useUtils.js\";\n/**\n * Utility hook to check if a given value is valid based on the provided validation props.\n * @template TDate\n * @template TValue The value type. It will be either the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {UseValidationOptions} options The options to configure the hook.\n * @param {TValue} options.value The value to validate.\n * @param {PickersTimezone} options.timezone The timezone to use for the validation.\n * @param {Validator} options.validator The validator function to use.\n * @param {TValidationProps} options.props The validation props, they differ depending on the component.\n * @param {(error: TError, value: TValue) => void} options.onError Callback fired when the error associated with the current value changes.\n */\nexport function useValidation(options) {\n const {\n props,\n validator,\n value,\n timezone,\n onError\n } = options;\n const adapter = useLocalizationContext();\n const previousValidationErrorRef = React.useRef(validator.valueManager.defaultErrorState);\n const validationError = validator({\n adapter,\n value,\n timezone,\n props\n });\n const hasValidationError = validator.valueManager.hasError(validationError);\n React.useEffect(() => {\n if (onError && !validator.valueManager.isSameError(validationError, previousValidationErrorRef.current)) {\n onError(validationError, value);\n }\n previousValidationErrorRef.current = validationError;\n }, [validator, onError, validationError, value]);\n const getValidationErrorForNewValue = useEventCallback(newValue => {\n return validator({\n adapter,\n value: newValue,\n timezone,\n props\n });\n });\n return {\n validationError,\n hasValidationError,\n getValidationErrorForNewValue\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { applyLocalizedDigits, cleanLeadingZeros, doesSectionFormatHaveLeadingZeros, getDateSectionConfigFromFormatToken, removeLocalizedDigits } from \"./useField.utils.js\";\nconst expandFormat = ({\n utils,\n format\n}) => {\n // Expand the provided format\n let formatExpansionOverflow = 10;\n let prevFormat = format;\n let nextFormat = utils.expandFormat(format);\n while (nextFormat !== prevFormat) {\n prevFormat = nextFormat;\n nextFormat = utils.expandFormat(prevFormat);\n formatExpansionOverflow -= 1;\n if (formatExpansionOverflow < 0) {\n throw new Error('MUI X: The format expansion seems to be in an infinite loop. Please open an issue with the format passed to the picker component.');\n }\n }\n return nextFormat;\n};\nconst getEscapedPartsFromFormat = ({\n utils,\n expandedFormat\n}) => {\n const escapedParts = [];\n const {\n start: startChar,\n end: endChar\n } = utils.escapedCharacters;\n const regExp = new RegExp(`(\\\\${startChar}[^\\\\${endChar}]*\\\\${endChar})+`, 'g');\n let match = null;\n // eslint-disable-next-line no-cond-assign\n while (match = regExp.exec(expandedFormat)) {\n escapedParts.push({\n start: match.index,\n end: regExp.lastIndex - 1\n });\n }\n return escapedParts;\n};\nconst getSectionPlaceholder = (utils, localeText, sectionConfig, sectionFormat) => {\n switch (sectionConfig.type) {\n case 'year':\n {\n return localeText.fieldYearPlaceholder({\n digitAmount: utils.formatByString(utils.date(undefined, 'default'), sectionFormat).length,\n format: sectionFormat\n });\n }\n case 'month':\n {\n return localeText.fieldMonthPlaceholder({\n contentType: sectionConfig.contentType,\n format: sectionFormat\n });\n }\n case 'day':\n {\n return localeText.fieldDayPlaceholder({\n format: sectionFormat\n });\n }\n case 'weekDay':\n {\n return localeText.fieldWeekDayPlaceholder({\n contentType: sectionConfig.contentType,\n format: sectionFormat\n });\n }\n case 'hours':\n {\n return localeText.fieldHoursPlaceholder({\n format: sectionFormat\n });\n }\n case 'minutes':\n {\n return localeText.fieldMinutesPlaceholder({\n format: sectionFormat\n });\n }\n case 'seconds':\n {\n return localeText.fieldSecondsPlaceholder({\n format: sectionFormat\n });\n }\n case 'meridiem':\n {\n return localeText.fieldMeridiemPlaceholder({\n format: sectionFormat\n });\n }\n default:\n {\n return sectionFormat;\n }\n }\n};\nconst createSection = ({\n utils,\n date,\n shouldRespectLeadingZeros,\n localeText,\n localizedDigits,\n now,\n token,\n startSeparator\n}) => {\n if (token === '') {\n throw new Error('MUI X: Should not call `commitToken` with an empty token');\n }\n const sectionConfig = getDateSectionConfigFromFormatToken(utils, token);\n const hasLeadingZerosInFormat = doesSectionFormatHaveLeadingZeros(utils, sectionConfig.contentType, sectionConfig.type, token);\n const hasLeadingZerosInInput = shouldRespectLeadingZeros ? hasLeadingZerosInFormat : sectionConfig.contentType === 'digit';\n const isValidDate = date != null && utils.isValid(date);\n let sectionValue = isValidDate ? utils.formatByString(date, token) : '';\n let maxLength = null;\n if (hasLeadingZerosInInput) {\n if (hasLeadingZerosInFormat) {\n maxLength = sectionValue === '' ? utils.formatByString(now, token).length : sectionValue.length;\n } else {\n if (sectionConfig.maxLength == null) {\n throw new Error(`MUI X: The token ${token} should have a 'maxDigitNumber' property on it's adapter`);\n }\n maxLength = sectionConfig.maxLength;\n if (isValidDate) {\n sectionValue = applyLocalizedDigits(cleanLeadingZeros(removeLocalizedDigits(sectionValue, localizedDigits), maxLength), localizedDigits);\n }\n }\n }\n return _extends({}, sectionConfig, {\n format: token,\n maxLength,\n value: sectionValue,\n placeholder: getSectionPlaceholder(utils, localeText, sectionConfig, token),\n hasLeadingZerosInFormat,\n hasLeadingZerosInInput,\n startSeparator,\n endSeparator: '',\n modified: false\n });\n};\nconst buildSections = params => {\n const {\n utils,\n expandedFormat,\n escapedParts\n } = params;\n const now = utils.date(undefined);\n const sections = [];\n let startSeparator = '';\n\n // This RegExp tests if the beginning of a string corresponds to a supported token\n const validTokens = Object.keys(utils.formatTokenMap).sort((a, b) => b.length - a.length); // Sort to put longest word first\n\n const regExpFirstWordInFormat = /^([a-zA-Z]+)/;\n const regExpWordOnlyComposedOfTokens = new RegExp(`^(${validTokens.join('|')})*$`);\n const regExpFirstTokenInWord = new RegExp(`^(${validTokens.join('|')})`);\n const getEscapedPartOfCurrentChar = i => escapedParts.find(escapeIndex => escapeIndex.start <= i && escapeIndex.end >= i);\n let i = 0;\n while (i < expandedFormat.length) {\n const escapedPartOfCurrentChar = getEscapedPartOfCurrentChar(i);\n const isEscapedChar = escapedPartOfCurrentChar != null;\n const firstWordInFormat = regExpFirstWordInFormat.exec(expandedFormat.slice(i))?.[1];\n\n // The first word in the format is only composed of tokens.\n // We extract those tokens to create a new sections.\n if (!isEscapedChar && firstWordInFormat != null && regExpWordOnlyComposedOfTokens.test(firstWordInFormat)) {\n let word = firstWordInFormat;\n while (word.length > 0) {\n const firstWord = regExpFirstTokenInWord.exec(word)[1];\n word = word.slice(firstWord.length);\n sections.push(createSection(_extends({}, params, {\n now,\n token: firstWord,\n startSeparator\n })));\n startSeparator = '';\n }\n i += firstWordInFormat.length;\n }\n // The remaining format does not start with a token,\n // We take the first character and add it to the current section's end separator.\n else {\n const char = expandedFormat[i];\n\n // If we are on the opening or closing character of an escaped part of the format,\n // Then we ignore this character.\n const isEscapeBoundary = isEscapedChar && escapedPartOfCurrentChar?.start === i || escapedPartOfCurrentChar?.end === i;\n if (!isEscapeBoundary) {\n if (sections.length === 0) {\n startSeparator += char;\n } else {\n sections[sections.length - 1].endSeparator += char;\n }\n }\n i += 1;\n }\n }\n if (sections.length === 0 && startSeparator.length > 0) {\n sections.push({\n type: 'empty',\n contentType: 'letter',\n maxLength: null,\n format: '',\n value: '',\n placeholder: '',\n hasLeadingZerosInFormat: false,\n hasLeadingZerosInInput: false,\n startSeparator,\n endSeparator: '',\n modified: false\n });\n }\n return sections;\n};\nconst postProcessSections = ({\n isRtl,\n formatDensity,\n sections\n}) => {\n return sections.map(section => {\n const cleanSeparator = separator => {\n let cleanedSeparator = separator;\n if (isRtl && cleanedSeparator !== null && cleanedSeparator.includes(' ')) {\n cleanedSeparator = `\\u2069${cleanedSeparator}\\u2066`;\n }\n if (formatDensity === 'spacious' && ['/', '.', '-'].includes(cleanedSeparator)) {\n cleanedSeparator = ` ${cleanedSeparator} `;\n }\n return cleanedSeparator;\n };\n section.startSeparator = cleanSeparator(section.startSeparator);\n section.endSeparator = cleanSeparator(section.endSeparator);\n return section;\n });\n};\nexport const buildSectionsFromFormat = params => {\n let expandedFormat = expandFormat(params);\n if (params.isRtl && params.enableAccessibleFieldDOMStructure) {\n expandedFormat = expandedFormat.split(' ').reverse().join(' ');\n }\n const escapedParts = getEscapedPartsFromFormat(_extends({}, params, {\n expandedFormat\n }));\n const sections = buildSections(_extends({}, params, {\n expandedFormat,\n escapedParts\n }));\n return postProcessSections(_extends({}, params, {\n sections\n }));\n};","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport useControlled from '@mui/utils/useControlled';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { usePickersTranslations } from \"../../../hooks/usePickersTranslations.js\";\nimport { useUtils, useLocalizationContext } from \"../useUtils.js\";\nimport { mergeDateIntoReferenceDate, getSectionsBoundaries, validateSections, getDateFromDateSections, parseSelectedSections, getLocalizedDigits } from \"./useField.utils.js\";\nimport { buildSectionsFromFormat } from \"./buildSectionsFromFormat.js\";\nimport { useValueWithTimezone } from \"../useValueWithTimezone.js\";\nimport { getSectionTypeGranularity } from \"../../utils/getDefaultReferenceDate.js\";\nexport const useFieldState = params => {\n const utils = useUtils();\n const translations = usePickersTranslations();\n const adapter = useLocalizationContext();\n const isRtl = useRtl();\n const {\n valueManager,\n fieldValueManager,\n valueType,\n validator,\n internalProps,\n internalProps: {\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n onChange,\n format,\n formatDensity = 'dense',\n selectedSections: selectedSectionsProp,\n onSelectedSectionsChange,\n shouldRespectLeadingZeros = false,\n timezone: timezoneProp,\n enableAccessibleFieldDOMStructure = false\n }\n } = params;\n const {\n timezone,\n value: valueFromTheOutside,\n handleValueChange\n } = useValueWithTimezone({\n timezone: timezoneProp,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n onChange,\n valueManager\n });\n const localizedDigits = React.useMemo(() => getLocalizedDigits(utils), [utils]);\n const sectionsValueBoundaries = React.useMemo(() => getSectionsBoundaries(utils, localizedDigits, timezone), [utils, localizedDigits, timezone]);\n const getSectionsFromValue = React.useCallback((value, fallbackSections = null) => fieldValueManager.getSectionsFromValue(utils, value, fallbackSections, date => buildSectionsFromFormat({\n utils,\n localeText: translations,\n localizedDigits,\n format,\n date,\n formatDensity,\n shouldRespectLeadingZeros,\n enableAccessibleFieldDOMStructure,\n isRtl\n })), [fieldValueManager, format, translations, localizedDigits, isRtl, shouldRespectLeadingZeros, utils, formatDensity, enableAccessibleFieldDOMStructure]);\n const [state, setState] = React.useState(() => {\n const sections = getSectionsFromValue(valueFromTheOutside);\n validateSections(sections, valueType);\n const stateWithoutReferenceDate = {\n sections,\n value: valueFromTheOutside,\n referenceValue: valueManager.emptyValue,\n tempValueStrAndroid: null\n };\n const granularity = getSectionTypeGranularity(sections);\n const referenceValue = valueManager.getInitialReferenceValue({\n referenceDate: referenceDateProp,\n value: valueFromTheOutside,\n utils,\n props: internalProps,\n granularity,\n timezone\n });\n return _extends({}, stateWithoutReferenceDate, {\n referenceValue\n });\n });\n const [selectedSections, innerSetSelectedSections] = useControlled({\n controlled: selectedSectionsProp,\n default: null,\n name: 'useField',\n state: 'selectedSections'\n });\n const setSelectedSections = newSelectedSections => {\n innerSetSelectedSections(newSelectedSections);\n onSelectedSectionsChange?.(newSelectedSections);\n };\n const parsedSelectedSections = React.useMemo(() => parseSelectedSections(selectedSections, state.sections), [selectedSections, state.sections]);\n const activeSectionIndex = parsedSelectedSections === 'all' ? 0 : parsedSelectedSections;\n const publishValue = ({\n value,\n referenceValue,\n sections\n }) => {\n setState(prevState => _extends({}, prevState, {\n sections,\n value,\n referenceValue,\n tempValueStrAndroid: null\n }));\n if (valueManager.areValuesEqual(utils, state.value, value)) {\n return;\n }\n const context = {\n validationError: validator({\n adapter,\n value,\n timezone,\n props: internalProps\n })\n };\n handleValueChange(value, context);\n };\n const setSectionValue = (sectionIndex, newSectionValue) => {\n const newSections = [...state.sections];\n newSections[sectionIndex] = _extends({}, newSections[sectionIndex], {\n value: newSectionValue,\n modified: true\n });\n return newSections;\n };\n const clearValue = () => {\n publishValue({\n value: valueManager.emptyValue,\n referenceValue: state.referenceValue,\n sections: getSectionsFromValue(valueManager.emptyValue)\n });\n };\n const clearActiveSection = () => {\n if (activeSectionIndex == null) {\n return;\n }\n const activeSection = state.sections[activeSectionIndex];\n const activeDateManager = fieldValueManager.getActiveDateManager(utils, state, activeSection);\n const nonEmptySectionCountBefore = activeDateManager.getSections(state.sections).filter(section => section.value !== '').length;\n const hasNoOtherNonEmptySections = nonEmptySectionCountBefore === (activeSection.value === '' ? 0 : 1);\n const newSections = setSectionValue(activeSectionIndex, '');\n const newActiveDate = hasNoOtherNonEmptySections ? null : utils.getInvalidDate();\n const newValues = activeDateManager.getNewValuesFromNewActiveDate(newActiveDate);\n publishValue(_extends({}, newValues, {\n sections: newSections\n }));\n };\n const updateValueFromValueStr = valueStr => {\n const parseDateStr = (dateStr, referenceDate) => {\n const date = utils.parse(dateStr, format);\n if (date == null || !utils.isValid(date)) {\n return null;\n }\n const sections = buildSectionsFromFormat({\n utils,\n localeText: translations,\n localizedDigits,\n format,\n date,\n formatDensity,\n shouldRespectLeadingZeros,\n enableAccessibleFieldDOMStructure,\n isRtl\n });\n return mergeDateIntoReferenceDate(utils, date, sections, referenceDate, false);\n };\n const newValue = fieldValueManager.parseValueStr(valueStr, state.referenceValue, parseDateStr);\n const newReferenceValue = fieldValueManager.updateReferenceValue(utils, newValue, state.referenceValue);\n publishValue({\n value: newValue,\n referenceValue: newReferenceValue,\n sections: getSectionsFromValue(newValue, state.sections)\n });\n };\n const updateSectionValue = ({\n activeSection,\n newSectionValue,\n shouldGoToNextSection\n }) => {\n /**\n * 1. Decide which section should be focused\n */\n if (shouldGoToNextSection && activeSectionIndex < state.sections.length - 1) {\n setSelectedSections(activeSectionIndex + 1);\n }\n\n /**\n * 2. Try to build a valid date from the new section value\n */\n const activeDateManager = fieldValueManager.getActiveDateManager(utils, state, activeSection);\n const newSections = setSectionValue(activeSectionIndex, newSectionValue);\n const newActiveDateSections = activeDateManager.getSections(newSections);\n const newActiveDate = getDateFromDateSections(utils, newActiveDateSections, localizedDigits);\n let values;\n let shouldPublish;\n\n /**\n * If the new date is valid,\n * Then we merge the value of the modified sections into the reference date.\n * This makes sure that we don't lose some information of the initial date (like the time on a date field).\n */\n if (newActiveDate != null && utils.isValid(newActiveDate)) {\n const mergedDate = mergeDateIntoReferenceDate(utils, newActiveDate, newActiveDateSections, activeDateManager.referenceDate, true);\n values = activeDateManager.getNewValuesFromNewActiveDate(mergedDate);\n shouldPublish = true;\n } else {\n values = activeDateManager.getNewValuesFromNewActiveDate(newActiveDate);\n shouldPublish = (newActiveDate != null && !utils.isValid(newActiveDate)) !== (activeDateManager.date != null && !utils.isValid(activeDateManager.date));\n }\n\n /**\n * Publish or update the internal state with the new value and sections.\n */\n if (shouldPublish) {\n return publishValue(_extends({}, values, {\n sections: newSections\n }));\n }\n return setState(prevState => _extends({}, prevState, values, {\n sections: newSections,\n tempValueStrAndroid: null\n }));\n };\n const setTempAndroidValueStr = tempValueStrAndroid => setState(prev => _extends({}, prev, {\n tempValueStrAndroid\n }));\n React.useEffect(() => {\n const sections = getSectionsFromValue(state.value);\n validateSections(sections, valueType);\n setState(prevState => _extends({}, prevState, {\n sections\n }));\n }, [format, utils.locale, isRtl]); // eslint-disable-line react-hooks/exhaustive-deps\n\n React.useEffect(() => {\n let shouldUpdate;\n if (!valueManager.areValuesEqual(utils, state.value, valueFromTheOutside)) {\n shouldUpdate = true;\n } else {\n shouldUpdate = valueManager.getTimezone(utils, state.value) !== valueManager.getTimezone(utils, valueFromTheOutside);\n }\n if (shouldUpdate) {\n setState(prevState => _extends({}, prevState, {\n value: valueFromTheOutside,\n referenceValue: fieldValueManager.updateReferenceValue(utils, valueFromTheOutside, prevState.referenceValue),\n sections: getSectionsFromValue(valueFromTheOutside)\n }));\n }\n }, [valueFromTheOutside]); // eslint-disable-line react-hooks/exhaustive-deps\n\n return {\n state,\n activeSectionIndex,\n parsedSelectedSections,\n setSelectedSections,\n clearValue,\n clearActiveSection,\n updateSectionValue,\n updateValueFromValueStr,\n setTempAndroidValueStr,\n getSectionsFromValue,\n sectionsValueBoundaries,\n localizedDigits,\n timezone\n };\n};","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport { useUtils } from \"../useUtils.js\";\nimport { changeSectionValueFormat, cleanDigitSectionValue, doesSectionFormatHaveLeadingZeros, getDateSectionConfigFromFormatToken, getDaysInWeekStr, getLetterEditingOptions, applyLocalizedDigits, removeLocalizedDigits, isStringNumber } from \"./useField.utils.js\";\n\n/**\n * The letter editing and the numeric editing each define a `CharacterEditingApplier`.\n * This function decides what the new section value should be and if the focus should switch to the next section.\n *\n * If it returns `null`, then the section value is not updated and the focus does not move.\n */\n\n/**\n * Function called by `applyQuery` which decides:\n * - what is the new section value ?\n * - should the query used to get this value be stored for the next key press ?\n *\n * If it returns `{ sectionValue: string; shouldGoToNextSection: boolean }`,\n * Then we store the query and update the section with the new value.\n *\n * If it returns `{ saveQuery: true` },\n * Then we store the query and don't update the section.\n *\n * If it returns `{ saveQuery: false },\n * Then we do nothing.\n */\n\nconst QUERY_LIFE_DURATION_MS = 5000;\nconst isQueryResponseWithoutValue = response => response.saveQuery != null;\n\n/**\n * Update the active section value when the user pressed a key that is not a navigation key (arrow key for example).\n * This hook has two main editing behaviors\n *\n * 1. The numeric editing when the user presses a digit\n * 2. The letter editing when the user presses another key\n */\nexport const useFieldCharacterEditing = ({\n sections,\n updateSectionValue,\n sectionsValueBoundaries,\n localizedDigits,\n setTempAndroidValueStr,\n timezone\n}) => {\n const utils = useUtils();\n const [query, setQuery] = React.useState(null);\n const resetQuery = useEventCallback(() => setQuery(null));\n React.useEffect(() => {\n if (query != null && sections[query.sectionIndex]?.type !== query.sectionType) {\n resetQuery();\n }\n }, [sections, query, resetQuery]);\n React.useEffect(() => {\n if (query != null) {\n const timeout = setTimeout(() => resetQuery(), QUERY_LIFE_DURATION_MS);\n return () => {\n clearTimeout(timeout);\n };\n }\n return () => {};\n }, [query, resetQuery]);\n const applyQuery = ({\n keyPressed,\n sectionIndex\n }, getFirstSectionValueMatchingWithQuery, isValidQueryValue) => {\n const cleanKeyPressed = keyPressed.toLowerCase();\n const activeSection = sections[sectionIndex];\n\n // The current query targets the section being editing\n // We can try to concatenate the value\n if (query != null && (!isValidQueryValue || isValidQueryValue(query.value)) && query.sectionIndex === sectionIndex) {\n const concatenatedQueryValue = `${query.value}${cleanKeyPressed}`;\n const queryResponse = getFirstSectionValueMatchingWithQuery(concatenatedQueryValue, activeSection);\n if (!isQueryResponseWithoutValue(queryResponse)) {\n setQuery({\n sectionIndex,\n value: concatenatedQueryValue,\n sectionType: activeSection.type\n });\n return queryResponse;\n }\n }\n const queryResponse = getFirstSectionValueMatchingWithQuery(cleanKeyPressed, activeSection);\n if (isQueryResponseWithoutValue(queryResponse) && !queryResponse.saveQuery) {\n resetQuery();\n return null;\n }\n setQuery({\n sectionIndex,\n value: cleanKeyPressed,\n sectionType: activeSection.type\n });\n if (isQueryResponseWithoutValue(queryResponse)) {\n return null;\n }\n return queryResponse;\n };\n const applyLetterEditing = params => {\n const findMatchingOptions = (format, options, queryValue) => {\n const matchingValues = options.filter(option => option.toLowerCase().startsWith(queryValue));\n if (matchingValues.length === 0) {\n return {\n saveQuery: false\n };\n }\n return {\n sectionValue: matchingValues[0],\n shouldGoToNextSection: matchingValues.length === 1\n };\n };\n const testQueryOnFormatAndFallbackFormat = (queryValue, activeSection, fallbackFormat, formatFallbackValue) => {\n const getOptions = format => getLetterEditingOptions(utils, timezone, activeSection.type, format);\n if (activeSection.contentType === 'letter') {\n return findMatchingOptions(activeSection.format, getOptions(activeSection.format), queryValue);\n }\n\n // When editing a digit-format month / weekDay and the user presses a letter,\n // We can support the letter editing by using the letter-format month / weekDay and re-formatting the result.\n // We just have to make sure that the default month / weekDay format is a letter format,\n if (fallbackFormat && formatFallbackValue != null && getDateSectionConfigFromFormatToken(utils, fallbackFormat).contentType === 'letter') {\n const fallbackOptions = getOptions(fallbackFormat);\n const response = findMatchingOptions(fallbackFormat, fallbackOptions, queryValue);\n if (isQueryResponseWithoutValue(response)) {\n return {\n saveQuery: false\n };\n }\n return _extends({}, response, {\n sectionValue: formatFallbackValue(response.sectionValue, fallbackOptions)\n });\n }\n return {\n saveQuery: false\n };\n };\n const getFirstSectionValueMatchingWithQuery = (queryValue, activeSection) => {\n switch (activeSection.type) {\n case 'month':\n {\n const formatFallbackValue = fallbackValue => changeSectionValueFormat(utils, fallbackValue, utils.formats.month, activeSection.format);\n return testQueryOnFormatAndFallbackFormat(queryValue, activeSection, utils.formats.month, formatFallbackValue);\n }\n case 'weekDay':\n {\n const formatFallbackValue = (fallbackValue, fallbackOptions) => fallbackOptions.indexOf(fallbackValue).toString();\n return testQueryOnFormatAndFallbackFormat(queryValue, activeSection, utils.formats.weekday, formatFallbackValue);\n }\n case 'meridiem':\n {\n return testQueryOnFormatAndFallbackFormat(queryValue, activeSection);\n }\n default:\n {\n return {\n saveQuery: false\n };\n }\n }\n };\n return applyQuery(params, getFirstSectionValueMatchingWithQuery);\n };\n const applyNumericEditing = params => {\n const getNewSectionValue = (queryValue, section) => {\n const cleanQueryValue = removeLocalizedDigits(queryValue, localizedDigits);\n const queryValueNumber = Number(cleanQueryValue);\n const sectionBoundaries = sectionsValueBoundaries[section.type]({\n currentDate: null,\n format: section.format,\n contentType: section.contentType\n });\n if (queryValueNumber > sectionBoundaries.maximum) {\n return {\n saveQuery: false\n };\n }\n\n // If the user types `0` on a month section,\n // It is below the minimum, but we want to store the `0` in the query,\n // So that when he pressed `1`, it will store `01` and move to the next section.\n if (queryValueNumber < sectionBoundaries.minimum) {\n return {\n saveQuery: true\n };\n }\n const shouldGoToNextSection = queryValueNumber * 10 > sectionBoundaries.maximum || cleanQueryValue.length === sectionBoundaries.maximum.toString().length;\n const newSectionValue = cleanDigitSectionValue(utils, queryValueNumber, sectionBoundaries, localizedDigits, section);\n return {\n sectionValue: newSectionValue,\n shouldGoToNextSection\n };\n };\n const getFirstSectionValueMatchingWithQuery = (queryValue, activeSection) => {\n if (activeSection.contentType === 'digit' || activeSection.contentType === 'digit-with-letter') {\n return getNewSectionValue(queryValue, activeSection);\n }\n\n // When editing a letter-format month and the user presses a digit,\n // We can support the numeric editing by using the digit-format month and re-formatting the result.\n if (activeSection.type === 'month') {\n const hasLeadingZerosInFormat = doesSectionFormatHaveLeadingZeros(utils, 'digit', 'month', 'MM');\n const response = getNewSectionValue(queryValue, {\n type: activeSection.type,\n format: 'MM',\n hasLeadingZerosInFormat,\n hasLeadingZerosInInput: true,\n contentType: 'digit',\n maxLength: 2\n });\n if (isQueryResponseWithoutValue(response)) {\n return response;\n }\n const formattedValue = changeSectionValueFormat(utils, response.sectionValue, 'MM', activeSection.format);\n return _extends({}, response, {\n sectionValue: formattedValue\n });\n }\n\n // When editing a letter-format weekDay and the user presses a digit,\n // We can support the numeric editing by returning the nth day in the week day array.\n if (activeSection.type === 'weekDay') {\n const response = getNewSectionValue(queryValue, activeSection);\n if (isQueryResponseWithoutValue(response)) {\n return response;\n }\n const formattedValue = getDaysInWeekStr(utils, activeSection.format)[Number(response.sectionValue) - 1];\n return _extends({}, response, {\n sectionValue: formattedValue\n });\n }\n return {\n saveQuery: false\n };\n };\n return applyQuery(params, getFirstSectionValueMatchingWithQuery, queryValue => isStringNumber(queryValue, localizedDigits));\n };\n const applyCharacterEditing = useEventCallback(params => {\n const activeSection = sections[params.sectionIndex];\n const isNumericEditing = isStringNumber(params.keyPressed, localizedDigits);\n const response = isNumericEditing ? applyNumericEditing(_extends({}, params, {\n keyPressed: applyLocalizedDigits(params.keyPressed, localizedDigits)\n })) : applyLetterEditing(params);\n if (response == null) {\n setTempAndroidValueStr(null);\n return;\n }\n updateSectionValue({\n activeSection,\n newSectionValue: response.sectionValue,\n shouldGoToNextSection: response.shouldGoToNextSection\n });\n });\n return {\n applyCharacterEditing,\n resetCharacterQuery: resetQuery\n };\n};","import * as React from 'react';\nimport useForkRef from '@mui/utils/useForkRef';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport useEnhancedEffect from '@mui/utils/useEnhancedEffect';\nimport useId from '@mui/utils/useId';\nimport { getSectionValueNow, getSectionValueText, parseSelectedSections } from \"./useField.utils.js\";\nimport { getActiveElement } from \"../../utils/utils.js\";\nimport { usePickersTranslations } from \"../../../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../useUtils.js\";\nexport const useFieldV7TextField = params => {\n const {\n internalProps: {\n disabled,\n readOnly = false\n },\n forwardedProps: {\n sectionListRef: inSectionListRef,\n onBlur,\n onClick,\n onFocus,\n onInput,\n onPaste,\n focused: focusedProp,\n autoFocus = false\n },\n fieldValueManager,\n applyCharacterEditing,\n resetCharacterQuery,\n setSelectedSections,\n parsedSelectedSections,\n state,\n clearActiveSection,\n clearValue,\n updateSectionValue,\n updateValueFromValueStr,\n sectionOrder,\n areAllSectionsEmpty,\n sectionsValueBoundaries\n } = params;\n const sectionListRef = React.useRef(null);\n const handleSectionListRef = useForkRef(inSectionListRef, sectionListRef);\n const translations = usePickersTranslations();\n const utils = useUtils();\n const id = useId();\n const [focused, setFocused] = React.useState(false);\n const interactions = React.useMemo(() => ({\n syncSelectionToDOM: () => {\n if (!sectionListRef.current) {\n return;\n }\n const selection = document.getSelection();\n if (!selection) {\n return;\n }\n if (parsedSelectedSections == null) {\n // If the selection contains an element inside the field, we reset it.\n if (selection.rangeCount > 0 && sectionListRef.current.getRoot().contains(selection.getRangeAt(0).startContainer)) {\n selection.removeAllRanges();\n }\n if (focused) {\n sectionListRef.current.getRoot().blur();\n }\n return;\n }\n\n // On multi input range pickers we want to update selection range only for the active input\n if (!sectionListRef.current.getRoot().contains(getActiveElement(document))) {\n return;\n }\n const range = new window.Range();\n let target;\n if (parsedSelectedSections === 'all') {\n target = sectionListRef.current.getRoot();\n } else {\n const section = state.sections[parsedSelectedSections];\n if (section.type === 'empty') {\n target = sectionListRef.current.getSectionContainer(parsedSelectedSections);\n } else {\n target = sectionListRef.current.getSectionContent(parsedSelectedSections);\n }\n }\n range.selectNodeContents(target);\n target.focus();\n selection.removeAllRanges();\n selection.addRange(range);\n },\n getActiveSectionIndexFromDOM: () => {\n const activeElement = getActiveElement(document);\n if (!activeElement || !sectionListRef.current || !sectionListRef.current.getRoot().contains(activeElement)) {\n return null;\n }\n return sectionListRef.current.getSectionIndexFromDOMElement(activeElement);\n },\n focusField: (newSelectedSections = 0) => {\n if (!sectionListRef.current) {\n return;\n }\n const newParsedSelectedSections = parseSelectedSections(newSelectedSections, state.sections);\n setFocused(true);\n sectionListRef.current.getSectionContent(newParsedSelectedSections).focus();\n },\n setSelectedSections: newSelectedSections => {\n if (!sectionListRef.current) {\n return;\n }\n const newParsedSelectedSections = parseSelectedSections(newSelectedSections, state.sections);\n const newActiveSectionIndex = newParsedSelectedSections === 'all' ? 0 : newParsedSelectedSections;\n setFocused(newActiveSectionIndex !== null);\n setSelectedSections(newSelectedSections);\n },\n isFieldFocused: () => {\n const activeElement = getActiveElement(document);\n return !!sectionListRef.current && sectionListRef.current.getRoot().contains(activeElement);\n }\n }), [parsedSelectedSections, setSelectedSections, state.sections, focused]);\n\n /**\n * If a section content has been updated with a value we don't want to keep,\n * Then we need to imperatively revert it (we can't let React do it because the value did not change in his internal representation).\n */\n const revertDOMSectionChange = useEventCallback(sectionIndex => {\n if (!sectionListRef.current) {\n return;\n }\n const section = state.sections[sectionIndex];\n sectionListRef.current.getSectionContent(sectionIndex).innerHTML = section.value || section.placeholder;\n interactions.syncSelectionToDOM();\n });\n const handleContainerClick = useEventCallback((event, ...args) => {\n // The click event on the clear button would propagate to the input, trigger this handler and result in a wrong section selection.\n // We avoid this by checking if the call of `handleContainerClick` is actually intended, or a side effect.\n if (event.isDefaultPrevented() || !sectionListRef.current) {\n return;\n }\n setFocused(true);\n onClick?.(event, ...args);\n if (parsedSelectedSections === 'all') {\n setTimeout(() => {\n const cursorPosition = document.getSelection().getRangeAt(0).startOffset;\n if (cursorPosition === 0) {\n setSelectedSections(sectionOrder.startIndex);\n return;\n }\n let sectionIndex = 0;\n let cursorOnStartOfSection = 0;\n while (cursorOnStartOfSection < cursorPosition && sectionIndex < state.sections.length) {\n const section = state.sections[sectionIndex];\n sectionIndex += 1;\n cursorOnStartOfSection += `${section.startSeparator}${section.value || section.placeholder}${section.endSeparator}`.length;\n }\n setSelectedSections(sectionIndex - 1);\n });\n } else if (!focused) {\n setFocused(true);\n setSelectedSections(sectionOrder.startIndex);\n } else {\n const hasClickedOnASection = sectionListRef.current.getRoot().contains(event.target);\n if (!hasClickedOnASection) {\n setSelectedSections(sectionOrder.startIndex);\n }\n }\n });\n const handleContainerInput = useEventCallback(event => {\n onInput?.(event);\n if (!sectionListRef.current || parsedSelectedSections !== 'all') {\n return;\n }\n const target = event.target;\n const keyPressed = target.textContent ?? '';\n sectionListRef.current.getRoot().innerHTML = state.sections.map(section => `${section.startSeparator}${section.value || section.placeholder}${section.endSeparator}`).join('');\n interactions.syncSelectionToDOM();\n if (keyPressed.length === 0 || keyPressed.charCodeAt(0) === 10) {\n resetCharacterQuery();\n clearValue();\n setSelectedSections('all');\n } else if (keyPressed.length > 1) {\n updateValueFromValueStr(keyPressed);\n } else {\n applyCharacterEditing({\n keyPressed,\n sectionIndex: 0\n });\n }\n });\n const handleContainerPaste = useEventCallback(event => {\n onPaste?.(event);\n if (readOnly || parsedSelectedSections !== 'all') {\n event.preventDefault();\n return;\n }\n const pastedValue = event.clipboardData.getData('text');\n event.preventDefault();\n resetCharacterQuery();\n updateValueFromValueStr(pastedValue);\n });\n const handleContainerFocus = useEventCallback((...args) => {\n onFocus?.(...args);\n if (focused || !sectionListRef.current) {\n return;\n }\n setFocused(true);\n const isFocusInsideASection = sectionListRef.current.getSectionIndexFromDOMElement(getActiveElement(document)) != null;\n if (!isFocusInsideASection) {\n setSelectedSections(sectionOrder.startIndex);\n }\n });\n const handleContainerBlur = useEventCallback((...args) => {\n onBlur?.(...args);\n setTimeout(() => {\n if (!sectionListRef.current) {\n return;\n }\n const activeElement = getActiveElement(document);\n const shouldBlur = !sectionListRef.current.getRoot().contains(activeElement);\n if (shouldBlur) {\n setFocused(false);\n setSelectedSections(null);\n }\n });\n });\n const getInputContainerClickHandler = useEventCallback(sectionIndex => event => {\n // The click event on the clear button would propagate to the input, trigger this handler and result in a wrong section selection.\n // We avoid this by checking if the call to this function is actually intended, or a side effect.\n if (event.isDefaultPrevented()) {\n return;\n }\n setSelectedSections(sectionIndex);\n });\n const handleInputContentMouseUp = useEventCallback(event => {\n // Without this, the browser will remove the selected when clicking inside an already-selected section.\n event.preventDefault();\n });\n const getInputContentFocusHandler = useEventCallback(sectionIndex => () => {\n setSelectedSections(sectionIndex);\n });\n const handleInputContentPaste = useEventCallback(event => {\n // prevent default to avoid the input `onInput` handler being called\n event.preventDefault();\n if (readOnly || disabled || typeof parsedSelectedSections !== 'number') {\n return;\n }\n const activeSection = state.sections[parsedSelectedSections];\n const pastedValue = event.clipboardData.getData('text');\n const lettersOnly = /^[a-zA-Z]+$/.test(pastedValue);\n const digitsOnly = /^[0-9]+$/.test(pastedValue);\n const digitsAndLetterOnly = /^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(pastedValue);\n const isValidPastedValue = activeSection.contentType === 'letter' && lettersOnly || activeSection.contentType === 'digit' && digitsOnly || activeSection.contentType === 'digit-with-letter' && digitsAndLetterOnly;\n if (isValidPastedValue) {\n resetCharacterQuery();\n updateSectionValue({\n activeSection,\n newSectionValue: pastedValue,\n shouldGoToNextSection: true\n });\n }\n // If the pasted value corresponds to a single section, but not the expected type, we skip the modification\n else if (!lettersOnly && !digitsOnly) {\n resetCharacterQuery();\n updateValueFromValueStr(pastedValue);\n }\n });\n const handleInputContentDragOver = useEventCallback(event => {\n event.preventDefault();\n event.dataTransfer.dropEffect = 'none';\n });\n const handleInputContentInput = useEventCallback(event => {\n if (!sectionListRef.current) {\n return;\n }\n const target = event.target;\n const keyPressed = target.textContent ?? '';\n const sectionIndex = sectionListRef.current.getSectionIndexFromDOMElement(target);\n const section = state.sections[sectionIndex];\n if (readOnly || !sectionListRef.current) {\n revertDOMSectionChange(sectionIndex);\n return;\n }\n if (keyPressed.length === 0) {\n if (section.value === '') {\n revertDOMSectionChange(sectionIndex);\n return;\n }\n const inputType = event.nativeEvent.inputType;\n if (inputType === 'insertParagraph' || inputType === 'insertLineBreak') {\n revertDOMSectionChange(sectionIndex);\n return;\n }\n resetCharacterQuery();\n clearActiveSection();\n return;\n }\n applyCharacterEditing({\n keyPressed,\n sectionIndex\n });\n\n // The DOM value needs to remain the one React is expecting.\n revertDOMSectionChange(sectionIndex);\n });\n useEnhancedEffect(() => {\n if (!focused || !sectionListRef.current) {\n return;\n }\n if (parsedSelectedSections === 'all') {\n sectionListRef.current.getRoot().focus();\n } else if (typeof parsedSelectedSections === 'number') {\n const domElement = sectionListRef.current.getSectionContent(parsedSelectedSections);\n if (domElement) {\n domElement.focus();\n }\n }\n }, [parsedSelectedSections, focused]);\n const sectionBoundaries = React.useMemo(() => {\n return state.sections.reduce((acc, next) => {\n acc[next.type] = sectionsValueBoundaries[next.type]({\n currentDate: null,\n contentType: next.contentType,\n format: next.format\n });\n return acc;\n }, {});\n }, [sectionsValueBoundaries, state.sections]);\n const isContainerEditable = parsedSelectedSections === 'all';\n const elements = React.useMemo(() => {\n return state.sections.map((section, index) => {\n const isEditable = !isContainerEditable && !disabled && !readOnly;\n return {\n container: {\n 'data-sectionindex': index,\n onClick: getInputContainerClickHandler(index)\n },\n content: {\n tabIndex: isContainerEditable || index > 0 ? -1 : 0,\n contentEditable: !isContainerEditable && !disabled && !readOnly,\n role: 'spinbutton',\n id: `${id}-${section.type}`,\n 'aria-labelledby': `${id}-${section.type}`,\n 'aria-readonly': readOnly,\n 'aria-valuenow': getSectionValueNow(section, utils),\n 'aria-valuemin': sectionBoundaries[section.type].minimum,\n 'aria-valuemax': sectionBoundaries[section.type].maximum,\n 'aria-valuetext': section.value ? getSectionValueText(section, utils) : translations.empty,\n 'aria-label': translations[section.type],\n 'aria-disabled': disabled,\n spellCheck: isEditable ? false : undefined,\n autoCapitalize: isEditable ? 'off' : undefined,\n autoCorrect: isEditable ? 'off' : undefined,\n [parseInt(React.version, 10) >= 17 ? 'enterKeyHint' : 'enterkeyhint']: isEditable ? 'next' : undefined,\n children: section.value || section.placeholder,\n onInput: handleInputContentInput,\n onPaste: handleInputContentPaste,\n onFocus: getInputContentFocusHandler(index),\n onDragOver: handleInputContentDragOver,\n onMouseUp: handleInputContentMouseUp,\n inputMode: section.contentType === 'letter' ? 'text' : 'numeric'\n },\n before: {\n children: section.startSeparator\n },\n after: {\n children: section.endSeparator\n }\n };\n });\n }, [state.sections, getInputContentFocusHandler, handleInputContentPaste, handleInputContentDragOver, handleInputContentInput, getInputContainerClickHandler, handleInputContentMouseUp, disabled, readOnly, isContainerEditable, translations, utils, sectionBoundaries, id]);\n const handleValueStrChange = useEventCallback(event => {\n updateValueFromValueStr(event.target.value);\n });\n const valueStr = React.useMemo(() => areAllSectionsEmpty ? '' : fieldValueManager.getV7HiddenInputValueFromSections(state.sections), [areAllSectionsEmpty, state.sections, fieldValueManager]);\n React.useEffect(() => {\n if (sectionListRef.current == null) {\n throw new Error(['MUI X: The `sectionListRef` prop has not been initialized by `PickersSectionList`', 'You probably tried to pass a component to the `textField` slot that contains an `` element instead of a `PickersSectionList`.', '', 'If you want to keep using an `` HTML element for the editing, please remove the `enableAccessibleFieldDOMStructure` prop from your picker or field component:', '', '', '', 'Learn more about the field accessible DOM structure on the MUI documentation: https://mui.com/x/react-date-pickers/fields/#fields-to-edit-a-single-element'].join('\\n'));\n }\n if (autoFocus && sectionListRef.current) {\n sectionListRef.current.getSectionContent(sectionOrder.startIndex).focus();\n }\n }, []); // eslint-disable-line react-hooks/exhaustive-deps\n\n return {\n interactions,\n returnedValue: {\n // Forwarded\n autoFocus,\n readOnly,\n focused: focusedProp ?? focused,\n sectionListRef: handleSectionListRef,\n onBlur: handleContainerBlur,\n onClick: handleContainerClick,\n onFocus: handleContainerFocus,\n onInput: handleContainerInput,\n onPaste: handleContainerPaste,\n // Additional\n enableAccessibleFieldDOMStructure: true,\n elements,\n // TODO v7: Try to set to undefined when there is a section selected.\n tabIndex: parsedSelectedSections === 0 ? -1 : 0,\n contentEditable: isContainerEditable,\n value: valueStr,\n onChange: handleValueStrChange,\n areAllSectionsEmpty\n }\n };\n};","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport useForkRef from '@mui/utils/useForkRef';\nimport { getActiveElement } from \"../../utils/utils.js\";\nimport { getSectionVisibleValue, isAndroid } from \"./useField.utils.js\";\nconst cleanString = dirtyString => dirtyString.replace(/[\\u2066\\u2067\\u2068\\u2069]/g, '');\nexport const addPositionPropertiesToSections = (sections, localizedDigits, isRtl) => {\n let position = 0;\n let positionInInput = isRtl ? 1 : 0;\n const newSections = [];\n for (let i = 0; i < sections.length; i += 1) {\n const section = sections[i];\n const renderedValue = getSectionVisibleValue(section, isRtl ? 'input-rtl' : 'input-ltr', localizedDigits);\n const sectionStr = `${section.startSeparator}${renderedValue}${section.endSeparator}`;\n const sectionLength = cleanString(sectionStr).length;\n const sectionLengthInInput = sectionStr.length;\n\n // The ...InInput values consider the unicode characters but do include them in their indexes\n const cleanedValue = cleanString(renderedValue);\n const startInInput = positionInInput + (cleanedValue === '' ? 0 : renderedValue.indexOf(cleanedValue[0])) + section.startSeparator.length;\n const endInInput = startInInput + cleanedValue.length;\n newSections.push(_extends({}, section, {\n start: position,\n end: position + sectionLength,\n startInInput,\n endInInput\n }));\n position += sectionLength;\n // Move position to the end of string associated to the current section\n positionInInput += sectionLengthInInput;\n }\n return newSections;\n};\nexport const useFieldV6TextField = params => {\n const isRtl = useRtl();\n const focusTimeoutRef = React.useRef();\n const selectionSyncTimeoutRef = React.useRef();\n const {\n forwardedProps: {\n onFocus,\n onClick,\n onPaste,\n onBlur,\n inputRef: inputRefProp,\n placeholder: inPlaceholder\n },\n internalProps: {\n readOnly = false,\n disabled = false\n },\n parsedSelectedSections,\n activeSectionIndex,\n state,\n fieldValueManager,\n valueManager,\n applyCharacterEditing,\n resetCharacterQuery,\n updateSectionValue,\n updateValueFromValueStr,\n clearActiveSection,\n clearValue,\n setTempAndroidValueStr,\n setSelectedSections,\n getSectionsFromValue,\n areAllSectionsEmpty,\n localizedDigits\n } = params;\n const inputRef = React.useRef(null);\n const handleRef = useForkRef(inputRefProp, inputRef);\n const sections = React.useMemo(() => addPositionPropertiesToSections(state.sections, localizedDigits, isRtl), [state.sections, localizedDigits, isRtl]);\n const interactions = React.useMemo(() => ({\n syncSelectionToDOM: () => {\n if (!inputRef.current) {\n return;\n }\n if (parsedSelectedSections == null) {\n if (inputRef.current.scrollLeft) {\n // Ensure that input content is not marked as selected.\n // setting selection range to 0 causes issues in Safari.\n // https://bugs.webkit.org/show_bug.cgi?id=224425\n inputRef.current.scrollLeft = 0;\n }\n return;\n }\n\n // On multi input range pickers we want to update selection range only for the active input\n // This helps to avoid the focus jumping on Safari https://github.com/mui/mui-x/issues/9003\n // because WebKit implements the `setSelectionRange` based on the spec: https://bugs.webkit.org/show_bug.cgi?id=224425\n if (inputRef.current !== getActiveElement(document)) {\n return;\n }\n\n // Fix scroll jumping on iOS browser: https://github.com/mui/mui-x/issues/8321\n const currentScrollTop = inputRef.current.scrollTop;\n if (parsedSelectedSections === 'all') {\n inputRef.current.select();\n } else {\n const selectedSection = sections[parsedSelectedSections];\n const selectionStart = selectedSection.type === 'empty' ? selectedSection.startInInput - selectedSection.startSeparator.length : selectedSection.startInInput;\n const selectionEnd = selectedSection.type === 'empty' ? selectedSection.endInInput + selectedSection.endSeparator.length : selectedSection.endInInput;\n if (selectionStart !== inputRef.current.selectionStart || selectionEnd !== inputRef.current.selectionEnd) {\n if (inputRef.current === getActiveElement(document)) {\n inputRef.current.setSelectionRange(selectionStart, selectionEnd);\n }\n }\n clearTimeout(selectionSyncTimeoutRef.current);\n selectionSyncTimeoutRef.current = setTimeout(() => {\n // handle case when the selection is not updated correctly\n // could happen on Android\n if (inputRef.current && inputRef.current === getActiveElement(document) &&\n // The section might loose all selection, where `selectionStart === selectionEnd`\n // https://github.com/mui/mui-x/pull/13652\n inputRef.current.selectionStart === inputRef.current.selectionEnd && (inputRef.current.selectionStart !== selectionStart || inputRef.current.selectionEnd !== selectionEnd)) {\n interactions.syncSelectionToDOM();\n }\n });\n }\n\n // Even reading this variable seems to do the trick, but also setting it just to make use of it\n inputRef.current.scrollTop = currentScrollTop;\n },\n getActiveSectionIndexFromDOM: () => {\n const browserStartIndex = inputRef.current.selectionStart ?? 0;\n const browserEndIndex = inputRef.current.selectionEnd ?? 0;\n if (browserStartIndex === 0 && browserEndIndex === 0) {\n return null;\n }\n const nextSectionIndex = browserStartIndex <= sections[0].startInInput ? 1 // Special case if browser index is in invisible characters at the beginning.\n : sections.findIndex(section => section.startInInput - section.startSeparator.length > browserStartIndex);\n return nextSectionIndex === -1 ? sections.length - 1 : nextSectionIndex - 1;\n },\n focusField: (newSelectedSection = 0) => {\n inputRef.current?.focus();\n setSelectedSections(newSelectedSection);\n },\n setSelectedSections: newSelectedSections => setSelectedSections(newSelectedSections),\n isFieldFocused: () => inputRef.current === getActiveElement(document)\n }), [inputRef, parsedSelectedSections, sections, setSelectedSections]);\n const syncSelectionFromDOM = () => {\n const browserStartIndex = inputRef.current.selectionStart ?? 0;\n let nextSectionIndex;\n if (browserStartIndex <= sections[0].startInInput) {\n // Special case if browser index is in invisible characters at the beginning\n nextSectionIndex = 1;\n } else if (browserStartIndex >= sections[sections.length - 1].endInInput) {\n // If the click is after the last character of the input, then we want to select the 1st section.\n nextSectionIndex = 1;\n } else {\n nextSectionIndex = sections.findIndex(section => section.startInInput - section.startSeparator.length > browserStartIndex);\n }\n const sectionIndex = nextSectionIndex === -1 ? sections.length - 1 : nextSectionIndex - 1;\n setSelectedSections(sectionIndex);\n };\n const handleInputFocus = useEventCallback((...args) => {\n onFocus?.(...args);\n // The ref is guaranteed to be resolved at this point.\n const input = inputRef.current;\n clearTimeout(focusTimeoutRef.current);\n focusTimeoutRef.current = setTimeout(() => {\n // The ref changed, the component got remounted, the focus event is no longer relevant.\n if (!input || input !== inputRef.current) {\n return;\n }\n if (activeSectionIndex != null) {\n return;\n }\n if (\n // avoid selecting all sections when focusing empty field without value\n input.value.length && Number(input.selectionEnd) - Number(input.selectionStart) === input.value.length) {\n setSelectedSections('all');\n } else {\n syncSelectionFromDOM();\n }\n });\n });\n const handleInputClick = useEventCallback((event, ...args) => {\n // The click event on the clear button would propagate to the input, trigger this handler and result in a wrong section selection.\n // We avoid this by checking if the call of `handleInputClick` is actually intended, or a side effect.\n if (event.isDefaultPrevented()) {\n return;\n }\n onClick?.(event, ...args);\n syncSelectionFromDOM();\n });\n const handleInputPaste = useEventCallback(event => {\n onPaste?.(event);\n\n // prevent default to avoid the input `onChange` handler being called\n event.preventDefault();\n if (readOnly || disabled) {\n return;\n }\n const pastedValue = event.clipboardData.getData('text');\n if (typeof parsedSelectedSections === 'number') {\n const activeSection = state.sections[parsedSelectedSections];\n const lettersOnly = /^[a-zA-Z]+$/.test(pastedValue);\n const digitsOnly = /^[0-9]+$/.test(pastedValue);\n const digitsAndLetterOnly = /^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(pastedValue);\n const isValidPastedValue = activeSection.contentType === 'letter' && lettersOnly || activeSection.contentType === 'digit' && digitsOnly || activeSection.contentType === 'digit-with-letter' && digitsAndLetterOnly;\n if (isValidPastedValue) {\n resetCharacterQuery();\n updateSectionValue({\n activeSection,\n newSectionValue: pastedValue,\n shouldGoToNextSection: true\n });\n return;\n }\n if (lettersOnly || digitsOnly) {\n // The pasted value corresponds to a single section, but not the expected type,\n // skip the modification\n return;\n }\n }\n resetCharacterQuery();\n updateValueFromValueStr(pastedValue);\n });\n const handleContainerBlur = useEventCallback((...args) => {\n onBlur?.(...args);\n setSelectedSections(null);\n });\n const handleInputChange = useEventCallback(event => {\n if (readOnly) {\n return;\n }\n const targetValue = event.target.value;\n if (targetValue === '') {\n resetCharacterQuery();\n clearValue();\n return;\n }\n const eventData = event.nativeEvent.data;\n // Calling `.fill(04/11/2022)` in playwright will trigger a change event with the requested content to insert in `event.nativeEvent.data`\n // usual changes have only the currently typed character in the `event.nativeEvent.data`\n const shouldUseEventData = eventData && eventData.length > 1;\n const valueStr = shouldUseEventData ? eventData : targetValue;\n const cleanValueStr = cleanString(valueStr);\n\n // If no section is selected or eventData should be used, we just try to parse the new value\n // This line is mostly triggered by imperative code / application tests.\n if (activeSectionIndex == null || shouldUseEventData) {\n updateValueFromValueStr(shouldUseEventData ? eventData : cleanValueStr);\n return;\n }\n let keyPressed;\n if (parsedSelectedSections === 'all' && cleanValueStr.length === 1) {\n keyPressed = cleanValueStr;\n } else {\n const prevValueStr = cleanString(fieldValueManager.getV6InputValueFromSections(sections, localizedDigits, isRtl));\n let startOfDiffIndex = -1;\n let endOfDiffIndex = -1;\n for (let i = 0; i < prevValueStr.length; i += 1) {\n if (startOfDiffIndex === -1 && prevValueStr[i] !== cleanValueStr[i]) {\n startOfDiffIndex = i;\n }\n if (endOfDiffIndex === -1 && prevValueStr[prevValueStr.length - i - 1] !== cleanValueStr[cleanValueStr.length - i - 1]) {\n endOfDiffIndex = i;\n }\n }\n const activeSection = sections[activeSectionIndex];\n const hasDiffOutsideOfActiveSection = startOfDiffIndex < activeSection.start || prevValueStr.length - endOfDiffIndex - 1 > activeSection.end;\n if (hasDiffOutsideOfActiveSection) {\n // TODO: Support if the new date is valid\n return;\n }\n\n // The active section being selected, the browser has replaced its value with the key pressed by the user.\n const activeSectionEndRelativeToNewValue = cleanValueStr.length - prevValueStr.length + activeSection.end - cleanString(activeSection.endSeparator || '').length;\n keyPressed = cleanValueStr.slice(activeSection.start + cleanString(activeSection.startSeparator || '').length, activeSectionEndRelativeToNewValue);\n }\n if (keyPressed.length === 0) {\n if (isAndroid()) {\n setTempAndroidValueStr(valueStr);\n }\n resetCharacterQuery();\n clearActiveSection();\n return;\n }\n applyCharacterEditing({\n keyPressed,\n sectionIndex: activeSectionIndex\n });\n });\n const placeholder = React.useMemo(() => {\n if (inPlaceholder !== undefined) {\n return inPlaceholder;\n }\n return fieldValueManager.getV6InputValueFromSections(getSectionsFromValue(valueManager.emptyValue), localizedDigits, isRtl);\n }, [inPlaceholder, fieldValueManager, getSectionsFromValue, valueManager.emptyValue, localizedDigits, isRtl]);\n const valueStr = React.useMemo(() => state.tempValueStrAndroid ?? fieldValueManager.getV6InputValueFromSections(state.sections, localizedDigits, isRtl), [state.sections, fieldValueManager, state.tempValueStrAndroid, localizedDigits, isRtl]);\n React.useEffect(() => {\n // Select all the sections when focused on mount (`autoFocus = true` on the input)\n if (inputRef.current && inputRef.current === getActiveElement(document)) {\n setSelectedSections('all');\n }\n return () => {\n clearTimeout(focusTimeoutRef.current);\n clearTimeout(selectionSyncTimeoutRef.current);\n };\n }, []); // eslint-disable-line react-hooks/exhaustive-deps\n\n const inputMode = React.useMemo(() => {\n if (activeSectionIndex == null) {\n return 'text';\n }\n if (state.sections[activeSectionIndex].contentType === 'letter') {\n return 'text';\n }\n return 'numeric';\n }, [activeSectionIndex, state.sections]);\n const inputHasFocus = inputRef.current && inputRef.current === getActiveElement(document);\n const shouldShowPlaceholder = !inputHasFocus && areAllSectionsEmpty;\n return {\n interactions,\n returnedValue: {\n // Forwarded\n readOnly,\n onBlur: handleContainerBlur,\n onClick: handleInputClick,\n onFocus: handleInputFocus,\n onPaste: handleInputPaste,\n inputRef: handleRef,\n // Additional\n enableAccessibleFieldDOMStructure: false,\n placeholder,\n inputMode,\n autoComplete: 'off',\n value: shouldShowPlaceholder ? '' : valueStr,\n onChange: handleInputChange\n }\n };\n};","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport useEnhancedEffect from '@mui/utils/useEnhancedEffect';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { useValidation } from \"../../../validation/index.js\";\nimport { useUtils } from \"../useUtils.js\";\nimport { adjustSectionValue, getSectionOrder } from \"./useField.utils.js\";\nimport { useFieldState } from \"./useFieldState.js\";\nimport { useFieldCharacterEditing } from \"./useFieldCharacterEditing.js\";\nimport { useFieldV7TextField } from \"./useFieldV7TextField.js\";\nimport { useFieldV6TextField } from \"./useFieldV6TextField.js\";\nexport const useField = params => {\n const utils = useUtils();\n const {\n internalProps,\n internalProps: {\n unstableFieldRef,\n minutesStep,\n enableAccessibleFieldDOMStructure = false,\n disabled = false,\n readOnly = false\n },\n forwardedProps: {\n onKeyDown,\n error,\n clearable,\n onClear\n },\n fieldValueManager,\n valueManager,\n validator\n } = params;\n const isRtl = useRtl();\n const stateResponse = useFieldState(params);\n const {\n state,\n activeSectionIndex,\n parsedSelectedSections,\n setSelectedSections,\n clearValue,\n clearActiveSection,\n updateSectionValue,\n setTempAndroidValueStr,\n sectionsValueBoundaries,\n localizedDigits,\n timezone\n } = stateResponse;\n const characterEditingResponse = useFieldCharacterEditing({\n sections: state.sections,\n updateSectionValue,\n sectionsValueBoundaries,\n localizedDigits,\n setTempAndroidValueStr,\n timezone\n });\n const {\n resetCharacterQuery\n } = characterEditingResponse;\n const areAllSectionsEmpty = valueManager.areValuesEqual(utils, state.value, valueManager.emptyValue);\n const useFieldTextField = enableAccessibleFieldDOMStructure ? useFieldV7TextField : useFieldV6TextField;\n const sectionOrder = React.useMemo(() => getSectionOrder(state.sections, isRtl && !enableAccessibleFieldDOMStructure), [state.sections, isRtl, enableAccessibleFieldDOMStructure]);\n const {\n returnedValue,\n interactions\n } = useFieldTextField(_extends({}, params, stateResponse, characterEditingResponse, {\n areAllSectionsEmpty,\n sectionOrder\n }));\n const handleContainerKeyDown = useEventCallback(event => {\n onKeyDown?.(event);\n if (disabled) {\n return;\n }\n // eslint-disable-next-line default-case\n switch (true) {\n // Select all\n case (event.ctrlKey || event.metaKey) && String.fromCharCode(event.keyCode) === 'A' && !event.shiftKey && !event.altKey:\n {\n // prevent default to make sure that the next line \"select all\" while updating\n // the internal state at the same time.\n event.preventDefault();\n setSelectedSections('all');\n break;\n }\n\n // Move selection to next section\n case event.key === 'ArrowRight':\n {\n event.preventDefault();\n if (parsedSelectedSections == null) {\n setSelectedSections(sectionOrder.startIndex);\n } else if (parsedSelectedSections === 'all') {\n setSelectedSections(sectionOrder.endIndex);\n } else {\n const nextSectionIndex = sectionOrder.neighbors[parsedSelectedSections].rightIndex;\n if (nextSectionIndex !== null) {\n setSelectedSections(nextSectionIndex);\n }\n }\n break;\n }\n\n // Move selection to previous section\n case event.key === 'ArrowLeft':\n {\n event.preventDefault();\n if (parsedSelectedSections == null) {\n setSelectedSections(sectionOrder.endIndex);\n } else if (parsedSelectedSections === 'all') {\n setSelectedSections(sectionOrder.startIndex);\n } else {\n const nextSectionIndex = sectionOrder.neighbors[parsedSelectedSections].leftIndex;\n if (nextSectionIndex !== null) {\n setSelectedSections(nextSectionIndex);\n }\n }\n break;\n }\n\n // Reset the value of the selected section\n case event.key === 'Delete':\n {\n event.preventDefault();\n if (readOnly) {\n break;\n }\n if (parsedSelectedSections == null || parsedSelectedSections === 'all') {\n clearValue();\n } else {\n clearActiveSection();\n }\n resetCharacterQuery();\n break;\n }\n\n // Increment / decrement the selected section value\n case ['ArrowUp', 'ArrowDown', 'Home', 'End', 'PageUp', 'PageDown'].includes(event.key):\n {\n event.preventDefault();\n if (readOnly || activeSectionIndex == null) {\n break;\n }\n const activeSection = state.sections[activeSectionIndex];\n const activeDateManager = fieldValueManager.getActiveDateManager(utils, state, activeSection);\n const newSectionValue = adjustSectionValue(utils, timezone, activeSection, event.key, sectionsValueBoundaries, localizedDigits, activeDateManager.date, {\n minutesStep\n });\n updateSectionValue({\n activeSection,\n newSectionValue,\n shouldGoToNextSection: false\n });\n break;\n }\n }\n });\n useEnhancedEffect(() => {\n interactions.syncSelectionToDOM();\n });\n const {\n hasValidationError\n } = useValidation({\n props: internalProps,\n validator,\n timezone,\n value: state.value,\n onError: internalProps.onError\n });\n const inputError = React.useMemo(() => {\n // only override when `error` is undefined.\n // in case of multi input fields, the `error` value is provided externally and will always be defined.\n if (error !== undefined) {\n return error;\n }\n return hasValidationError;\n }, [hasValidationError, error]);\n React.useEffect(() => {\n if (!inputError && activeSectionIndex == null) {\n resetCharacterQuery();\n }\n }, [state.referenceValue, activeSectionIndex, inputError]); // eslint-disable-line react-hooks/exhaustive-deps\n\n // If `tempValueStrAndroid` is still defined for some section when running `useEffect`,\n // Then `onChange` has only been called once, which means the user pressed `Backspace` to reset the section.\n // This causes a small flickering on Android,\n // But we can't use `useEnhancedEffect` which is always called before the second `onChange` call and then would cause false positives.\n React.useEffect(() => {\n if (state.tempValueStrAndroid != null && activeSectionIndex != null) {\n resetCharacterQuery();\n clearActiveSection();\n }\n }, [state.sections]); // eslint-disable-line react-hooks/exhaustive-deps\n\n React.useImperativeHandle(unstableFieldRef, () => ({\n getSections: () => state.sections,\n getActiveSectionIndex: interactions.getActiveSectionIndexFromDOM,\n setSelectedSections: interactions.setSelectedSections,\n focusField: interactions.focusField,\n isFieldFocused: interactions.isFieldFocused\n }));\n const handleClearValue = useEventCallback((event, ...args) => {\n event.preventDefault();\n onClear?.(event, ...args);\n clearValue();\n if (!interactions.isFieldFocused()) {\n // setSelectedSections is called internally\n interactions.focusField(0);\n } else {\n setSelectedSections(sectionOrder.startIndex);\n }\n });\n const commonForwardedProps = {\n onKeyDown: handleContainerKeyDown,\n onClear: handleClearValue,\n error: inputError,\n clearable: Boolean(clearable && !areAllSectionsEmpty && !readOnly && !disabled)\n };\n const commonAdditionalProps = {\n disabled,\n readOnly\n };\n return _extends({}, params.forwardedProps, commonForwardedProps, commonAdditionalProps, returnedValue);\n};","import { applyDefaultDate } from \"../internals/utils/date-utils.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nexport const validateDate = ({\n props,\n value,\n timezone,\n adapter\n}) => {\n if (value === null) {\n return null;\n }\n const {\n shouldDisableDate,\n shouldDisableMonth,\n shouldDisableYear,\n disablePast,\n disableFuture\n } = props;\n const now = adapter.utils.date(undefined, timezone);\n const minDate = applyDefaultDate(adapter.utils, props.minDate, adapter.defaultDates.minDate);\n const maxDate = applyDefaultDate(adapter.utils, props.maxDate, adapter.defaultDates.maxDate);\n switch (true) {\n case !adapter.utils.isValid(value):\n return 'invalidDate';\n case Boolean(shouldDisableDate && shouldDisableDate(value)):\n return 'shouldDisableDate';\n case Boolean(shouldDisableMonth && shouldDisableMonth(value)):\n return 'shouldDisableMonth';\n case Boolean(shouldDisableYear && shouldDisableYear(value)):\n return 'shouldDisableYear';\n case Boolean(disableFuture && adapter.utils.isAfterDay(value, now)):\n return 'disableFuture';\n case Boolean(disablePast && adapter.utils.isBeforeDay(value, now)):\n return 'disablePast';\n case Boolean(minDate && adapter.utils.isBeforeDay(value, minDate)):\n return 'minDate';\n case Boolean(maxDate && adapter.utils.isAfterDay(value, maxDate)):\n return 'maxDate';\n default:\n return null;\n }\n};\nvalidateDate.valueManager = singleItemValueManager;","export const DATE_VALIDATION_PROP_NAMES = ['disablePast', 'disableFuture', 'minDate', 'maxDate', 'shouldDisableDate', 'shouldDisableMonth', 'shouldDisableYear'];\nexport const TIME_VALIDATION_PROP_NAMES = ['disablePast', 'disableFuture', 'minTime', 'maxTime', 'shouldDisableTime', 'minutesStep', 'ampm', 'disableIgnoringDatePartForTimeValidation'];\nexport const DATE_TIME_VALIDATION_PROP_NAMES = ['minDateTime', 'maxDateTime'];\nconst VALIDATION_PROP_NAMES = [...DATE_VALIDATION_PROP_NAMES, ...TIME_VALIDATION_PROP_NAMES, ...DATE_TIME_VALIDATION_PROP_NAMES];\n/**\n * Extract the validation props for the props received by a component.\n * Limit the risk of forgetting some of them and reduce the bundle size.\n */\nexport const extractValidationProps = props => VALIDATION_PROP_NAMES.reduce((extractedProps, propName) => {\n if (props.hasOwnProperty(propName)) {\n extractedProps[propName] = props[propName];\n }\n return extractedProps;\n}, {});","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport { DATE_TIME_VALIDATION_PROP_NAMES, DATE_VALIDATION_PROP_NAMES, TIME_VALIDATION_PROP_NAMES } from \"../validation/extractValidationProps.js\";\nconst SHARED_FIELD_INTERNAL_PROP_NAMES = ['value', 'defaultValue', 'referenceDate', 'format', 'formatDensity', 'onChange', 'timezone', 'onError', 'shouldRespectLeadingZeros', 'selectedSections', 'onSelectedSectionsChange', 'unstableFieldRef', 'enableAccessibleFieldDOMStructure', 'disabled', 'readOnly', 'dateSeparator'];\n/**\n * Split the props received by the field component into:\n * - `internalProps` which are used by the various hooks called by the field component.\n * - `forwardedProps` which are passed to the underlying component.\n * Note that some forwarded props might be used by the hooks as well.\n * For instance, hooks like `useDateField` need props like `autoFocus` to know how to behave.\n * @template TProps, TValueType\n * @param {TProps} props The props received by the field component.\n * @param {TValueType} valueType The type of the field value ('date', 'time', or 'date-time').\n */\nexport const useSplitFieldProps = (props, valueType) => {\n return React.useMemo(() => {\n const forwardedProps = _extends({}, props);\n const internalProps = {};\n const extractProp = propName => {\n if (forwardedProps.hasOwnProperty(propName)) {\n // @ts-ignore\n internalProps[propName] = forwardedProps[propName];\n delete forwardedProps[propName];\n }\n };\n SHARED_FIELD_INTERNAL_PROP_NAMES.forEach(extractProp);\n if (valueType === 'date') {\n DATE_VALIDATION_PROP_NAMES.forEach(extractProp);\n } else if (valueType === 'time') {\n TIME_VALIDATION_PROP_NAMES.forEach(extractProp);\n } else if (valueType === 'date-time') {\n DATE_VALIDATION_PROP_NAMES.forEach(extractProp);\n TIME_VALIDATION_PROP_NAMES.forEach(extractProp);\n DATE_TIME_VALIDATION_PROP_NAMES.forEach(extractProp);\n }\n return {\n forwardedProps,\n internalProps\n };\n }, [props, valueType]);\n};","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { applyDefaultDate } from \"../utils/date-utils.js\";\nimport { useUtils, useDefaultDates } from \"./useUtils.js\";\nexport const useDefaultizedDateField = props => {\n const utils = useUtils();\n const defaultDates = useDefaultDates();\n return _extends({}, props, {\n disablePast: props.disablePast ?? false,\n disableFuture: props.disableFuture ?? false,\n format: props.format ?? utils.formats.keyboardDate,\n minDate: applyDefaultDate(utils, props.minDate, defaultDates.minDate),\n maxDate: applyDefaultDate(utils, props.maxDate, defaultDates.maxDate)\n });\n};\nexport const useDefaultizedTimeField = props => {\n const utils = useUtils();\n const ampm = props.ampm ?? utils.is12HourCycleInCurrentLocale();\n const defaultFormat = ampm ? utils.formats.fullTime12h : utils.formats.fullTime24h;\n return _extends({}, props, {\n disablePast: props.disablePast ?? false,\n disableFuture: props.disableFuture ?? false,\n format: props.format ?? defaultFormat\n });\n};\nexport const useDefaultizedDateTimeField = props => {\n const utils = useUtils();\n const defaultDates = useDefaultDates();\n const ampm = props.ampm ?? utils.is12HourCycleInCurrentLocale();\n const defaultFormat = ampm ? utils.formats.keyboardDateTime12h : utils.formats.keyboardDateTime24h;\n return _extends({}, props, {\n disablePast: props.disablePast ?? false,\n disableFuture: props.disableFuture ?? false,\n format: props.format ?? defaultFormat,\n disableIgnoringDatePartForTimeValidation: Boolean(props.minDateTime || props.maxDateTime),\n minDate: applyDefaultDate(utils, props.minDateTime ?? props.minDate, defaultDates.minDate),\n maxDate: applyDefaultDate(utils, props.maxDateTime ?? props.maxDate, defaultDates.maxDate),\n minTime: props.minDateTime ?? props.minTime,\n maxTime: props.maxDateTime ?? props.maxTime\n });\n};","'use client';\n\nimport { singleItemFieldValueManager, singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { useField } from \"../internals/hooks/useField/index.js\";\nimport { validateDate } from \"../validation/index.js\";\nimport { useSplitFieldProps } from \"../hooks/index.js\";\nimport { useDefaultizedDateField } from \"../internals/hooks/defaultizedFieldProps.js\";\nexport const useDateField = inProps => {\n const props = useDefaultizedDateField(inProps);\n const {\n forwardedProps,\n internalProps\n } = useSplitFieldProps(props, 'date');\n return useField({\n forwardedProps,\n internalProps,\n valueManager: singleItemValueManager,\n fieldValueManager: singleItemFieldValueManager,\n validator: validateDate,\n valueType: 'date'\n });\n};","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"clearable\", \"onClear\", \"InputProps\", \"sx\", \"slots\", \"slotProps\"],\n _excluded2 = [\"ownerState\"];\nimport * as React from 'react';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport MuiIconButton from '@mui/material/IconButton';\nimport InputAdornment from '@mui/material/InputAdornment';\nimport { ClearIcon } from \"../icons/index.js\";\nimport { usePickersTranslations } from \"./usePickersTranslations.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nexport const useClearableField = props => {\n const translations = usePickersTranslations();\n const {\n clearable,\n onClear,\n InputProps,\n sx,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const IconButton = slots?.clearButton ?? MuiIconButton;\n // The spread is here to avoid this bug mui/material-ui#34056\n const _useSlotProps = useSlotProps({\n elementType: IconButton,\n externalSlotProps: slotProps?.clearButton,\n ownerState: {},\n className: 'clearButton',\n additionalProps: {\n title: translations.fieldClearLabel\n }\n }),\n iconButtonProps = _objectWithoutPropertiesLoose(_useSlotProps, _excluded2);\n const EndClearIcon = slots?.clearIcon ?? ClearIcon;\n const endClearIconProps = useSlotProps({\n elementType: EndClearIcon,\n externalSlotProps: slotProps?.clearIcon,\n ownerState: {}\n });\n return _extends({}, other, {\n InputProps: _extends({}, InputProps, {\n endAdornment: /*#__PURE__*/_jsxs(React.Fragment, {\n children: [clearable && /*#__PURE__*/_jsx(InputAdornment, {\n position: \"end\",\n sx: {\n marginRight: InputProps?.endAdornment ? -1 : -1.5\n },\n children: /*#__PURE__*/_jsx(IconButton, _extends({}, iconButtonProps, {\n onClick: onClear,\n children: /*#__PURE__*/_jsx(EndClearIcon, _extends({\n fontSize: \"small\"\n }, endClearIconProps))\n }))\n }), InputProps?.endAdornment]\n })\n }),\n sx: [{\n '& .clearButton': {\n opacity: 1\n },\n '@media (pointer: fine)': {\n '& .clearButton': {\n opacity: 0\n },\n '&:hover, &:focus-within': {\n '.clearButton': {\n opacity: 1\n }\n }\n }\n }, ...(Array.isArray(sx) ? sx : [sx])]\n });\n};","import generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nexport function getPickersTextFieldUtilityClass(slot) {\n return generateUtilityClass('MuiPickersTextField', slot);\n}\nexport const pickersTextFieldClasses = generateUtilityClasses('MuiPickersTextField', ['root', 'focused', 'disabled', 'error', 'required']);","import generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nexport function getPickersInputBaseUtilityClass(slot) {\n return generateUtilityClass('MuiPickersInputBase', slot);\n}\nexport const pickersInputBaseClasses = generateUtilityClasses('MuiPickersInputBase', ['root', 'focused', 'disabled', 'error', 'notchedOutline', 'sectionContent', 'sectionBefore', 'sectionAfter', 'adornedStart', 'adornedEnd', 'input']);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport { pickersInputBaseClasses } from \"../PickersInputBase/index.js\";\nexport function getPickersOutlinedInputUtilityClass(slot) {\n return generateUtilityClass('MuiPickersOutlinedInput', slot);\n}\nexport const pickersOutlinedInputClasses = _extends({}, pickersInputBaseClasses, generateUtilityClasses('MuiPickersOutlinedInput', ['root', 'notchedOutline', 'input']));","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"label\", \"notched\", \"shrink\"];\nimport * as React from 'react';\nimport { styled } from '@mui/material/styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst OutlineRoot = styled('fieldset', {\n name: 'MuiPickersOutlinedInput',\n slot: 'NotchedOutline',\n overridesResolver: (props, styles) => styles.notchedOutline\n})(({\n theme\n}) => {\n const borderColor = theme.palette.mode === 'light' ? 'rgba(0, 0, 0, 0.23)' : 'rgba(255, 255, 255, 0.23)';\n return {\n textAlign: 'left',\n position: 'absolute',\n bottom: 0,\n right: 0,\n top: -5,\n left: 0,\n margin: 0,\n padding: '0 8px',\n pointerEvents: 'none',\n borderRadius: 'inherit',\n borderStyle: 'solid',\n borderWidth: 1,\n overflow: 'hidden',\n minWidth: '0%',\n borderColor: theme.vars ? `rgba(${theme.vars.palette.common.onBackgroundChannel} / 0.23)` : borderColor\n };\n});\nconst OutlineLabel = styled('span')(({\n theme\n}) => ({\n fontFamily: theme.typography.fontFamily,\n fontSize: 'inherit'\n}));\nconst OutlineLegend = styled('legend')(({\n theme\n}) => ({\n float: 'unset',\n // Fix conflict with bootstrap\n width: 'auto',\n // Fix conflict with bootstrap\n overflow: 'hidden',\n // Fix Horizontal scroll when label too long\n variants: [{\n props: {\n withLabel: false\n },\n style: {\n padding: 0,\n lineHeight: '11px',\n // sync with `height` in `legend` styles\n transition: theme.transitions.create('width', {\n duration: 150,\n easing: theme.transitions.easing.easeOut\n })\n }\n }, {\n props: {\n withLabel: true\n },\n style: {\n display: 'block',\n // Fix conflict with normalize.css and sanitize.css\n padding: 0,\n height: 11,\n // sync with `lineHeight` in `legend` styles\n fontSize: '0.75em',\n visibility: 'hidden',\n maxWidth: 0.01,\n transition: theme.transitions.create('max-width', {\n duration: 50,\n easing: theme.transitions.easing.easeOut\n }),\n whiteSpace: 'nowrap',\n '& > span': {\n paddingLeft: 5,\n paddingRight: 5,\n display: 'inline-block',\n opacity: 0,\n visibility: 'visible'\n }\n }\n }, {\n props: {\n withLabel: true,\n notched: true\n },\n style: {\n maxWidth: '100%',\n transition: theme.transitions.create('max-width', {\n duration: 100,\n easing: theme.transitions.easing.easeOut,\n delay: 50\n })\n }\n }]\n}));\n\n/**\n * @ignore - internal component.\n */\nexport default function Outline(props) {\n const {\n className,\n label\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const withLabel = label != null && label !== '';\n const ownerState = _extends({}, props, {\n withLabel\n });\n return /*#__PURE__*/_jsx(OutlineRoot, _extends({\n \"aria-hidden\": true,\n className: className\n }, other, {\n ownerState: ownerState,\n children: /*#__PURE__*/_jsx(OutlineLegend, {\n ownerState: ownerState,\n children: withLabel ? /*#__PURE__*/_jsx(OutlineLabel, {\n children: label\n }) :\n /*#__PURE__*/\n // notranslate needed while Google Translate will not fix zero-width space issue\n _jsx(OutlineLabel, {\n className: \"notranslate\",\n children: \"\\u200B\"\n })\n })\n }));\n}","import generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nexport function getPickersSectionListUtilityClass(slot) {\n return generateUtilityClass('MuiPickersSectionList', slot);\n}\nexport const pickersSectionListClasses = generateUtilityClasses('MuiPickersSectionList', ['root', 'section', 'sectionContent']);","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"slots\", \"slotProps\", \"elements\", \"sectionListRef\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport composeClasses from '@mui/utils/composeClasses';\nimport useForkRef from '@mui/utils/useForkRef';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { getPickersSectionListUtilityClass, pickersSectionListClasses } from \"./pickersSectionListClasses.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nexport const PickersSectionListRoot = styled('div', {\n name: 'MuiPickersSectionList',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({\n direction: 'ltr /*! @noflip */',\n outline: 'none'\n});\nexport const PickersSectionListSection = styled('span', {\n name: 'MuiPickersSectionList',\n slot: 'Section',\n overridesResolver: (props, styles) => styles.section\n})({});\nexport const PickersSectionListSectionSeparator = styled('span', {\n name: 'MuiPickersSectionList',\n slot: 'SectionSeparator',\n overridesResolver: (props, styles) => styles.sectionSeparator\n})({\n whiteSpace: 'pre'\n});\nexport const PickersSectionListSectionContent = styled('span', {\n name: 'MuiPickersSectionList',\n slot: 'SectionContent',\n overridesResolver: (props, styles) => styles.sectionContent\n})({\n outline: 'none'\n});\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n section: ['section'],\n sectionContent: ['sectionContent']\n };\n return composeClasses(slots, getPickersSectionListUtilityClass, classes);\n};\nfunction PickersSection(props) {\n const {\n slots,\n slotProps,\n element,\n classes\n } = props;\n const Section = slots?.section ?? PickersSectionListSection;\n const sectionProps = useSlotProps({\n elementType: Section,\n externalSlotProps: slotProps?.section,\n externalForwardedProps: element.container,\n className: classes.section,\n ownerState: {}\n });\n const SectionContent = slots?.sectionContent ?? PickersSectionListSectionContent;\n const sectionContentProps = useSlotProps({\n elementType: SectionContent,\n externalSlotProps: slotProps?.sectionContent,\n externalForwardedProps: element.content,\n additionalProps: {\n suppressContentEditableWarning: true\n },\n className: classes.sectionContent,\n ownerState: {}\n });\n const SectionSeparator = slots?.sectionSeparator ?? PickersSectionListSectionSeparator;\n const sectionSeparatorBeforeProps = useSlotProps({\n elementType: SectionSeparator,\n externalSlotProps: slotProps?.sectionSeparator,\n externalForwardedProps: element.before,\n ownerState: {\n position: 'before'\n }\n });\n const sectionSeparatorAfterProps = useSlotProps({\n elementType: SectionSeparator,\n externalSlotProps: slotProps?.sectionSeparator,\n externalForwardedProps: element.after,\n ownerState: {\n position: 'after'\n }\n });\n return /*#__PURE__*/_jsxs(Section, _extends({}, sectionProps, {\n children: [/*#__PURE__*/_jsx(SectionSeparator, _extends({}, sectionSeparatorBeforeProps)), /*#__PURE__*/_jsx(SectionContent, _extends({}, sectionContentProps)), /*#__PURE__*/_jsx(SectionSeparator, _extends({}, sectionSeparatorAfterProps))]\n }));\n}\nprocess.env.NODE_ENV !== \"production\" ? PickersSection.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n classes: PropTypes.object.isRequired,\n element: PropTypes.shape({\n after: PropTypes.object.isRequired,\n before: PropTypes.object.isRequired,\n container: PropTypes.object.isRequired,\n content: PropTypes.object.isRequired\n }).isRequired,\n /**\n * The props used for each component slot.\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n */\n slots: PropTypes.object\n} : void 0;\n/**\n * Demos:\n *\n * - [Custom field](https://mui.com/x/react-date-pickers/custom-field/)\n *\n * API:\n *\n * - [PickersSectionList API](https://mui.com/x/api/date-pickers/pickers-section-list/)\n */\nconst PickersSectionList = /*#__PURE__*/React.forwardRef(function PickersSectionList(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersSectionList'\n });\n const {\n slots,\n slotProps,\n elements,\n sectionListRef\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const classes = useUtilityClasses(props);\n const rootRef = React.useRef(null);\n const handleRootRef = useForkRef(ref, rootRef);\n const getRoot = methodName => {\n if (!rootRef.current) {\n throw new Error(`MUI X: Cannot call sectionListRef.${methodName} before the mount of the component.`);\n }\n return rootRef.current;\n };\n React.useImperativeHandle(sectionListRef, () => ({\n getRoot() {\n return getRoot('getRoot');\n },\n getSectionContainer(index) {\n const root = getRoot('getSectionContainer');\n return root.querySelector(`.${pickersSectionListClasses.section}[data-sectionindex=\"${index}\"]`);\n },\n getSectionContent(index) {\n const root = getRoot('getSectionContent');\n return root.querySelector(`.${pickersSectionListClasses.section}[data-sectionindex=\"${index}\"] .${pickersSectionListClasses.sectionContent}`);\n },\n getSectionIndexFromDOMElement(element) {\n const root = getRoot('getSectionIndexFromDOMElement');\n if (element == null || !root.contains(element)) {\n return null;\n }\n let sectionContainer = null;\n if (element.classList.contains(pickersSectionListClasses.section)) {\n sectionContainer = element;\n } else if (element.classList.contains(pickersSectionListClasses.sectionContent)) {\n sectionContainer = element.parentElement;\n }\n if (sectionContainer == null) {\n return null;\n }\n return Number(sectionContainer.dataset.sectionindex);\n }\n }));\n const Root = slots?.root ?? PickersSectionListRoot;\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps?.root,\n externalForwardedProps: other,\n additionalProps: {\n ref: handleRootRef,\n suppressContentEditableWarning: true\n },\n className: classes.root,\n ownerState: {}\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: rootProps.contentEditable ? elements.map(({\n content,\n before,\n after\n }) => `${before.children}${content.children}${after.children}`).join('') : /*#__PURE__*/_jsx(React.Fragment, {\n children: elements.map((element, elementIndex) => /*#__PURE__*/_jsx(PickersSection, {\n slots: slots,\n slotProps: slotProps,\n element: element,\n classes: classes\n }, elementIndex))\n })\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? PickersSectionList.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * If true, the whole element is editable.\n * Useful when all the sections are selected.\n */\n contentEditable: PropTypes.bool.isRequired,\n /**\n * The elements to render.\n * Each element contains the prop to edit a section of the value.\n */\n elements: PropTypes.arrayOf(PropTypes.shape({\n after: PropTypes.object.isRequired,\n before: PropTypes.object.isRequired,\n container: PropTypes.object.isRequired,\n content: PropTypes.object.isRequired\n })).isRequired,\n sectionListRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({\n current: PropTypes.shape({\n getRoot: PropTypes.func.isRequired,\n getSectionContainer: PropTypes.func.isRequired,\n getSectionContent: PropTypes.func.isRequired,\n getSectionIndexFromDOMElement: PropTypes.func.isRequired\n })\n })]),\n /**\n * The props used for each component slot.\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n */\n slots: PropTypes.object\n} : void 0;\nexport { PickersSectionList };","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"elements\", \"areAllSectionsEmpty\", \"defaultValue\", \"label\", \"value\", \"onChange\", \"id\", \"autoFocus\", \"endAdornment\", \"startAdornment\", \"renderSuffix\", \"slots\", \"slotProps\", \"contentEditable\", \"tabIndex\", \"onInput\", \"onPaste\", \"onKeyDown\", \"fullWidth\", \"name\", \"readOnly\", \"inputProps\", \"inputRef\", \"sectionListRef\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { useFormControl } from '@mui/material/FormControl';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport useForkRef from '@mui/utils/useForkRef';\nimport { refType } from '@mui/utils';\nimport composeClasses from '@mui/utils/composeClasses';\nimport capitalize from '@mui/utils/capitalize';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport visuallyHidden from '@mui/utils/visuallyHidden';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { pickersInputBaseClasses, getPickersInputBaseUtilityClass } from \"./pickersInputBaseClasses.js\";\nimport { Unstable_PickersSectionList as PickersSectionList, Unstable_PickersSectionListRoot as PickersSectionListRoot, Unstable_PickersSectionListSection as PickersSectionListSection, Unstable_PickersSectionListSectionSeparator as PickersSectionListSectionSeparator, Unstable_PickersSectionListSectionContent as PickersSectionListSectionContent } from \"../../PickersSectionList/index.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst round = value => Math.round(value * 1e5) / 1e5;\nexport const PickersInputBaseRoot = styled('div', {\n name: 'MuiPickersInputBase',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})(({\n theme\n}) => _extends({}, theme.typography.body1, {\n color: (theme.vars || theme).palette.text.primary,\n cursor: 'text',\n padding: 0,\n display: 'flex',\n justifyContent: 'flex-start',\n alignItems: 'center',\n position: 'relative',\n boxSizing: 'border-box',\n // Prevent padding issue with fullWidth.\n letterSpacing: `${round(0.15 / 16)}em`,\n variants: [{\n props: {\n fullWidth: true\n },\n style: {\n width: '100%'\n }\n }]\n}));\nexport const PickersInputBaseSectionsContainer = styled(PickersSectionListRoot, {\n name: 'MuiPickersInputBase',\n slot: 'SectionsContainer',\n overridesResolver: (props, styles) => styles.sectionsContainer\n})(({\n theme\n}) => ({\n padding: '4px 0 5px',\n fontFamily: theme.typography.fontFamily,\n fontSize: 'inherit',\n lineHeight: '1.4375em',\n // 23px\n flexGrow: 1,\n outline: 'none',\n display: 'flex',\n flexWrap: 'nowrap',\n overflow: 'hidden',\n letterSpacing: 'inherit',\n // Baseline behavior\n width: '182px',\n variants: [{\n props: {\n isRtl: true\n },\n style: {\n textAlign: 'right /*! @noflip */'\n }\n }, {\n props: {\n size: 'small'\n },\n style: {\n paddingTop: 1\n }\n }, {\n props: {\n adornedStart: false,\n focused: false,\n filled: false\n },\n style: {\n color: 'currentColor',\n opacity: 0\n }\n }, {\n // Can't use the object notation because label can be null or undefined\n props: ({\n adornedStart,\n focused,\n filled,\n label\n }) => !adornedStart && !focused && !filled && label == null,\n style: theme.vars ? {\n opacity: theme.vars.opacity.inputPlaceholder\n } : {\n opacity: theme.palette.mode === 'light' ? 0.42 : 0.5\n }\n }]\n}));\nconst PickersInputBaseSection = styled(PickersSectionListSection, {\n name: 'MuiPickersInputBase',\n slot: 'Section',\n overridesResolver: (props, styles) => styles.section\n})(({\n theme\n}) => ({\n fontFamily: theme.typography.fontFamily,\n fontSize: 'inherit',\n letterSpacing: 'inherit',\n lineHeight: '1.4375em',\n // 23px\n display: 'flex'\n}));\nconst PickersInputBaseSectionContent = styled(PickersSectionListSectionContent, {\n name: 'MuiPickersInputBase',\n slot: 'SectionContent',\n overridesResolver: (props, styles) => styles.content\n})(({\n theme\n}) => ({\n fontFamily: theme.typography.fontFamily,\n lineHeight: '1.4375em',\n // 23px\n letterSpacing: 'inherit',\n width: 'fit-content',\n outline: 'none'\n}));\nconst PickersInputBaseSectionSeparator = styled(PickersSectionListSectionSeparator, {\n name: 'MuiPickersInputBase',\n slot: 'Separator',\n overridesResolver: (props, styles) => styles.separator\n})(() => ({\n whiteSpace: 'pre',\n letterSpacing: 'inherit'\n}));\nconst PickersInputBaseInput = styled('input', {\n name: 'MuiPickersInputBase',\n slot: 'Input',\n overridesResolver: (props, styles) => styles.hiddenInput\n})(_extends({}, visuallyHidden));\nconst useUtilityClasses = ownerState => {\n const {\n focused,\n disabled,\n error,\n classes,\n fullWidth,\n readOnly,\n color,\n size,\n endAdornment,\n startAdornment\n } = ownerState;\n const slots = {\n root: ['root', focused && !disabled && 'focused', disabled && 'disabled', readOnly && 'readOnly', error && 'error', fullWidth && 'fullWidth', `color${capitalize(color)}`, size === 'small' && 'inputSizeSmall', Boolean(startAdornment) && 'adornedStart', Boolean(endAdornment) && 'adornedEnd'],\n notchedOutline: ['notchedOutline'],\n input: ['input'],\n sectionsContainer: ['sectionsContainer'],\n sectionContent: ['sectionContent'],\n sectionBefore: ['sectionBefore'],\n sectionAfter: ['sectionAfter']\n };\n return composeClasses(slots, getPickersInputBaseUtilityClass, classes);\n};\n/**\n * @ignore - internal component.\n */\nconst PickersInputBase = /*#__PURE__*/React.forwardRef(function PickersInputBase(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersInputBase'\n });\n const {\n elements,\n areAllSectionsEmpty,\n value,\n onChange,\n id,\n endAdornment,\n startAdornment,\n renderSuffix,\n slots,\n slotProps,\n contentEditable,\n tabIndex,\n onInput,\n onPaste,\n onKeyDown,\n name,\n readOnly,\n inputProps,\n inputRef,\n sectionListRef\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const rootRef = React.useRef(null);\n const handleRootRef = useForkRef(ref, rootRef);\n const handleInputRef = useForkRef(inputProps?.ref, inputRef);\n const isRtl = useRtl();\n const muiFormControl = useFormControl();\n if (!muiFormControl) {\n throw new Error('MUI X: PickersInputBase should always be used inside a PickersTextField component');\n }\n const handleInputFocus = event => {\n // Fix a bug with IE11 where the focus/blur events are triggered\n // while the component is disabled.\n if (muiFormControl.disabled) {\n event.stopPropagation();\n return;\n }\n muiFormControl.onFocus?.(event);\n };\n React.useEffect(() => {\n if (muiFormControl) {\n muiFormControl.setAdornedStart(Boolean(startAdornment));\n }\n }, [muiFormControl, startAdornment]);\n React.useEffect(() => {\n if (!muiFormControl) {\n return;\n }\n if (areAllSectionsEmpty) {\n muiFormControl.onEmpty();\n } else {\n muiFormControl.onFilled();\n }\n }, [muiFormControl, areAllSectionsEmpty]);\n const ownerState = _extends({}, props, muiFormControl, {\n isRtl\n });\n const classes = useUtilityClasses(ownerState);\n const InputRoot = slots?.root || PickersInputBaseRoot;\n const inputRootProps = useSlotProps({\n elementType: InputRoot,\n externalSlotProps: slotProps?.root,\n externalForwardedProps: other,\n additionalProps: {\n 'aria-invalid': muiFormControl.error,\n ref: handleRootRef\n },\n className: classes.root,\n ownerState\n });\n const InputSectionsContainer = slots?.input || PickersInputBaseSectionsContainer;\n return /*#__PURE__*/_jsxs(InputRoot, _extends({}, inputRootProps, {\n children: [startAdornment, /*#__PURE__*/_jsx(PickersSectionList, {\n sectionListRef: sectionListRef,\n elements: elements,\n contentEditable: contentEditable,\n tabIndex: tabIndex,\n className: classes.sectionsContainer,\n onFocus: handleInputFocus,\n onBlur: muiFormControl.onBlur,\n onInput: onInput,\n onPaste: onPaste,\n onKeyDown: onKeyDown,\n slots: {\n root: InputSectionsContainer,\n section: PickersInputBaseSection,\n sectionContent: PickersInputBaseSectionContent,\n sectionSeparator: PickersInputBaseSectionSeparator\n },\n slotProps: {\n root: {\n ownerState\n },\n sectionContent: {\n className: pickersInputBaseClasses.sectionContent\n },\n sectionSeparator: ({\n position\n }) => ({\n className: position === 'before' ? pickersInputBaseClasses.sectionBefore : pickersInputBaseClasses.sectionAfter\n })\n }\n }), endAdornment, renderSuffix ? renderSuffix(_extends({}, muiFormControl)) : null, /*#__PURE__*/_jsx(PickersInputBaseInput, _extends({\n name: name,\n className: classes.input,\n value: value,\n onChange: onChange,\n id: id,\n \"aria-hidden\": \"true\",\n tabIndex: -1,\n readOnly: readOnly,\n required: muiFormControl.required,\n disabled: muiFormControl.disabled\n }, inputProps, {\n ref: handleInputRef\n }))]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? PickersInputBase.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Is `true` if the current values equals the empty value.\n * For a single item value, it means that `value === null`\n * For a range value, it means that `value === [null, null]`\n */\n areAllSectionsEmpty: PropTypes.bool.isRequired,\n className: PropTypes.string,\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * If true, the whole element is editable.\n * Useful when all the sections are selected.\n */\n contentEditable: PropTypes.bool.isRequired,\n /**\n * The elements to render.\n * Each element contains the prop to edit a section of the value.\n */\n elements: PropTypes.arrayOf(PropTypes.shape({\n after: PropTypes.object.isRequired,\n before: PropTypes.object.isRequired,\n container: PropTypes.object.isRequired,\n content: PropTypes.object.isRequired\n })).isRequired,\n endAdornment: PropTypes.node,\n fullWidth: PropTypes.bool,\n id: PropTypes.string,\n inputProps: PropTypes.object,\n inputRef: refType,\n label: PropTypes.node,\n margin: PropTypes.oneOf(['dense', 'none', 'normal']),\n name: PropTypes.string,\n onChange: PropTypes.func.isRequired,\n onClick: PropTypes.func.isRequired,\n onInput: PropTypes.func.isRequired,\n onKeyDown: PropTypes.func.isRequired,\n onPaste: PropTypes.func.isRequired,\n ownerState: PropTypes.any,\n readOnly: PropTypes.bool,\n renderSuffix: PropTypes.func,\n sectionListRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({\n current: PropTypes.shape({\n getRoot: PropTypes.func.isRequired,\n getSectionContainer: PropTypes.func.isRequired,\n getSectionContent: PropTypes.func.isRequired,\n getSectionIndexFromDOMElement: PropTypes.func.isRequired\n })\n })]),\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * The components used for each slot inside.\n *\n * @default {}\n */\n slots: PropTypes.object,\n startAdornment: PropTypes.node,\n style: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n value: PropTypes.string.isRequired\n} : void 0;\nexport { PickersInputBase };","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"label\", \"autoFocus\", \"ownerState\", \"notched\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { useFormControl } from '@mui/material/FormControl';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { refType } from '@mui/utils';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { pickersOutlinedInputClasses, getPickersOutlinedInputUtilityClass } from \"./pickersOutlinedInputClasses.js\";\nimport Outline from \"./Outline.js\";\nimport { PickersInputBase } from \"../PickersInputBase/index.js\";\nimport { PickersInputBaseRoot, PickersInputBaseSectionsContainer } from \"../PickersInputBase/PickersInputBase.js\";\nimport { jsxs as _jsxs, jsx as _jsx } from \"react/jsx-runtime\";\nconst PickersOutlinedInputRoot = styled(PickersInputBaseRoot, {\n name: 'MuiPickersOutlinedInput',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})(({\n theme\n}) => {\n const borderColor = theme.palette.mode === 'light' ? 'rgba(0, 0, 0, 0.23)' : 'rgba(255, 255, 255, 0.23)';\n return {\n padding: '0 14px',\n borderRadius: (theme.vars || theme).shape.borderRadius,\n [`&:hover .${pickersOutlinedInputClasses.notchedOutline}`]: {\n borderColor: (theme.vars || theme).palette.text.primary\n },\n // Reset on touch devices, it doesn't add specificity\n '@media (hover: none)': {\n [`&:hover .${pickersOutlinedInputClasses.notchedOutline}`]: {\n borderColor: theme.vars ? `rgba(${theme.vars.palette.common.onBackgroundChannel} / 0.23)` : borderColor\n }\n },\n [`&.${pickersOutlinedInputClasses.focused} .${pickersOutlinedInputClasses.notchedOutline}`]: {\n borderStyle: 'solid',\n borderWidth: 2\n },\n [`&.${pickersOutlinedInputClasses.disabled}`]: {\n [`& .${pickersOutlinedInputClasses.notchedOutline}`]: {\n borderColor: (theme.vars || theme).palette.action.disabled\n },\n '*': {\n color: (theme.vars || theme).palette.action.disabled\n }\n },\n [`&.${pickersOutlinedInputClasses.error} .${pickersOutlinedInputClasses.notchedOutline}`]: {\n borderColor: (theme.vars || theme).palette.error.main\n },\n variants: Object.keys((theme.vars ?? theme).palette)\n // @ts-ignore\n .filter(key => (theme.vars ?? theme).palette[key]?.main ?? false).map(color => ({\n props: {\n color\n },\n style: {\n [`&.${pickersOutlinedInputClasses.focused}:not(.${pickersOutlinedInputClasses.error}) .${pickersOutlinedInputClasses.notchedOutline}`]: {\n // @ts-ignore\n borderColor: (theme.vars || theme).palette[color].main\n }\n }\n }))\n };\n});\nconst PickersOutlinedInputSectionsContainer = styled(PickersInputBaseSectionsContainer, {\n name: 'MuiPickersOutlinedInput',\n slot: 'SectionsContainer',\n overridesResolver: (props, styles) => styles.sectionsContainer\n})({\n padding: '16.5px 0',\n variants: [{\n props: {\n size: 'small'\n },\n style: {\n padding: '8.5px 0'\n }\n }]\n});\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n notchedOutline: ['notchedOutline'],\n input: ['input']\n };\n const composedClasses = composeClasses(slots, getPickersOutlinedInputUtilityClass, classes);\n return _extends({}, classes, composedClasses);\n};\n/**\n * @ignore - internal component.\n */\nconst PickersOutlinedInput = /*#__PURE__*/React.forwardRef(function PickersOutlinedInput(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersOutlinedInput'\n });\n const {\n label,\n ownerState: ownerStateProp,\n notched\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const muiFormControl = useFormControl();\n const ownerState = _extends({}, props, ownerStateProp, muiFormControl, {\n color: muiFormControl?.color || 'primary'\n });\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsx(PickersInputBase, _extends({\n slots: {\n root: PickersOutlinedInputRoot,\n input: PickersOutlinedInputSectionsContainer\n },\n renderSuffix: state => /*#__PURE__*/_jsx(Outline, {\n shrink: Boolean(notched || state.adornedStart || state.focused || state.filled),\n notched: Boolean(notched || state.adornedStart || state.focused || state.filled),\n className: classes.notchedOutline,\n label: label != null && label !== '' && muiFormControl?.required ? /*#__PURE__*/_jsxs(React.Fragment, {\n children: [label, \"\\u2009\", '*']\n }) : label,\n ownerState: ownerState\n })\n }, other, {\n label: label,\n classes: classes,\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? PickersOutlinedInput.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Is `true` if the current values equals the empty value.\n * For a single item value, it means that `value === null`\n * For a range value, it means that `value === [null, null]`\n */\n areAllSectionsEmpty: PropTypes.bool.isRequired,\n className: PropTypes.string,\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * If true, the whole element is editable.\n * Useful when all the sections are selected.\n */\n contentEditable: PropTypes.bool.isRequired,\n /**\n * The elements to render.\n * Each element contains the prop to edit a section of the value.\n */\n elements: PropTypes.arrayOf(PropTypes.shape({\n after: PropTypes.object.isRequired,\n before: PropTypes.object.isRequired,\n container: PropTypes.object.isRequired,\n content: PropTypes.object.isRequired\n })).isRequired,\n endAdornment: PropTypes.node,\n fullWidth: PropTypes.bool,\n id: PropTypes.string,\n inputProps: PropTypes.object,\n inputRef: refType,\n label: PropTypes.node,\n margin: PropTypes.oneOf(['dense', 'none', 'normal']),\n name: PropTypes.string,\n notched: PropTypes.bool,\n onChange: PropTypes.func.isRequired,\n onClick: PropTypes.func.isRequired,\n onInput: PropTypes.func.isRequired,\n onKeyDown: PropTypes.func.isRequired,\n onPaste: PropTypes.func.isRequired,\n ownerState: PropTypes.any,\n readOnly: PropTypes.bool,\n renderSuffix: PropTypes.func,\n sectionListRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({\n current: PropTypes.shape({\n getRoot: PropTypes.func.isRequired,\n getSectionContainer: PropTypes.func.isRequired,\n getSectionContent: PropTypes.func.isRequired,\n getSectionIndexFromDOMElement: PropTypes.func.isRequired\n })\n })]),\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * The components used for each slot inside.\n *\n * @default {}\n */\n slots: PropTypes.object,\n startAdornment: PropTypes.node,\n style: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n value: PropTypes.string.isRequired\n} : void 0;\nexport { PickersOutlinedInput };\nPickersOutlinedInput.muiName = 'Input';","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport { pickersInputBaseClasses } from \"../PickersInputBase/index.js\";\nexport function getPickersFilledInputUtilityClass(slot) {\n return generateUtilityClass('MuiPickersFilledInput', slot);\n}\nexport const pickersFilledInputClasses = _extends({}, pickersInputBaseClasses, generateUtilityClasses('MuiPickersFilledInput', ['root', 'underline', 'input']));","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"label\", \"autoFocus\", \"disableUnderline\", \"ownerState\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { useFormControl } from '@mui/material/FormControl';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { shouldForwardProp } from '@mui/system';\nimport { refType } from '@mui/utils';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { pickersFilledInputClasses, getPickersFilledInputUtilityClass } from \"./pickersFilledInputClasses.js\";\nimport { PickersInputBase } from \"../PickersInputBase/index.js\";\nimport { PickersInputBaseRoot, PickersInputBaseSectionsContainer } from \"../PickersInputBase/PickersInputBase.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PickersFilledInputRoot = styled(PickersInputBaseRoot, {\n name: 'MuiPickersFilledInput',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root,\n shouldForwardProp: prop => shouldForwardProp(prop) && prop !== 'disableUnderline'\n})(({\n theme\n}) => {\n const light = theme.palette.mode === 'light';\n const bottomLineColor = light ? 'rgba(0, 0, 0, 0.42)' : 'rgba(255, 255, 255, 0.7)';\n const backgroundColor = light ? 'rgba(0, 0, 0, 0.06)' : 'rgba(255, 255, 255, 0.09)';\n const hoverBackground = light ? 'rgba(0, 0, 0, 0.09)' : 'rgba(255, 255, 255, 0.13)';\n const disabledBackground = light ? 'rgba(0, 0, 0, 0.12)' : 'rgba(255, 255, 255, 0.12)';\n return {\n backgroundColor: theme.vars ? theme.vars.palette.FilledInput.bg : backgroundColor,\n borderTopLeftRadius: (theme.vars || theme).shape.borderRadius,\n borderTopRightRadius: (theme.vars || theme).shape.borderRadius,\n transition: theme.transitions.create('background-color', {\n duration: theme.transitions.duration.shorter,\n easing: theme.transitions.easing.easeOut\n }),\n '&:hover': {\n backgroundColor: theme.vars ? theme.vars.palette.FilledInput.hoverBg : hoverBackground,\n // Reset on touch devices, it doesn't add specificity\n '@media (hover: none)': {\n backgroundColor: theme.vars ? theme.vars.palette.FilledInput.bg : backgroundColor\n }\n },\n [`&.${pickersFilledInputClasses.focused}`]: {\n backgroundColor: theme.vars ? theme.vars.palette.FilledInput.bg : backgroundColor\n },\n [`&.${pickersFilledInputClasses.disabled}`]: {\n backgroundColor: theme.vars ? theme.vars.palette.FilledInput.disabledBg : disabledBackground\n },\n variants: [...Object.keys((theme.vars ?? theme).palette)\n // @ts-ignore\n .filter(key => (theme.vars ?? theme).palette[key].main).map(color => ({\n props: {\n color,\n disableUnderline: false\n },\n style: {\n '&::after': {\n // @ts-ignore\n borderBottom: `2px solid ${(theme.vars || theme).palette[color]?.main}`\n }\n }\n })), {\n props: {\n disableUnderline: false\n },\n style: {\n '&::after': {\n left: 0,\n bottom: 0,\n // Doing the other way around crash on IE11 \"''\" https://github.com/cssinjs/jss/issues/242\n content: '\"\"',\n position: 'absolute',\n right: 0,\n transform: 'scaleX(0)',\n transition: theme.transitions.create('transform', {\n duration: theme.transitions.duration.shorter,\n easing: theme.transitions.easing.easeOut\n }),\n pointerEvents: 'none' // Transparent to the hover style.\n },\n [`&.${pickersFilledInputClasses.focused}:after`]: {\n // translateX(0) is a workaround for Safari transform scale bug\n // See https://github.com/mui/material-ui/issues/31766\n transform: 'scaleX(1) translateX(0)'\n },\n [`&.${pickersFilledInputClasses.error}`]: {\n '&:before, &:after': {\n borderBottomColor: (theme.vars || theme).palette.error.main\n }\n },\n '&::before': {\n borderBottom: `1px solid ${theme.vars ? `rgba(${theme.vars.palette.common.onBackgroundChannel} / ${theme.vars.opacity.inputUnderline})` : bottomLineColor}`,\n left: 0,\n bottom: 0,\n // Doing the other way around crash on IE11 \"''\" https://github.com/cssinjs/jss/issues/242\n content: '\"\\\\00a0\"',\n position: 'absolute',\n right: 0,\n transition: theme.transitions.create('border-bottom-color', {\n duration: theme.transitions.duration.shorter\n }),\n pointerEvents: 'none' // Transparent to the hover style.\n },\n [`&:hover:not(.${pickersFilledInputClasses.disabled}, .${pickersFilledInputClasses.error}):before`]: {\n borderBottom: `1px solid ${(theme.vars || theme).palette.text.primary}`\n },\n [`&.${pickersFilledInputClasses.disabled}:before`]: {\n borderBottomStyle: 'dotted'\n }\n }\n }, {\n props: ({\n startAdornment\n }) => !!startAdornment,\n style: {\n paddingLeft: 12\n }\n }, {\n props: ({\n endAdornment\n }) => !!endAdornment,\n style: {\n paddingRight: 12\n }\n }]\n };\n});\nconst PickersFilledSectionsContainer = styled(PickersInputBaseSectionsContainer, {\n name: 'MuiPickersFilledInput',\n slot: 'sectionsContainer',\n overridesResolver: (props, styles) => styles.sectionsContainer\n})({\n paddingTop: 25,\n paddingRight: 12,\n paddingBottom: 8,\n paddingLeft: 12,\n variants: [{\n props: {\n size: 'small'\n },\n style: {\n paddingTop: 21,\n paddingBottom: 4\n }\n }, {\n props: ({\n startAdornment\n }) => !!startAdornment,\n style: {\n paddingLeft: 0\n }\n }, {\n props: ({\n endAdornment\n }) => !!endAdornment,\n style: {\n paddingRight: 0\n }\n }, {\n props: {\n hiddenLabel: true\n },\n style: {\n paddingTop: 16,\n paddingBottom: 17\n }\n }, {\n props: {\n hiddenLabel: true,\n size: 'small'\n },\n style: {\n paddingTop: 8,\n paddingBottom: 9\n }\n }]\n});\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableUnderline\n } = ownerState;\n const slots = {\n root: ['root', !disableUnderline && 'underline'],\n input: ['input']\n };\n const composedClasses = composeClasses(slots, getPickersFilledInputUtilityClass, classes);\n return _extends({}, classes, composedClasses);\n};\n/**\n * @ignore - internal component.\n */\nconst PickersFilledInput = /*#__PURE__*/React.forwardRef(function PickersFilledInput(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersFilledInput'\n });\n const {\n label,\n disableUnderline = false,\n ownerState: ownerStateProp\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const muiFormControl = useFormControl();\n const ownerState = _extends({}, props, ownerStateProp, muiFormControl, {\n color: muiFormControl?.color || 'primary'\n });\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsx(PickersInputBase, _extends({\n slots: {\n root: PickersFilledInputRoot,\n input: PickersFilledSectionsContainer\n },\n slotProps: {\n root: {\n disableUnderline\n }\n }\n }, other, {\n label: label,\n classes: classes,\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? PickersFilledInput.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Is `true` if the current values equals the empty value.\n * For a single item value, it means that `value === null`\n * For a range value, it means that `value === [null, null]`\n */\n areAllSectionsEmpty: PropTypes.bool.isRequired,\n className: PropTypes.string,\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * If true, the whole element is editable.\n * Useful when all the sections are selected.\n */\n contentEditable: PropTypes.bool.isRequired,\n disableUnderline: PropTypes.bool,\n /**\n * The elements to render.\n * Each element contains the prop to edit a section of the value.\n */\n elements: PropTypes.arrayOf(PropTypes.shape({\n after: PropTypes.object.isRequired,\n before: PropTypes.object.isRequired,\n container: PropTypes.object.isRequired,\n content: PropTypes.object.isRequired\n })).isRequired,\n endAdornment: PropTypes.node,\n fullWidth: PropTypes.bool,\n hiddenLabel: PropTypes.bool,\n id: PropTypes.string,\n inputProps: PropTypes.object,\n inputRef: refType,\n label: PropTypes.node,\n margin: PropTypes.oneOf(['dense', 'none', 'normal']),\n name: PropTypes.string,\n onChange: PropTypes.func.isRequired,\n onClick: PropTypes.func.isRequired,\n onInput: PropTypes.func.isRequired,\n onKeyDown: PropTypes.func.isRequired,\n onPaste: PropTypes.func.isRequired,\n ownerState: PropTypes.any,\n readOnly: PropTypes.bool,\n renderSuffix: PropTypes.func,\n sectionListRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({\n current: PropTypes.shape({\n getRoot: PropTypes.func.isRequired,\n getSectionContainer: PropTypes.func.isRequired,\n getSectionContent: PropTypes.func.isRequired,\n getSectionIndexFromDOMElement: PropTypes.func.isRequired\n })\n })]),\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * The components used for each slot inside.\n *\n * @default {}\n */\n slots: PropTypes.object,\n startAdornment: PropTypes.node,\n style: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n value: PropTypes.string.isRequired\n} : void 0;\nexport { PickersFilledInput };\nPickersFilledInput.muiName = 'Input';","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport { pickersInputBaseClasses } from \"../PickersInputBase/index.js\";\nexport function getPickersInputUtilityClass(slot) {\n return generateUtilityClass('MuiPickersFilledInput', slot);\n}\nexport const pickersInputClasses = _extends({}, pickersInputBaseClasses, generateUtilityClasses('MuiPickersInput', ['root', 'input']));","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"label\", \"autoFocus\", \"disableUnderline\", \"ownerState\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { useFormControl } from '@mui/material/FormControl';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { refType } from '@mui/utils';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { pickersInputClasses, getPickersInputUtilityClass } from \"./pickersInputClasses.js\";\nimport { PickersInputBase } from \"../PickersInputBase/index.js\";\nimport { PickersInputBaseRoot } from \"../PickersInputBase/PickersInputBase.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PickersInputRoot = styled(PickersInputBaseRoot, {\n name: 'MuiPickersInput',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})(({\n theme\n}) => {\n const light = theme.palette.mode === 'light';\n let bottomLineColor = light ? 'rgba(0, 0, 0, 0.42)' : 'rgba(255, 255, 255, 0.7)';\n if (theme.vars) {\n bottomLineColor = `rgba(${theme.vars.palette.common.onBackgroundChannel} / ${theme.vars.opacity.inputUnderline})`;\n }\n return {\n 'label + &': {\n marginTop: 16\n },\n variants: [...Object.keys((theme.vars ?? theme).palette)\n // @ts-ignore\n .filter(key => (theme.vars ?? theme).palette[key].main).map(color => ({\n props: {\n color\n },\n style: {\n '&::after': {\n // @ts-ignore\n borderBottom: `2px solid ${(theme.vars || theme).palette[color].main}`\n }\n }\n })), {\n props: {\n disableUnderline: false\n },\n style: {\n '&::after': {\n background: 'red',\n left: 0,\n bottom: 0,\n // Doing the other way around crash on IE11 \"''\" https://github.com/cssinjs/jss/issues/242\n content: '\"\"',\n position: 'absolute',\n right: 0,\n transform: 'scaleX(0)',\n transition: theme.transitions.create('transform', {\n duration: theme.transitions.duration.shorter,\n easing: theme.transitions.easing.easeOut\n }),\n pointerEvents: 'none' // Transparent to the hover style.\n },\n [`&.${pickersInputClasses.focused}:after`]: {\n // translateX(0) is a workaround for Safari transform scale bug\n // See https://github.com/mui/material-ui/issues/31766\n transform: 'scaleX(1) translateX(0)'\n },\n [`&.${pickersInputClasses.error}`]: {\n '&:before, &:after': {\n borderBottomColor: (theme.vars || theme).palette.error.main\n }\n },\n '&::before': {\n borderBottom: `1px solid ${bottomLineColor}`,\n left: 0,\n bottom: 0,\n // Doing the other way around crash on IE11 \"''\" https://github.com/cssinjs/jss/issues/242\n content: '\"\\\\00a0\"',\n position: 'absolute',\n right: 0,\n transition: theme.transitions.create('border-bottom-color', {\n duration: theme.transitions.duration.shorter\n }),\n pointerEvents: 'none' // Transparent to the hover style.\n },\n [`&:hover:not(.${pickersInputClasses.disabled}, .${pickersInputClasses.error}):before`]: {\n borderBottom: `2px solid ${(theme.vars || theme).palette.text.primary}`,\n // Reset on touch devices, it doesn't add specificity\n '@media (hover: none)': {\n borderBottom: `1px solid ${bottomLineColor}`\n }\n },\n [`&.${pickersInputClasses.disabled}:before`]: {\n borderBottomStyle: 'dotted'\n }\n }\n }]\n };\n});\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableUnderline\n } = ownerState;\n const slots = {\n root: ['root', !disableUnderline && 'underline'],\n input: ['input']\n };\n const composedClasses = composeClasses(slots, getPickersInputUtilityClass, classes);\n return _extends({}, classes, composedClasses);\n};\n/**\n * @ignore - internal component.\n */\nconst PickersInput = /*#__PURE__*/React.forwardRef(function PickersInput(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersInput'\n });\n const {\n label,\n disableUnderline = false,\n ownerState: ownerStateProp\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const muiFormControl = useFormControl();\n const ownerState = _extends({}, props, ownerStateProp, muiFormControl, {\n disableUnderline,\n color: muiFormControl?.color || 'primary'\n });\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsx(PickersInputBase, _extends({\n slots: {\n root: PickersInputRoot\n }\n }, other, {\n label: label,\n classes: classes,\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? PickersInput.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Is `true` if the current values equals the empty value.\n * For a single item value, it means that `value === null`\n * For a range value, it means that `value === [null, null]`\n */\n areAllSectionsEmpty: PropTypes.bool.isRequired,\n className: PropTypes.string,\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * If true, the whole element is editable.\n * Useful when all the sections are selected.\n */\n contentEditable: PropTypes.bool.isRequired,\n disableUnderline: PropTypes.bool,\n /**\n * The elements to render.\n * Each element contains the prop to edit a section of the value.\n */\n elements: PropTypes.arrayOf(PropTypes.shape({\n after: PropTypes.object.isRequired,\n before: PropTypes.object.isRequired,\n container: PropTypes.object.isRequired,\n content: PropTypes.object.isRequired\n })).isRequired,\n endAdornment: PropTypes.node,\n fullWidth: PropTypes.bool,\n id: PropTypes.string,\n inputProps: PropTypes.object,\n inputRef: refType,\n label: PropTypes.node,\n margin: PropTypes.oneOf(['dense', 'none', 'normal']),\n name: PropTypes.string,\n onChange: PropTypes.func.isRequired,\n onClick: PropTypes.func.isRequired,\n onInput: PropTypes.func.isRequired,\n onKeyDown: PropTypes.func.isRequired,\n onPaste: PropTypes.func.isRequired,\n ownerState: PropTypes.any,\n readOnly: PropTypes.bool,\n renderSuffix: PropTypes.func,\n sectionListRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({\n current: PropTypes.shape({\n getRoot: PropTypes.func.isRequired,\n getSectionContainer: PropTypes.func.isRequired,\n getSectionContent: PropTypes.func.isRequired,\n getSectionIndexFromDOMElement: PropTypes.func.isRequired\n })\n })]),\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * The components used for each slot inside.\n *\n * @default {}\n */\n slots: PropTypes.object,\n startAdornment: PropTypes.node,\n style: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n value: PropTypes.string.isRequired\n} : void 0;\nexport { PickersInput };\nPickersInput.muiName = 'Input';","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"onFocus\", \"onBlur\", \"className\", \"color\", \"disabled\", \"error\", \"variant\", \"required\", \"InputProps\", \"inputProps\", \"inputRef\", \"sectionListRef\", \"elements\", \"areAllSectionsEmpty\", \"onClick\", \"onKeyDown\", \"onKeyUp\", \"onPaste\", \"onInput\", \"endAdornment\", \"startAdornment\", \"tabIndex\", \"contentEditable\", \"focused\", \"value\", \"onChange\", \"fullWidth\", \"id\", \"name\", \"helperText\", \"FormHelperTextProps\", \"label\", \"InputLabelProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { refType } from '@mui/utils';\nimport useForkRef from '@mui/utils/useForkRef';\nimport composeClasses from '@mui/utils/composeClasses';\nimport useId from '@mui/utils/useId';\nimport InputLabel from '@mui/material/InputLabel';\nimport FormHelperText from '@mui/material/FormHelperText';\nimport FormControl from '@mui/material/FormControl';\nimport { getPickersTextFieldUtilityClass } from \"./pickersTextFieldClasses.js\";\nimport { PickersOutlinedInput } from \"./PickersOutlinedInput/index.js\";\nimport { PickersFilledInput } from \"./PickersFilledInput/index.js\";\nimport { PickersInput } from \"./PickersInput/index.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst VARIANT_COMPONENT = {\n standard: PickersInput,\n filled: PickersFilledInput,\n outlined: PickersOutlinedInput\n};\nconst PickersTextFieldRoot = styled(FormControl, {\n name: 'MuiPickersTextField',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\nconst useUtilityClasses = ownerState => {\n const {\n focused,\n disabled,\n classes,\n required\n } = ownerState;\n const slots = {\n root: ['root', focused && !disabled && 'focused', disabled && 'disabled', required && 'required']\n };\n return composeClasses(slots, getPickersTextFieldUtilityClass, classes);\n};\nconst PickersTextField = /*#__PURE__*/React.forwardRef(function PickersTextField(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersTextField'\n });\n const {\n // Props used by FormControl\n onFocus,\n onBlur,\n className,\n color = 'primary',\n disabled = false,\n error = false,\n variant = 'outlined',\n required = false,\n // Props used by PickersInput\n InputProps,\n inputProps,\n inputRef,\n sectionListRef,\n elements,\n areAllSectionsEmpty,\n onClick,\n onKeyDown,\n onKeyUp,\n onPaste,\n onInput,\n endAdornment,\n startAdornment,\n tabIndex,\n contentEditable,\n focused,\n value,\n onChange,\n fullWidth,\n id: idProp,\n name,\n // Props used by FormHelperText\n helperText,\n FormHelperTextProps,\n // Props used by InputLabel\n label,\n InputLabelProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const rootRef = React.useRef(null);\n const handleRootRef = useForkRef(ref, rootRef);\n const id = useId(idProp);\n const helperTextId = helperText && id ? `${id}-helper-text` : undefined;\n const inputLabelId = label && id ? `${id}-label` : undefined;\n const ownerState = _extends({}, props, {\n color,\n disabled,\n error,\n focused,\n required,\n variant\n });\n const classes = useUtilityClasses(ownerState);\n const PickersInputComponent = VARIANT_COMPONENT[variant];\n return /*#__PURE__*/_jsxs(PickersTextFieldRoot, _extends({\n className: clsx(classes.root, className),\n ref: handleRootRef,\n focused: focused,\n onFocus: onFocus,\n onBlur: onBlur,\n disabled: disabled,\n variant: variant,\n error: error,\n color: color,\n fullWidth: fullWidth,\n required: required,\n ownerState: ownerState\n }, other, {\n children: [/*#__PURE__*/_jsx(InputLabel, _extends({\n htmlFor: id,\n id: inputLabelId\n }, InputLabelProps, {\n children: label\n })), /*#__PURE__*/_jsx(PickersInputComponent, _extends({\n elements: elements,\n areAllSectionsEmpty: areAllSectionsEmpty,\n onClick: onClick,\n onKeyDown: onKeyDown,\n onKeyUp: onKeyUp,\n onInput: onInput,\n onPaste: onPaste,\n endAdornment: endAdornment,\n startAdornment: startAdornment,\n tabIndex: tabIndex,\n contentEditable: contentEditable,\n value: value,\n onChange: onChange,\n id: id,\n fullWidth: fullWidth,\n inputProps: inputProps,\n inputRef: inputRef,\n sectionListRef: sectionListRef,\n label: label,\n name: name,\n role: \"group\",\n \"aria-labelledby\": inputLabelId\n }, InputProps)), helperText && /*#__PURE__*/_jsx(FormHelperText, _extends({\n id: helperTextId\n }, FormHelperTextProps, {\n children: helperText\n }))]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? PickersTextField.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Is `true` if the current values equals the empty value.\n * For a single item value, it means that `value === null`\n * For a range value, it means that `value === [null, null]`\n */\n areAllSectionsEmpty: PropTypes.bool.isRequired,\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * @default 'primary'\n */\n color: PropTypes.oneOf(['error', 'info', 'primary', 'secondary', 'success', 'warning']),\n component: PropTypes.elementType,\n /**\n * If true, the whole element is editable.\n * Useful when all the sections are selected.\n */\n contentEditable: PropTypes.bool.isRequired,\n disabled: PropTypes.bool.isRequired,\n /**\n * The elements to render.\n * Each element contains the prop to edit a section of the value.\n */\n elements: PropTypes.arrayOf(PropTypes.shape({\n after: PropTypes.object.isRequired,\n before: PropTypes.object.isRequired,\n container: PropTypes.object.isRequired,\n content: PropTypes.object.isRequired\n })).isRequired,\n endAdornment: PropTypes.node,\n error: PropTypes.bool.isRequired,\n /**\n * If `true`, the component is displayed in focused state.\n */\n focused: PropTypes.bool,\n FormHelperTextProps: PropTypes.object,\n fullWidth: PropTypes.bool,\n /**\n * The helper text content.\n */\n helperText: PropTypes.node,\n /**\n * If `true`, the label is hidden.\n * This is used to increase density for a `FilledInput`.\n * Be sure to add `aria-label` to the `input` element.\n * @default false\n */\n hiddenLabel: PropTypes.bool,\n id: PropTypes.string,\n InputLabelProps: PropTypes.object,\n inputProps: PropTypes.object,\n /**\n * Props applied to the Input element.\n * It will be a [`FilledInput`](/material-ui/api/filled-input/),\n * [`OutlinedInput`](/material-ui/api/outlined-input/) or [`Input`](/material-ui/api/input/)\n * component depending on the `variant` prop value.\n */\n InputProps: PropTypes.object,\n inputRef: refType,\n label: PropTypes.node,\n /**\n * If `dense` or `normal`, will adjust vertical spacing of this and contained components.\n * @default 'none'\n */\n margin: PropTypes.oneOf(['dense', 'none', 'normal']),\n name: PropTypes.string,\n onBlur: PropTypes.func.isRequired,\n onChange: PropTypes.func.isRequired,\n onClick: PropTypes.func.isRequired,\n onFocus: PropTypes.func.isRequired,\n onInput: PropTypes.func.isRequired,\n onKeyDown: PropTypes.func.isRequired,\n onPaste: PropTypes.func.isRequired,\n readOnly: PropTypes.bool,\n /**\n * If `true`, the label will indicate that the `input` is required.\n * @default false\n */\n required: PropTypes.bool,\n sectionListRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({\n current: PropTypes.shape({\n getRoot: PropTypes.func.isRequired,\n getSectionContainer: PropTypes.func.isRequired,\n getSectionContent: PropTypes.func.isRequired,\n getSectionIndexFromDOMElement: PropTypes.func.isRequired\n })\n })]),\n /**\n * The size of the component.\n * @default 'medium'\n */\n size: PropTypes.oneOf(['medium', 'small']),\n startAdornment: PropTypes.node,\n style: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n value: PropTypes.string.isRequired,\n /**\n * The variant to use.\n * @default 'outlined'\n */\n variant: PropTypes.oneOf(['filled', 'outlined', 'standard'])\n} : void 0;\nexport { PickersTextField };","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"enableAccessibleFieldDOMStructure\"],\n _excluded2 = [\"InputProps\", \"readOnly\"],\n _excluded3 = [\"onPaste\", \"onKeyDown\", \"inputMode\", \"readOnly\", \"InputProps\", \"inputProps\", \"inputRef\"];\nexport const convertFieldResponseIntoMuiTextFieldProps = _ref => {\n let {\n enableAccessibleFieldDOMStructure\n } = _ref,\n fieldResponse = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (enableAccessibleFieldDOMStructure) {\n const {\n InputProps,\n readOnly\n } = fieldResponse,\n other = _objectWithoutPropertiesLoose(fieldResponse, _excluded2);\n return _extends({}, other, {\n InputProps: _extends({}, InputProps ?? {}, {\n readOnly\n })\n });\n }\n const {\n onPaste,\n onKeyDown,\n inputMode,\n readOnly,\n InputProps,\n inputProps,\n inputRef\n } = fieldResponse,\n other = _objectWithoutPropertiesLoose(fieldResponse, _excluded3);\n return _extends({}, other, {\n InputProps: _extends({}, InputProps ?? {}, {\n readOnly\n }),\n inputProps: _extends({}, inputProps ?? {}, {\n inputMode,\n onPaste,\n onKeyDown,\n ref: inputRef\n })\n });\n};","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"slots\", \"slotProps\", \"InputProps\", \"inputProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport MuiTextField from '@mui/material/TextField';\nimport { useThemeProps } from '@mui/material/styles';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport { refType } from '@mui/utils';\nimport { useDateField } from \"./useDateField.js\";\nimport { useClearableField } from \"../hooks/index.js\";\nimport { PickersTextField } from \"../PickersTextField/index.js\";\nimport { convertFieldResponseIntoMuiTextFieldProps } from \"../internals/utils/convertFieldResponseIntoMuiTextFieldProps.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\n/**\n * Demos:\n *\n * - [DateField](http://mui.com/x/react-date-pickers/date-field/)\n * - [Fields](https://mui.com/x/react-date-pickers/fields/)\n *\n * API:\n *\n * - [DateField API](https://mui.com/x/api/date-pickers/date-field/)\n */\nconst DateField = /*#__PURE__*/React.forwardRef(function DateField(inProps, inRef) {\n const themeProps = useThemeProps({\n props: inProps,\n name: 'MuiDateField'\n });\n const {\n slots,\n slotProps,\n InputProps,\n inputProps\n } = themeProps,\n other = _objectWithoutPropertiesLoose(themeProps, _excluded);\n const ownerState = themeProps;\n const TextField = slots?.textField ?? (inProps.enableAccessibleFieldDOMStructure ? PickersTextField : MuiTextField);\n const textFieldProps = useSlotProps({\n elementType: TextField,\n externalSlotProps: slotProps?.textField,\n externalForwardedProps: other,\n additionalProps: {\n ref: inRef\n },\n ownerState\n });\n\n // TODO: Remove when mui/material-ui#35088 will be merged\n textFieldProps.inputProps = _extends({}, inputProps, textFieldProps.inputProps);\n textFieldProps.InputProps = _extends({}, InputProps, textFieldProps.InputProps);\n const fieldResponse = useDateField(textFieldProps);\n const convertedFieldResponse = convertFieldResponseIntoMuiTextFieldProps(fieldResponse);\n const processedFieldProps = useClearableField(_extends({}, convertedFieldResponse, {\n slots,\n slotProps\n }));\n return /*#__PURE__*/_jsx(TextField, _extends({}, processedFieldProps));\n});\nprocess.env.NODE_ENV !== \"production\" ? DateField.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * If `true`, the `input` element is focused during the first mount.\n * @default false\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, a clear button will be shown in the field allowing value clearing.\n * @default false\n */\n clearable: PropTypes.bool,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * @default 'primary'\n */\n color: PropTypes.oneOf(['error', 'info', 'primary', 'secondary', 'success', 'warning']),\n component: PropTypes.elementType,\n /**\n * The default value. Use when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the component is disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.bool,\n /**\n * If `true`, the component is displayed in focused state.\n */\n focused: PropTypes.bool,\n /**\n * Format of the date when rendered in the input(s).\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Props applied to the [`FormHelperText`](/material-ui/api/form-helper-text/) element.\n */\n FormHelperTextProps: PropTypes.object,\n /**\n * If `true`, the input will take up the full width of its container.\n * @default false\n */\n fullWidth: PropTypes.bool,\n /**\n * The helper text content.\n */\n helperText: PropTypes.node,\n /**\n * If `true`, the label is hidden.\n * This is used to increase density for a `FilledInput`.\n * Be sure to add `aria-label` to the `input` element.\n * @default false\n */\n hiddenLabel: PropTypes.bool,\n /**\n * The id of the `input` element.\n * Use this prop to make `label` and `helperText` accessible for screen readers.\n */\n id: PropTypes.string,\n /**\n * Props applied to the [`InputLabel`](/material-ui/api/input-label/) element.\n * Pointer events like `onClick` are enabled if and only if `shrink` is `true`.\n */\n InputLabelProps: PropTypes.object,\n /**\n * [Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#Attributes) applied to the `input` element.\n */\n inputProps: PropTypes.object,\n /**\n * Props applied to the Input element.\n * It will be a [`FilledInput`](/material-ui/api/filled-input/),\n * [`OutlinedInput`](/material-ui/api/outlined-input/) or [`Input`](/material-ui/api/input/)\n * component depending on the `variant` prop value.\n */\n InputProps: PropTypes.object,\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * If `dense` or `normal`, will adjust vertical spacing of this and contained components.\n * @default 'none'\n */\n margin: PropTypes.oneOf(['dense', 'none', 'normal']),\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Name attribute of the `input` element.\n */\n name: PropTypes.string,\n onBlur: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the clear button is clicked.\n */\n onClear: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n onFocus: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * It prevents the user from changing the value of the field\n * (not from interacting with the field).\n * @default false\n */\n readOnly: PropTypes.bool,\n /**\n * The date used to generate a part of the new value that is not present in the format when both `value` and `defaultValue` are empty.\n * For example, on time fields it will be used to determine the date to set.\n * @default The closest valid date using the validation props, except callbacks such as `shouldDisableDate`. Value is rounded to the most granular section used.\n */\n referenceDate: PropTypes.object,\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n * @default false\n */\n required: PropTypes.bool,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, the format will respect the leading zeroes (e.g: on dayjs, the format `M/D/YYYY` will render `8/16/2018`)\n * If `false`, the format will always add leading zeroes (e.g: on dayjs, the format `M/D/YYYY` will render `08/16/2018`)\n *\n * Warning n°1: Luxon is not able to respect the leading zeroes when using macro tokens (e.g: \"DD\"), so `shouldRespectLeadingZeros={true}` might lead to inconsistencies when using `AdapterLuxon`.\n *\n * Warning n°2: When `shouldRespectLeadingZeros={true}`, the field will add an invisible character on the sections containing a single digit to make sure `onChange` is fired.\n * If you need to get the clean value from the input, you can remove this character using `input.value.replace(/\\u200e/g, '')`.\n *\n * Warning n°3: When used in strict mode, dayjs and moment require to respect the leading zeros.\n * This mean that when using `shouldRespectLeadingZeros={false}`, if you retrieve the value directly from the input (not listening to `onChange`) and your format contains tokens without leading zeros, the value will not be parsed by your library.\n *\n * @default false\n */\n shouldRespectLeadingZeros: PropTypes.bool,\n /**\n * The size of the component.\n */\n size: PropTypes.oneOf(['medium', 'small']),\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n style: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The ref object used to imperatively interact with the field.\n */\n unstableFieldRef: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The variant to use.\n * @default 'outlined'\n */\n variant: PropTypes.oneOf(['filled', 'outlined', 'standard'])\n} : void 0;\nexport { DateField };","import { createIsAfterIgnoreDatePart } from \"../internals/utils/time-utils.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nexport const validateTime = ({\n adapter,\n value,\n timezone,\n props\n}) => {\n if (value === null) {\n return null;\n }\n const {\n minTime,\n maxTime,\n minutesStep,\n shouldDisableTime,\n disableIgnoringDatePartForTimeValidation = false,\n disablePast,\n disableFuture\n } = props;\n const now = adapter.utils.date(undefined, timezone);\n const isAfter = createIsAfterIgnoreDatePart(disableIgnoringDatePartForTimeValidation, adapter.utils);\n switch (true) {\n case !adapter.utils.isValid(value):\n return 'invalidDate';\n case Boolean(minTime && isAfter(minTime, value)):\n return 'minTime';\n case Boolean(maxTime && isAfter(value, maxTime)):\n return 'maxTime';\n case Boolean(disableFuture && adapter.utils.isAfter(value, now)):\n return 'disableFuture';\n case Boolean(disablePast && adapter.utils.isBefore(value, now)):\n return 'disablePast';\n case Boolean(shouldDisableTime && shouldDisableTime(value, 'hours')):\n return 'shouldDisableTime-hours';\n case Boolean(shouldDisableTime && shouldDisableTime(value, 'minutes')):\n return 'shouldDisableTime-minutes';\n case Boolean(shouldDisableTime && shouldDisableTime(value, 'seconds')):\n return 'shouldDisableTime-seconds';\n case Boolean(minutesStep && adapter.utils.getMinutes(value) % minutesStep !== 0):\n return 'minutesStep';\n default:\n return null;\n }\n};\nvalidateTime.valueManager = singleItemValueManager;","'use client';\n\nimport { singleItemFieldValueManager, singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { useField } from \"../internals/hooks/useField/index.js\";\nimport { validateTime } from \"../validation/index.js\";\nimport { useSplitFieldProps } from \"../hooks/index.js\";\nimport { useDefaultizedTimeField } from \"../internals/hooks/defaultizedFieldProps.js\";\nexport const useTimeField = inProps => {\n const props = useDefaultizedTimeField(inProps);\n const {\n forwardedProps,\n internalProps\n } = useSplitFieldProps(props, 'time');\n return useField({\n forwardedProps,\n internalProps,\n valueManager: singleItemValueManager,\n fieldValueManager: singleItemFieldValueManager,\n validator: validateTime,\n valueType: 'time'\n });\n};","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"slots\", \"slotProps\", \"InputProps\", \"inputProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport MuiTextField from '@mui/material/TextField';\nimport { useThemeProps } from '@mui/material/styles';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport { refType } from '@mui/utils';\nimport { useTimeField } from \"./useTimeField.js\";\nimport { useClearableField } from \"../hooks/index.js\";\nimport { PickersTextField } from \"../PickersTextField/index.js\";\nimport { convertFieldResponseIntoMuiTextFieldProps } from \"../internals/utils/convertFieldResponseIntoMuiTextFieldProps.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\n/**\n * Demos:\n *\n * - [TimeField](http://mui.com/x/react-date-pickers/time-field/)\n * - [Fields](https://mui.com/x/react-date-pickers/fields/)\n *\n * API:\n *\n * - [TimeField API](https://mui.com/x/api/date-pickers/time-field/)\n */\nconst TimeField = /*#__PURE__*/React.forwardRef(function TimeField(inProps, inRef) {\n const themeProps = useThemeProps({\n props: inProps,\n name: 'MuiTimeField'\n });\n const {\n slots,\n slotProps,\n InputProps,\n inputProps\n } = themeProps,\n other = _objectWithoutPropertiesLoose(themeProps, _excluded);\n const ownerState = themeProps;\n const TextField = slots?.textField ?? (inProps.enableAccessibleFieldDOMStructure ? PickersTextField : MuiTextField);\n const textFieldProps = useSlotProps({\n elementType: TextField,\n externalSlotProps: slotProps?.textField,\n externalForwardedProps: other,\n ownerState,\n additionalProps: {\n ref: inRef\n }\n });\n\n // TODO: Remove when mui/material-ui#35088 will be merged\n textFieldProps.inputProps = _extends({}, inputProps, textFieldProps.inputProps);\n textFieldProps.InputProps = _extends({}, InputProps, textFieldProps.InputProps);\n const fieldResponse = useTimeField(textFieldProps);\n const convertedFieldResponse = convertFieldResponseIntoMuiTextFieldProps(fieldResponse);\n const processedFieldProps = useClearableField(_extends({}, convertedFieldResponse, {\n slots,\n slotProps\n }));\n return /*#__PURE__*/_jsx(TextField, _extends({}, processedFieldProps));\n});\nprocess.env.NODE_ENV !== \"production\" ? TimeField.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * If `true`, the `input` element is focused during the first mount.\n * @default false\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, a clear button will be shown in the field allowing value clearing.\n * @default false\n */\n clearable: PropTypes.bool,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * @default 'primary'\n */\n color: PropTypes.oneOf(['error', 'info', 'primary', 'secondary', 'success', 'warning']),\n component: PropTypes.elementType,\n /**\n * The default value. Use when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the component is disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.bool,\n /**\n * If `true`, the component is displayed in focused state.\n */\n focused: PropTypes.bool,\n /**\n * Format of the date when rendered in the input(s).\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Props applied to the [`FormHelperText`](/material-ui/api/form-helper-text/) element.\n */\n FormHelperTextProps: PropTypes.object,\n /**\n * If `true`, the input will take up the full width of its container.\n * @default false\n */\n fullWidth: PropTypes.bool,\n /**\n * The helper text content.\n */\n helperText: PropTypes.node,\n /**\n * If `true`, the label is hidden.\n * This is used to increase density for a `FilledInput`.\n * Be sure to add `aria-label` to the `input` element.\n * @default false\n */\n hiddenLabel: PropTypes.bool,\n /**\n * The id of the `input` element.\n * Use this prop to make `label` and `helperText` accessible for screen readers.\n */\n id: PropTypes.string,\n /**\n * Props applied to the [`InputLabel`](/material-ui/api/input-label/) element.\n * Pointer events like `onClick` are enabled if and only if `shrink` is `true`.\n */\n InputLabelProps: PropTypes.object,\n /**\n * [Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#Attributes) applied to the `input` element.\n */\n inputProps: PropTypes.object,\n /**\n * Props applied to the Input element.\n * It will be a [`FilledInput`](/material-ui/api/filled-input/),\n * [`OutlinedInput`](/material-ui/api/outlined-input/) or [`Input`](/material-ui/api/input/)\n * component depending on the `variant` prop value.\n */\n InputProps: PropTypes.object,\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * If `dense` or `normal`, will adjust vertical spacing of this and contained components.\n * @default 'none'\n */\n margin: PropTypes.oneOf(['dense', 'none', 'normal']),\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Name attribute of the `input` element.\n */\n name: PropTypes.string,\n onBlur: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the clear button is clicked.\n */\n onClear: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n onFocus: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * It prevents the user from changing the value of the field\n * (not from interacting with the field).\n * @default false\n */\n readOnly: PropTypes.bool,\n /**\n * The date used to generate a part of the new value that is not present in the format when both `value` and `defaultValue` are empty.\n * For example, on time fields it will be used to determine the date to set.\n * @default The closest valid date using the validation props, except callbacks such as `shouldDisableDate`. Value is rounded to the most granular section used.\n */\n referenceDate: PropTypes.object,\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n * @default false\n */\n required: PropTypes.bool,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * If `true`, the format will respect the leading zeroes (e.g: on dayjs, the format `M/D/YYYY` will render `8/16/2018`)\n * If `false`, the format will always add leading zeroes (e.g: on dayjs, the format `M/D/YYYY` will render `08/16/2018`)\n *\n * Warning n°1: Luxon is not able to respect the leading zeroes when using macro tokens (e.g: \"DD\"), so `shouldRespectLeadingZeros={true}` might lead to inconsistencies when using `AdapterLuxon`.\n *\n * Warning n°2: When `shouldRespectLeadingZeros={true}`, the field will add an invisible character on the sections containing a single digit to make sure `onChange` is fired.\n * If you need to get the clean value from the input, you can remove this character using `input.value.replace(/\\u200e/g, '')`.\n *\n * Warning n°3: When used in strict mode, dayjs and moment require to respect the leading zeros.\n * This mean that when using `shouldRespectLeadingZeros={false}`, if you retrieve the value directly from the input (not listening to `onChange`) and your format contains tokens without leading zeros, the value will not be parsed by your library.\n *\n * @default false\n */\n shouldRespectLeadingZeros: PropTypes.bool,\n /**\n * The size of the component.\n */\n size: PropTypes.oneOf(['medium', 'small']),\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n style: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The ref object used to imperatively interact with the field.\n */\n unstableFieldRef: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The variant to use.\n * @default 'outlined'\n */\n variant: PropTypes.oneOf(['filled', 'outlined', 'standard'])\n} : void 0;\nexport { TimeField };","import { validateDate } from \"./validateDate.js\";\nimport { validateTime } from \"./validateTime.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nexport const validateDateTime = ({\n adapter,\n value,\n timezone,\n props\n}) => {\n const dateValidationResult = validateDate({\n adapter,\n value,\n timezone,\n props\n });\n if (dateValidationResult !== null) {\n return dateValidationResult;\n }\n return validateTime({\n adapter,\n value,\n timezone,\n props\n });\n};\nvalidateDateTime.valueManager = singleItemValueManager;","'use client';\n\nimport { singleItemFieldValueManager, singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { useField } from \"../internals/hooks/useField/index.js\";\nimport { validateDateTime } from \"../validation/index.js\";\nimport { useSplitFieldProps } from \"../hooks/index.js\";\nimport { useDefaultizedDateTimeField } from \"../internals/hooks/defaultizedFieldProps.js\";\nexport const useDateTimeField = inProps => {\n const props = useDefaultizedDateTimeField(inProps);\n const {\n forwardedProps,\n internalProps\n } = useSplitFieldProps(props, 'date-time');\n return useField({\n forwardedProps,\n internalProps,\n valueManager: singleItemValueManager,\n fieldValueManager: singleItemFieldValueManager,\n validator: validateDateTime,\n valueType: 'date-time'\n });\n};","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"slots\", \"slotProps\", \"InputProps\", \"inputProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport MuiTextField from '@mui/material/TextField';\nimport { useThemeProps } from '@mui/material/styles';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport { refType } from '@mui/utils';\nimport { useDateTimeField } from \"./useDateTimeField.js\";\nimport { useClearableField } from \"../hooks/index.js\";\nimport { PickersTextField } from \"../PickersTextField/index.js\";\nimport { convertFieldResponseIntoMuiTextFieldProps } from \"../internals/utils/convertFieldResponseIntoMuiTextFieldProps.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\n/**\n * Demos:\n *\n * - [DateTimeField](http://mui.com/x/react-date-pickers/date-time-field/)\n * - [Fields](https://mui.com/x/react-date-pickers/fields/)\n *\n * API:\n *\n * - [DateTimeField API](https://mui.com/x/api/date-pickers/date-time-field/)\n */\nconst DateTimeField = /*#__PURE__*/React.forwardRef(function DateTimeField(inProps, inRef) {\n const themeProps = useThemeProps({\n props: inProps,\n name: 'MuiDateTimeField'\n });\n const {\n slots,\n slotProps,\n InputProps,\n inputProps\n } = themeProps,\n other = _objectWithoutPropertiesLoose(themeProps, _excluded);\n const ownerState = themeProps;\n const TextField = slots?.textField ?? (inProps.enableAccessibleFieldDOMStructure ? PickersTextField : MuiTextField);\n const textFieldProps = useSlotProps({\n elementType: TextField,\n externalSlotProps: slotProps?.textField,\n externalForwardedProps: other,\n ownerState,\n additionalProps: {\n ref: inRef\n }\n });\n\n // TODO: Remove when mui/material-ui#35088 will be merged\n textFieldProps.inputProps = _extends({}, inputProps, textFieldProps.inputProps);\n textFieldProps.InputProps = _extends({}, InputProps, textFieldProps.InputProps);\n const fieldResponse = useDateTimeField(textFieldProps);\n const convertedFieldResponse = convertFieldResponseIntoMuiTextFieldProps(fieldResponse);\n const processedFieldProps = useClearableField(_extends({}, convertedFieldResponse, {\n slots,\n slotProps\n }));\n return /*#__PURE__*/_jsx(TextField, _extends({}, processedFieldProps));\n});\nprocess.env.NODE_ENV !== \"production\" ? DateTimeField.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * If `true`, the `input` element is focused during the first mount.\n * @default false\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, a clear button will be shown in the field allowing value clearing.\n * @default false\n */\n clearable: PropTypes.bool,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * @default 'primary'\n */\n color: PropTypes.oneOf(['error', 'info', 'primary', 'secondary', 'success', 'warning']),\n component: PropTypes.elementType,\n /**\n * The default value. Use when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the component is disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.bool,\n /**\n * If `true`, the component is displayed in focused state.\n */\n focused: PropTypes.bool,\n /**\n * Format of the date when rendered in the input(s).\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Props applied to the [`FormHelperText`](/material-ui/api/form-helper-text/) element.\n */\n FormHelperTextProps: PropTypes.object,\n /**\n * If `true`, the input will take up the full width of its container.\n * @default false\n */\n fullWidth: PropTypes.bool,\n /**\n * The helper text content.\n */\n helperText: PropTypes.node,\n /**\n * If `true`, the label is hidden.\n * This is used to increase density for a `FilledInput`.\n * Be sure to add `aria-label` to the `input` element.\n * @default false\n */\n hiddenLabel: PropTypes.bool,\n /**\n * The id of the `input` element.\n * Use this prop to make `label` and `helperText` accessible for screen readers.\n */\n id: PropTypes.string,\n /**\n * Props applied to the [`InputLabel`](/material-ui/api/input-label/) element.\n * Pointer events like `onClick` are enabled if and only if `shrink` is `true`.\n */\n InputLabelProps: PropTypes.object,\n /**\n * [Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#Attributes) applied to the `input` element.\n */\n inputProps: PropTypes.object,\n /**\n * Props applied to the Input element.\n * It will be a [`FilledInput`](/material-ui/api/filled-input/),\n * [`OutlinedInput`](/material-ui/api/outlined-input/) or [`Input`](/material-ui/api/input/)\n * component depending on the `variant` prop value.\n */\n InputProps: PropTypes.object,\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * If `dense` or `normal`, will adjust vertical spacing of this and contained components.\n * @default 'none'\n */\n margin: PropTypes.oneOf(['dense', 'none', 'normal']),\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Maximal selectable moment of time with binding to date, to set max time in each day use `maxTime`.\n */\n maxDateTime: PropTypes.object,\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Minimal selectable moment of time with binding to date, to set min time in each day use `minTime`.\n */\n minDateTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Name attribute of the `input` element.\n */\n name: PropTypes.string,\n onBlur: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the clear button is clicked.\n */\n onClear: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n onFocus: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * It prevents the user from changing the value of the field\n * (not from interacting with the field).\n * @default false\n */\n readOnly: PropTypes.bool,\n /**\n * The date used to generate a part of the new value that is not present in the format when both `value` and `defaultValue` are empty.\n * For example, on time fields it will be used to determine the date to set.\n * @default The closest valid date using the validation props, except callbacks such as `shouldDisableDate`. Value is rounded to the most granular section used.\n */\n referenceDate: PropTypes.object,\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n * @default false\n */\n required: PropTypes.bool,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, the format will respect the leading zeroes (e.g: on dayjs, the format `M/D/YYYY` will render `8/16/2018`)\n * If `false`, the format will always add leading zeroes (e.g: on dayjs, the format `M/D/YYYY` will render `08/16/2018`)\n *\n * Warning n°1: Luxon is not able to respect the leading zeroes when using macro tokens (e.g: \"DD\"), so `shouldRespectLeadingZeros={true}` might lead to inconsistencies when using `AdapterLuxon`.\n *\n * Warning n°2: When `shouldRespectLeadingZeros={true}`, the field will add an invisible character on the sections containing a single digit to make sure `onChange` is fired.\n * If you need to get the clean value from the input, you can remove this character using `input.value.replace(/\\u200e/g, '')`.\n *\n * Warning n°3: When used in strict mode, dayjs and moment require to respect the leading zeros.\n * This mean that when using `shouldRespectLeadingZeros={false}`, if you retrieve the value directly from the input (not listening to `onChange`) and your format contains tokens without leading zeros, the value will not be parsed by your library.\n *\n * @default false\n */\n shouldRespectLeadingZeros: PropTypes.bool,\n /**\n * The size of the component.\n */\n size: PropTypes.oneOf(['medium', 'small']),\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n style: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The ref object used to imperatively interact with the field.\n */\n unstableFieldRef: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The variant to use.\n * @default 'outlined'\n */\n variant: PropTypes.oneOf(['filled', 'outlined', 'standard'])\n} : void 0;\nexport { DateTimeField };","'use client';\n\nimport * as React from 'react';\nimport { validateDate } from \"../validation/index.js\";\nimport { useLocalizationContext } from \"../internals/hooks/useUtils.js\";\nexport const useIsDateDisabled = ({\n shouldDisableDate,\n shouldDisableMonth,\n shouldDisableYear,\n minDate,\n maxDate,\n disableFuture,\n disablePast,\n timezone\n}) => {\n const adapter = useLocalizationContext();\n return React.useCallback(day => validateDate({\n adapter,\n value: day,\n timezone,\n props: {\n shouldDisableDate,\n shouldDisableMonth,\n shouldDisableYear,\n minDate,\n maxDate,\n disableFuture,\n disablePast\n }\n }) !== null, [adapter, shouldDisableDate, shouldDisableMonth, shouldDisableYear, minDate, maxDate, disableFuture, disablePast, timezone]);\n};","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport { useIsDateDisabled } from \"./useIsDateDisabled.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { SECTION_TYPE_GRANULARITY } from \"../internals/utils/getDefaultReferenceDate.js\";\nexport const createCalendarStateReducer = (reduceAnimations, disableSwitchToMonthOnDayFocus, utils) => (state, action) => {\n switch (action.type) {\n case 'changeMonth':\n return _extends({}, state, {\n slideDirection: action.direction,\n currentMonth: action.newMonth,\n isMonthSwitchingAnimating: !reduceAnimations\n });\n case 'changeMonthTimezone':\n {\n const newTimezone = action.newTimezone;\n if (utils.getTimezone(state.currentMonth) === newTimezone) {\n return state;\n }\n let newCurrentMonth = utils.setTimezone(state.currentMonth, newTimezone);\n if (utils.getMonth(newCurrentMonth) !== utils.getMonth(state.currentMonth)) {\n newCurrentMonth = utils.setMonth(newCurrentMonth, utils.getMonth(state.currentMonth));\n }\n return _extends({}, state, {\n currentMonth: newCurrentMonth\n });\n }\n case 'finishMonthSwitchingAnimation':\n return _extends({}, state, {\n isMonthSwitchingAnimating: false\n });\n case 'changeFocusedDay':\n {\n if (state.focusedDay != null && action.focusedDay != null && utils.isSameDay(action.focusedDay, state.focusedDay)) {\n return state;\n }\n const needMonthSwitch = action.focusedDay != null && !disableSwitchToMonthOnDayFocus && !utils.isSameMonth(state.currentMonth, action.focusedDay);\n return _extends({}, state, {\n focusedDay: action.focusedDay,\n isMonthSwitchingAnimating: needMonthSwitch && !reduceAnimations && !action.withoutMonthSwitchingAnimation,\n currentMonth: needMonthSwitch ? utils.startOfMonth(action.focusedDay) : state.currentMonth,\n slideDirection: action.focusedDay != null && utils.isAfterDay(action.focusedDay, state.currentMonth) ? 'left' : 'right'\n });\n }\n default:\n throw new Error('missing support');\n }\n};\nexport const useCalendarState = params => {\n const {\n value,\n referenceDate: referenceDateProp,\n disableFuture,\n disablePast,\n disableSwitchToMonthOnDayFocus = false,\n maxDate,\n minDate,\n onMonthChange,\n reduceAnimations,\n shouldDisableDate,\n timezone\n } = params;\n const utils = useUtils();\n const reducerFn = React.useRef(createCalendarStateReducer(Boolean(reduceAnimations), disableSwitchToMonthOnDayFocus, utils)).current;\n const referenceDate = React.useMemo(() => {\n return singleItemValueManager.getInitialReferenceValue({\n value,\n utils,\n timezone,\n props: params,\n referenceDate: referenceDateProp,\n granularity: SECTION_TYPE_GRANULARITY.day\n });\n },\n // We want the `referenceDate` to update on prop and `timezone` change (https://github.com/mui/mui-x/issues/10804)\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [referenceDateProp, timezone]);\n const [calendarState, dispatch] = React.useReducer(reducerFn, {\n isMonthSwitchingAnimating: false,\n focusedDay: referenceDate,\n currentMonth: utils.startOfMonth(referenceDate),\n slideDirection: 'left'\n });\n\n // Ensure that `calendarState.currentMonth` timezone is updated when `referenceDate` (or timezone changes)\n // https://github.com/mui/mui-x/issues/10804\n React.useEffect(() => {\n dispatch({\n type: 'changeMonthTimezone',\n newTimezone: utils.getTimezone(referenceDate)\n });\n }, [referenceDate, utils]);\n const handleChangeMonth = React.useCallback(payload => {\n dispatch(_extends({\n type: 'changeMonth'\n }, payload));\n if (onMonthChange) {\n onMonthChange(payload.newMonth);\n }\n }, [onMonthChange]);\n const changeMonth = React.useCallback(newDate => {\n const newDateRequested = newDate;\n if (utils.isSameMonth(newDateRequested, calendarState.currentMonth)) {\n return;\n }\n handleChangeMonth({\n newMonth: utils.startOfMonth(newDateRequested),\n direction: utils.isAfterDay(newDateRequested, calendarState.currentMonth) ? 'left' : 'right'\n });\n }, [calendarState.currentMonth, handleChangeMonth, utils]);\n const isDateDisabled = useIsDateDisabled({\n shouldDisableDate,\n minDate,\n maxDate,\n disableFuture,\n disablePast,\n timezone\n });\n const onMonthSwitchingAnimationEnd = React.useCallback(() => {\n dispatch({\n type: 'finishMonthSwitchingAnimation'\n });\n }, []);\n const changeFocusedDay = useEventCallback((newFocusedDate, withoutMonthSwitchingAnimation) => {\n if (!isDateDisabled(newFocusedDate)) {\n dispatch({\n type: 'changeFocusedDay',\n focusedDay: newFocusedDate,\n withoutMonthSwitchingAnimation\n });\n }\n });\n return {\n referenceDate,\n calendarState,\n changeMonth,\n changeFocusedDay,\n isDateDisabled,\n onMonthSwitchingAnimationEnd,\n handleChangeMonth\n };\n};","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport const getPickersFadeTransitionGroupUtilityClass = slot => generateUtilityClass('MuiPickersFadeTransitionGroup', slot);\nexport const pickersFadeTransitionGroupClasses = generateUtilityClasses('MuiPickersFadeTransitionGroup', ['root']);","import * as React from 'react';\nimport clsx from 'clsx';\nimport { TransitionGroup } from 'react-transition-group';\nimport Fade from '@mui/material/Fade';\nimport { styled, useTheme, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { getPickersFadeTransitionGroupUtilityClass } from \"./pickersFadeTransitionGroupClasses.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, getPickersFadeTransitionGroupUtilityClass, classes);\n};\nconst PickersFadeTransitionGroupRoot = styled(TransitionGroup, {\n name: 'MuiPickersFadeTransitionGroup',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})({\n display: 'block',\n position: 'relative'\n});\n\n/**\n * @ignore - do not document.\n */\nexport function PickersFadeTransitionGroup(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersFadeTransitionGroup'\n });\n const {\n children,\n className,\n reduceAnimations,\n transKey\n } = props;\n const classes = useUtilityClasses(props);\n const theme = useTheme();\n if (reduceAnimations) {\n return children;\n }\n return /*#__PURE__*/_jsx(PickersFadeTransitionGroupRoot, {\n className: clsx(classes.root, className),\n children: /*#__PURE__*/_jsx(Fade, {\n appear: false,\n mountOnEnter: true,\n unmountOnExit: true,\n timeout: {\n appear: theme.transitions.duration.enteringScreen,\n enter: theme.transitions.duration.enteringScreen,\n exit: 0\n },\n children: children\n }, transKey)\n });\n}","/**\n * Checks if a given element has a CSS class.\n * \n * @param element the element\n * @param className the CSS class name\n */\nexport default function hasClass(element, className) {\n if (element.classList) return !!className && element.classList.contains(className);\n return (\" \" + (element.className.baseVal || element.className) + \" \").indexOf(\" \" + className + \" \") !== -1;\n}","import hasClass from './hasClass';\n/**\n * Adds a CSS class to a given element.\n * \n * @param element the element\n * @param className the CSS class name\n */\n\nexport default function addClass(element, className) {\n if (element.classList) element.classList.add(className);else if (!hasClass(element, className)) if (typeof element.className === 'string') element.className = element.className + \" \" + className;else element.setAttribute('class', (element.className && element.className.baseVal || '') + \" \" + className);\n}","function replaceClassName(origClass, classToRemove) {\n return origClass.replace(new RegExp(\"(^|\\\\s)\" + classToRemove + \"(?:\\\\s|$)\", 'g'), '$1').replace(/\\s+/g, ' ').replace(/^\\s*|\\s*$/g, '');\n}\n/**\n * Removes a CSS class from a given element.\n * \n * @param element the element\n * @param className the CSS class name\n */\n\n\nexport default function removeClass(element, className) {\n if (element.classList) {\n element.classList.remove(className);\n } else if (typeof element.className === 'string') {\n element.className = replaceClassName(element.className, className);\n } else {\n element.setAttribute('class', replaceClassName(element.className && element.className.baseVal || '', className));\n }\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport addOneClass from 'dom-helpers/addClass';\nimport removeOneClass from 'dom-helpers/removeClass';\nimport React from 'react';\nimport Transition from './Transition';\nimport { classNamesShape } from './utils/PropTypes';\nimport { forceReflow } from './utils/reflow';\n\nvar _addClass = function addClass(node, classes) {\n return node && classes && classes.split(' ').forEach(function (c) {\n return addOneClass(node, c);\n });\n};\n\nvar removeClass = function removeClass(node, classes) {\n return node && classes && classes.split(' ').forEach(function (c) {\n return removeOneClass(node, c);\n });\n};\n/**\n * A transition component inspired by the excellent\n * [ng-animate](https://docs.angularjs.org/api/ngAnimate) library, you should\n * use it if you're using CSS transitions or animations. It's built upon the\n * [`Transition`](https://reactcommunity.org/react-transition-group/transition)\n * component, so it inherits all of its props.\n *\n * `CSSTransition` applies a pair of class names during the `appear`, `enter`,\n * and `exit` states of the transition. The first class is applied and then a\n * second `*-active` class in order to activate the CSS transition. After the\n * transition, matching `*-done` class names are applied to persist the\n * transition state.\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
\n * \n *
\n * {\"I'll receive my-node-* classes\"}\n *
\n *
\n * \n *
\n * );\n * }\n * ```\n *\n * When the `in` prop is set to `true`, the child component will first receive\n * the class `example-enter`, then the `example-enter-active` will be added in\n * the next tick. `CSSTransition` [forces a\n * reflow](https://github.com/reactjs/react-transition-group/blob/5007303e729a74be66a21c3e2205e4916821524b/src/CSSTransition.js#L208-L215)\n * between before adding the `example-enter-active`. This is an important trick\n * because it allows us to transition between `example-enter` and\n * `example-enter-active` even though they were added immediately one after\n * another. Most notably, this is what makes it possible for us to animate\n * _appearance_.\n *\n * ```css\n * .my-node-enter {\n * opacity: 0;\n * }\n * .my-node-enter-active {\n * opacity: 1;\n * transition: opacity 200ms;\n * }\n * .my-node-exit {\n * opacity: 1;\n * }\n * .my-node-exit-active {\n * opacity: 0;\n * transition: opacity 200ms;\n * }\n * ```\n *\n * `*-active` classes represent which styles you want to animate **to**, so it's\n * important to add `transition` declaration only to them, otherwise transitions\n * might not behave as intended! This might not be obvious when the transitions\n * are symmetrical, i.e. when `*-enter-active` is the same as `*-exit`, like in\n * the example above (minus `transition`), but it becomes apparent in more\n * complex transitions.\n *\n * **Note**: If you're using the\n * [`appear`](http://reactcommunity.org/react-transition-group/transition#Transition-prop-appear)\n * prop, make sure to define styles for `.appear-*` classes as well.\n */\n\n\nvar CSSTransition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(CSSTransition, _React$Component);\n\n function CSSTransition() {\n var _this;\n\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n _this = _React$Component.call.apply(_React$Component, [this].concat(args)) || this;\n _this.appliedClasses = {\n appear: {},\n enter: {},\n exit: {}\n };\n\n _this.onEnter = function (maybeNode, maybeAppearing) {\n var _this$resolveArgument = _this.resolveArguments(maybeNode, maybeAppearing),\n node = _this$resolveArgument[0],\n appearing = _this$resolveArgument[1];\n\n _this.removeClasses(node, 'exit');\n\n _this.addClass(node, appearing ? 'appear' : 'enter', 'base');\n\n if (_this.props.onEnter) {\n _this.props.onEnter(maybeNode, maybeAppearing);\n }\n };\n\n _this.onEntering = function (maybeNode, maybeAppearing) {\n var _this$resolveArgument2 = _this.resolveArguments(maybeNode, maybeAppearing),\n node = _this$resolveArgument2[0],\n appearing = _this$resolveArgument2[1];\n\n var type = appearing ? 'appear' : 'enter';\n\n _this.addClass(node, type, 'active');\n\n if (_this.props.onEntering) {\n _this.props.onEntering(maybeNode, maybeAppearing);\n }\n };\n\n _this.onEntered = function (maybeNode, maybeAppearing) {\n var _this$resolveArgument3 = _this.resolveArguments(maybeNode, maybeAppearing),\n node = _this$resolveArgument3[0],\n appearing = _this$resolveArgument3[1];\n\n var type = appearing ? 'appear' : 'enter';\n\n _this.removeClasses(node, type);\n\n _this.addClass(node, type, 'done');\n\n if (_this.props.onEntered) {\n _this.props.onEntered(maybeNode, maybeAppearing);\n }\n };\n\n _this.onExit = function (maybeNode) {\n var _this$resolveArgument4 = _this.resolveArguments(maybeNode),\n node = _this$resolveArgument4[0];\n\n _this.removeClasses(node, 'appear');\n\n _this.removeClasses(node, 'enter');\n\n _this.addClass(node, 'exit', 'base');\n\n if (_this.props.onExit) {\n _this.props.onExit(maybeNode);\n }\n };\n\n _this.onExiting = function (maybeNode) {\n var _this$resolveArgument5 = _this.resolveArguments(maybeNode),\n node = _this$resolveArgument5[0];\n\n _this.addClass(node, 'exit', 'active');\n\n if (_this.props.onExiting) {\n _this.props.onExiting(maybeNode);\n }\n };\n\n _this.onExited = function (maybeNode) {\n var _this$resolveArgument6 = _this.resolveArguments(maybeNode),\n node = _this$resolveArgument6[0];\n\n _this.removeClasses(node, 'exit');\n\n _this.addClass(node, 'exit', 'done');\n\n if (_this.props.onExited) {\n _this.props.onExited(maybeNode);\n }\n };\n\n _this.resolveArguments = function (maybeNode, maybeAppearing) {\n return _this.props.nodeRef ? [_this.props.nodeRef.current, maybeNode] // here `maybeNode` is actually `appearing`\n : [maybeNode, maybeAppearing];\n };\n\n _this.getClassNames = function (type) {\n var classNames = _this.props.classNames;\n var isStringClassNames = typeof classNames === 'string';\n var prefix = isStringClassNames && classNames ? classNames + \"-\" : '';\n var baseClassName = isStringClassNames ? \"\" + prefix + type : classNames[type];\n var activeClassName = isStringClassNames ? baseClassName + \"-active\" : classNames[type + \"Active\"];\n var doneClassName = isStringClassNames ? baseClassName + \"-done\" : classNames[type + \"Done\"];\n return {\n baseClassName: baseClassName,\n activeClassName: activeClassName,\n doneClassName: doneClassName\n };\n };\n\n return _this;\n }\n\n var _proto = CSSTransition.prototype;\n\n _proto.addClass = function addClass(node, type, phase) {\n var className = this.getClassNames(type)[phase + \"ClassName\"];\n\n var _this$getClassNames = this.getClassNames('enter'),\n doneClassName = _this$getClassNames.doneClassName;\n\n if (type === 'appear' && phase === 'done' && doneClassName) {\n className += \" \" + doneClassName;\n } // This is to force a repaint,\n // which is necessary in order to transition styles when adding a class name.\n\n\n if (phase === 'active') {\n if (node) forceReflow(node);\n }\n\n if (className) {\n this.appliedClasses[type][phase] = className;\n\n _addClass(node, className);\n }\n };\n\n _proto.removeClasses = function removeClasses(node, type) {\n var _this$appliedClasses$ = this.appliedClasses[type],\n baseClassName = _this$appliedClasses$.base,\n activeClassName = _this$appliedClasses$.active,\n doneClassName = _this$appliedClasses$.done;\n this.appliedClasses[type] = {};\n\n if (baseClassName) {\n removeClass(node, baseClassName);\n }\n\n if (activeClassName) {\n removeClass(node, activeClassName);\n }\n\n if (doneClassName) {\n removeClass(node, doneClassName);\n }\n };\n\n _proto.render = function render() {\n var _this$props = this.props,\n _ = _this$props.classNames,\n props = _objectWithoutPropertiesLoose(_this$props, [\"classNames\"]);\n\n return /*#__PURE__*/React.createElement(Transition, _extends({}, props, {\n onEnter: this.onEnter,\n onEntered: this.onEntered,\n onEntering: this.onEntering,\n onExit: this.onExit,\n onExiting: this.onExiting,\n onExited: this.onExited\n }));\n };\n\n return CSSTransition;\n}(React.Component);\n\nCSSTransition.defaultProps = {\n classNames: ''\n};\nCSSTransition.propTypes = process.env.NODE_ENV !== \"production\" ? _extends({}, Transition.propTypes, {\n /**\n * The animation classNames applied to the component as it appears, enters,\n * exits or has finished the transition. A single name can be provided, which\n * will be suffixed for each stage, e.g. `classNames=\"fade\"` applies:\n *\n * - `fade-appear`, `fade-appear-active`, `fade-appear-done`\n * - `fade-enter`, `fade-enter-active`, `fade-enter-done`\n * - `fade-exit`, `fade-exit-active`, `fade-exit-done`\n *\n * A few details to note about how these classes are applied:\n *\n * 1. They are _joined_ with the ones that are already defined on the child\n * component, so if you want to add some base styles, you can use\n * `className` without worrying that it will be overridden.\n *\n * 2. If the transition component mounts with `in={false}`, no classes are\n * applied yet. You might be expecting `*-exit-done`, but if you think\n * about it, a component cannot finish exiting if it hasn't entered yet.\n *\n * 2. `fade-appear-done` and `fade-enter-done` will _both_ be applied. This\n * allows you to define different behavior for when appearing is done and\n * when regular entering is done, using selectors like\n * `.fade-enter-done:not(.fade-appear-done)`. For example, you could apply\n * an epic entrance animation when element first appears in the DOM using\n * [Animate.css](https://daneden.github.io/animate.css/). Otherwise you can\n * simply use `fade-enter-done` for defining both cases.\n *\n * Each individual classNames can also be specified independently like:\n *\n * ```js\n * classNames={{\n * appear: 'my-appear',\n * appearActive: 'my-active-appear',\n * appearDone: 'my-done-appear',\n * enter: 'my-enter',\n * enterActive: 'my-active-enter',\n * enterDone: 'my-done-enter',\n * exit: 'my-exit',\n * exitActive: 'my-active-exit',\n * exitDone: 'my-done-exit',\n * }}\n * ```\n *\n * If you want to set these classes using CSS Modules:\n *\n * ```js\n * import styles from './styles.css';\n * ```\n *\n * you might want to use camelCase in your CSS file, that way could simply\n * spread them instead of listing them one by one:\n *\n * ```js\n * classNames={{ ...styles }}\n * ```\n *\n * @type {string | {\n * appear?: string,\n * appearActive?: string,\n * appearDone?: string,\n * enter?: string,\n * enterActive?: string,\n * enterDone?: string,\n * exit?: string,\n * exitActive?: string,\n * exitDone?: string,\n * }}\n */\n classNames: classNamesShape,\n\n /**\n * A `` callback fired immediately after the 'enter' or 'appear' class is\n * applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEnter: PropTypes.func,\n\n /**\n * A `` callback fired immediately after the 'enter-active' or\n * 'appear-active' class is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * A `` callback fired immediately after the 'enter' or\n * 'appear' classes are **removed** and the `done` class is added to the DOM node.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntered: PropTypes.func,\n\n /**\n * A `` callback fired immediately after the 'exit' class is\n * applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement)\n */\n onExit: PropTypes.func,\n\n /**\n * A `` callback fired immediately after the 'exit-active' is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement)\n */\n onExiting: PropTypes.func,\n\n /**\n * A `` callback fired immediately after the 'exit' classes\n * are **removed** and the `exit-done` class is added to the DOM node.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement)\n */\n onExited: PropTypes.func\n}) : {};\nexport default CSSTransition;","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport const getPickersSlideTransitionUtilityClass = slot => generateUtilityClass('MuiPickersSlideTransition', slot);\nexport const pickersSlideTransitionClasses = generateUtilityClasses('MuiPickersSlideTransition', ['root', 'slideEnter-left', 'slideEnter-right', 'slideEnterActive', 'slideExit', 'slideExitActiveLeft-left', 'slideExitActiveLeft-right']);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"reduceAnimations\", \"slideDirection\", \"transKey\", \"classes\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport { styled, useTheme, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { CSSTransition, TransitionGroup } from 'react-transition-group';\nimport { getPickersSlideTransitionUtilityClass, pickersSlideTransitionClasses } from \"./pickersSlideTransitionClasses.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n slideDirection\n } = ownerState;\n const slots = {\n root: ['root'],\n exit: ['slideExit'],\n enterActive: ['slideEnterActive'],\n enter: [`slideEnter-${slideDirection}`],\n exitActive: [`slideExitActiveLeft-${slideDirection}`]\n };\n return composeClasses(slots, getPickersSlideTransitionUtilityClass, classes);\n};\nconst PickersSlideTransitionRoot = styled(TransitionGroup, {\n name: 'MuiPickersSlideTransition',\n slot: 'Root',\n overridesResolver: (_, styles) => [styles.root, {\n [`.${pickersSlideTransitionClasses['slideEnter-left']}`]: styles['slideEnter-left']\n }, {\n [`.${pickersSlideTransitionClasses['slideEnter-right']}`]: styles['slideEnter-right']\n }, {\n [`.${pickersSlideTransitionClasses.slideEnterActive}`]: styles.slideEnterActive\n }, {\n [`.${pickersSlideTransitionClasses.slideExit}`]: styles.slideExit\n }, {\n [`.${pickersSlideTransitionClasses['slideExitActiveLeft-left']}`]: styles['slideExitActiveLeft-left']\n }, {\n [`.${pickersSlideTransitionClasses['slideExitActiveLeft-right']}`]: styles['slideExitActiveLeft-right']\n }]\n})(({\n theme\n}) => {\n const slideTransition = theme.transitions.create('transform', {\n duration: theme.transitions.duration.complex,\n easing: 'cubic-bezier(0.35, 0.8, 0.4, 1)'\n });\n return {\n display: 'block',\n position: 'relative',\n overflowX: 'hidden',\n '& > *': {\n position: 'absolute',\n top: 0,\n right: 0,\n left: 0\n },\n [`& .${pickersSlideTransitionClasses['slideEnter-left']}`]: {\n willChange: 'transform',\n transform: 'translate(100%)',\n zIndex: 1\n },\n [`& .${pickersSlideTransitionClasses['slideEnter-right']}`]: {\n willChange: 'transform',\n transform: 'translate(-100%)',\n zIndex: 1\n },\n [`& .${pickersSlideTransitionClasses.slideEnterActive}`]: {\n transform: 'translate(0%)',\n transition: slideTransition\n },\n [`& .${pickersSlideTransitionClasses.slideExit}`]: {\n transform: 'translate(0%)'\n },\n [`& .${pickersSlideTransitionClasses['slideExitActiveLeft-left']}`]: {\n willChange: 'transform',\n transform: 'translate(-100%)',\n transition: slideTransition,\n zIndex: 0\n },\n [`& .${pickersSlideTransitionClasses['slideExitActiveLeft-right']}`]: {\n willChange: 'transform',\n transform: 'translate(100%)',\n transition: slideTransition,\n zIndex: 0\n }\n };\n});\n\n/**\n * @ignore - do not document.\n */\nexport function PickersSlideTransition(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersSlideTransition'\n });\n const {\n children,\n className,\n reduceAnimations,\n transKey\n // extracting `classes` from `other`\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const classes = useUtilityClasses(props);\n const theme = useTheme();\n if (reduceAnimations) {\n return /*#__PURE__*/_jsx(\"div\", {\n className: clsx(classes.root, className),\n children: children\n });\n }\n const transitionClasses = {\n exit: classes.exit,\n enterActive: classes.enterActive,\n enter: classes.enter,\n exitActive: classes.exitActive\n };\n return /*#__PURE__*/_jsx(PickersSlideTransitionRoot, {\n className: clsx(classes.root, className),\n childFactory: element => /*#__PURE__*/React.cloneElement(element, {\n classNames: transitionClasses\n }),\n role: \"presentation\",\n children: /*#__PURE__*/_jsx(CSSTransition, _extends({\n mountOnEnter: true,\n unmountOnExit: true,\n timeout: theme.transitions.duration.complex,\n classNames: transitionClasses\n }, other, {\n children: children\n }), transKey)\n });\n}","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport const getDayCalendarUtilityClass = slot => generateUtilityClass('MuiDayCalendar', slot);\nexport const dayCalendarClasses = generateUtilityClasses('MuiDayCalendar', ['root', 'header', 'weekDayLabel', 'loadingContainer', 'slideTransition', 'monthContainer', 'weekContainer', 'weekNumberLabel', 'weekNumber']);","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"parentProps\", \"day\", \"focusableDay\", \"selectedDays\", \"isDateDisabled\", \"currentMonthNumber\", \"isViewFocused\"],\n _excluded2 = [\"ownerState\"];\nimport * as React from 'react';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport Typography from '@mui/material/Typography';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { unstable_composeClasses as composeClasses, unstable_useControlled as useControlled } from '@mui/utils';\nimport clsx from 'clsx';\nimport { PickersDay } from \"../PickersDay/PickersDay.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils, useNow } from \"../internals/hooks/useUtils.js\";\nimport { DAY_SIZE, DAY_MARGIN } from \"../internals/constants/dimensions.js\";\nimport { PickersSlideTransition } from \"./PickersSlideTransition.js\";\nimport { useIsDateDisabled } from \"./useIsDateDisabled.js\";\nimport { findClosestEnabledDate, getWeekdays } from \"../internals/utils/date-utils.js\";\nimport { getDayCalendarUtilityClass } from \"./dayCalendarClasses.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n header: ['header'],\n weekDayLabel: ['weekDayLabel'],\n loadingContainer: ['loadingContainer'],\n slideTransition: ['slideTransition'],\n monthContainer: ['monthContainer'],\n weekContainer: ['weekContainer'],\n weekNumberLabel: ['weekNumberLabel'],\n weekNumber: ['weekNumber']\n };\n return composeClasses(slots, getDayCalendarUtilityClass, classes);\n};\nconst weeksContainerHeight = (DAY_SIZE + DAY_MARGIN * 2) * 6;\nconst PickersCalendarDayRoot = styled('div', {\n name: 'MuiDayCalendar',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})({});\nconst PickersCalendarDayHeader = styled('div', {\n name: 'MuiDayCalendar',\n slot: 'Header',\n overridesResolver: (_, styles) => styles.header\n})({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center'\n});\nconst PickersCalendarWeekDayLabel = styled(Typography, {\n name: 'MuiDayCalendar',\n slot: 'WeekDayLabel',\n overridesResolver: (_, styles) => styles.weekDayLabel\n})(({\n theme\n}) => ({\n width: 36,\n height: 40,\n margin: '0 2px',\n textAlign: 'center',\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n color: (theme.vars || theme).palette.text.secondary\n}));\nconst PickersCalendarWeekNumberLabel = styled(Typography, {\n name: 'MuiDayCalendar',\n slot: 'WeekNumberLabel',\n overridesResolver: (_, styles) => styles.weekNumberLabel\n})(({\n theme\n}) => ({\n width: 36,\n height: 40,\n margin: '0 2px',\n textAlign: 'center',\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n color: theme.palette.text.disabled\n}));\nconst PickersCalendarWeekNumber = styled(Typography, {\n name: 'MuiDayCalendar',\n slot: 'WeekNumber',\n overridesResolver: (_, styles) => styles.weekNumber\n})(({\n theme\n}) => _extends({}, theme.typography.caption, {\n width: DAY_SIZE,\n height: DAY_SIZE,\n padding: 0,\n margin: `0 ${DAY_MARGIN}px`,\n color: theme.palette.text.disabled,\n fontSize: '0.75rem',\n alignItems: 'center',\n justifyContent: 'center',\n display: 'inline-flex'\n}));\nconst PickersCalendarLoadingContainer = styled('div', {\n name: 'MuiDayCalendar',\n slot: 'LoadingContainer',\n overridesResolver: (_, styles) => styles.loadingContainer\n})({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n minHeight: weeksContainerHeight\n});\nconst PickersCalendarSlideTransition = styled(PickersSlideTransition, {\n name: 'MuiDayCalendar',\n slot: 'SlideTransition',\n overridesResolver: (_, styles) => styles.slideTransition\n})({\n minHeight: weeksContainerHeight\n});\nconst PickersCalendarWeekContainer = styled('div', {\n name: 'MuiDayCalendar',\n slot: 'MonthContainer',\n overridesResolver: (_, styles) => styles.monthContainer\n})({\n overflow: 'hidden'\n});\nconst PickersCalendarWeek = styled('div', {\n name: 'MuiDayCalendar',\n slot: 'WeekContainer',\n overridesResolver: (_, styles) => styles.weekContainer\n})({\n margin: `${DAY_MARGIN}px 0`,\n display: 'flex',\n justifyContent: 'center'\n});\nfunction WrappedDay(_ref) {\n let {\n parentProps,\n day,\n focusableDay,\n selectedDays,\n isDateDisabled,\n currentMonthNumber,\n isViewFocused\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n const {\n disabled,\n disableHighlightToday,\n isMonthSwitchingAnimating,\n showDaysOutsideCurrentMonth,\n slots,\n slotProps,\n timezone\n } = parentProps;\n const utils = useUtils();\n const now = useNow(timezone);\n const isFocusableDay = focusableDay !== null && utils.isSameDay(day, focusableDay);\n const isSelected = selectedDays.some(selectedDay => utils.isSameDay(selectedDay, day));\n const isToday = utils.isSameDay(day, now);\n const Day = slots?.day ?? PickersDay;\n // We don't want to pass to ownerState down, to avoid re-rendering all the day whenever a prop changes.\n const _useSlotProps = useSlotProps({\n elementType: Day,\n externalSlotProps: slotProps?.day,\n additionalProps: _extends({\n disableHighlightToday,\n showDaysOutsideCurrentMonth,\n role: 'gridcell',\n isAnimating: isMonthSwitchingAnimating,\n // it is used in date range dragging logic by accessing `dataset.timestamp`\n 'data-timestamp': utils.toJsDate(day).valueOf()\n }, other),\n ownerState: _extends({}, parentProps, {\n day,\n selected: isSelected\n })\n }),\n dayProps = _objectWithoutPropertiesLoose(_useSlotProps, _excluded2);\n const isDisabled = React.useMemo(() => disabled || isDateDisabled(day), [disabled, isDateDisabled, day]);\n const outsideCurrentMonth = React.useMemo(() => utils.getMonth(day) !== currentMonthNumber, [utils, day, currentMonthNumber]);\n const isFirstVisibleCell = React.useMemo(() => {\n const startOfMonth = utils.startOfMonth(utils.setMonth(day, currentMonthNumber));\n if (!showDaysOutsideCurrentMonth) {\n return utils.isSameDay(day, startOfMonth);\n }\n return utils.isSameDay(day, utils.startOfWeek(startOfMonth));\n }, [currentMonthNumber, day, showDaysOutsideCurrentMonth, utils]);\n const isLastVisibleCell = React.useMemo(() => {\n const endOfMonth = utils.endOfMonth(utils.setMonth(day, currentMonthNumber));\n if (!showDaysOutsideCurrentMonth) {\n return utils.isSameDay(day, endOfMonth);\n }\n return utils.isSameDay(day, utils.endOfWeek(endOfMonth));\n }, [currentMonthNumber, day, showDaysOutsideCurrentMonth, utils]);\n return /*#__PURE__*/_jsx(Day, _extends({}, dayProps, {\n day: day,\n disabled: isDisabled,\n autoFocus: isViewFocused && isFocusableDay,\n today: isToday,\n outsideCurrentMonth: outsideCurrentMonth,\n isFirstVisibleCell: isFirstVisibleCell,\n isLastVisibleCell: isLastVisibleCell,\n selected: isSelected,\n tabIndex: isFocusableDay ? 0 : -1,\n \"aria-selected\": isSelected,\n \"aria-current\": isToday ? 'date' : undefined\n }));\n}\n\n/**\n * @ignore - do not document.\n */\nexport function DayCalendar(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiDayCalendar'\n });\n const utils = useUtils();\n const {\n onFocusedDayChange,\n className,\n currentMonth,\n selectedDays,\n focusedDay,\n loading,\n onSelectedDaysChange,\n onMonthSwitchingAnimationEnd,\n readOnly,\n reduceAnimations,\n renderLoading = () => /*#__PURE__*/_jsx(\"span\", {\n children: \"...\"\n }),\n slideDirection,\n TransitionProps,\n disablePast,\n disableFuture,\n minDate,\n maxDate,\n shouldDisableDate,\n shouldDisableMonth,\n shouldDisableYear,\n dayOfWeekFormatter = date => utils.format(date, 'weekdayShort').charAt(0).toUpperCase(),\n hasFocus,\n onFocusedViewChange,\n gridLabelId,\n displayWeekNumber,\n fixedWeekNumber,\n autoFocus,\n timezone\n } = props;\n const now = useNow(timezone);\n const classes = useUtilityClasses(props);\n const isRtl = useRtl();\n const isDateDisabled = useIsDateDisabled({\n shouldDisableDate,\n shouldDisableMonth,\n shouldDisableYear,\n minDate,\n maxDate,\n disablePast,\n disableFuture,\n timezone\n });\n const translations = usePickersTranslations();\n const [internalHasFocus, setInternalHasFocus] = useControlled({\n name: 'DayCalendar',\n state: 'hasFocus',\n controlled: hasFocus,\n default: autoFocus ?? false\n });\n const [internalFocusedDay, setInternalFocusedDay] = React.useState(() => focusedDay || now);\n const handleDaySelect = useEventCallback(day => {\n if (readOnly) {\n return;\n }\n onSelectedDaysChange(day);\n });\n const focusDay = day => {\n if (!isDateDisabled(day)) {\n onFocusedDayChange(day);\n setInternalFocusedDay(day);\n onFocusedViewChange?.(true);\n setInternalHasFocus(true);\n }\n };\n const handleKeyDown = useEventCallback((event, day) => {\n switch (event.key) {\n case 'ArrowUp':\n focusDay(utils.addDays(day, -7));\n event.preventDefault();\n break;\n case 'ArrowDown':\n focusDay(utils.addDays(day, 7));\n event.preventDefault();\n break;\n case 'ArrowLeft':\n {\n const newFocusedDayDefault = utils.addDays(day, isRtl ? 1 : -1);\n const nextAvailableMonth = utils.addMonths(day, isRtl ? 1 : -1);\n const closestDayToFocus = findClosestEnabledDate({\n utils,\n date: newFocusedDayDefault,\n minDate: isRtl ? newFocusedDayDefault : utils.startOfMonth(nextAvailableMonth),\n maxDate: isRtl ? utils.endOfMonth(nextAvailableMonth) : newFocusedDayDefault,\n isDateDisabled,\n timezone\n });\n focusDay(closestDayToFocus || newFocusedDayDefault);\n event.preventDefault();\n break;\n }\n case 'ArrowRight':\n {\n const newFocusedDayDefault = utils.addDays(day, isRtl ? -1 : 1);\n const nextAvailableMonth = utils.addMonths(day, isRtl ? -1 : 1);\n const closestDayToFocus = findClosestEnabledDate({\n utils,\n date: newFocusedDayDefault,\n minDate: isRtl ? utils.startOfMonth(nextAvailableMonth) : newFocusedDayDefault,\n maxDate: isRtl ? newFocusedDayDefault : utils.endOfMonth(nextAvailableMonth),\n isDateDisabled,\n timezone\n });\n focusDay(closestDayToFocus || newFocusedDayDefault);\n event.preventDefault();\n break;\n }\n case 'Home':\n focusDay(utils.startOfWeek(day));\n event.preventDefault();\n break;\n case 'End':\n focusDay(utils.endOfWeek(day));\n event.preventDefault();\n break;\n case 'PageUp':\n focusDay(utils.addMonths(day, 1));\n event.preventDefault();\n break;\n case 'PageDown':\n focusDay(utils.addMonths(day, -1));\n event.preventDefault();\n break;\n default:\n break;\n }\n });\n const handleFocus = useEventCallback((event, day) => focusDay(day));\n const handleBlur = useEventCallback((event, day) => {\n if (internalHasFocus && utils.isSameDay(internalFocusedDay, day)) {\n onFocusedViewChange?.(false);\n }\n });\n const currentMonthNumber = utils.getMonth(currentMonth);\n const currentYearNumber = utils.getYear(currentMonth);\n const validSelectedDays = React.useMemo(() => selectedDays.filter(day => !!day).map(day => utils.startOfDay(day)), [utils, selectedDays]);\n\n // need a new ref whenever the `key` of the transition changes: https://reactcommunity.org/react-transition-group/transition/#Transition-prop-nodeRef.\n const transitionKey = `${currentYearNumber}-${currentMonthNumber}`;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n const slideNodeRef = React.useMemo(() => /*#__PURE__*/React.createRef(), [transitionKey]);\n const focusableDay = React.useMemo(() => {\n const startOfMonth = utils.startOfMonth(currentMonth);\n const endOfMonth = utils.endOfMonth(currentMonth);\n if (isDateDisabled(internalFocusedDay) || utils.isAfterDay(internalFocusedDay, endOfMonth) || utils.isBeforeDay(internalFocusedDay, startOfMonth)) {\n return findClosestEnabledDate({\n utils,\n date: internalFocusedDay,\n minDate: startOfMonth,\n maxDate: endOfMonth,\n disablePast,\n disableFuture,\n isDateDisabled,\n timezone\n });\n }\n return internalFocusedDay;\n }, [currentMonth, disableFuture, disablePast, internalFocusedDay, isDateDisabled, utils, timezone]);\n const weeksToDisplay = React.useMemo(() => {\n const toDisplay = utils.getWeekArray(currentMonth);\n let nextMonth = utils.addMonths(currentMonth, 1);\n while (fixedWeekNumber && toDisplay.length < fixedWeekNumber) {\n const additionalWeeks = utils.getWeekArray(nextMonth);\n const hasCommonWeek = utils.isSameDay(toDisplay[toDisplay.length - 1][0], additionalWeeks[0][0]);\n additionalWeeks.slice(hasCommonWeek ? 1 : 0).forEach(week => {\n if (toDisplay.length < fixedWeekNumber) {\n toDisplay.push(week);\n }\n });\n nextMonth = utils.addMonths(nextMonth, 1);\n }\n return toDisplay;\n }, [currentMonth, fixedWeekNumber, utils]);\n return /*#__PURE__*/_jsxs(PickersCalendarDayRoot, {\n role: \"grid\",\n \"aria-labelledby\": gridLabelId,\n className: classes.root,\n children: [/*#__PURE__*/_jsxs(PickersCalendarDayHeader, {\n role: \"row\",\n className: classes.header,\n children: [displayWeekNumber && /*#__PURE__*/_jsx(PickersCalendarWeekNumberLabel, {\n variant: \"caption\",\n role: \"columnheader\",\n \"aria-label\": translations.calendarWeekNumberHeaderLabel,\n className: classes.weekNumberLabel,\n children: translations.calendarWeekNumberHeaderText\n }), getWeekdays(utils, now).map((weekday, i) => /*#__PURE__*/_jsx(PickersCalendarWeekDayLabel, {\n variant: \"caption\",\n role: \"columnheader\",\n \"aria-label\": utils.format(weekday, 'weekday'),\n className: classes.weekDayLabel,\n children: dayOfWeekFormatter(weekday)\n }, i.toString()))]\n }), loading ? /*#__PURE__*/_jsx(PickersCalendarLoadingContainer, {\n className: classes.loadingContainer,\n children: renderLoading()\n }) : /*#__PURE__*/_jsx(PickersCalendarSlideTransition, _extends({\n transKey: transitionKey,\n onExited: onMonthSwitchingAnimationEnd,\n reduceAnimations: reduceAnimations,\n slideDirection: slideDirection,\n className: clsx(className, classes.slideTransition)\n }, TransitionProps, {\n nodeRef: slideNodeRef,\n children: /*#__PURE__*/_jsx(PickersCalendarWeekContainer, {\n ref: slideNodeRef,\n role: \"rowgroup\",\n className: classes.monthContainer,\n children: weeksToDisplay.map((week, index) => /*#__PURE__*/_jsxs(PickersCalendarWeek, {\n role: \"row\",\n className: classes.weekContainer\n // fix issue of announcing row 1 as row 2\n // caused by week day labels row\n ,\n \"aria-rowindex\": index + 1,\n children: [displayWeekNumber && /*#__PURE__*/_jsx(PickersCalendarWeekNumber, {\n className: classes.weekNumber,\n role: \"rowheader\",\n \"aria-label\": translations.calendarWeekNumberAriaLabelText(utils.getWeekNumber(week[0])),\n children: translations.calendarWeekNumberText(utils.getWeekNumber(week[0]))\n }), week.map((day, dayIndex) => /*#__PURE__*/_jsx(WrappedDay, {\n parentProps: props,\n day: day,\n selectedDays: validSelectedDays,\n focusableDay: focusableDay,\n onKeyDown: handleKeyDown,\n onFocus: handleFocus,\n onBlur: handleBlur,\n onDaySelect: handleDaySelect,\n isDateDisabled: isDateDisabled,\n currentMonthNumber: currentMonthNumber,\n isViewFocused: internalHasFocus\n // fix issue of announcing column 1 as column 2 when `displayWeekNumber` is enabled\n ,\n \"aria-colindex\": dayIndex + 1\n }, day.toString()))]\n }, `week-${week[0]}`))\n })\n }))]\n });\n}","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getPickersMonthUtilityClass(slot) {\n return generateUtilityClass('MuiPickersMonth', slot);\n}\nexport const pickersMonthClasses = generateUtilityClasses('MuiPickersMonth', ['root', 'monthButton', 'disabled', 'selected']);","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"autoFocus\", \"className\", \"children\", \"disabled\", \"selected\", \"value\", \"tabIndex\", \"onClick\", \"onKeyDown\", \"onFocus\", \"onBlur\", \"aria-current\", \"aria-label\", \"monthsPerRow\", \"slots\", \"slotProps\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport { styled, alpha, useThemeProps } from '@mui/material/styles';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport composeClasses from '@mui/utils/composeClasses';\nimport useEnhancedEffect from '@mui/utils/useEnhancedEffect';\nimport { getPickersMonthUtilityClass, pickersMonthClasses } from \"./pickersMonthClasses.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n disabled,\n selected,\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n monthButton: ['monthButton', disabled && 'disabled', selected && 'selected']\n };\n return composeClasses(slots, getPickersMonthUtilityClass, classes);\n};\nconst PickersMonthRoot = styled('div', {\n name: 'MuiPickersMonth',\n slot: 'Root',\n overridesResolver: (_, styles) => [styles.root]\n})({\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n flexBasis: '33.3%',\n variants: [{\n props: {\n monthsPerRow: 4\n },\n style: {\n flexBasis: '25%'\n }\n }]\n});\nconst MonthCalendarButton = styled('button', {\n name: 'MuiPickersMonth',\n slot: 'MonthButton',\n overridesResolver: (_, styles) => [styles.monthButton, {\n [`&.${pickersMonthClasses.disabled}`]: styles.disabled\n }, {\n [`&.${pickersMonthClasses.selected}`]: styles.selected\n }]\n})(({\n theme\n}) => _extends({\n color: 'unset',\n backgroundColor: 'transparent',\n border: 0,\n outline: 0\n}, theme.typography.subtitle1, {\n margin: '8px 0',\n height: 36,\n width: 72,\n borderRadius: 18,\n cursor: 'pointer',\n '&:focus': {\n backgroundColor: theme.vars ? `rgba(${theme.vars.palette.action.activeChannel} / ${theme.vars.palette.action.hoverOpacity})` : alpha(theme.palette.action.active, theme.palette.action.hoverOpacity)\n },\n '&:hover': {\n backgroundColor: theme.vars ? `rgba(${theme.vars.palette.action.activeChannel} / ${theme.vars.palette.action.hoverOpacity})` : alpha(theme.palette.action.active, theme.palette.action.hoverOpacity)\n },\n '&:disabled': {\n cursor: 'auto',\n pointerEvents: 'none'\n },\n [`&.${pickersMonthClasses.disabled}`]: {\n color: (theme.vars || theme).palette.text.secondary\n },\n [`&.${pickersMonthClasses.selected}`]: {\n color: (theme.vars || theme).palette.primary.contrastText,\n backgroundColor: (theme.vars || theme).palette.primary.main,\n '&:focus, &:hover': {\n backgroundColor: (theme.vars || theme).palette.primary.dark\n }\n }\n}));\n\n/**\n * @ignore - do not document.\n */\nexport const PickersMonth = /*#__PURE__*/React.memo(function PickersMonth(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersMonth'\n });\n const {\n autoFocus,\n className,\n children,\n disabled,\n selected,\n value,\n tabIndex,\n onClick,\n onKeyDown,\n onFocus,\n onBlur,\n 'aria-current': ariaCurrent,\n 'aria-label': ariaLabel\n // We don't want to forward this prop to the root element\n ,\n\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const ref = React.useRef(null);\n const classes = useUtilityClasses(props);\n\n // We can't forward the `autoFocus` to the button because it is a native button, not a MUI Button\n useEnhancedEffect(() => {\n if (autoFocus) {\n // `ref.current` being `null` would be a bug in MUI.\n ref.current?.focus();\n }\n }, [autoFocus]);\n const MonthButton = slots?.monthButton ?? MonthCalendarButton;\n const monthButtonProps = useSlotProps({\n elementType: MonthButton,\n externalSlotProps: slotProps?.monthButton,\n additionalProps: {\n children,\n disabled,\n tabIndex,\n ref,\n type: 'button',\n role: 'radio',\n 'aria-current': ariaCurrent,\n 'aria-checked': selected,\n 'aria-label': ariaLabel,\n onClick: event => onClick(event, value),\n onKeyDown: event => onKeyDown(event, value),\n onFocus: event => onFocus(event, value),\n onBlur: event => onBlur(event, value)\n },\n ownerState: props,\n className: classes.monthButton\n });\n return /*#__PURE__*/_jsx(PickersMonthRoot, _extends({\n className: clsx(classes.root, className),\n ownerState: props\n }, other, {\n children: /*#__PURE__*/_jsx(MonthButton, _extends({}, monthButtonProps))\n }));\n});","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getMonthCalendarUtilityClass(slot) {\n return generateUtilityClass('MuiMonthCalendar', slot);\n}\nexport const monthCalendarClasses = generateUtilityClasses('MuiMonthCalendar', ['root']);","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"className\", \"value\", \"defaultValue\", \"referenceDate\", \"disabled\", \"disableFuture\", \"disablePast\", \"maxDate\", \"minDate\", \"onChange\", \"shouldDisableMonth\", \"readOnly\", \"disableHighlightToday\", \"autoFocus\", \"onMonthFocus\", \"hasFocus\", \"onFocusedViewChange\", \"monthsPerRow\", \"timezone\", \"gridLabelId\", \"slots\", \"slotProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { unstable_useControlled as useControlled, unstable_composeClasses as composeClasses, unstable_useEventCallback as useEventCallback } from '@mui/utils';\nimport { PickersMonth } from \"./PickersMonth.js\";\nimport { useUtils, useNow, useDefaultDates } from \"../internals/hooks/useUtils.js\";\nimport { getMonthCalendarUtilityClass } from \"./monthCalendarClasses.js\";\nimport { applyDefaultDate, getMonthsInYear } from \"../internals/utils/date-utils.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { SECTION_TYPE_GRANULARITY } from \"../internals/utils/getDefaultReferenceDate.js\";\nimport { useControlledValueWithTimezone } from \"../internals/hooks/useValueWithTimezone.js\";\nimport { DIALOG_WIDTH } from \"../internals/constants/dimensions.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, getMonthCalendarUtilityClass, classes);\n};\nexport function useMonthCalendarDefaultizedProps(props, name) {\n const utils = useUtils();\n const defaultDates = useDefaultDates();\n const themeProps = useThemeProps({\n props,\n name\n });\n return _extends({\n disableFuture: false,\n disablePast: false\n }, themeProps, {\n minDate: applyDefaultDate(utils, themeProps.minDate, defaultDates.minDate),\n maxDate: applyDefaultDate(utils, themeProps.maxDate, defaultDates.maxDate)\n });\n}\nconst MonthCalendarRoot = styled('div', {\n name: 'MuiMonthCalendar',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({\n display: 'flex',\n flexWrap: 'wrap',\n alignContent: 'stretch',\n padding: '0 4px',\n width: DIALOG_WIDTH,\n // avoid padding increasing width over defined\n boxSizing: 'border-box'\n});\n/**\n * Demos:\n *\n * - [DateCalendar](https://mui.com/x/react-date-pickers/date-calendar/)\n *\n * API:\n *\n * - [MonthCalendar API](https://mui.com/x/api/date-pickers/month-calendar/)\n */\nexport const MonthCalendar = /*#__PURE__*/React.forwardRef(function MonthCalendar(inProps, ref) {\n const props = useMonthCalendarDefaultizedProps(inProps, 'MuiMonthCalendar');\n const {\n className,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n disabled,\n disableFuture,\n disablePast,\n maxDate,\n minDate,\n onChange,\n shouldDisableMonth,\n readOnly,\n autoFocus = false,\n onMonthFocus,\n hasFocus,\n onFocusedViewChange,\n monthsPerRow = 3,\n timezone: timezoneProp,\n gridLabelId,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const {\n value,\n handleValueChange,\n timezone\n } = useControlledValueWithTimezone({\n name: 'MonthCalendar',\n timezone: timezoneProp,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n onChange,\n valueManager: singleItemValueManager\n });\n const now = useNow(timezone);\n const isRtl = useRtl();\n const utils = useUtils();\n const referenceDate = React.useMemo(() => singleItemValueManager.getInitialReferenceValue({\n value,\n utils,\n props,\n timezone,\n referenceDate: referenceDateProp,\n granularity: SECTION_TYPE_GRANULARITY.month\n }), [] // eslint-disable-line react-hooks/exhaustive-deps\n );\n const ownerState = props;\n const classes = useUtilityClasses(ownerState);\n const todayMonth = React.useMemo(() => utils.getMonth(now), [utils, now]);\n const selectedMonth = React.useMemo(() => {\n if (value != null) {\n return utils.getMonth(value);\n }\n return null;\n }, [value, utils]);\n const [focusedMonth, setFocusedMonth] = React.useState(() => selectedMonth || utils.getMonth(referenceDate));\n const [internalHasFocus, setInternalHasFocus] = useControlled({\n name: 'MonthCalendar',\n state: 'hasFocus',\n controlled: hasFocus,\n default: autoFocus ?? false\n });\n const changeHasFocus = useEventCallback(newHasFocus => {\n setInternalHasFocus(newHasFocus);\n if (onFocusedViewChange) {\n onFocusedViewChange(newHasFocus);\n }\n });\n const isMonthDisabled = React.useCallback(dateToValidate => {\n const firstEnabledMonth = utils.startOfMonth(disablePast && utils.isAfter(now, minDate) ? now : minDate);\n const lastEnabledMonth = utils.startOfMonth(disableFuture && utils.isBefore(now, maxDate) ? now : maxDate);\n const monthToValidate = utils.startOfMonth(dateToValidate);\n if (utils.isBefore(monthToValidate, firstEnabledMonth)) {\n return true;\n }\n if (utils.isAfter(monthToValidate, lastEnabledMonth)) {\n return true;\n }\n if (!shouldDisableMonth) {\n return false;\n }\n return shouldDisableMonth(monthToValidate);\n }, [disableFuture, disablePast, maxDate, minDate, now, shouldDisableMonth, utils]);\n const handleMonthSelection = useEventCallback((event, month) => {\n if (readOnly) {\n return;\n }\n const newDate = utils.setMonth(value ?? referenceDate, month);\n handleValueChange(newDate);\n });\n const focusMonth = useEventCallback(month => {\n if (!isMonthDisabled(utils.setMonth(value ?? referenceDate, month))) {\n setFocusedMonth(month);\n changeHasFocus(true);\n if (onMonthFocus) {\n onMonthFocus(month);\n }\n }\n });\n React.useEffect(() => {\n setFocusedMonth(prevFocusedMonth => selectedMonth !== null && prevFocusedMonth !== selectedMonth ? selectedMonth : prevFocusedMonth);\n }, [selectedMonth]);\n const handleKeyDown = useEventCallback((event, month) => {\n const monthsInYear = 12;\n const monthsInRow = 3;\n switch (event.key) {\n case 'ArrowUp':\n focusMonth((monthsInYear + month - monthsInRow) % monthsInYear);\n event.preventDefault();\n break;\n case 'ArrowDown':\n focusMonth((monthsInYear + month + monthsInRow) % monthsInYear);\n event.preventDefault();\n break;\n case 'ArrowLeft':\n focusMonth((monthsInYear + month + (isRtl ? 1 : -1)) % monthsInYear);\n event.preventDefault();\n break;\n case 'ArrowRight':\n focusMonth((monthsInYear + month + (isRtl ? -1 : 1)) % monthsInYear);\n event.preventDefault();\n break;\n default:\n break;\n }\n });\n const handleMonthFocus = useEventCallback((event, month) => {\n focusMonth(month);\n });\n const handleMonthBlur = useEventCallback((event, month) => {\n if (focusedMonth === month) {\n changeHasFocus(false);\n }\n });\n return /*#__PURE__*/_jsx(MonthCalendarRoot, _extends({\n ref: ref,\n className: clsx(classes.root, className),\n ownerState: ownerState,\n role: \"radiogroup\",\n \"aria-labelledby\": gridLabelId\n }, other, {\n children: getMonthsInYear(utils, value ?? referenceDate).map(month => {\n const monthNumber = utils.getMonth(month);\n const monthText = utils.format(month, 'monthShort');\n const monthLabel = utils.format(month, 'month');\n const isSelected = monthNumber === selectedMonth;\n const isDisabled = disabled || isMonthDisabled(month);\n return /*#__PURE__*/_jsx(PickersMonth, {\n selected: isSelected,\n value: monthNumber,\n onClick: handleMonthSelection,\n onKeyDown: handleKeyDown,\n autoFocus: internalHasFocus && monthNumber === focusedMonth,\n disabled: isDisabled,\n tabIndex: monthNumber === focusedMonth && !isDisabled ? 0 : -1,\n onFocus: handleMonthFocus,\n onBlur: handleMonthBlur,\n \"aria-current\": todayMonth === monthNumber ? 'date' : undefined,\n \"aria-label\": monthLabel,\n monthsPerRow: monthsPerRow,\n slots: slots,\n slotProps: slotProps,\n children: monthText\n }, monthText);\n })\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? MonthCalendar.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n autoFocus: PropTypes.bool,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n /**\n * The default selected value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true` picker is disabled\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n gridLabelId: PropTypes.string,\n hasFocus: PropTypes.bool,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Months rendered per row.\n * @default 3\n */\n monthsPerRow: PropTypes.oneOf([3, 4]),\n /**\n * Callback fired when the value changes.\n * @template TDate\n * @param {TDate} value The new value.\n */\n onChange: PropTypes.func,\n onFocusedViewChange: PropTypes.func,\n onMonthFocus: PropTypes.func,\n /**\n * If `true` picker is readonly\n */\n readOnly: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid month using the validation props, except callbacks such as `shouldDisableMonth`.\n */\n referenceDate: PropTypes.object,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object\n} : void 0;","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getPickersYearUtilityClass(slot) {\n return generateUtilityClass('MuiPickersYear', slot);\n}\nexport const pickersYearClasses = generateUtilityClasses('MuiPickersYear', ['root', 'yearButton', 'selected', 'disabled']);","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"autoFocus\", \"className\", \"children\", \"disabled\", \"selected\", \"value\", \"tabIndex\", \"onClick\", \"onKeyDown\", \"onFocus\", \"onBlur\", \"aria-current\", \"yearsPerRow\", \"slots\", \"slotProps\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport { styled, alpha, useThemeProps } from '@mui/material/styles';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport composeClasses from '@mui/utils/composeClasses';\nimport useEnhancedEffect from '@mui/utils/useEnhancedEffect';\nimport { getPickersYearUtilityClass, pickersYearClasses } from \"./pickersYearClasses.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n disabled,\n selected,\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n yearButton: ['yearButton', disabled && 'disabled', selected && 'selected']\n };\n return composeClasses(slots, getPickersYearUtilityClass, classes);\n};\nconst PickersYearRoot = styled('div', {\n name: 'MuiPickersYear',\n slot: 'Root',\n overridesResolver: (_, styles) => [styles.root]\n})({\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n flexBasis: '33.3%',\n variants: [{\n props: {\n yearsPerRow: 4\n },\n style: {\n flexBasis: '25%'\n }\n }]\n});\nconst YearCalendarButton = styled('button', {\n name: 'MuiPickersYear',\n slot: 'YearButton',\n overridesResolver: (_, styles) => [styles.yearButton, {\n [`&.${pickersYearClasses.disabled}`]: styles.disabled\n }, {\n [`&.${pickersYearClasses.selected}`]: styles.selected\n }]\n})(({\n theme\n}) => _extends({\n color: 'unset',\n backgroundColor: 'transparent',\n border: 0,\n outline: 0\n}, theme.typography.subtitle1, {\n margin: '6px 0',\n height: 36,\n width: 72,\n borderRadius: 18,\n cursor: 'pointer',\n '&:focus': {\n backgroundColor: theme.vars ? `rgba(${theme.vars.palette.action.activeChannel} / ${theme.vars.palette.action.focusOpacity})` : alpha(theme.palette.action.active, theme.palette.action.focusOpacity)\n },\n '&:hover': {\n backgroundColor: theme.vars ? `rgba(${theme.vars.palette.action.activeChannel} / ${theme.vars.palette.action.hoverOpacity})` : alpha(theme.palette.action.active, theme.palette.action.hoverOpacity)\n },\n '&:disabled': {\n cursor: 'auto',\n pointerEvents: 'none'\n },\n [`&.${pickersYearClasses.disabled}`]: {\n color: (theme.vars || theme).palette.text.secondary\n },\n [`&.${pickersYearClasses.selected}`]: {\n color: (theme.vars || theme).palette.primary.contrastText,\n backgroundColor: (theme.vars || theme).palette.primary.main,\n '&:focus, &:hover': {\n backgroundColor: (theme.vars || theme).palette.primary.dark\n }\n }\n}));\n\n/**\n * @ignore - internal component.\n */\nexport const PickersYear = /*#__PURE__*/React.memo(function PickersYear(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersYear'\n });\n const {\n autoFocus,\n className,\n children,\n disabled,\n selected,\n value,\n tabIndex,\n onClick,\n onKeyDown,\n onFocus,\n onBlur,\n 'aria-current': ariaCurrent\n // We don't want to forward this prop to the root element\n ,\n\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const ref = React.useRef(null);\n const classes = useUtilityClasses(props);\n\n // We can't forward the `autoFocus` to the button because it is a native button, not a MUI Button\n useEnhancedEffect(() => {\n if (autoFocus) {\n // `ref.current` being `null` would be a bug in MUI.\n ref.current?.focus();\n }\n }, [autoFocus]);\n const YearButton = slots?.yearButton ?? YearCalendarButton;\n const yearButtonProps = useSlotProps({\n elementType: YearButton,\n externalSlotProps: slotProps?.yearButton,\n additionalProps: {\n children,\n disabled,\n tabIndex,\n ref,\n type: 'button',\n role: 'radio',\n 'aria-current': ariaCurrent,\n 'aria-checked': selected,\n onClick: event => onClick(event, value),\n onKeyDown: event => onKeyDown(event, value),\n onFocus: event => onFocus(event, value),\n onBlur: event => onBlur(event, value)\n },\n ownerState: props,\n className: classes.yearButton\n });\n return /*#__PURE__*/_jsx(PickersYearRoot, _extends({\n className: clsx(classes.root, className),\n ownerState: props\n }, other, {\n children: /*#__PURE__*/_jsx(YearButton, _extends({}, yearButtonProps))\n }));\n});","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getYearCalendarUtilityClass(slot) {\n return generateUtilityClass('MuiYearCalendar', slot);\n}\nexport const yearCalendarClasses = generateUtilityClasses('MuiYearCalendar', ['root']);","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"autoFocus\", \"className\", \"value\", \"defaultValue\", \"referenceDate\", \"disabled\", \"disableFuture\", \"disablePast\", \"maxDate\", \"minDate\", \"onChange\", \"readOnly\", \"shouldDisableYear\", \"disableHighlightToday\", \"onYearFocus\", \"hasFocus\", \"onFocusedViewChange\", \"yearsOrder\", \"yearsPerRow\", \"timezone\", \"gridLabelId\", \"slots\", \"slotProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { unstable_useForkRef as useForkRef, unstable_composeClasses as composeClasses, unstable_useControlled as useControlled, unstable_useEventCallback as useEventCallback } from '@mui/utils';\nimport { PickersYear } from \"./PickersYear.js\";\nimport { useUtils, useNow, useDefaultDates } from \"../internals/hooks/useUtils.js\";\nimport { getYearCalendarUtilityClass } from \"./yearCalendarClasses.js\";\nimport { applyDefaultDate } from \"../internals/utils/date-utils.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { SECTION_TYPE_GRANULARITY } from \"../internals/utils/getDefaultReferenceDate.js\";\nimport { useControlledValueWithTimezone } from \"../internals/hooks/useValueWithTimezone.js\";\nimport { DIALOG_WIDTH, MAX_CALENDAR_HEIGHT } from \"../internals/constants/dimensions.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, getYearCalendarUtilityClass, classes);\n};\nfunction useYearCalendarDefaultizedProps(props, name) {\n const utils = useUtils();\n const defaultDates = useDefaultDates();\n const themeProps = useThemeProps({\n props,\n name\n });\n return _extends({\n disablePast: false,\n disableFuture: false\n }, themeProps, {\n yearsPerRow: themeProps.yearsPerRow ?? 3,\n minDate: applyDefaultDate(utils, themeProps.minDate, defaultDates.minDate),\n maxDate: applyDefaultDate(utils, themeProps.maxDate, defaultDates.maxDate)\n });\n}\nconst YearCalendarRoot = styled('div', {\n name: 'MuiYearCalendar',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({\n display: 'flex',\n flexDirection: 'row',\n flexWrap: 'wrap',\n overflowY: 'auto',\n height: '100%',\n padding: '0 4px',\n width: DIALOG_WIDTH,\n maxHeight: MAX_CALENDAR_HEIGHT,\n // avoid padding increasing width over defined\n boxSizing: 'border-box',\n position: 'relative'\n});\n/**\n * Demos:\n *\n * - [DateCalendar](https://mui.com/x/react-date-pickers/date-calendar/)\n *\n * API:\n *\n * - [YearCalendar API](https://mui.com/x/api/date-pickers/year-calendar/)\n */\nexport const YearCalendar = /*#__PURE__*/React.forwardRef(function YearCalendar(inProps, ref) {\n const props = useYearCalendarDefaultizedProps(inProps, 'MuiYearCalendar');\n const {\n autoFocus,\n className,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n disabled,\n disableFuture,\n disablePast,\n maxDate,\n minDate,\n onChange,\n readOnly,\n shouldDisableYear,\n onYearFocus,\n hasFocus,\n onFocusedViewChange,\n yearsOrder = 'asc',\n yearsPerRow,\n timezone: timezoneProp,\n gridLabelId,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const {\n value,\n handleValueChange,\n timezone\n } = useControlledValueWithTimezone({\n name: 'YearCalendar',\n timezone: timezoneProp,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n onChange,\n valueManager: singleItemValueManager\n });\n const now = useNow(timezone);\n const isRtl = useRtl();\n const utils = useUtils();\n const referenceDate = React.useMemo(() => singleItemValueManager.getInitialReferenceValue({\n value,\n utils,\n props,\n timezone,\n referenceDate: referenceDateProp,\n granularity: SECTION_TYPE_GRANULARITY.year\n }), [] // eslint-disable-line react-hooks/exhaustive-deps\n );\n const ownerState = props;\n const classes = useUtilityClasses(ownerState);\n const todayYear = React.useMemo(() => utils.getYear(now), [utils, now]);\n const selectedYear = React.useMemo(() => {\n if (value != null) {\n return utils.getYear(value);\n }\n return null;\n }, [value, utils]);\n const [focusedYear, setFocusedYear] = React.useState(() => selectedYear || utils.getYear(referenceDate));\n const [internalHasFocus, setInternalHasFocus] = useControlled({\n name: 'YearCalendar',\n state: 'hasFocus',\n controlled: hasFocus,\n default: autoFocus ?? false\n });\n const changeHasFocus = useEventCallback(newHasFocus => {\n setInternalHasFocus(newHasFocus);\n if (onFocusedViewChange) {\n onFocusedViewChange(newHasFocus);\n }\n });\n const isYearDisabled = React.useCallback(dateToValidate => {\n if (disablePast && utils.isBeforeYear(dateToValidate, now)) {\n return true;\n }\n if (disableFuture && utils.isAfterYear(dateToValidate, now)) {\n return true;\n }\n if (minDate && utils.isBeforeYear(dateToValidate, minDate)) {\n return true;\n }\n if (maxDate && utils.isAfterYear(dateToValidate, maxDate)) {\n return true;\n }\n if (!shouldDisableYear) {\n return false;\n }\n const yearToValidate = utils.startOfYear(dateToValidate);\n return shouldDisableYear(yearToValidate);\n }, [disableFuture, disablePast, maxDate, minDate, now, shouldDisableYear, utils]);\n const handleYearSelection = useEventCallback((event, year) => {\n if (readOnly) {\n return;\n }\n const newDate = utils.setYear(value ?? referenceDate, year);\n handleValueChange(newDate);\n });\n const focusYear = useEventCallback(year => {\n if (!isYearDisabled(utils.setYear(value ?? referenceDate, year))) {\n setFocusedYear(year);\n changeHasFocus(true);\n onYearFocus?.(year);\n }\n });\n React.useEffect(() => {\n setFocusedYear(prevFocusedYear => selectedYear !== null && prevFocusedYear !== selectedYear ? selectedYear : prevFocusedYear);\n }, [selectedYear]);\n const verticalDirection = yearsOrder !== 'desc' ? yearsPerRow * 1 : yearsPerRow * -1;\n const horizontalDirection = isRtl && yearsOrder === 'asc' || !isRtl && yearsOrder === 'desc' ? -1 : 1;\n const handleKeyDown = useEventCallback((event, year) => {\n switch (event.key) {\n case 'ArrowUp':\n focusYear(year - verticalDirection);\n event.preventDefault();\n break;\n case 'ArrowDown':\n focusYear(year + verticalDirection);\n event.preventDefault();\n break;\n case 'ArrowLeft':\n focusYear(year - horizontalDirection);\n event.preventDefault();\n break;\n case 'ArrowRight':\n focusYear(year + horizontalDirection);\n event.preventDefault();\n break;\n default:\n break;\n }\n });\n const handleYearFocus = useEventCallback((event, year) => {\n focusYear(year);\n });\n const handleYearBlur = useEventCallback((event, year) => {\n if (focusedYear === year) {\n changeHasFocus(false);\n }\n });\n const scrollerRef = React.useRef(null);\n const handleRef = useForkRef(ref, scrollerRef);\n React.useEffect(() => {\n if (autoFocus || scrollerRef.current === null) {\n return;\n }\n const tabbableButton = scrollerRef.current.querySelector('[tabindex=\"0\"]');\n if (!tabbableButton) {\n return;\n }\n\n // Taken from useScroll in x-data-grid, but vertically centered\n const offsetHeight = tabbableButton.offsetHeight;\n const offsetTop = tabbableButton.offsetTop;\n const clientHeight = scrollerRef.current.clientHeight;\n const scrollTop = scrollerRef.current.scrollTop;\n const elementBottom = offsetTop + offsetHeight;\n if (offsetHeight > clientHeight || offsetTop < scrollTop) {\n // Button already visible\n return;\n }\n scrollerRef.current.scrollTop = elementBottom - clientHeight / 2 - offsetHeight / 2;\n }, [autoFocus]);\n const yearRange = utils.getYearRange([minDate, maxDate]);\n if (yearsOrder === 'desc') {\n yearRange.reverse();\n }\n return /*#__PURE__*/_jsx(YearCalendarRoot, _extends({\n ref: handleRef,\n className: clsx(classes.root, className),\n ownerState: ownerState,\n role: \"radiogroup\",\n \"aria-labelledby\": gridLabelId\n }, other, {\n children: yearRange.map(year => {\n const yearNumber = utils.getYear(year);\n const isSelected = yearNumber === selectedYear;\n const isDisabled = disabled || isYearDisabled(year);\n return /*#__PURE__*/_jsx(PickersYear, {\n selected: isSelected,\n value: yearNumber,\n onClick: handleYearSelection,\n onKeyDown: handleKeyDown,\n autoFocus: internalHasFocus && yearNumber === focusedYear,\n disabled: isDisabled,\n tabIndex: yearNumber === focusedYear && !isDisabled ? 0 : -1,\n onFocus: handleYearFocus,\n onBlur: handleYearBlur,\n \"aria-current\": todayYear === yearNumber ? 'date' : undefined,\n yearsPerRow: yearsPerRow,\n slots: slots,\n slotProps: slotProps,\n children: utils.format(year, 'year')\n }, utils.format(year, 'year'));\n })\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? YearCalendar.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n autoFocus: PropTypes.bool,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n /**\n * The default selected value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true` picker is disabled\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n gridLabelId: PropTypes.string,\n hasFocus: PropTypes.bool,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Callback fired when the value changes.\n * @template TDate\n * @param {TDate} value The new value.\n */\n onChange: PropTypes.func,\n onFocusedViewChange: PropTypes.func,\n onYearFocus: PropTypes.func,\n /**\n * If `true` picker is readonly\n */\n readOnly: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid year using the validation props, except callbacks such as `shouldDisableYear`.\n */\n referenceDate: PropTypes.object,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * Years are displayed in ascending (chronological) order by default.\n * If `desc`, years are displayed in descending order.\n * @default 'asc'\n */\n yearsOrder: PropTypes.oneOf(['asc', 'desc']),\n /**\n * Years rendered per row.\n * @default 3\n */\n yearsPerRow: PropTypes.oneOf([3, 4])\n} : void 0;","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport const getPickersCalendarHeaderUtilityClass = slot => generateUtilityClass('MuiPickersCalendarHeader', slot);\nexport const pickersCalendarHeaderClasses = generateUtilityClasses('MuiPickersCalendarHeader', ['root', 'labelContainer', 'label', 'switchViewButton', 'switchViewIcon']);","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"slots\", \"slotProps\", \"currentMonth\", \"disabled\", \"disableFuture\", \"disablePast\", \"maxDate\", \"minDate\", \"onMonthChange\", \"onViewChange\", \"view\", \"reduceAnimations\", \"views\", \"labelId\", \"className\", \"timezone\", \"format\"],\n _excluded2 = [\"ownerState\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport Fade from '@mui/material/Fade';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport composeClasses from '@mui/utils/composeClasses';\nimport IconButton from '@mui/material/IconButton';\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { PickersFadeTransitionGroup } from \"../DateCalendar/PickersFadeTransitionGroup.js\";\nimport { ArrowDropDownIcon } from \"../icons/index.js\";\nimport { PickersArrowSwitcher } from \"../internals/components/PickersArrowSwitcher/index.js\";\nimport { usePreviousMonthDisabled, useNextMonthDisabled } from \"../internals/hooks/date-helpers-hooks.js\";\nimport { getPickersCalendarHeaderUtilityClass, pickersCalendarHeaderClasses } from \"./pickersCalendarHeaderClasses.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n labelContainer: ['labelContainer'],\n label: ['label'],\n switchViewButton: ['switchViewButton'],\n switchViewIcon: ['switchViewIcon']\n };\n return composeClasses(slots, getPickersCalendarHeaderUtilityClass, classes);\n};\nconst PickersCalendarHeaderRoot = styled('div', {\n name: 'MuiPickersCalendarHeader',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})({\n display: 'flex',\n alignItems: 'center',\n marginTop: 12,\n marginBottom: 4,\n paddingLeft: 24,\n paddingRight: 12,\n // prevent jumping in safari\n maxHeight: 40,\n minHeight: 40\n});\nconst PickersCalendarHeaderLabelContainer = styled('div', {\n name: 'MuiPickersCalendarHeader',\n slot: 'LabelContainer',\n overridesResolver: (_, styles) => styles.labelContainer\n})(({\n theme\n}) => _extends({\n display: 'flex',\n overflow: 'hidden',\n alignItems: 'center',\n cursor: 'pointer',\n marginRight: 'auto'\n}, theme.typography.body1, {\n fontWeight: theme.typography.fontWeightMedium\n}));\nconst PickersCalendarHeaderLabel = styled('div', {\n name: 'MuiPickersCalendarHeader',\n slot: 'Label',\n overridesResolver: (_, styles) => styles.label\n})({\n marginRight: 6\n});\nconst PickersCalendarHeaderSwitchViewButton = styled(IconButton, {\n name: 'MuiPickersCalendarHeader',\n slot: 'SwitchViewButton',\n overridesResolver: (_, styles) => styles.switchViewButton\n})({\n marginRight: 'auto',\n variants: [{\n props: {\n view: 'year'\n },\n style: {\n [`.${pickersCalendarHeaderClasses.switchViewIcon}`]: {\n transform: 'rotate(180deg)'\n }\n }\n }]\n});\nconst PickersCalendarHeaderSwitchViewIcon = styled(ArrowDropDownIcon, {\n name: 'MuiPickersCalendarHeader',\n slot: 'SwitchViewIcon',\n overridesResolver: (_, styles) => styles.switchViewIcon\n})(({\n theme\n}) => ({\n willChange: 'transform',\n transition: theme.transitions.create('transform'),\n transform: 'rotate(0deg)'\n}));\n/**\n * Demos:\n *\n * - [DateCalendar](https://mui.com/x/react-date-pickers/date-calendar/)\n * - [DateRangeCalendar](https://mui.com/x/react-date-pickers/date-range-calendar/)\n * - [Custom slots and subcomponents](https://mui.com/x/react-date-pickers/custom-components/)\n *\n * API:\n *\n * - [PickersCalendarHeader API](https://mui.com/x/api/date-pickers/pickers-calendar-header/)\n */\nconst PickersCalendarHeader = /*#__PURE__*/React.forwardRef(function PickersCalendarHeader(inProps, ref) {\n const translations = usePickersTranslations();\n const utils = useUtils();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersCalendarHeader'\n });\n const {\n slots,\n slotProps,\n currentMonth: month,\n disabled,\n disableFuture,\n disablePast,\n maxDate,\n minDate,\n onMonthChange,\n onViewChange,\n view,\n reduceAnimations,\n views,\n labelId,\n className,\n timezone,\n format = `${utils.formats.month} ${utils.formats.year}`\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const ownerState = props;\n const classes = useUtilityClasses(props);\n const SwitchViewButton = slots?.switchViewButton ?? PickersCalendarHeaderSwitchViewButton;\n const switchViewButtonProps = useSlotProps({\n elementType: SwitchViewButton,\n externalSlotProps: slotProps?.switchViewButton,\n additionalProps: {\n size: 'small',\n 'aria-label': translations.calendarViewSwitchingButtonAriaLabel(view)\n },\n ownerState,\n className: classes.switchViewButton\n });\n const SwitchViewIcon = slots?.switchViewIcon ?? PickersCalendarHeaderSwitchViewIcon;\n // The spread is here to avoid this bug mui/material-ui#34056\n const _useSlotProps = useSlotProps({\n elementType: SwitchViewIcon,\n externalSlotProps: slotProps?.switchViewIcon,\n ownerState,\n className: classes.switchViewIcon\n }),\n switchViewIconProps = _objectWithoutPropertiesLoose(_useSlotProps, _excluded2);\n const selectNextMonth = () => onMonthChange(utils.addMonths(month, 1), 'left');\n const selectPreviousMonth = () => onMonthChange(utils.addMonths(month, -1), 'right');\n const isNextMonthDisabled = useNextMonthDisabled(month, {\n disableFuture,\n maxDate,\n timezone\n });\n const isPreviousMonthDisabled = usePreviousMonthDisabled(month, {\n disablePast,\n minDate,\n timezone\n });\n const handleToggleView = () => {\n if (views.length === 1 || !onViewChange || disabled) {\n return;\n }\n if (views.length === 2) {\n onViewChange(views.find(el => el !== view) || views[0]);\n } else {\n // switching only between first 2\n const nextIndexToOpen = views.indexOf(view) !== 0 ? 0 : 1;\n onViewChange(views[nextIndexToOpen]);\n }\n };\n\n // No need to display more information\n if (views.length === 1 && views[0] === 'year') {\n return null;\n }\n const label = utils.formatByString(month, format);\n return /*#__PURE__*/_jsxs(PickersCalendarHeaderRoot, _extends({}, other, {\n ownerState: ownerState,\n className: clsx(classes.root, className),\n ref: ref,\n children: [/*#__PURE__*/_jsxs(PickersCalendarHeaderLabelContainer, {\n role: \"presentation\",\n onClick: handleToggleView,\n ownerState: ownerState\n // putting this on the label item element below breaks when using transition\n ,\n \"aria-live\": \"polite\",\n className: classes.labelContainer,\n children: [/*#__PURE__*/_jsx(PickersFadeTransitionGroup, {\n reduceAnimations: reduceAnimations,\n transKey: label,\n children: /*#__PURE__*/_jsx(PickersCalendarHeaderLabel, {\n id: labelId,\n ownerState: ownerState,\n className: classes.label,\n children: label\n })\n }), views.length > 1 && !disabled && /*#__PURE__*/_jsx(SwitchViewButton, _extends({}, switchViewButtonProps, {\n children: /*#__PURE__*/_jsx(SwitchViewIcon, _extends({}, switchViewIconProps))\n }))]\n }), /*#__PURE__*/_jsx(Fade, {\n in: view === 'day',\n children: /*#__PURE__*/_jsx(PickersArrowSwitcher, {\n slots: slots,\n slotProps: slotProps,\n onGoToPrevious: selectPreviousMonth,\n isPreviousDisabled: isPreviousMonthDisabled,\n previousLabel: translations.previousMonth,\n onGoToNext: selectNextMonth,\n isNextDisabled: isNextMonthDisabled,\n nextLabel: translations.nextMonth\n })\n })]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? PickersCalendarHeader.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n currentMonth: PropTypes.object.isRequired,\n disabled: PropTypes.bool,\n disableFuture: PropTypes.bool,\n disablePast: PropTypes.bool,\n /**\n * Format used to display the date.\n * @default `${adapter.formats.month} ${adapter.formats.year}`\n */\n format: PropTypes.string,\n /**\n * Id of the calendar text element.\n * It is used to establish an `aria-labelledby` relationship with the calendar `grid` element.\n */\n labelId: PropTypes.string,\n maxDate: PropTypes.object.isRequired,\n minDate: PropTypes.object.isRequired,\n onMonthChange: PropTypes.func.isRequired,\n onViewChange: PropTypes.func,\n reduceAnimations: PropTypes.bool.isRequired,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n timezone: PropTypes.string.isRequired,\n view: PropTypes.oneOf(['day', 'month', 'year']).isRequired,\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'month', 'year']).isRequired).isRequired\n} : void 0;\nexport { PickersCalendarHeader };","import useMediaQuery from '@mui/material/useMediaQuery';\nconst PREFERS_REDUCED_MOTION = '@media (prefers-reduced-motion: reduce)';\n\n// detect if user agent has Android version < 10 or iOS version < 13\nconst mobileVersionMatches = typeof navigator !== 'undefined' && navigator.userAgent.match(/android\\s(\\d+)|OS\\s(\\d+)/i);\nconst androidVersion = mobileVersionMatches && mobileVersionMatches[1] ? parseInt(mobileVersionMatches[1], 10) : null;\nconst iOSVersion = mobileVersionMatches && mobileVersionMatches[2] ? parseInt(mobileVersionMatches[2], 10) : null;\nexport const slowAnimationDevices = androidVersion && androidVersion < 10 || iOSVersion && iOSVersion < 13 || false;\nexport const useDefaultReduceAnimations = () => {\n const prefersReduced = useMediaQuery(PREFERS_REDUCED_MOTION, {\n defaultMatches: false\n });\n return prefersReduced || slowAnimationDevices;\n};","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport const getDateCalendarUtilityClass = slot => generateUtilityClass('MuiDateCalendar', slot);\nexport const dateCalendarClasses = generateUtilityClasses('MuiDateCalendar', ['root', 'viewTransitionContainer']);","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"autoFocus\", \"onViewChange\", \"value\", \"defaultValue\", \"referenceDate\", \"disableFuture\", \"disablePast\", \"onChange\", \"onYearChange\", \"onMonthChange\", \"reduceAnimations\", \"shouldDisableDate\", \"shouldDisableMonth\", \"shouldDisableYear\", \"view\", \"views\", \"openTo\", \"className\", \"disabled\", \"readOnly\", \"minDate\", \"maxDate\", \"disableHighlightToday\", \"focusedView\", \"onFocusedViewChange\", \"showDaysOutsideCurrentMonth\", \"fixedWeekNumber\", \"dayOfWeekFormatter\", \"slots\", \"slotProps\", \"loading\", \"renderLoading\", \"displayWeekNumber\", \"yearsOrder\", \"yearsPerRow\", \"monthsPerRow\", \"timezone\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { unstable_composeClasses as composeClasses, unstable_useId as useId, unstable_useEventCallback as useEventCallback } from '@mui/utils';\nimport { useCalendarState } from \"./useCalendarState.js\";\nimport { useDefaultDates, useUtils } from \"../internals/hooks/useUtils.js\";\nimport { PickersFadeTransitionGroup } from \"./PickersFadeTransitionGroup.js\";\nimport { DayCalendar } from \"./DayCalendar.js\";\nimport { MonthCalendar } from \"../MonthCalendar/index.js\";\nimport { YearCalendar } from \"../YearCalendar/index.js\";\nimport { useViews } from \"../internals/hooks/useViews.js\";\nimport { PickersCalendarHeader } from \"../PickersCalendarHeader/index.js\";\nimport { findClosestEnabledDate, applyDefaultDate, mergeDateAndTime } from \"../internals/utils/date-utils.js\";\nimport { PickerViewRoot } from \"../internals/components/PickerViewRoot/index.js\";\nimport { useDefaultReduceAnimations } from \"../internals/hooks/useDefaultReduceAnimations.js\";\nimport { getDateCalendarUtilityClass } from \"./dateCalendarClasses.js\";\nimport { useControlledValueWithTimezone } from \"../internals/hooks/useValueWithTimezone.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { VIEW_HEIGHT } from \"../internals/constants/dimensions.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n viewTransitionContainer: ['viewTransitionContainer']\n };\n return composeClasses(slots, getDateCalendarUtilityClass, classes);\n};\nfunction useDateCalendarDefaultizedProps(props, name) {\n const utils = useUtils();\n const defaultDates = useDefaultDates();\n const defaultReduceAnimations = useDefaultReduceAnimations();\n const themeProps = useThemeProps({\n props,\n name\n });\n return _extends({}, themeProps, {\n loading: themeProps.loading ?? false,\n disablePast: themeProps.disablePast ?? false,\n disableFuture: themeProps.disableFuture ?? false,\n openTo: themeProps.openTo ?? 'day',\n views: themeProps.views ?? ['year', 'day'],\n reduceAnimations: themeProps.reduceAnimations ?? defaultReduceAnimations,\n renderLoading: themeProps.renderLoading ?? (() => /*#__PURE__*/_jsx(\"span\", {\n children: \"...\"\n })),\n minDate: applyDefaultDate(utils, themeProps.minDate, defaultDates.minDate),\n maxDate: applyDefaultDate(utils, themeProps.maxDate, defaultDates.maxDate)\n });\n}\nconst DateCalendarRoot = styled(PickerViewRoot, {\n name: 'MuiDateCalendar',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({\n display: 'flex',\n flexDirection: 'column',\n height: VIEW_HEIGHT\n});\nconst DateCalendarViewTransitionContainer = styled(PickersFadeTransitionGroup, {\n name: 'MuiDateCalendar',\n slot: 'ViewTransitionContainer',\n overridesResolver: (props, styles) => styles.viewTransitionContainer\n})({});\n/**\n * Demos:\n *\n * - [DatePicker](https://mui.com/x/react-date-pickers/date-picker/)\n * - [DateCalendar](https://mui.com/x/react-date-pickers/date-calendar/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [DateCalendar API](https://mui.com/x/api/date-pickers/date-calendar/)\n */\nexport const DateCalendar = /*#__PURE__*/React.forwardRef(function DateCalendar(inProps, ref) {\n const utils = useUtils();\n const id = useId();\n const props = useDateCalendarDefaultizedProps(inProps, 'MuiDateCalendar');\n const {\n autoFocus,\n onViewChange,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n disableFuture,\n disablePast,\n onChange,\n onYearChange,\n onMonthChange,\n reduceAnimations,\n shouldDisableDate,\n shouldDisableMonth,\n shouldDisableYear,\n view: inView,\n views,\n openTo,\n className,\n disabled,\n readOnly,\n minDate,\n maxDate,\n disableHighlightToday,\n focusedView: inFocusedView,\n onFocusedViewChange,\n showDaysOutsideCurrentMonth,\n fixedWeekNumber,\n dayOfWeekFormatter,\n slots,\n slotProps,\n loading,\n renderLoading,\n displayWeekNumber,\n yearsOrder,\n yearsPerRow,\n monthsPerRow,\n timezone: timezoneProp\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const {\n value,\n handleValueChange,\n timezone\n } = useControlledValueWithTimezone({\n name: 'DateCalendar',\n timezone: timezoneProp,\n value: valueProp,\n defaultValue,\n referenceDate: referenceDateProp,\n onChange,\n valueManager: singleItemValueManager\n });\n const {\n view,\n setView,\n focusedView,\n setFocusedView,\n goToNextView,\n setValueAndGoToNextView\n } = useViews({\n view: inView,\n views,\n openTo,\n onChange: handleValueChange,\n onViewChange,\n autoFocus,\n focusedView: inFocusedView,\n onFocusedViewChange\n });\n const {\n referenceDate,\n calendarState,\n changeFocusedDay,\n changeMonth,\n handleChangeMonth,\n isDateDisabled,\n onMonthSwitchingAnimationEnd\n } = useCalendarState({\n value,\n referenceDate: referenceDateProp,\n reduceAnimations,\n onMonthChange,\n minDate,\n maxDate,\n shouldDisableDate,\n disablePast,\n disableFuture,\n timezone\n });\n\n // When disabled, limit the view to the selected date\n const minDateWithDisabled = disabled && value || minDate;\n const maxDateWithDisabled = disabled && value || maxDate;\n const gridLabelId = `${id}-grid-label`;\n const hasFocus = focusedView !== null;\n const CalendarHeader = slots?.calendarHeader ?? PickersCalendarHeader;\n const calendarHeaderProps = useSlotProps({\n elementType: CalendarHeader,\n externalSlotProps: slotProps?.calendarHeader,\n additionalProps: {\n views,\n view,\n currentMonth: calendarState.currentMonth,\n onViewChange: setView,\n onMonthChange: (newMonth, direction) => handleChangeMonth({\n newMonth,\n direction\n }),\n minDate: minDateWithDisabled,\n maxDate: maxDateWithDisabled,\n disabled,\n disablePast,\n disableFuture,\n reduceAnimations,\n timezone,\n labelId: gridLabelId\n },\n ownerState: props\n });\n const handleDateMonthChange = useEventCallback(newDate => {\n const startOfMonth = utils.startOfMonth(newDate);\n const endOfMonth = utils.endOfMonth(newDate);\n const closestEnabledDate = isDateDisabled(newDate) ? findClosestEnabledDate({\n utils,\n date: newDate,\n minDate: utils.isBefore(minDate, startOfMonth) ? startOfMonth : minDate,\n maxDate: utils.isAfter(maxDate, endOfMonth) ? endOfMonth : maxDate,\n disablePast,\n disableFuture,\n isDateDisabled,\n timezone\n }) : newDate;\n if (closestEnabledDate) {\n setValueAndGoToNextView(closestEnabledDate, 'finish');\n onMonthChange?.(startOfMonth);\n } else {\n goToNextView();\n changeMonth(startOfMonth);\n }\n changeFocusedDay(closestEnabledDate, true);\n });\n const handleDateYearChange = useEventCallback(newDate => {\n const startOfYear = utils.startOfYear(newDate);\n const endOfYear = utils.endOfYear(newDate);\n const closestEnabledDate = isDateDisabled(newDate) ? findClosestEnabledDate({\n utils,\n date: newDate,\n minDate: utils.isBefore(minDate, startOfYear) ? startOfYear : minDate,\n maxDate: utils.isAfter(maxDate, endOfYear) ? endOfYear : maxDate,\n disablePast,\n disableFuture,\n isDateDisabled,\n timezone\n }) : newDate;\n if (closestEnabledDate) {\n setValueAndGoToNextView(closestEnabledDate, 'finish');\n onYearChange?.(closestEnabledDate);\n } else {\n goToNextView();\n changeMonth(startOfYear);\n }\n changeFocusedDay(closestEnabledDate, true);\n });\n const handleSelectedDayChange = useEventCallback(day => {\n if (day) {\n // If there is a date already selected, then we want to keep its time\n return handleValueChange(mergeDateAndTime(utils, day, value ?? referenceDate), 'finish', view);\n }\n return handleValueChange(day, 'finish', view);\n });\n React.useEffect(() => {\n if (value != null && utils.isValid(value)) {\n changeMonth(value);\n }\n }, [value]); // eslint-disable-line\n\n const ownerState = props;\n const classes = useUtilityClasses(ownerState);\n const baseDateValidationProps = {\n disablePast,\n disableFuture,\n maxDate,\n minDate\n };\n const commonViewProps = {\n disableHighlightToday,\n readOnly,\n disabled,\n timezone,\n gridLabelId,\n slots,\n slotProps\n };\n const prevOpenViewRef = React.useRef(view);\n React.useEffect(() => {\n // If the view change and the focus was on the previous view\n // Then we update the focus.\n if (prevOpenViewRef.current === view) {\n return;\n }\n if (focusedView === prevOpenViewRef.current) {\n setFocusedView(view, true);\n }\n prevOpenViewRef.current = view;\n }, [focusedView, setFocusedView, view]);\n const selectedDays = React.useMemo(() => [value], [value]);\n return /*#__PURE__*/_jsxs(DateCalendarRoot, _extends({\n ref: ref,\n className: clsx(classes.root, className),\n ownerState: ownerState\n }, other, {\n children: [/*#__PURE__*/_jsx(CalendarHeader, _extends({}, calendarHeaderProps, {\n slots: slots,\n slotProps: slotProps\n })), /*#__PURE__*/_jsx(DateCalendarViewTransitionContainer, {\n reduceAnimations: reduceAnimations,\n className: classes.viewTransitionContainer,\n transKey: view,\n ownerState: ownerState,\n children: /*#__PURE__*/_jsxs(\"div\", {\n children: [view === 'year' && /*#__PURE__*/_jsx(YearCalendar, _extends({}, baseDateValidationProps, commonViewProps, {\n value: value,\n onChange: handleDateYearChange,\n shouldDisableYear: shouldDisableYear,\n hasFocus: hasFocus,\n onFocusedViewChange: isViewFocused => setFocusedView('year', isViewFocused),\n yearsOrder: yearsOrder,\n yearsPerRow: yearsPerRow,\n referenceDate: referenceDate\n })), view === 'month' && /*#__PURE__*/_jsx(MonthCalendar, _extends({}, baseDateValidationProps, commonViewProps, {\n hasFocus: hasFocus,\n className: className,\n value: value,\n onChange: handleDateMonthChange,\n shouldDisableMonth: shouldDisableMonth,\n onFocusedViewChange: isViewFocused => setFocusedView('month', isViewFocused),\n monthsPerRow: monthsPerRow,\n referenceDate: referenceDate\n })), view === 'day' && /*#__PURE__*/_jsx(DayCalendar, _extends({}, calendarState, baseDateValidationProps, commonViewProps, {\n onMonthSwitchingAnimationEnd: onMonthSwitchingAnimationEnd,\n onFocusedDayChange: changeFocusedDay,\n reduceAnimations: reduceAnimations,\n selectedDays: selectedDays,\n onSelectedDaysChange: handleSelectedDayChange,\n shouldDisableDate: shouldDisableDate,\n shouldDisableMonth: shouldDisableMonth,\n shouldDisableYear: shouldDisableYear,\n hasFocus: hasFocus,\n onFocusedViewChange: isViewFocused => setFocusedView('day', isViewFocused),\n showDaysOutsideCurrentMonth: showDaysOutsideCurrentMonth,\n fixedWeekNumber: fixedWeekNumber,\n dayOfWeekFormatter: dayOfWeekFormatter,\n displayWeekNumber: displayWeekNumber,\n loading: loading,\n renderLoading: renderLoading\n }))]\n })\n })]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? DateCalendar.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n /**\n * Formats the day of week displayed in the calendar header.\n * @param {TDate} date The date of the day of week provided by the adapter.\n * @returns {string} The name to display.\n * @default (date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()\n */\n dayOfWeekFormatter: PropTypes.func,\n /**\n * The default selected value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * If `true`, the week number will be display in the calendar.\n */\n displayWeekNumber: PropTypes.bool,\n /**\n * The day view will show as many weeks as needed after the end of the current month to match this value.\n * Put it to 6 to have a fixed number of weeks in Gregorian calendars\n */\n fixedWeekNumber: PropTypes.number,\n /**\n * Controlled focused view.\n */\n focusedView: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * If `true`, calls `renderLoading` instead of rendering the day calendar.\n * Can be used to preload information and show it in calendar.\n * @default false\n */\n loading: PropTypes.bool,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Months rendered per row.\n * @default 3\n */\n monthsPerRow: PropTypes.oneOf([3, 4]),\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TView The view type. Will be one of date or time views.\n * @param {TValue} value The new value.\n * @param {PickerSelectionState | undefined} selectionState Indicates if the date selection is complete.\n * @param {TView | undefined} selectedView Indicates the view in which the selection has been made.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired on focused view change.\n * @template TView\n * @param {TView} view The new view to focus or not.\n * @param {boolean} hasFocus `true` if the view should be focused.\n */\n onFocusedViewChange: PropTypes.func,\n /**\n * Callback fired on month change.\n * @template TDate\n * @param {TDate} month The new month.\n */\n onMonthChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Callback fired on year change.\n * @template TDate\n * @param {TDate} year The new year.\n */\n onYearChange: PropTypes.func,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * Make picker read only.\n * @default false\n */\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date using the validation props, except callbacks such as `shouldDisableDate`.\n */\n referenceDate: PropTypes.object,\n /**\n * Component displaying when passed `loading` true.\n * @returns {React.ReactNode} The node to render when loading.\n * @default () => ...\n */\n renderLoading: PropTypes.func,\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, days outside the current month are rendered:\n *\n * - if `fixedWeekNumber` is defined, renders days to have the weeks requested.\n *\n * - if `fixedWeekNumber` is not defined, renders day to fill the first and last week of the current month.\n *\n * - ignored if `calendars` equals more than `1` on range pickers.\n * @default false\n */\n showDaysOutsideCurrentMonth: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'month', 'year']).isRequired),\n /**\n * Years are displayed in ascending (chronological) order by default.\n * If `desc`, years are displayed in descending order.\n * @default 'asc'\n */\n yearsOrder: PropTypes.oneOf(['asc', 'desc']),\n /**\n * Years rendered per row.\n * @default 3\n */\n yearsPerRow: PropTypes.oneOf([3, 4])\n} : void 0;","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport const getDayCalendarSkeletonUtilityClass = slot => generateUtilityClass('MuiDayCalendarSkeleton', slot);\nexport const dayCalendarSkeletonClasses = generateUtilityClasses('MuiDayCalendarSkeleton', ['root', 'week', 'daySkeleton']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"className\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport Skeleton from '@mui/material/Skeleton';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { DAY_SIZE, DAY_MARGIN } from \"../internals/constants/dimensions.js\";\nimport { getDayCalendarSkeletonUtilityClass } from \"./dayCalendarSkeletonClasses.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n week: ['week'],\n daySkeleton: ['daySkeleton']\n };\n return composeClasses(slots, getDayCalendarSkeletonUtilityClass, classes);\n};\nconst DayCalendarSkeletonRoot = styled('div', {\n name: 'MuiDayCalendarSkeleton',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({\n alignSelf: 'start'\n});\nconst DayCalendarSkeletonWeek = styled('div', {\n name: 'MuiDayCalendarSkeleton',\n slot: 'Week',\n overridesResolver: (props, styles) => styles.week\n})({\n margin: `${DAY_MARGIN}px 0`,\n display: 'flex',\n justifyContent: 'center'\n});\nconst DayCalendarSkeletonDay = styled(Skeleton, {\n name: 'MuiDayCalendarSkeleton',\n slot: 'DaySkeleton',\n overridesResolver: (props, styles) => styles.daySkeleton\n})({\n margin: `0 ${DAY_MARGIN}px`,\n variants: [{\n props: {\n day: 0\n },\n style: {\n visibility: 'hidden'\n }\n }]\n});\nconst monthMap = [[0, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 0, 0, 0]];\n\n/**\n * Demos:\n *\n * - [DateCalendar](https://mui.com/x/react-date-pickers/date-calendar/)\n *\n * API:\n *\n * - [CalendarPickerSkeleton API](https://mui.com/x/api/date-pickers/calendar-picker-skeleton/)\n */\nfunction DayCalendarSkeleton(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiDayCalendarSkeleton'\n });\n const {\n className\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const classes = useUtilityClasses(other);\n return /*#__PURE__*/_jsx(DayCalendarSkeletonRoot, _extends({\n className: clsx(classes.root, className)\n }, other, {\n children: monthMap.map((week, index) => /*#__PURE__*/_jsx(DayCalendarSkeletonWeek, {\n className: classes.week,\n children: week.map((day, index2) => /*#__PURE__*/_jsx(DayCalendarSkeletonDay, {\n variant: \"circular\",\n width: DAY_SIZE,\n height: DAY_SIZE,\n className: classes.daySkeleton,\n ownerState: {\n day\n }\n }, index2))\n }, index))\n }));\n}\nprocess.env.NODE_ENV !== \"production\" ? DayCalendarSkeleton.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object])\n} : void 0;\nexport { DayCalendarSkeleton };","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getPickersToolbarUtilityClass(slot) {\n return generateUtilityClass('MuiPickersToolbar', slot);\n}\nexport const pickersToolbarClasses = generateUtilityClasses('MuiPickersToolbar', ['root', 'content']);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"toolbarTitle\", \"hidden\", \"titleId\", \"isLandscape\", \"classes\", \"landscapeDirection\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport Typography from '@mui/material/Typography';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { getPickersToolbarUtilityClass } from \"./pickersToolbarClasses.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n content: ['content']\n };\n return composeClasses(slots, getPickersToolbarUtilityClass, classes);\n};\nconst PickersToolbarRoot = styled('div', {\n name: 'MuiPickersToolbar',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})(({\n theme\n}) => ({\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'flex-start',\n justifyContent: 'space-between',\n padding: theme.spacing(2, 3),\n variants: [{\n props: {\n isLandscape: true\n },\n style: {\n height: 'auto',\n maxWidth: 160,\n padding: 16,\n justifyContent: 'flex-start',\n flexWrap: 'wrap'\n }\n }]\n}));\nconst PickersToolbarContent = styled('div', {\n name: 'MuiPickersToolbar',\n slot: 'Content',\n overridesResolver: (props, styles) => styles.content\n})({\n display: 'flex',\n flexWrap: 'wrap',\n width: '100%',\n flex: 1,\n justifyContent: 'space-between',\n alignItems: 'center',\n flexDirection: 'row',\n variants: [{\n props: {\n isLandscape: true\n },\n style: {\n justifyContent: 'flex-start',\n alignItems: 'flex-start',\n flexDirection: 'column'\n }\n }, {\n props: {\n isLandscape: true,\n landscapeDirection: 'row'\n },\n style: {\n flexDirection: 'row'\n }\n }]\n});\nexport const PickersToolbar = /*#__PURE__*/React.forwardRef(function PickersToolbar(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersToolbar'\n });\n const {\n children,\n className,\n toolbarTitle,\n hidden,\n titleId\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const ownerState = props;\n const classes = useUtilityClasses(ownerState);\n if (hidden) {\n return null;\n }\n return /*#__PURE__*/_jsxs(PickersToolbarRoot, _extends({\n ref: ref,\n className: clsx(classes.root, className),\n ownerState: ownerState\n }, other, {\n children: [/*#__PURE__*/_jsx(Typography, {\n color: \"text.secondary\",\n variant: \"overline\",\n id: titleId,\n children: toolbarTitle\n }), /*#__PURE__*/_jsx(PickersToolbarContent, {\n className: classes.content,\n ownerState: ownerState,\n children: children\n })]\n }));\n});","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getDatePickerToolbarUtilityClass(slot) {\n return generateUtilityClass('MuiDatePickerToolbar', slot);\n}\nexport const datePickerToolbarClasses = generateUtilityClasses('MuiDatePickerToolbar', ['root', 'title']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"value\", \"isLandscape\", \"onChange\", \"toolbarFormat\", \"toolbarPlaceholder\", \"views\", \"className\", \"onViewChange\", \"view\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport PropTypes from 'prop-types';\nimport Typography from '@mui/material/Typography';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { PickersToolbar } from \"../internals/components/PickersToolbar.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { getDatePickerToolbarUtilityClass } from \"./datePickerToolbarClasses.js\";\nimport { resolveDateFormat } from \"../internals/utils/date-utils.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n title: ['title']\n };\n return composeClasses(slots, getDatePickerToolbarUtilityClass, classes);\n};\nconst DatePickerToolbarRoot = styled(PickersToolbar, {\n name: 'MuiDatePickerToolbar',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})({});\nconst DatePickerToolbarTitle = styled(Typography, {\n name: 'MuiDatePickerToolbar',\n slot: 'Title',\n overridesResolver: (_, styles) => styles.title\n})({\n variants: [{\n props: {\n isLandscape: true\n },\n style: {\n margin: 'auto 16px auto auto'\n }\n }]\n});\n/**\n * Demos:\n *\n * - [DatePicker](https://mui.com/x/react-date-pickers/date-picker/)\n * - [Custom components](https://mui.com/x/react-date-pickers/custom-components/)\n *\n * API:\n *\n * - [DatePickerToolbar API](https://mui.com/x/api/date-pickers/date-picker-toolbar/)\n */\nexport const DatePickerToolbar = /*#__PURE__*/React.forwardRef(function DatePickerToolbar(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiDatePickerToolbar'\n });\n const {\n value,\n isLandscape,\n toolbarFormat,\n toolbarPlaceholder = '––',\n views,\n className\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const utils = useUtils();\n const translations = usePickersTranslations();\n const classes = useUtilityClasses(props);\n const dateText = React.useMemo(() => {\n if (!value) {\n return toolbarPlaceholder;\n }\n const formatFromViews = resolveDateFormat(utils, {\n format: toolbarFormat,\n views\n }, true);\n return utils.formatByString(value, formatFromViews);\n }, [value, toolbarFormat, toolbarPlaceholder, utils, views]);\n const ownerState = props;\n return /*#__PURE__*/_jsx(DatePickerToolbarRoot, _extends({\n ref: ref,\n toolbarTitle: translations.datePickerToolbarTitle,\n isLandscape: isLandscape,\n className: clsx(classes.root, className)\n }, other, {\n children: /*#__PURE__*/_jsx(DatePickerToolbarTitle, {\n variant: \"h4\",\n align: isLandscape ? 'left' : 'center',\n ownerState: ownerState,\n className: classes.title,\n children: dateText\n })\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? DatePickerToolbar.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n disabled: PropTypes.bool,\n /**\n * If `true`, show the toolbar even in desktop mode.\n * @default `true` for Desktop, `false` for Mobile.\n */\n hidden: PropTypes.bool,\n isLandscape: PropTypes.bool.isRequired,\n onChange: PropTypes.func.isRequired,\n /**\n * Callback called when a toolbar is clicked\n * @template TView\n * @param {TView} view The view to open\n */\n onViewChange: PropTypes.func.isRequired,\n readOnly: PropTypes.bool,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n titleId: PropTypes.string,\n /**\n * Toolbar date format.\n */\n toolbarFormat: PropTypes.string,\n /**\n * Toolbar value placeholder—it is displayed when the value is empty.\n * @default \"––\"\n */\n toolbarPlaceholder: PropTypes.node,\n value: PropTypes.object,\n /**\n * Currently visible picker view.\n */\n view: PropTypes.oneOf(['day', 'month', 'year']).isRequired,\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'month', 'year']).isRequired).isRequired\n} : void 0;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport { useThemeProps } from '@mui/material/styles';\nimport { useDefaultDates, useUtils } from \"../internals/hooks/useUtils.js\";\nimport { applyDefaultViewProps } from \"../internals/utils/views.js\";\nimport { applyDefaultDate } from \"../internals/utils/date-utils.js\";\nimport { DatePickerToolbar } from \"./DatePickerToolbar.js\";\nexport function useDatePickerDefaultizedProps(props, name) {\n const utils = useUtils();\n const defaultDates = useDefaultDates();\n const themeProps = useThemeProps({\n props,\n name\n });\n const localeText = React.useMemo(() => {\n if (themeProps.localeText?.toolbarTitle == null) {\n return themeProps.localeText;\n }\n return _extends({}, themeProps.localeText, {\n datePickerToolbarTitle: themeProps.localeText.toolbarTitle\n });\n }, [themeProps.localeText]);\n return _extends({}, themeProps, {\n localeText\n }, applyDefaultViewProps({\n views: themeProps.views,\n openTo: themeProps.openTo,\n defaultViews: ['year', 'day'],\n defaultOpenTo: 'day'\n }), {\n disableFuture: themeProps.disableFuture ?? false,\n disablePast: themeProps.disablePast ?? false,\n minDate: applyDefaultDate(utils, themeProps.minDate, defaultDates.minDate),\n maxDate: applyDefaultDate(utils, themeProps.maxDate, defaultDates.maxDate),\n slots: _extends({\n toolbar: DatePickerToolbar\n }, themeProps.slots)\n });\n}","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getPickersPopperUtilityClass(slot) {\n return generateUtilityClass('MuiPickersPopper', slot);\n}\nexport const pickersPopperClasses = generateUtilityClasses('MuiPickersPopper', ['root', 'paper']);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"PaperComponent\", \"popperPlacement\", \"ownerState\", \"children\", \"paperSlotProps\", \"paperClasses\", \"onPaperClick\", \"onPaperTouchStart\"];\nimport * as React from 'react';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport Grow from '@mui/material/Grow';\nimport Fade from '@mui/material/Fade';\nimport MuiPaper from '@mui/material/Paper';\nimport MuiPopper from '@mui/material/Popper';\nimport BaseFocusTrap from '@mui/material/Unstable_TrapFocus';\nimport { unstable_useForkRef as useForkRef, unstable_useEventCallback as useEventCallback, unstable_ownerDocument as ownerDocument, unstable_composeClasses as composeClasses } from '@mui/utils';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport { getPickersPopperUtilityClass } from \"./pickersPopperClasses.js\";\nimport { getActiveElement } from \"../utils/utils.js\";\nimport { useDefaultReduceAnimations } from \"../hooks/useDefaultReduceAnimations.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root'],\n paper: ['paper']\n };\n return composeClasses(slots, getPickersPopperUtilityClass, classes);\n};\nconst PickersPopperRoot = styled(MuiPopper, {\n name: 'MuiPickersPopper',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})(({\n theme\n}) => ({\n zIndex: theme.zIndex.modal\n}));\nconst PickersPopperPaper = styled(MuiPaper, {\n name: 'MuiPickersPopper',\n slot: 'Paper',\n overridesResolver: (_, styles) => styles.paper\n})({\n outline: 0,\n transformOrigin: 'top center',\n variants: [{\n props: ({\n placement\n }) => ['top', 'top-start', 'top-end'].includes(placement),\n style: {\n transformOrigin: 'bottom center'\n }\n }]\n});\nfunction clickedRootScrollbar(event, doc) {\n return doc.documentElement.clientWidth < event.clientX || doc.documentElement.clientHeight < event.clientY;\n}\n/**\n * Based on @mui/material/ClickAwayListener without the customization.\n * We can probably strip away even more since children won't be portaled.\n * @param {boolean} active Only listen to clicks when the popper is opened.\n * @param {(event: MouseEvent | TouchEvent) => void} onClickAway The callback to call when clicking outside the popper.\n * @returns {Array} The ref and event handler to listen to the outside clicks.\n */\nfunction useClickAwayListener(active, onClickAway) {\n const movedRef = React.useRef(false);\n const syntheticEventRef = React.useRef(false);\n const nodeRef = React.useRef(null);\n const activatedRef = React.useRef(false);\n React.useEffect(() => {\n if (!active) {\n return undefined;\n }\n\n // Ensure that this hook is not \"activated\" synchronously.\n // https://github.com/facebook/react/issues/20074\n function armClickAwayListener() {\n activatedRef.current = true;\n }\n document.addEventListener('mousedown', armClickAwayListener, true);\n document.addEventListener('touchstart', armClickAwayListener, true);\n return () => {\n document.removeEventListener('mousedown', armClickAwayListener, true);\n document.removeEventListener('touchstart', armClickAwayListener, true);\n activatedRef.current = false;\n };\n }, [active]);\n\n // The handler doesn't take event.defaultPrevented into account:\n //\n // event.preventDefault() is meant to stop default behaviors like\n // clicking a checkbox to check it, hitting a button to submit a form,\n // and hitting left arrow to move the cursor in a text input etc.\n // Only special HTML elements have these default behaviors.\n const handleClickAway = useEventCallback(event => {\n if (!activatedRef.current) {\n return;\n }\n\n // Given developers can stop the propagation of the synthetic event,\n // we can only be confident with a positive value.\n const insideReactTree = syntheticEventRef.current;\n syntheticEventRef.current = false;\n const doc = ownerDocument(nodeRef.current);\n\n // 1. IE11 support, which trigger the handleClickAway even after the unbind\n // 2. The child might render null.\n // 3. Behave like a blur listener.\n if (!nodeRef.current ||\n // is a TouchEvent?\n 'clientX' in event && clickedRootScrollbar(event, doc)) {\n return;\n }\n\n // Do not act if user performed touchmove\n if (movedRef.current) {\n movedRef.current = false;\n return;\n }\n let insideDOM;\n\n // If not enough, can use https://github.com/DieterHolvoet/event-propagation-path/blob/master/propagationPath.js\n if (event.composedPath) {\n insideDOM = event.composedPath().indexOf(nodeRef.current) > -1;\n } else {\n insideDOM = !doc.documentElement.contains(event.target) || nodeRef.current.contains(event.target);\n }\n if (!insideDOM && !insideReactTree) {\n onClickAway(event);\n }\n });\n\n // Keep track of mouse/touch events that bubbled up through the portal.\n const handleSynthetic = () => {\n syntheticEventRef.current = true;\n };\n React.useEffect(() => {\n if (active) {\n const doc = ownerDocument(nodeRef.current);\n const handleTouchMove = () => {\n movedRef.current = true;\n };\n doc.addEventListener('touchstart', handleClickAway);\n doc.addEventListener('touchmove', handleTouchMove);\n return () => {\n doc.removeEventListener('touchstart', handleClickAway);\n doc.removeEventListener('touchmove', handleTouchMove);\n };\n }\n return undefined;\n }, [active, handleClickAway]);\n React.useEffect(() => {\n // TODO This behavior is not tested automatically\n // It's unclear whether this is due to different update semantics in test (batched in act() vs discrete on click).\n // Or if this is a timing related issues due to different Transition components\n // Once we get rid of all the manual scheduling (for example setTimeout(update, 0)) we can revisit this code+test.\n if (active) {\n const doc = ownerDocument(nodeRef.current);\n doc.addEventListener('click', handleClickAway);\n return () => {\n doc.removeEventListener('click', handleClickAway);\n // cleanup `handleClickAway`\n syntheticEventRef.current = false;\n };\n }\n return undefined;\n }, [active, handleClickAway]);\n return [nodeRef, handleSynthetic, handleSynthetic];\n}\nconst PickersPopperPaperWrapper = /*#__PURE__*/React.forwardRef((props, ref) => {\n const {\n PaperComponent,\n popperPlacement,\n ownerState: inOwnerState,\n children,\n paperSlotProps,\n paperClasses,\n onPaperClick,\n onPaperTouchStart\n // picks up the style props provided by `Transition`\n // https://mui.com/material-ui/transitions/#child-requirement\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const ownerState = _extends({}, inOwnerState, {\n placement: popperPlacement\n });\n const paperProps = useSlotProps({\n elementType: PaperComponent,\n externalSlotProps: paperSlotProps,\n additionalProps: {\n tabIndex: -1,\n elevation: 8,\n ref\n },\n className: paperClasses,\n ownerState\n });\n return /*#__PURE__*/_jsx(PaperComponent, _extends({}, other, paperProps, {\n onClick: event => {\n onPaperClick(event);\n paperProps.onClick?.(event);\n },\n onTouchStart: event => {\n onPaperTouchStart(event);\n paperProps.onTouchStart?.(event);\n },\n ownerState: ownerState,\n children: children\n }));\n});\nexport function PickersPopper(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersPopper'\n });\n const {\n anchorEl,\n children,\n containerRef = null,\n shouldRestoreFocus,\n onBlur,\n onDismiss,\n open,\n role,\n placement,\n slots,\n slotProps,\n reduceAnimations: inReduceAnimations\n } = props;\n React.useEffect(() => {\n function handleKeyDown(nativeEvent) {\n if (open && nativeEvent.key === 'Escape') {\n onDismiss();\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [onDismiss, open]);\n const lastFocusedElementRef = React.useRef(null);\n React.useEffect(() => {\n if (role === 'tooltip' || shouldRestoreFocus && !shouldRestoreFocus()) {\n return;\n }\n if (open) {\n lastFocusedElementRef.current = getActiveElement(document);\n } else if (lastFocusedElementRef.current && lastFocusedElementRef.current instanceof HTMLElement) {\n // make sure the button is flushed with updated label, before returning focus to it\n // avoids issue, where screen reader could fail to announce selected date after selection\n setTimeout(() => {\n if (lastFocusedElementRef.current instanceof HTMLElement) {\n lastFocusedElementRef.current.focus();\n }\n });\n }\n }, [open, role, shouldRestoreFocus]);\n const [clickAwayRef, onPaperClick, onPaperTouchStart] = useClickAwayListener(open, onBlur ?? onDismiss);\n const paperRef = React.useRef(null);\n const handleRef = useForkRef(paperRef, containerRef);\n const handlePaperRef = useForkRef(handleRef, clickAwayRef);\n const ownerState = props;\n const classes = useUtilityClasses(ownerState);\n const defaultReduceAnimations = useDefaultReduceAnimations();\n const reduceAnimations = inReduceAnimations ?? defaultReduceAnimations;\n const handleKeyDown = event => {\n if (event.key === 'Escape') {\n // stop the propagation to avoid closing parent modal\n event.stopPropagation();\n onDismiss();\n }\n };\n const Transition = slots?.desktopTransition ?? reduceAnimations ? Fade : Grow;\n const FocusTrap = slots?.desktopTrapFocus ?? BaseFocusTrap;\n const Paper = slots?.desktopPaper ?? PickersPopperPaper;\n const Popper = slots?.popper ?? PickersPopperRoot;\n const popperProps = useSlotProps({\n elementType: Popper,\n externalSlotProps: slotProps?.popper,\n additionalProps: {\n transition: true,\n role,\n open,\n anchorEl,\n placement,\n onKeyDown: handleKeyDown\n },\n className: classes.root,\n ownerState: props\n });\n return /*#__PURE__*/_jsx(Popper, _extends({}, popperProps, {\n children: ({\n TransitionProps,\n placement: popperPlacement\n }) => /*#__PURE__*/_jsx(FocusTrap, _extends({\n open: open,\n disableAutoFocus: true\n // pickers are managing focus position manually\n // without this prop the focus is returned to the button before `aria-label` is updated\n // which would force screen readers to read too old label\n ,\n disableRestoreFocus: true,\n disableEnforceFocus: role === 'tooltip',\n isEnabled: () => true\n }, slotProps?.desktopTrapFocus, {\n children: /*#__PURE__*/_jsx(Transition, _extends({}, TransitionProps, slotProps?.desktopTransition, {\n children: /*#__PURE__*/_jsx(PickersPopperPaperWrapper, {\n PaperComponent: Paper,\n ownerState: ownerState,\n popperPlacement: popperPlacement,\n ref: handlePaperRef,\n onPaperClick: onPaperClick,\n onPaperTouchStart: onPaperTouchStart,\n paperClasses: classes.paper,\n paperSlotProps: slotProps?.desktopPaper,\n children: children\n })\n }))\n }))\n }));\n}","import * as React from 'react';\nexport const useOpenState = ({\n open,\n onOpen,\n onClose\n}) => {\n const isControllingOpenProp = React.useRef(typeof open === 'boolean').current;\n const [openState, setIsOpenState] = React.useState(false);\n\n // It is required to update inner state in useEffect in order to avoid situation when\n // Our component is not mounted yet, but `open` state is set to `true` (for example initially opened)\n React.useEffect(() => {\n if (isControllingOpenProp) {\n if (typeof open !== 'boolean') {\n throw new Error('You must not mix controlling and uncontrolled mode for `open` prop');\n }\n setIsOpenState(open);\n }\n }, [isControllingOpenProp, open]);\n const setIsOpen = React.useCallback(newIsOpen => {\n if (!isControllingOpenProp) {\n setIsOpenState(newIsOpen);\n }\n if (newIsOpen && onOpen) {\n onOpen();\n }\n if (!newIsOpen && onClose) {\n onClose();\n }\n }, [isControllingOpenProp, onOpen, onClose]);\n return {\n isOpen: openState,\n setIsOpen\n };\n};","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport { useOpenState } from \"../useOpenState.js\";\nimport { useLocalizationContext, useUtils } from \"../useUtils.js\";\nimport { useValidation } from \"../../../validation/index.js\";\nimport { useValueWithTimezone } from \"../useValueWithTimezone.js\";\n/**\n * Decide if the new value should be published\n * The published value will be passed to `onChange` if defined.\n */\nconst shouldPublishValue = params => {\n const {\n action,\n hasChanged,\n dateState,\n isControlled\n } = params;\n const isCurrentValueTheDefaultValue = !isControlled && !dateState.hasBeenModifiedSinceMount;\n\n // The field is responsible for only calling `onChange` when needed.\n if (action.name === 'setValueFromField') {\n return true;\n }\n if (action.name === 'setValueFromAction') {\n // If the component is not controlled, and the value has not been modified since the mount,\n // Then we want to publish the default value whenever the user pressed the \"Accept\", \"Today\" or \"Clear\" button.\n if (isCurrentValueTheDefaultValue && ['accept', 'today', 'clear'].includes(action.pickerAction)) {\n return true;\n }\n return hasChanged(dateState.lastPublishedValue);\n }\n if (action.name === 'setValueFromView' && action.selectionState !== 'shallow') {\n // On the first view,\n // If the value is not controlled, then clicking on any value (including the one equal to `defaultValue`) should call `onChange`\n if (isCurrentValueTheDefaultValue) {\n return true;\n }\n return hasChanged(dateState.lastPublishedValue);\n }\n if (action.name === 'setValueFromShortcut') {\n // On the first view,\n // If the value is not controlled, then clicking on any value (including the one equal to `defaultValue`) should call `onChange`\n if (isCurrentValueTheDefaultValue) {\n return true;\n }\n return hasChanged(dateState.lastPublishedValue);\n }\n return false;\n};\n\n/**\n * Decide if the new value should be committed.\n * The committed value will be passed to `onAccept` if defined.\n * It will also be used as a reset target when calling the `cancel` picker action (when clicking on the \"Cancel\" button).\n */\nconst shouldCommitValue = params => {\n const {\n action,\n hasChanged,\n dateState,\n isControlled,\n closeOnSelect\n } = params;\n const isCurrentValueTheDefaultValue = !isControlled && !dateState.hasBeenModifiedSinceMount;\n if (action.name === 'setValueFromAction') {\n // If the component is not controlled, and the value has not been modified since the mount,\n // Then we want to commit the default value whenever the user pressed the \"Accept\", \"Today\" or \"Clear\" button.\n if (isCurrentValueTheDefaultValue && ['accept', 'today', 'clear'].includes(action.pickerAction)) {\n return true;\n }\n return hasChanged(dateState.lastCommittedValue);\n }\n if (action.name === 'setValueFromView' && action.selectionState === 'finish' && closeOnSelect) {\n // On picker where the 1st view is also the last view,\n // If the value is not controlled, then clicking on any value (including the one equal to `defaultValue`) should call `onAccept`\n if (isCurrentValueTheDefaultValue) {\n return true;\n }\n return hasChanged(dateState.lastCommittedValue);\n }\n if (action.name === 'setValueFromShortcut') {\n return action.changeImportance === 'accept' && hasChanged(dateState.lastCommittedValue);\n }\n return false;\n};\n\n/**\n * Decide if the picker should be closed after the value is updated.\n */\nconst shouldClosePicker = params => {\n const {\n action,\n closeOnSelect\n } = params;\n if (action.name === 'setValueFromAction') {\n return true;\n }\n if (action.name === 'setValueFromView') {\n return action.selectionState === 'finish' && closeOnSelect;\n }\n if (action.name === 'setValueFromShortcut') {\n return action.changeImportance === 'accept';\n }\n return false;\n};\n\n/**\n * Manage the value lifecycle of all the pickers.\n */\nexport const usePickerValue = ({\n props,\n valueManager,\n valueType,\n wrapperVariant,\n validator\n}) => {\n const {\n onAccept,\n onChange,\n value: inValueWithoutRenderTimezone,\n defaultValue: inDefaultValue,\n closeOnSelect = wrapperVariant === 'desktop',\n timezone: timezoneProp,\n referenceDate\n } = props;\n const {\n current: defaultValue\n } = React.useRef(inDefaultValue);\n const {\n current: isControlled\n } = React.useRef(inValueWithoutRenderTimezone !== undefined);\n const [previousTimezoneProp, setPreviousTimezoneProp] = React.useState(timezoneProp);\n\n /* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (inValueWithoutRenderTimezone !== undefined)) {\n console.error([`MUI X: A component is changing the ${isControlled ? '' : 'un'}controlled value of a picker to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled value` + 'for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [inValueWithoutRenderTimezone]);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== inDefaultValue) {\n console.error([`MUI X: A component is changing the defaultValue of an uncontrolled picker after being initialized. ` + `To suppress this warning opt to use a controlled value.`].join('\\n'));\n }\n }, [JSON.stringify(defaultValue)]);\n }\n /* eslint-enable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\n\n const utils = useUtils();\n const adapter = useLocalizationContext();\n const {\n isOpen,\n setIsOpen\n } = useOpenState(props);\n const {\n timezone,\n value: inValueWithTimezoneToRender,\n handleValueChange\n } = useValueWithTimezone({\n timezone: timezoneProp,\n value: inValueWithoutRenderTimezone,\n defaultValue,\n referenceDate,\n onChange,\n valueManager\n });\n const [dateState, setDateState] = React.useState(() => {\n let initialValue;\n if (inValueWithTimezoneToRender !== undefined) {\n initialValue = inValueWithTimezoneToRender;\n } else if (defaultValue !== undefined) {\n initialValue = defaultValue;\n } else {\n initialValue = valueManager.emptyValue;\n }\n return {\n draft: initialValue,\n lastPublishedValue: initialValue,\n lastCommittedValue: initialValue,\n lastControlledValue: inValueWithoutRenderTimezone,\n hasBeenModifiedSinceMount: false\n };\n });\n const timezoneFromDraftValue = valueManager.getTimezone(utils, dateState.draft);\n if (previousTimezoneProp !== timezoneProp) {\n setPreviousTimezoneProp(timezoneProp);\n if (timezoneProp && timezoneFromDraftValue && timezoneProp !== timezoneFromDraftValue) {\n setDateState(prev => _extends({}, prev, {\n draft: valueManager.setTimezone(utils, timezoneProp, prev.draft)\n }));\n }\n }\n const {\n getValidationErrorForNewValue\n } = useValidation({\n props,\n validator,\n timezone,\n value: dateState.draft,\n onError: props.onError\n });\n const updateDate = useEventCallback(action => {\n const updaterParams = {\n action,\n dateState,\n hasChanged: comparison => !valueManager.areValuesEqual(utils, action.value, comparison),\n isControlled,\n closeOnSelect\n };\n const shouldPublish = shouldPublishValue(updaterParams);\n const shouldCommit = shouldCommitValue(updaterParams);\n const shouldClose = shouldClosePicker(updaterParams);\n setDateState(prev => _extends({}, prev, {\n draft: action.value,\n lastPublishedValue: shouldPublish ? action.value : prev.lastPublishedValue,\n lastCommittedValue: shouldCommit ? action.value : prev.lastCommittedValue,\n hasBeenModifiedSinceMount: true\n }));\n let cachedContext = null;\n const getContext = () => {\n if (!cachedContext) {\n const validationError = action.name === 'setValueFromField' ? action.context.validationError : getValidationErrorForNewValue(action.value);\n cachedContext = {\n validationError\n };\n if (action.name === 'setValueFromShortcut') {\n cachedContext.shortcut = action.shortcut;\n }\n }\n return cachedContext;\n };\n if (shouldPublish) {\n handleValueChange(action.value, getContext());\n }\n if (shouldCommit && onAccept) {\n onAccept(action.value, getContext());\n }\n if (shouldClose) {\n setIsOpen(false);\n }\n });\n if (dateState.lastControlledValue !== inValueWithoutRenderTimezone) {\n const isUpdateComingFromPicker = valueManager.areValuesEqual(utils, dateState.draft, inValueWithTimezoneToRender);\n setDateState(prev => _extends({}, prev, {\n lastControlledValue: inValueWithoutRenderTimezone\n }, isUpdateComingFromPicker ? {} : {\n lastCommittedValue: inValueWithTimezoneToRender,\n lastPublishedValue: inValueWithTimezoneToRender,\n draft: inValueWithTimezoneToRender,\n hasBeenModifiedSinceMount: true\n }));\n }\n const handleClear = useEventCallback(() => {\n updateDate({\n value: valueManager.emptyValue,\n name: 'setValueFromAction',\n pickerAction: 'clear'\n });\n });\n const handleAccept = useEventCallback(() => {\n updateDate({\n value: dateState.lastPublishedValue,\n name: 'setValueFromAction',\n pickerAction: 'accept'\n });\n });\n const handleDismiss = useEventCallback(() => {\n updateDate({\n value: dateState.lastPublishedValue,\n name: 'setValueFromAction',\n pickerAction: 'dismiss'\n });\n });\n const handleCancel = useEventCallback(() => {\n updateDate({\n value: dateState.lastCommittedValue,\n name: 'setValueFromAction',\n pickerAction: 'cancel'\n });\n });\n const handleSetToday = useEventCallback(() => {\n updateDate({\n value: valueManager.getTodayValue(utils, timezone, valueType),\n name: 'setValueFromAction',\n pickerAction: 'today'\n });\n });\n const handleOpen = useEventCallback(event => {\n event.preventDefault();\n setIsOpen(true);\n });\n const handleClose = useEventCallback(event => {\n event?.preventDefault();\n setIsOpen(false);\n });\n const handleChange = useEventCallback((newValue, selectionState = 'partial') => updateDate({\n name: 'setValueFromView',\n value: newValue,\n selectionState\n }));\n const handleSelectShortcut = useEventCallback((newValue, changeImportance, shortcut) => updateDate({\n name: 'setValueFromShortcut',\n value: newValue,\n changeImportance,\n shortcut\n }));\n const handleChangeFromField = useEventCallback((newValue, context) => updateDate({\n name: 'setValueFromField',\n value: newValue,\n context\n }));\n const actions = {\n onClear: handleClear,\n onAccept: handleAccept,\n onDismiss: handleDismiss,\n onCancel: handleCancel,\n onSetToday: handleSetToday,\n onOpen: handleOpen,\n onClose: handleClose\n };\n const fieldResponse = {\n value: dateState.draft,\n onChange: handleChangeFromField\n };\n const viewValue = React.useMemo(() => valueManager.cleanValue(utils, dateState.draft), [utils, valueManager, dateState.draft]);\n const viewResponse = {\n value: viewValue,\n onChange: handleChange,\n onClose: handleClose,\n open: isOpen\n };\n const isValid = testedValue => {\n const error = validator({\n adapter,\n value: testedValue,\n timezone,\n props\n });\n return !valueManager.hasError(error);\n };\n const layoutResponse = _extends({}, actions, {\n value: viewValue,\n onChange: handleChange,\n onSelectShortcut: handleSelectShortcut,\n isValid\n });\n const contextValue = React.useMemo(() => ({\n onOpen: handleOpen,\n onClose: handleClose,\n open: isOpen\n }), [isOpen, handleClose, handleOpen]);\n return {\n open: isOpen,\n fieldProps: fieldResponse,\n viewProps: viewResponse,\n layoutProps: layoutResponse,\n actions,\n contextValue\n };\n};","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"className\", \"sx\"];\nimport * as React from 'react';\nimport useEnhancedEffect from '@mui/utils/useEnhancedEffect';\nimport useEventCallback from '@mui/utils/useEventCallback';\nimport { useViews } from \"../useViews.js\";\nimport { isTimeView } from \"../../utils/time-utils.js\";\n\n/**\n * Props used to handle the views that are common to all pickers.\n */\n\n/**\n * Props used to handle the views of the pickers.\n */\n\n/**\n * Props used to handle the value of the pickers.\n */\n\n/**\n * Manage the views of all the pickers:\n * - Handles the view switch\n * - Handles the switch between UI views and field views\n * - Handles the focus management when switching views\n */\nexport const usePickerViews = ({\n props,\n propsFromPickerValue,\n additionalViewProps,\n autoFocusView,\n rendererInterceptor,\n fieldRef\n}) => {\n const {\n onChange,\n open,\n onClose\n } = propsFromPickerValue;\n const {\n view: inView,\n views,\n openTo,\n onViewChange,\n viewRenderers,\n timezone\n } = props;\n const propsToForwardToView = _objectWithoutPropertiesLoose(props, _excluded);\n const {\n view,\n setView,\n defaultView,\n focusedView,\n setFocusedView,\n setValueAndGoToNextView\n } = useViews({\n view: inView,\n views,\n openTo,\n onChange,\n onViewChange,\n autoFocus: autoFocusView\n });\n const {\n hasUIView,\n viewModeLookup\n } = React.useMemo(() => views.reduce((acc, viewForReduce) => {\n let viewMode;\n if (viewRenderers[viewForReduce] != null) {\n viewMode = 'UI';\n } else {\n viewMode = 'field';\n }\n acc.viewModeLookup[viewForReduce] = viewMode;\n if (viewMode === 'UI') {\n acc.hasUIView = true;\n }\n return acc;\n }, {\n hasUIView: false,\n viewModeLookup: {}\n }), [viewRenderers, views]);\n const timeViewsCount = React.useMemo(() => views.reduce((acc, viewForReduce) => {\n if (viewRenderers[viewForReduce] != null && isTimeView(viewForReduce)) {\n return acc + 1;\n }\n return acc;\n }, 0), [viewRenderers, views]);\n const currentViewMode = viewModeLookup[view];\n const shouldRestoreFocus = useEventCallback(() => currentViewMode === 'UI');\n const [popperView, setPopperView] = React.useState(currentViewMode === 'UI' ? view : null);\n if (popperView !== view && viewModeLookup[view] === 'UI') {\n setPopperView(view);\n }\n useEnhancedEffect(() => {\n // Handle case of `DateTimePicker` without time renderers\n if (currentViewMode === 'field' && open) {\n onClose();\n setTimeout(() => {\n fieldRef?.current?.setSelectedSections(view);\n // focusing the input before the range selection is done\n // calling it outside of timeout results in an inconsistent behavior between Safari And Chrome\n fieldRef?.current?.focusField(view);\n });\n }\n }, [view]); // eslint-disable-line react-hooks/exhaustive-deps\n\n useEnhancedEffect(() => {\n if (!open) {\n return;\n }\n let newView = view;\n\n // If the current view is a field view, go to the last popper view\n if (currentViewMode === 'field' && popperView != null) {\n newView = popperView;\n }\n\n // If the current view is not the default view and both are UI views\n if (newView !== defaultView && viewModeLookup[newView] === 'UI' && viewModeLookup[defaultView] === 'UI') {\n newView = defaultView;\n }\n if (newView !== view) {\n setView(newView);\n }\n setFocusedView(newView, true);\n }, [open]); // eslint-disable-line react-hooks/exhaustive-deps\n\n const layoutProps = {\n views,\n view: popperView,\n onViewChange: setView\n };\n return {\n hasUIView,\n shouldRestoreFocus,\n layoutProps,\n renderCurrentView: () => {\n if (popperView == null) {\n return null;\n }\n const renderer = viewRenderers[popperView];\n if (renderer == null) {\n return null;\n }\n const rendererProps = _extends({}, propsToForwardToView, additionalViewProps, propsFromPickerValue, {\n views,\n timezone,\n onChange: setValueAndGoToNextView,\n view: popperView,\n onViewChange: setView,\n focusedView,\n onFocusedViewChange: setFocusedView,\n showViewSwitcher: timeViewsCount > 1,\n timeViewsCount\n });\n if (rendererInterceptor) {\n return rendererInterceptor(viewRenderers, popperView, rendererProps);\n }\n return renderer(rendererProps);\n }\n };\n};","import * as React from 'react';\nimport { unstable_useEnhancedEffect as useEnhancedEffect } from '@mui/utils';\nimport { arrayIncludes } from \"../utils/utils.js\";\nfunction getOrientation() {\n if (typeof window === 'undefined') {\n return 'portrait';\n }\n if (window.screen && window.screen.orientation && window.screen.orientation.angle) {\n return Math.abs(window.screen.orientation.angle) === 90 ? 'landscape' : 'portrait';\n }\n\n // Support IOS safari\n if (window.orientation) {\n return Math.abs(Number(window.orientation)) === 90 ? 'landscape' : 'portrait';\n }\n return 'portrait';\n}\nexport const useIsLandscape = (views, customOrientation) => {\n const [orientation, setOrientation] = React.useState(getOrientation);\n useEnhancedEffect(() => {\n const eventHandler = () => {\n setOrientation(getOrientation());\n };\n window.addEventListener('orientationchange', eventHandler);\n return () => {\n window.removeEventListener('orientationchange', eventHandler);\n };\n }, []);\n if (arrayIncludes(views, ['hours', 'minutes', 'seconds'])) {\n // could not display 13:34:44 in landscape mode\n return false;\n }\n const orientationToUse = customOrientation || orientation;\n return orientationToUse === 'landscape';\n};","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { useIsLandscape } from \"../useIsLandscape.js\";\n\n/**\n * Props used to create the layout of the views.\n * Those props are exposed on all the pickers.\n */\n\n/**\n * Prepare the props for the view layout (managed by `PickersLayout`)\n */\nexport const usePickerLayoutProps = ({\n props,\n propsFromPickerValue,\n propsFromPickerViews,\n wrapperVariant\n}) => {\n const {\n orientation\n } = props;\n const isLandscape = useIsLandscape(propsFromPickerViews.views, orientation);\n const isRtl = useRtl();\n const layoutProps = _extends({}, propsFromPickerViews, propsFromPickerValue, {\n isLandscape,\n isRtl,\n wrapperVariant,\n disabled: props.disabled,\n readOnly: props.readOnly\n });\n return {\n layoutProps\n };\n};","import * as React from 'react';\nexport function usePickerOwnerState(parameters) {\n const {\n props,\n pickerValueResponse\n } = parameters;\n return React.useMemo(() => ({\n value: pickerValueResponse.viewProps.value,\n open: pickerValueResponse.open,\n disabled: props.disabled ?? false,\n readOnly: props.readOnly ?? false\n }), [pickerValueResponse.viewProps.value, pickerValueResponse.open, props.disabled, props.readOnly]);\n}","import { warnOnce } from '@mui/x-internals/warning';\nimport { usePickerValue } from \"./usePickerValue.js\";\nimport { usePickerViews } from \"./usePickerViews.js\";\nimport { usePickerLayoutProps } from \"./usePickerLayoutProps.js\";\nimport { usePickerOwnerState } from \"./usePickerOwnerState.js\";\nexport const usePicker = ({\n props,\n valueManager,\n valueType,\n wrapperVariant,\n additionalViewProps,\n validator,\n autoFocusView,\n rendererInterceptor,\n fieldRef\n}) => {\n if (process.env.NODE_ENV !== 'production') {\n if (props.renderInput != null) {\n warnOnce(['MUI X: The `renderInput` prop has been removed in version 6.0 of the Date and Time Pickers.', 'You can replace it with the `textField` component slot in most cases.', 'For more information, please have a look at the migration guide (https://mui.com/x/migration/migration-pickers-v5/#input-renderer-required-in-v5).']);\n }\n }\n const pickerValueResponse = usePickerValue({\n props,\n valueManager,\n valueType,\n wrapperVariant,\n validator\n });\n const pickerViewsResponse = usePickerViews({\n props,\n additionalViewProps,\n autoFocusView,\n fieldRef,\n propsFromPickerValue: pickerValueResponse.viewProps,\n rendererInterceptor\n });\n const pickerLayoutResponse = usePickerLayoutProps({\n props,\n wrapperVariant,\n propsFromPickerValue: pickerValueResponse.layoutProps,\n propsFromPickerViews: pickerViewsResponse.layoutProps\n });\n const pickerOwnerState = usePickerOwnerState({\n props,\n pickerValueResponse\n });\n return {\n // Picker value\n open: pickerValueResponse.open,\n actions: pickerValueResponse.actions,\n fieldProps: pickerValueResponse.fieldProps,\n // Picker views\n renderCurrentView: pickerViewsResponse.renderCurrentView,\n hasUIView: pickerViewsResponse.hasUIView,\n shouldRestoreFocus: pickerViewsResponse.shouldRestoreFocus,\n // Picker layout\n layoutProps: pickerLayoutResponse.layoutProps,\n // Picker context\n contextValue: pickerValueResponse.contextValue,\n // Picker owner state\n ownerState: pickerOwnerState\n };\n};","import generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nexport function getPickersLayoutUtilityClass(slot) {\n return generateUtilityClass('MuiPickersLayout', slot);\n}\nexport const pickersLayoutClasses = generateUtilityClasses('MuiPickersLayout', ['root', 'landscape', 'contentWrapper', 'toolbar', 'actionBar', 'tabs', 'shortcuts']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"onAccept\", \"onClear\", \"onCancel\", \"onSetToday\", \"actions\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport Button from '@mui/material/Button';\nimport DialogActions from '@mui/material/DialogActions';\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\n/**\n * Demos:\n *\n * - [Custom slots and subcomponents](https://mui.com/x/react-date-pickers/custom-components/)\n * - [Custom layout](https://mui.com/x/react-date-pickers/custom-layout/)\n *\n * API:\n *\n * - [PickersActionBar API](https://mui.com/x/api/date-pickers/pickers-action-bar/)\n */\nfunction PickersActionBar(props) {\n const {\n onAccept,\n onClear,\n onCancel,\n onSetToday,\n actions\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const translations = usePickersTranslations();\n if (actions == null || actions.length === 0) {\n return null;\n }\n const buttons = actions?.map(actionType => {\n switch (actionType) {\n case 'clear':\n return /*#__PURE__*/_jsx(Button, {\n onClick: onClear,\n children: translations.clearButtonLabel\n }, actionType);\n case 'cancel':\n return /*#__PURE__*/_jsx(Button, {\n onClick: onCancel,\n children: translations.cancelButtonLabel\n }, actionType);\n case 'accept':\n return /*#__PURE__*/_jsx(Button, {\n onClick: onAccept,\n children: translations.okButtonLabel\n }, actionType);\n case 'today':\n return /*#__PURE__*/_jsx(Button, {\n onClick: onSetToday,\n children: translations.todayButtonLabel\n }, actionType);\n default:\n return null;\n }\n });\n return /*#__PURE__*/_jsx(DialogActions, _extends({}, other, {\n children: buttons\n }));\n}\nprocess.env.NODE_ENV !== \"production\" ? PickersActionBar.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Ordered array of actions to display.\n * If empty, does not display that action bar.\n * @default `['cancel', 'accept']` for mobile and `[]` for desktop\n */\n actions: PropTypes.arrayOf(PropTypes.oneOf(['accept', 'cancel', 'clear', 'today']).isRequired),\n /**\n * If `true`, the actions do not have additional margin.\n * @default false\n */\n disableSpacing: PropTypes.bool,\n onAccept: PropTypes.func.isRequired,\n onCancel: PropTypes.func.isRequired,\n onClear: PropTypes.func.isRequired,\n onSetToday: PropTypes.func.isRequired,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object])\n} : void 0;\nexport { PickersActionBar };","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"items\", \"changeImportance\", \"isLandscape\", \"onChange\", \"isValid\"],\n _excluded2 = [\"getValue\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport List from '@mui/material/List';\nimport ListItem from '@mui/material/ListItem';\nimport Chip from '@mui/material/Chip';\nimport { VIEW_HEIGHT } from \"../internals/constants/dimensions.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\n/**\n * Demos:\n *\n * - [Shortcuts](https://mui.com/x/react-date-pickers/shortcuts/)\n *\n * API:\n *\n * - [PickersShortcuts API](https://mui.com/x/api/date-pickers/pickers-shortcuts/)\n */\nfunction PickersShortcuts(props) {\n const {\n items,\n changeImportance = 'accept',\n onChange,\n isValid\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n if (items == null || items.length === 0) {\n return null;\n }\n const resolvedItems = items.map(_ref => {\n let {\n getValue\n } = _ref,\n item = _objectWithoutPropertiesLoose(_ref, _excluded2);\n const newValue = getValue({\n isValid\n });\n return _extends({}, item, {\n label: item.label,\n onClick: () => {\n onChange(newValue, changeImportance, item);\n },\n disabled: !isValid(newValue)\n });\n });\n return /*#__PURE__*/_jsx(List, _extends({\n dense: true,\n sx: [{\n maxHeight: VIEW_HEIGHT,\n maxWidth: 200,\n overflow: 'auto'\n }, ...(Array.isArray(other.sx) ? other.sx : [other.sx])]\n }, other, {\n children: resolvedItems.map(item => {\n return /*#__PURE__*/_jsx(ListItem, {\n children: /*#__PURE__*/_jsx(Chip, _extends({}, item))\n }, item.id ?? item.label);\n })\n }));\n}\nprocess.env.NODE_ENV !== \"production\" ? PickersShortcuts.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Importance of the change when picking a shortcut:\n * - \"accept\": fires `onChange`, fires `onAccept` and closes the picker.\n * - \"set\": fires `onChange` but do not fire `onAccept` and does not close the picker.\n * @default \"accept\"\n */\n changeImportance: PropTypes.oneOf(['accept', 'set']),\n className: PropTypes.string,\n component: PropTypes.elementType,\n /**\n * If `true`, compact vertical padding designed for keyboard and mouse input is used for\n * the list and list items.\n * The prop is available to descendant components as the `dense` context.\n * @default false\n */\n dense: PropTypes.bool,\n /**\n * If `true`, vertical padding is removed from the list.\n * @default false\n */\n disablePadding: PropTypes.bool,\n isLandscape: PropTypes.bool.isRequired,\n isValid: PropTypes.func.isRequired,\n /**\n * Ordered array of shortcuts to display.\n * If empty, does not display the shortcuts.\n * @default []\n */\n items: PropTypes.arrayOf(PropTypes.shape({\n getValue: PropTypes.func.isRequired,\n id: PropTypes.string,\n label: PropTypes.string.isRequired\n })),\n onChange: PropTypes.func.isRequired,\n style: PropTypes.object,\n /**\n * The content of the subheader, normally `ListSubheader`.\n */\n subheader: PropTypes.node,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object])\n} : void 0;\nexport { PickersShortcuts };","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { PickersActionBar } from \"../PickersActionBar/index.js\";\nimport { getPickersLayoutUtilityClass } from \"./pickersLayoutClasses.js\";\nimport { PickersShortcuts } from \"../PickersShortcuts/index.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction toolbarHasView(toolbarProps) {\n return toolbarProps.view !== null;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n isLandscape\n } = ownerState;\n const slots = {\n root: ['root', isLandscape && 'landscape'],\n contentWrapper: ['contentWrapper'],\n toolbar: ['toolbar'],\n actionBar: ['actionBar'],\n tabs: ['tabs'],\n landscape: ['landscape'],\n shortcuts: ['shortcuts']\n };\n return composeClasses(slots, getPickersLayoutUtilityClass, classes);\n};\nconst usePickerLayout = props => {\n const {\n wrapperVariant,\n onAccept,\n onClear,\n onCancel,\n onSetToday,\n view,\n views,\n onViewChange,\n value,\n onChange,\n onSelectShortcut,\n isValid,\n isLandscape,\n disabled,\n readOnly,\n children,\n slots,\n slotProps\n // TODO: Remove this \"as\" hack. It get introduced to mark `value` prop in PickersLayoutProps as not required.\n // The true type should be\n // - For pickers value: TDate | null\n // - For range pickers value: [TDate | null, TDate | null]\n } = props;\n const classes = useUtilityClasses(props);\n\n // Action bar\n const ActionBar = slots?.actionBar ?? PickersActionBar;\n const actionBarProps = useSlotProps({\n elementType: ActionBar,\n externalSlotProps: slotProps?.actionBar,\n additionalProps: {\n onAccept,\n onClear,\n onCancel,\n onSetToday,\n actions: wrapperVariant === 'desktop' ? [] : ['cancel', 'accept']\n },\n className: classes.actionBar,\n ownerState: _extends({}, props, {\n wrapperVariant\n })\n });\n const actionBar = /*#__PURE__*/_jsx(ActionBar, _extends({}, actionBarProps));\n\n // Toolbar\n const Toolbar = slots?.toolbar;\n const toolbarProps = useSlotProps({\n elementType: Toolbar,\n externalSlotProps: slotProps?.toolbar,\n additionalProps: {\n isLandscape,\n onChange,\n value,\n view,\n onViewChange,\n views,\n disabled,\n readOnly\n },\n className: classes.toolbar,\n ownerState: _extends({}, props, {\n wrapperVariant\n })\n });\n const toolbar = toolbarHasView(toolbarProps) && !!Toolbar ? /*#__PURE__*/_jsx(Toolbar, _extends({}, toolbarProps)) : null;\n\n // Content\n const content = children;\n\n // Tabs\n const Tabs = slots?.tabs;\n const tabs = view && Tabs ? /*#__PURE__*/_jsx(Tabs, _extends({\n view: view,\n onViewChange: onViewChange,\n className: classes.tabs\n }, slotProps?.tabs)) : null;\n\n // Shortcuts\n const Shortcuts = slots?.shortcuts ?? PickersShortcuts;\n const shortcutsProps = useSlotProps({\n elementType: Shortcuts,\n externalSlotProps: slotProps?.shortcuts,\n additionalProps: {\n isValid,\n isLandscape,\n onChange: onSelectShortcut\n },\n className: classes.shortcuts,\n ownerState: {\n isValid,\n isLandscape,\n onChange: onSelectShortcut,\n wrapperVariant\n }\n });\n const shortcuts = view && !!Shortcuts ? /*#__PURE__*/_jsx(Shortcuts, _extends({}, shortcutsProps)) : null;\n return {\n toolbar,\n content,\n tabs,\n actionBar,\n shortcuts\n };\n};\nexport default usePickerLayout;","'use client';\n\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { pickersLayoutClasses, getPickersLayoutUtilityClass } from \"./pickersLayoutClasses.js\";\nimport usePickerLayout from \"./usePickerLayout.js\";\nimport { jsxs as _jsxs, jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n isLandscape,\n classes\n } = ownerState;\n const slots = {\n root: ['root', isLandscape && 'landscape'],\n contentWrapper: ['contentWrapper']\n };\n return composeClasses(slots, getPickersLayoutUtilityClass, classes);\n};\nexport const PickersLayoutRoot = styled('div', {\n name: 'MuiPickersLayout',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({\n display: 'grid',\n gridAutoColumns: 'max-content auto max-content',\n gridAutoRows: 'max-content auto max-content',\n [`& .${pickersLayoutClasses.actionBar}`]: {\n gridColumn: '1 / 4',\n gridRow: 3\n },\n variants: [{\n props: {\n isLandscape: true\n },\n style: {\n [`& .${pickersLayoutClasses.toolbar}`]: {\n gridColumn: 1,\n gridRow: '2 / 3'\n },\n [`.${pickersLayoutClasses.shortcuts}`]: {\n gridColumn: '2 / 4',\n gridRow: 1\n }\n }\n }, {\n props: {\n isLandscape: true,\n isRtl: true\n },\n style: {\n [`& .${pickersLayoutClasses.toolbar}`]: {\n gridColumn: 3\n }\n }\n }, {\n props: {\n isLandscape: false\n },\n style: {\n [`& .${pickersLayoutClasses.toolbar}`]: {\n gridColumn: '2 / 4',\n gridRow: 1\n },\n [`& .${pickersLayoutClasses.shortcuts}`]: {\n gridColumn: 1,\n gridRow: '2 / 3'\n }\n }\n }, {\n props: {\n isLandscape: false,\n isRtl: true\n },\n style: {\n [`& .${pickersLayoutClasses.shortcuts}`]: {\n gridColumn: 3\n }\n }\n }]\n});\nexport const PickersLayoutContentWrapper = styled('div', {\n name: 'MuiPickersLayout',\n slot: 'ContentWrapper',\n overridesResolver: (props, styles) => styles.contentWrapper\n})({\n gridColumn: 2,\n gridRow: 2,\n display: 'flex',\n flexDirection: 'column'\n});\n/**\n * Demos:\n *\n * - [Custom layout](https://mui.com/x/react-date-pickers/custom-layout/)\n *\n * API:\n *\n * - [PickersLayout API](https://mui.com/x/api/date-pickers/pickers-layout/)\n */\nconst PickersLayout = /*#__PURE__*/React.forwardRef(function PickersLayout(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersLayout'\n });\n const {\n toolbar,\n content,\n tabs,\n actionBar,\n shortcuts\n } = usePickerLayout(props);\n const {\n sx,\n className,\n isLandscape,\n wrapperVariant\n } = props;\n const classes = useUtilityClasses(props);\n return /*#__PURE__*/_jsxs(PickersLayoutRoot, {\n ref: ref,\n sx: sx,\n className: clsx(classes.root, className),\n ownerState: props,\n children: [isLandscape ? shortcuts : toolbar, isLandscape ? toolbar : shortcuts, /*#__PURE__*/_jsx(PickersLayoutContentWrapper, {\n className: classes.contentWrapper,\n children: wrapperVariant === 'desktop' ? /*#__PURE__*/_jsxs(React.Fragment, {\n children: [content, tabs]\n }) : /*#__PURE__*/_jsxs(React.Fragment, {\n children: [tabs, content]\n })\n }), actionBar]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? PickersLayout.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n disabled: PropTypes.bool,\n isLandscape: PropTypes.bool.isRequired,\n /**\n * `true` if the application is in right-to-left direction.\n */\n isRtl: PropTypes.bool.isRequired,\n isValid: PropTypes.func.isRequired,\n onAccept: PropTypes.func.isRequired,\n onCancel: PropTypes.func.isRequired,\n onChange: PropTypes.func.isRequired,\n onClear: PropTypes.func.isRequired,\n onClose: PropTypes.func.isRequired,\n onDismiss: PropTypes.func.isRequired,\n onOpen: PropTypes.func.isRequired,\n onSelectShortcut: PropTypes.func.isRequired,\n onSetToday: PropTypes.func.isRequired,\n onViewChange: PropTypes.func.isRequired,\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n value: PropTypes.any,\n view: PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']),\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']).isRequired).isRequired,\n wrapperVariant: PropTypes.oneOf(['desktop', 'mobile'])\n} : void 0;\nexport { PickersLayout };","import * as React from 'react';\nimport { LocalizationProvider } from \"../../LocalizationProvider/index.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport const PickersContext = /*#__PURE__*/React.createContext(null);\n\n/**\n * Provides the context for the various parts of a picker component:\n * - contextValue: the context for the picker sub-components.\n * - localizationProvider: the translations passed through the props and through a parent LocalizationProvider.\n *\n * @ignore - do not document.\n */\nexport function PickersProvider(props) {\n const {\n contextValue,\n localeText,\n children\n } = props;\n return /*#__PURE__*/_jsx(PickersContext.Provider, {\n value: contextValue,\n children: /*#__PURE__*/_jsx(LocalizationProvider, {\n localeText: localeText,\n children: children\n })\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"props\", \"getOpenDialogAriaText\"],\n _excluded2 = [\"ownerState\"],\n _excluded3 = [\"ownerState\"];\nimport * as React from 'react';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport MuiInputAdornment from '@mui/material/InputAdornment';\nimport IconButton from '@mui/material/IconButton';\nimport useForkRef from '@mui/utils/useForkRef';\nimport useId from '@mui/utils/useId';\nimport { PickersPopper } from \"../../components/PickersPopper.js\";\nimport { usePicker } from \"../usePicker/index.js\";\nimport { PickersLayout } from \"../../../PickersLayout/index.js\";\nimport { PickersProvider } from \"../../components/PickersProvider.js\";\n\n/**\n * Hook managing all the single-date desktop pickers:\n * - DesktopDatePicker\n * - DesktopDateTimePicker\n * - DesktopTimePicker\n */\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nexport const useDesktopPicker = _ref => {\n let {\n props,\n getOpenDialogAriaText\n } = _ref,\n pickerParams = _objectWithoutPropertiesLoose(_ref, _excluded);\n const {\n slots,\n slotProps: innerSlotProps,\n className,\n sx,\n format,\n formatDensity,\n enableAccessibleFieldDOMStructure,\n selectedSections,\n onSelectedSectionsChange,\n timezone,\n name,\n label,\n inputRef,\n readOnly,\n disabled,\n autoFocus,\n localeText,\n reduceAnimations\n } = props;\n const containerRef = React.useRef(null);\n const fieldRef = React.useRef(null);\n const labelId = useId();\n const isToolbarHidden = innerSlotProps?.toolbar?.hidden ?? false;\n const {\n open,\n actions,\n hasUIView,\n layoutProps,\n renderCurrentView,\n shouldRestoreFocus,\n fieldProps: pickerFieldProps,\n contextValue,\n ownerState\n } = usePicker(_extends({}, pickerParams, {\n props,\n fieldRef,\n autoFocusView: true,\n additionalViewProps: {},\n wrapperVariant: 'desktop'\n }));\n const InputAdornment = slots.inputAdornment ?? MuiInputAdornment;\n const _useSlotProps = useSlotProps({\n elementType: InputAdornment,\n externalSlotProps: innerSlotProps?.inputAdornment,\n additionalProps: {\n position: 'end'\n },\n ownerState: props\n }),\n inputAdornmentProps = _objectWithoutPropertiesLoose(_useSlotProps, _excluded2);\n const OpenPickerButton = slots.openPickerButton ?? IconButton;\n const _useSlotProps2 = useSlotProps({\n elementType: OpenPickerButton,\n externalSlotProps: innerSlotProps?.openPickerButton,\n additionalProps: {\n disabled: disabled || readOnly,\n onClick: open ? actions.onClose : actions.onOpen,\n 'aria-label': getOpenDialogAriaText(pickerFieldProps.value),\n edge: inputAdornmentProps.position\n },\n ownerState: props\n }),\n openPickerButtonProps = _objectWithoutPropertiesLoose(_useSlotProps2, _excluded3);\n const OpenPickerIcon = slots.openPickerIcon;\n const openPickerIconProps = useSlotProps({\n elementType: OpenPickerIcon,\n externalSlotProps: innerSlotProps?.openPickerIcon,\n ownerState\n });\n const Field = slots.field;\n const fieldProps = useSlotProps({\n elementType: Field,\n externalSlotProps: innerSlotProps?.field,\n additionalProps: _extends({}, pickerFieldProps, isToolbarHidden && {\n id: labelId\n }, {\n readOnly,\n disabled,\n className,\n sx,\n format,\n formatDensity,\n enableAccessibleFieldDOMStructure,\n selectedSections,\n onSelectedSectionsChange,\n timezone,\n label,\n name,\n autoFocus: autoFocus && !props.open,\n focused: open ? true : undefined\n }, inputRef ? {\n inputRef\n } : {}),\n ownerState: props\n });\n\n // TODO: Move to `useSlotProps` when https://github.com/mui/material-ui/pull/35088 will be merged\n if (hasUIView) {\n fieldProps.InputProps = _extends({}, fieldProps.InputProps, {\n ref: containerRef\n }, !props.disableOpenPicker && {\n [`${inputAdornmentProps.position}Adornment`]: /*#__PURE__*/_jsx(InputAdornment, _extends({}, inputAdornmentProps, {\n children: /*#__PURE__*/_jsx(OpenPickerButton, _extends({}, openPickerButtonProps, {\n children: /*#__PURE__*/_jsx(OpenPickerIcon, _extends({}, openPickerIconProps))\n }))\n }))\n });\n }\n const slotsForField = _extends({\n textField: slots.textField,\n clearIcon: slots.clearIcon,\n clearButton: slots.clearButton\n }, fieldProps.slots);\n const Layout = slots.layout ?? PickersLayout;\n let labelledById = labelId;\n if (isToolbarHidden) {\n if (label) {\n labelledById = `${labelId}-label`;\n } else {\n labelledById = undefined;\n }\n }\n const slotProps = _extends({}, innerSlotProps, {\n toolbar: _extends({}, innerSlotProps?.toolbar, {\n titleId: labelId\n }),\n popper: _extends({\n 'aria-labelledby': labelledById\n }, innerSlotProps?.popper)\n });\n const handleFieldRef = useForkRef(fieldRef, fieldProps.unstableFieldRef);\n const renderPicker = () => /*#__PURE__*/_jsxs(PickersProvider, {\n contextValue: contextValue,\n localeText: localeText,\n children: [/*#__PURE__*/_jsx(Field, _extends({}, fieldProps, {\n slots: slotsForField,\n slotProps: slotProps,\n unstableFieldRef: handleFieldRef\n })), /*#__PURE__*/_jsx(PickersPopper, _extends({\n role: \"dialog\",\n placement: \"bottom-start\",\n anchorEl: containerRef.current\n }, actions, {\n open: open,\n slots: slots,\n slotProps: slotProps,\n shouldRestoreFocus: shouldRestoreFocus,\n reduceAnimations: reduceAnimations,\n children: /*#__PURE__*/_jsx(Layout, _extends({}, layoutProps, slotProps?.layout, {\n slots: slots,\n slotProps: slotProps,\n children: renderCurrentView()\n }))\n }))]\n });\n return {\n renderPicker\n };\n};","import * as React from 'react';\nimport { DateCalendar } from \"../DateCalendar/index.js\";\nimport { isDatePickerView } from \"../internals/utils/date-utils.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport const renderDateViewCalendar = ({\n view,\n onViewChange,\n views,\n focusedView,\n onFocusedViewChange,\n value,\n defaultValue,\n referenceDate,\n onChange,\n className,\n classes,\n disableFuture,\n disablePast,\n minDate,\n maxDate,\n shouldDisableDate,\n shouldDisableMonth,\n shouldDisableYear,\n reduceAnimations,\n onMonthChange,\n monthsPerRow,\n onYearChange,\n yearsOrder,\n yearsPerRow,\n slots,\n slotProps,\n loading,\n renderLoading,\n disableHighlightToday,\n readOnly,\n disabled,\n showDaysOutsideCurrentMonth,\n dayOfWeekFormatter,\n sx,\n autoFocus,\n fixedWeekNumber,\n displayWeekNumber,\n timezone\n}) => /*#__PURE__*/_jsx(DateCalendar, {\n view: view,\n onViewChange: onViewChange,\n views: views.filter(isDatePickerView),\n focusedView: focusedView && isDatePickerView(focusedView) ? focusedView : null,\n onFocusedViewChange: onFocusedViewChange,\n value: value,\n defaultValue: defaultValue,\n referenceDate: referenceDate,\n onChange: onChange,\n className: className,\n classes: classes,\n disableFuture: disableFuture,\n disablePast: disablePast,\n minDate: minDate,\n maxDate: maxDate,\n shouldDisableDate: shouldDisableDate,\n shouldDisableMonth: shouldDisableMonth,\n shouldDisableYear: shouldDisableYear,\n reduceAnimations: reduceAnimations,\n onMonthChange: onMonthChange,\n monthsPerRow: monthsPerRow,\n onYearChange: onYearChange,\n yearsOrder: yearsOrder,\n yearsPerRow: yearsPerRow,\n slots: slots,\n slotProps: slotProps,\n loading: loading,\n renderLoading: renderLoading,\n disableHighlightToday: disableHighlightToday,\n readOnly: readOnly,\n disabled: disabled,\n showDaysOutsideCurrentMonth: showDaysOutsideCurrentMonth,\n dayOfWeekFormatter: dayOfWeekFormatter,\n sx: sx,\n autoFocus: autoFocus,\n fixedWeekNumber: fixedWeekNumber,\n displayWeekNumber: displayWeekNumber,\n timezone: timezone\n});","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport resolveComponentProps from '@mui/utils/resolveComponentProps';\nimport { refType } from '@mui/utils';\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { useDatePickerDefaultizedProps } from \"../DatePicker/shared.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { validateDate, extractValidationProps } from \"../validation/index.js\";\nimport { useDesktopPicker } from \"../internals/hooks/useDesktopPicker/index.js\";\nimport { CalendarIcon } from \"../icons/index.js\";\nimport { DateField } from \"../DateField/index.js\";\nimport { renderDateViewCalendar } from \"../dateViewRenderers/index.js\";\nimport { resolveDateFormat } from \"../internals/utils/date-utils.js\";\nimport { buildGetOpenDialogAriaText } from \"../locales/utils/getPickersLocalization.js\";\n/**\n * Demos:\n *\n * - [DatePicker](https://mui.com/x/react-date-pickers/date-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [DesktopDatePicker API](https://mui.com/x/api/date-pickers/desktop-date-picker/)\n */\nconst DesktopDatePicker = /*#__PURE__*/React.forwardRef(function DesktopDatePicker(inProps, ref) {\n const translations = usePickersTranslations();\n const utils = useUtils();\n\n // Props with the default values common to all date pickers\n const defaultizedProps = useDatePickerDefaultizedProps(inProps, 'MuiDesktopDatePicker');\n const viewRenderers = _extends({\n day: renderDateViewCalendar,\n month: renderDateViewCalendar,\n year: renderDateViewCalendar\n }, defaultizedProps.viewRenderers);\n\n // Props with the default values specific to the desktop variant\n const props = _extends({}, defaultizedProps, {\n viewRenderers,\n format: resolveDateFormat(utils, defaultizedProps, false),\n yearsPerRow: defaultizedProps.yearsPerRow ?? 4,\n slots: _extends({\n openPickerIcon: CalendarIcon,\n field: DateField\n }, defaultizedProps.slots),\n slotProps: _extends({}, defaultizedProps.slotProps, {\n field: ownerState => _extends({}, resolveComponentProps(defaultizedProps.slotProps?.field, ownerState), extractValidationProps(defaultizedProps), {\n ref\n }),\n toolbar: _extends({\n hidden: true\n }, defaultizedProps.slotProps?.toolbar)\n })\n });\n const {\n renderPicker\n } = useDesktopPicker({\n props,\n valueManager: singleItemValueManager,\n valueType: 'date',\n getOpenDialogAriaText: buildGetOpenDialogAriaText({\n utils,\n formatKey: 'fullDate',\n contextTranslation: translations.openDatePickerDialogue,\n propsTranslation: props.localeText?.openDatePickerDialogue\n }),\n validator: validateDate\n });\n return renderPicker();\n});\nDesktopDatePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, the popover or modal will close after submitting the full date.\n * @default `true` for desktop, `false` for mobile (based on the chosen wrapper and `desktopModeMediaQuery` prop).\n */\n closeOnSelect: PropTypes.bool,\n /**\n * Formats the day of week displayed in the calendar header.\n * @param {TDate} date The date of the day of week provided by the adapter.\n * @returns {string} The name to display.\n * @default (date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()\n */\n dayOfWeekFormatter: PropTypes.func,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * If `true`, the open picker button will not be rendered (renders only the field).\n * @default false\n */\n disableOpenPicker: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * If `true`, the week number will be display in the calendar.\n */\n displayWeekNumber: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.any,\n /**\n * The day view will show as many weeks as needed after the end of the current month to match this value.\n * Put it to 6 to have a fixed number of weeks in Gregorian calendars\n */\n fixedWeekNumber: PropTypes.number,\n /**\n * Format of the date when rendered in the input(s).\n * Defaults to localized format based on the used `views`.\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * If `true`, calls `renderLoading` instead of rendering the day calendar.\n * Can be used to preload information and show it in calendar.\n * @default false\n */\n loading: PropTypes.bool,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Months rendered per row.\n * @default 3\n */\n monthsPerRow: PropTypes.oneOf([3, 4]),\n /**\n * Name attribute used by the `input` element in the Field.\n */\n name: PropTypes.string,\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be closed.\n * Use in controlled mode (see `open`).\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired on month change.\n * @template TDate\n * @param {TDate} month The new month.\n */\n onMonthChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be opened.\n * Use in controlled mode (see `open`).\n */\n onOpen: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Callback fired on year change.\n * @template TDate\n * @param {TDate} year The new year.\n */\n onYearChange: PropTypes.func,\n /**\n * Control the popup or dialog open state.\n * @default false\n */\n open: PropTypes.bool,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * Component displaying when passed `loading` true.\n * @returns {React.ReactNode} The node to render when loading.\n * @default () => ...\n */\n renderLoading: PropTypes.func,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, days outside the current month are rendered:\n *\n * - if `fixedWeekNumber` is defined, renders days to have the weeks requested.\n *\n * - if `fixedWeekNumber` is not defined, renders day to fill the first and last week of the current month.\n *\n * - ignored if `calendars` equals more than `1` on range pickers.\n * @default false\n */\n showDaysOutsideCurrentMonth: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n day: PropTypes.func,\n month: PropTypes.func,\n year: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'month', 'year']).isRequired),\n /**\n * Years are displayed in ascending (chronological) order by default.\n * If `desc`, years are displayed in descending order.\n * @default 'asc'\n */\n yearsOrder: PropTypes.oneOf(['asc', 'desc']),\n /**\n * Years rendered per row.\n * @default 4\n */\n yearsPerRow: PropTypes.oneOf([3, 4])\n};\nexport { DesktopDatePicker };","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport DialogContent from '@mui/material/DialogContent';\nimport Fade from '@mui/material/Fade';\nimport MuiDialog, { dialogClasses } from '@mui/material/Dialog';\nimport { styled } from '@mui/material/styles';\nimport { DIALOG_WIDTH } from \"../constants/dimensions.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PickersModalDialogRoot = styled(MuiDialog)({\n [`& .${dialogClasses.container}`]: {\n outline: 0\n },\n [`& .${dialogClasses.paper}`]: {\n outline: 0,\n minWidth: DIALOG_WIDTH\n }\n});\nconst PickersModalDialogContent = styled(DialogContent)({\n '&:first-of-type': {\n padding: 0\n }\n});\nexport function PickersModalDialog(props) {\n const {\n children,\n onDismiss,\n open,\n slots,\n slotProps\n } = props;\n const Dialog = slots?.dialog ?? PickersModalDialogRoot;\n const Transition = slots?.mobileTransition ?? Fade;\n return /*#__PURE__*/_jsx(Dialog, _extends({\n open: open,\n onClose: onDismiss\n }, slotProps?.dialog, {\n TransitionComponent: Transition,\n TransitionProps: slotProps?.mobileTransition,\n PaperComponent: slots?.mobilePaper,\n PaperProps: slotProps?.mobilePaper,\n children: /*#__PURE__*/_jsx(PickersModalDialogContent, {\n children: children\n })\n }));\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"props\", \"getOpenDialogAriaText\"];\nimport * as React from 'react';\nimport useSlotProps from '@mui/utils/useSlotProps';\nimport useForkRef from '@mui/utils/useForkRef';\nimport useId from '@mui/utils/useId';\nimport { PickersModalDialog } from \"../../components/PickersModalDialog.js\";\nimport { usePicker } from \"../usePicker/index.js\";\nimport { onSpaceOrEnter } from \"../../utils/utils.js\";\nimport { PickersLayout } from \"../../../PickersLayout/index.js\";\nimport { PickersProvider } from \"../../components/PickersProvider.js\";\n\n/**\n * Hook managing all the single-date mobile pickers:\n * - MobileDatePicker\n * - MobileDateTimePicker\n * - MobileTimePicker\n */\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nexport const useMobilePicker = _ref => {\n let {\n props,\n getOpenDialogAriaText\n } = _ref,\n pickerParams = _objectWithoutPropertiesLoose(_ref, _excluded);\n const {\n slots,\n slotProps: innerSlotProps,\n className,\n sx,\n format,\n formatDensity,\n enableAccessibleFieldDOMStructure,\n selectedSections,\n onSelectedSectionsChange,\n timezone,\n name,\n label,\n inputRef,\n readOnly,\n disabled,\n localeText\n } = props;\n const fieldRef = React.useRef(null);\n const labelId = useId();\n const isToolbarHidden = innerSlotProps?.toolbar?.hidden ?? false;\n const {\n open,\n actions,\n layoutProps,\n renderCurrentView,\n fieldProps: pickerFieldProps,\n contextValue\n } = usePicker(_extends({}, pickerParams, {\n props,\n fieldRef,\n autoFocusView: true,\n additionalViewProps: {},\n wrapperVariant: 'mobile'\n }));\n const Field = slots.field;\n const fieldProps = useSlotProps({\n elementType: Field,\n externalSlotProps: innerSlotProps?.field,\n additionalProps: _extends({}, pickerFieldProps, isToolbarHidden && {\n id: labelId\n }, !(disabled || readOnly) && {\n onClick: actions.onOpen,\n onKeyDown: onSpaceOrEnter(actions.onOpen)\n }, {\n readOnly: readOnly ?? true,\n disabled,\n className,\n sx,\n format,\n formatDensity,\n enableAccessibleFieldDOMStructure,\n selectedSections,\n onSelectedSectionsChange,\n timezone,\n label,\n name\n }, inputRef ? {\n inputRef\n } : {}),\n ownerState: props\n });\n\n // TODO: Move to `useSlotProps` when https://github.com/mui/material-ui/pull/35088 will be merged\n fieldProps.inputProps = _extends({}, fieldProps.inputProps, {\n 'aria-label': getOpenDialogAriaText(pickerFieldProps.value)\n });\n const slotsForField = _extends({\n textField: slots.textField\n }, fieldProps.slots);\n const Layout = slots.layout ?? PickersLayout;\n let labelledById = labelId;\n if (isToolbarHidden) {\n if (label) {\n labelledById = `${labelId}-label`;\n } else {\n labelledById = undefined;\n }\n }\n const slotProps = _extends({}, innerSlotProps, {\n toolbar: _extends({}, innerSlotProps?.toolbar, {\n titleId: labelId\n }),\n mobilePaper: _extends({\n 'aria-labelledby': labelledById\n }, innerSlotProps?.mobilePaper)\n });\n const handleFieldRef = useForkRef(fieldRef, fieldProps.unstableFieldRef);\n const renderPicker = () => /*#__PURE__*/_jsxs(PickersProvider, {\n contextValue: contextValue,\n localeText: localeText,\n children: [/*#__PURE__*/_jsx(Field, _extends({}, fieldProps, {\n slots: slotsForField,\n slotProps: slotProps,\n unstableFieldRef: handleFieldRef\n })), /*#__PURE__*/_jsx(PickersModalDialog, _extends({}, actions, {\n open: open,\n slots: slots,\n slotProps: slotProps,\n children: /*#__PURE__*/_jsx(Layout, _extends({}, layoutProps, slotProps?.layout, {\n slots: slots,\n slotProps: slotProps,\n children: renderCurrentView()\n }))\n }))]\n });\n return {\n renderPicker\n };\n};","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport resolveComponentProps from '@mui/utils/resolveComponentProps';\nimport { refType } from '@mui/utils';\nimport { useMobilePicker } from \"../internals/hooks/useMobilePicker/index.js\";\nimport { useDatePickerDefaultizedProps } from \"../DatePicker/shared.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { extractValidationProps, validateDate } from \"../validation/index.js\";\nimport { DateField } from \"../DateField/index.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { renderDateViewCalendar } from \"../dateViewRenderers/index.js\";\nimport { resolveDateFormat } from \"../internals/utils/date-utils.js\";\nimport { buildGetOpenDialogAriaText } from \"../locales/utils/getPickersLocalization.js\";\n/**\n * Demos:\n *\n * - [DatePicker](https://mui.com/x/react-date-pickers/date-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [MobileDatePicker API](https://mui.com/x/api/date-pickers/mobile-date-picker/)\n */\nconst MobileDatePicker = /*#__PURE__*/React.forwardRef(function MobileDatePicker(inProps, ref) {\n const translations = usePickersTranslations();\n const utils = useUtils();\n\n // Props with the default values common to all date pickers\n const defaultizedProps = useDatePickerDefaultizedProps(inProps, 'MuiMobileDatePicker');\n const viewRenderers = _extends({\n day: renderDateViewCalendar,\n month: renderDateViewCalendar,\n year: renderDateViewCalendar\n }, defaultizedProps.viewRenderers);\n\n // Props with the default values specific to the mobile variant\n const props = _extends({}, defaultizedProps, {\n viewRenderers,\n format: resolveDateFormat(utils, defaultizedProps, false),\n slots: _extends({\n field: DateField\n }, defaultizedProps.slots),\n slotProps: _extends({}, defaultizedProps.slotProps, {\n field: ownerState => _extends({}, resolveComponentProps(defaultizedProps.slotProps?.field, ownerState), extractValidationProps(defaultizedProps), {\n ref\n }),\n toolbar: _extends({\n hidden: false\n }, defaultizedProps.slotProps?.toolbar)\n })\n });\n const {\n renderPicker\n } = useMobilePicker({\n props,\n valueManager: singleItemValueManager,\n valueType: 'date',\n getOpenDialogAriaText: buildGetOpenDialogAriaText({\n utils,\n formatKey: 'fullDate',\n contextTranslation: translations.openDatePickerDialogue,\n propsTranslation: props.localeText?.openDatePickerDialogue\n }),\n validator: validateDate\n });\n return renderPicker();\n});\nMobileDatePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, the popover or modal will close after submitting the full date.\n * @default `true` for desktop, `false` for mobile (based on the chosen wrapper and `desktopModeMediaQuery` prop).\n */\n closeOnSelect: PropTypes.bool,\n /**\n * Formats the day of week displayed in the calendar header.\n * @param {TDate} date The date of the day of week provided by the adapter.\n * @returns {string} The name to display.\n * @default (date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()\n */\n dayOfWeekFormatter: PropTypes.func,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * If `true`, the open picker button will not be rendered (renders only the field).\n * @default false\n */\n disableOpenPicker: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * If `true`, the week number will be display in the calendar.\n */\n displayWeekNumber: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.any,\n /**\n * The day view will show as many weeks as needed after the end of the current month to match this value.\n * Put it to 6 to have a fixed number of weeks in Gregorian calendars\n */\n fixedWeekNumber: PropTypes.number,\n /**\n * Format of the date when rendered in the input(s).\n * Defaults to localized format based on the used `views`.\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * If `true`, calls `renderLoading` instead of rendering the day calendar.\n * Can be used to preload information and show it in calendar.\n * @default false\n */\n loading: PropTypes.bool,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Months rendered per row.\n * @default 3\n */\n monthsPerRow: PropTypes.oneOf([3, 4]),\n /**\n * Name attribute used by the `input` element in the Field.\n */\n name: PropTypes.string,\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be closed.\n * Use in controlled mode (see `open`).\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired on month change.\n * @template TDate\n * @param {TDate} month The new month.\n */\n onMonthChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be opened.\n * Use in controlled mode (see `open`).\n */\n onOpen: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Callback fired on year change.\n * @template TDate\n * @param {TDate} year The new year.\n */\n onYearChange: PropTypes.func,\n /**\n * Control the popup or dialog open state.\n * @default false\n */\n open: PropTypes.bool,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * Component displaying when passed `loading` true.\n * @returns {React.ReactNode} The node to render when loading.\n * @default () => ...\n */\n renderLoading: PropTypes.func,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, days outside the current month are rendered:\n *\n * - if `fixedWeekNumber` is defined, renders days to have the weeks requested.\n *\n * - if `fixedWeekNumber` is not defined, renders day to fill the first and last week of the current month.\n *\n * - ignored if `calendars` equals more than `1` on range pickers.\n * @default false\n */\n showDaysOutsideCurrentMonth: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n day: PropTypes.func,\n month: PropTypes.func,\n year: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'month', 'year']).isRequired),\n /**\n * Years are displayed in ascending (chronological) order by default.\n * If `desc`, years are displayed in descending order.\n * @default 'asc'\n */\n yearsOrder: PropTypes.oneOf(['asc', 'desc']),\n /**\n * Years rendered per row.\n * @default 3\n */\n yearsPerRow: PropTypes.oneOf([3, 4])\n};\nexport { MobileDatePicker };","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"desktopModeMediaQuery\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport useMediaQuery from '@mui/material/useMediaQuery';\nimport { useThemeProps } from '@mui/material/styles';\nimport { refType } from '@mui/utils';\nimport { DesktopDatePicker } from \"../DesktopDatePicker/index.js\";\nimport { MobileDatePicker } from \"../MobileDatePicker/index.js\";\nimport { DEFAULT_DESKTOP_MODE_MEDIA_QUERY } from \"../internals/utils/utils.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\n/**\n * Demos:\n *\n * - [DatePicker](https://mui.com/x/react-date-pickers/date-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [DatePicker API](https://mui.com/x/api/date-pickers/date-picker/)\n */\nconst DatePicker = /*#__PURE__*/React.forwardRef(function DatePicker(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiDatePicker'\n });\n const {\n desktopModeMediaQuery = DEFAULT_DESKTOP_MODE_MEDIA_QUERY\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // defaults to `true` in environments where `window.matchMedia` would not be available (i.e. test/jsdom)\n const isDesktop = useMediaQuery(desktopModeMediaQuery, {\n defaultMatches: true\n });\n if (isDesktop) {\n return /*#__PURE__*/_jsx(DesktopDatePicker, _extends({\n ref: ref\n }, other));\n }\n return /*#__PURE__*/_jsx(MobileDatePicker, _extends({\n ref: ref\n }, other));\n});\nprocess.env.NODE_ENV !== \"production\" ? DatePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, the popover or modal will close after submitting the full date.\n * @default `true` for desktop, `false` for mobile (based on the chosen wrapper and `desktopModeMediaQuery` prop).\n */\n closeOnSelect: PropTypes.bool,\n /**\n * Formats the day of week displayed in the calendar header.\n * @param {TDate} date The date of the day of week provided by the adapter.\n * @returns {string} The name to display.\n * @default (date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()\n */\n dayOfWeekFormatter: PropTypes.func,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * CSS media query when `Mobile` mode will be changed to `Desktop`.\n * @default '@media (pointer: fine)'\n * @example '@media (min-width: 720px)' or theme.breakpoints.up(\"sm\")\n */\n desktopModeMediaQuery: PropTypes.string,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * If `true`, the open picker button will not be rendered (renders only the field).\n * @default false\n */\n disableOpenPicker: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * If `true`, the week number will be display in the calendar.\n */\n displayWeekNumber: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.any,\n /**\n * The day view will show as many weeks as needed after the end of the current month to match this value.\n * Put it to 6 to have a fixed number of weeks in Gregorian calendars\n */\n fixedWeekNumber: PropTypes.number,\n /**\n * Format of the date when rendered in the input(s).\n * Defaults to localized format based on the used `views`.\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * If `true`, calls `renderLoading` instead of rendering the day calendar.\n * Can be used to preload information and show it in calendar.\n * @default false\n */\n loading: PropTypes.bool,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Months rendered per row.\n * @default 3\n */\n monthsPerRow: PropTypes.oneOf([3, 4]),\n /**\n * Name attribute used by the `input` element in the Field.\n */\n name: PropTypes.string,\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be closed.\n * Use in controlled mode (see `open`).\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired on month change.\n * @template TDate\n * @param {TDate} month The new month.\n */\n onMonthChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be opened.\n * Use in controlled mode (see `open`).\n */\n onOpen: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Callback fired on year change.\n * @template TDate\n * @param {TDate} year The new year.\n */\n onYearChange: PropTypes.func,\n /**\n * Control the popup or dialog open state.\n * @default false\n */\n open: PropTypes.bool,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * Component displaying when passed `loading` true.\n * @returns {React.ReactNode} The node to render when loading.\n * @default () => ...\n */\n renderLoading: PropTypes.func,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, days outside the current month are rendered:\n *\n * - if `fixedWeekNumber` is defined, renders days to have the weeks requested.\n *\n * - if `fixedWeekNumber` is not defined, renders day to fill the first and last week of the current month.\n *\n * - ignored if `calendars` equals more than `1` on range pickers.\n * @default false\n */\n showDaysOutsideCurrentMonth: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n day: PropTypes.func,\n month: PropTypes.func,\n year: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'month', 'year']).isRequired),\n /**\n * Years are displayed in ascending (chronological) order by default.\n * If `desc`, years are displayed in descending order.\n * @default 'asc'\n */\n yearsOrder: PropTypes.oneOf(['asc', 'desc']),\n /**\n * Years rendered per row.\n * @default 4 on desktop, 3 on mobile\n */\n yearsPerRow: PropTypes.oneOf([3, 4])\n} : void 0;\nexport { DatePicker };","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"props\", \"ref\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport { styled } from '@mui/material/styles';\nimport { usePicker } from \"../usePicker/index.js\";\nimport { LocalizationProvider } from \"../../../LocalizationProvider/index.js\";\nimport { PickersLayout } from \"../../../PickersLayout/index.js\";\nimport { DIALOG_WIDTH } from \"../../constants/dimensions.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PickerStaticLayout = styled(PickersLayout)(({\n theme\n}) => ({\n overflow: 'hidden',\n minWidth: DIALOG_WIDTH,\n backgroundColor: (theme.vars || theme).palette.background.paper\n}));\n\n/**\n * Hook managing all the single-date static pickers:\n * - StaticDatePicker\n * - StaticDateTimePicker\n * - StaticTimePicker\n */\nexport const useStaticPicker = _ref => {\n let {\n props,\n ref\n } = _ref,\n pickerParams = _objectWithoutPropertiesLoose(_ref, _excluded);\n const {\n localeText,\n slots,\n slotProps,\n className,\n sx,\n displayStaticWrapperAs,\n autoFocus\n } = props;\n const {\n layoutProps,\n renderCurrentView\n } = usePicker(_extends({}, pickerParams, {\n props,\n autoFocusView: autoFocus ?? false,\n fieldRef: undefined,\n additionalViewProps: {},\n wrapperVariant: displayStaticWrapperAs\n }));\n const Layout = slots?.layout ?? PickerStaticLayout;\n const renderPicker = () => /*#__PURE__*/_jsx(LocalizationProvider, {\n localeText: localeText,\n children: /*#__PURE__*/_jsx(Layout, _extends({}, layoutProps, slotProps?.layout, {\n slots: slots,\n slotProps: slotProps,\n sx: [...(Array.isArray(sx) ? sx : [sx]), ...(Array.isArray(slotProps?.layout?.sx) ? slotProps.layout.sx : [slotProps?.layout?.sx])],\n className: clsx(className, slotProps?.layout?.className),\n ref: ref,\n children: renderCurrentView()\n }))\n });\n return {\n renderPicker\n };\n};","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { useDatePickerDefaultizedProps } from \"../DatePicker/shared.js\";\nimport { renderDateViewCalendar } from \"../dateViewRenderers/index.js\";\nimport { useStaticPicker } from \"../internals/hooks/useStaticPicker/index.js\";\nimport { validateDate } from \"../validation/index.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\n/**\n * Demos:\n *\n * - [DatePicker](https://mui.com/x/react-date-pickers/date-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [StaticDatePicker API](https://mui.com/x/api/date-pickers/static-date-picker/)\n */\nconst StaticDatePicker = /*#__PURE__*/React.forwardRef(function StaticDatePicker(inProps, ref) {\n const defaultizedProps = useDatePickerDefaultizedProps(inProps, 'MuiStaticDatePicker');\n const displayStaticWrapperAs = defaultizedProps.displayStaticWrapperAs ?? 'mobile';\n const viewRenderers = _extends({\n day: renderDateViewCalendar,\n month: renderDateViewCalendar,\n year: renderDateViewCalendar\n }, defaultizedProps.viewRenderers);\n\n // Props with the default values specific to the static variant\n const props = _extends({}, defaultizedProps, {\n viewRenderers,\n displayStaticWrapperAs,\n yearsPerRow: defaultizedProps.yearsPerRow ?? (displayStaticWrapperAs === 'mobile' ? 3 : 4),\n slotProps: _extends({}, defaultizedProps.slotProps, {\n toolbar: _extends({\n hidden: displayStaticWrapperAs === 'desktop'\n }, defaultizedProps.slotProps?.toolbar)\n })\n });\n const {\n renderPicker\n } = useStaticPicker({\n props,\n valueManager: singleItemValueManager,\n valueType: 'date',\n validator: validateDate,\n ref\n });\n return renderPicker();\n});\nStaticDatePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * Formats the day of week displayed in the calendar header.\n * @param {TDate} date The date of the day of week provided by the adapter.\n * @returns {string} The name to display.\n * @default (date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()\n */\n dayOfWeekFormatter: PropTypes.func,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * Force static wrapper inner components to be rendered in mobile or desktop mode.\n * @default \"mobile\"\n */\n displayStaticWrapperAs: PropTypes.oneOf(['desktop', 'mobile']),\n /**\n * If `true`, the week number will be display in the calendar.\n */\n displayWeekNumber: PropTypes.bool,\n /**\n * The day view will show as many weeks as needed after the end of the current month to match this value.\n * Put it to 6 to have a fixed number of weeks in Gregorian calendars\n */\n fixedWeekNumber: PropTypes.number,\n /**\n * If `true`, calls `renderLoading` instead of rendering the day calendar.\n * Can be used to preload information and show it in calendar.\n * @default false\n */\n loading: PropTypes.bool,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Months rendered per row.\n * @default 3\n */\n monthsPerRow: PropTypes.oneOf([3, 4]),\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when component requests to be closed.\n * Can be fired when selecting (by default on `desktop` mode) or clearing a value.\n * @deprecated Please avoid using as it will be removed in next major version.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired on month change.\n * @template TDate\n * @param {TDate} month The new month.\n */\n onMonthChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Callback fired on year change.\n * @template TDate\n * @param {TDate} year The new year.\n */\n onYearChange: PropTypes.func,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * Component displaying when passed `loading` true.\n * @returns {React.ReactNode} The node to render when loading.\n * @default () => ...\n */\n renderLoading: PropTypes.func,\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, days outside the current month are rendered:\n *\n * - if `fixedWeekNumber` is defined, renders days to have the weeks requested.\n *\n * - if `fixedWeekNumber` is not defined, renders day to fill the first and last week of the current month.\n *\n * - ignored if `calendars` equals more than `1` on range pickers.\n * @default false\n */\n showDaysOutsideCurrentMonth: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['day', 'month', 'year']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n day: PropTypes.func,\n month: PropTypes.func,\n year: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'month', 'year']).isRequired),\n /**\n * Years are displayed in ascending (chronological) order by default.\n * If `desc`, years are displayed in descending order.\n * @default 'asc'\n */\n yearsOrder: PropTypes.oneOf(['asc', 'desc']),\n /**\n * Years rendered per row.\n * @default `4` when `displayStaticWrapperAs === 'desktop'`, `3` otherwise.\n */\n yearsPerRow: PropTypes.oneOf([3, 4])\n};\nexport { StaticDatePicker };","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getPickersToolbarTextUtilityClass(slot) {\n return generateUtilityClass('MuiPickersToolbarText', slot);\n}\nexport const pickersToolbarTextClasses = generateUtilityClasses('MuiPickersToolbarText', ['root', 'selected']);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"className\", \"selected\", \"value\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport Typography from '@mui/material/Typography';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { getPickersToolbarTextUtilityClass, pickersToolbarTextClasses } from \"./pickersToolbarTextClasses.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n selected\n } = ownerState;\n const slots = {\n root: ['root', selected && 'selected']\n };\n return composeClasses(slots, getPickersToolbarTextUtilityClass, classes);\n};\nconst PickersToolbarTextRoot = styled(Typography, {\n name: 'MuiPickersToolbarText',\n slot: 'Root',\n overridesResolver: (_, styles) => [styles.root, {\n [`&.${pickersToolbarTextClasses.selected}`]: styles.selected\n }]\n})(({\n theme\n}) => ({\n transition: theme.transitions.create('color'),\n color: (theme.vars || theme).palette.text.secondary,\n [`&.${pickersToolbarTextClasses.selected}`]: {\n color: (theme.vars || theme).palette.text.primary\n }\n}));\nexport const PickersToolbarText = /*#__PURE__*/React.forwardRef(function PickersToolbarText(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersToolbarText'\n });\n const {\n className,\n value\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const classes = useUtilityClasses(props);\n return /*#__PURE__*/_jsx(PickersToolbarTextRoot, _extends({\n ref: ref,\n className: clsx(classes.root, className),\n component: \"span\"\n }, other, {\n children: value\n }));\n});","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"align\", \"className\", \"selected\", \"typographyClassName\", \"value\", \"variant\", \"width\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport Button from '@mui/material/Button';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { PickersToolbarText } from \"./PickersToolbarText.js\";\nimport { getPickersToolbarUtilityClass } from \"./pickersToolbarClasses.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, getPickersToolbarUtilityClass, classes);\n};\nconst PickersToolbarButtonRoot = styled(Button, {\n name: 'MuiPickersToolbarButton',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})({\n padding: 0,\n minWidth: 16,\n textTransform: 'none'\n});\nexport const PickersToolbarButton = /*#__PURE__*/React.forwardRef(function PickersToolbarButton(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPickersToolbarButton'\n });\n const {\n align,\n className,\n selected,\n typographyClassName,\n value,\n variant,\n width\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const classes = useUtilityClasses(props);\n return /*#__PURE__*/_jsx(PickersToolbarButtonRoot, _extends({\n variant: \"text\",\n ref: ref,\n className: clsx(classes.root, className)\n }, width ? {\n sx: {\n width\n }\n } : {}, other, {\n children: /*#__PURE__*/_jsx(PickersToolbarText, {\n align: align,\n className: typographyClassName,\n variant: variant,\n value: value,\n selected: selected\n })\n }));\n});","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getTimePickerToolbarUtilityClass(slot) {\n return generateUtilityClass('MuiTimePickerToolbar', slot);\n}\nexport const timePickerToolbarClasses = generateUtilityClasses('MuiTimePickerToolbar', ['root', 'separator', 'hourMinuteLabel', 'hourMinuteLabelLandscape', 'hourMinuteLabelReverse', 'ampmSelection', 'ampmLandscape', 'ampmLabel']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ampm\", \"ampmInClock\", \"value\", \"isLandscape\", \"onChange\", \"view\", \"onViewChange\", \"views\", \"disabled\", \"readOnly\", \"className\"];\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport PropTypes from 'prop-types';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { PickersToolbarText } from \"../internals/components/PickersToolbarText.js\";\nimport { PickersToolbarButton } from \"../internals/components/PickersToolbarButton.js\";\nimport { PickersToolbar } from \"../internals/components/PickersToolbar.js\";\nimport { arrayIncludes } from \"../internals/utils/utils.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { useMeridiemMode } from \"../internals/hooks/date-helpers-hooks.js\";\nimport { getTimePickerToolbarUtilityClass, timePickerToolbarClasses } from \"./timePickerToolbarClasses.js\";\nimport { formatMeridiem } from \"../internals/utils/date-utils.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n isLandscape,\n classes,\n isRtl\n } = ownerState;\n const slots = {\n root: ['root'],\n separator: ['separator'],\n hourMinuteLabel: ['hourMinuteLabel', isLandscape && 'hourMinuteLabelLandscape', isRtl && 'hourMinuteLabelReverse'],\n ampmSelection: ['ampmSelection', isLandscape && 'ampmLandscape'],\n ampmLabel: ['ampmLabel']\n };\n return composeClasses(slots, getTimePickerToolbarUtilityClass, classes);\n};\nconst TimePickerToolbarRoot = styled(PickersToolbar, {\n name: 'MuiTimePickerToolbar',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\nconst TimePickerToolbarSeparator = styled(PickersToolbarText, {\n name: 'MuiTimePickerToolbar',\n slot: 'Separator',\n overridesResolver: (props, styles) => styles.separator\n})({\n outline: 0,\n margin: '0 4px 0 2px',\n cursor: 'default'\n});\nconst TimePickerToolbarHourMinuteLabel = styled('div', {\n name: 'MuiTimePickerToolbar',\n slot: 'HourMinuteLabel',\n overridesResolver: (props, styles) => [{\n [`&.${timePickerToolbarClasses.hourMinuteLabelLandscape}`]: styles.hourMinuteLabelLandscape,\n [`&.${timePickerToolbarClasses.hourMinuteLabelReverse}`]: styles.hourMinuteLabelReverse\n }, styles.hourMinuteLabel]\n})({\n display: 'flex',\n justifyContent: 'flex-end',\n alignItems: 'flex-end',\n variants: [{\n props: {\n isRtl: true\n },\n style: {\n flexDirection: 'row-reverse'\n }\n }, {\n props: {\n isLandscape: true\n },\n style: {\n marginTop: 'auto'\n }\n }]\n});\nconst TimePickerToolbarAmPmSelection = styled('div', {\n name: 'MuiTimePickerToolbar',\n slot: 'AmPmSelection',\n overridesResolver: (props, styles) => [{\n [`.${timePickerToolbarClasses.ampmLabel}`]: styles.ampmLabel\n }, {\n [`&.${timePickerToolbarClasses.ampmLandscape}`]: styles.ampmLandscape\n }, styles.ampmSelection]\n})({\n display: 'flex',\n flexDirection: 'column',\n marginRight: 'auto',\n marginLeft: 12,\n [`& .${timePickerToolbarClasses.ampmLabel}`]: {\n fontSize: 17\n },\n variants: [{\n props: {\n isLandscape: true\n },\n style: {\n margin: '4px 0 auto',\n flexDirection: 'row',\n justifyContent: 'space-around',\n flexBasis: '100%'\n }\n }]\n});\n\n/**\n * Demos:\n *\n * - [TimePicker](https://mui.com/x/react-date-pickers/time-picker/)\n * - [Custom components](https://mui.com/x/react-date-pickers/custom-components/)\n *\n * API:\n *\n * - [TimePickerToolbar API](https://mui.com/x/api/date-pickers/time-picker-toolbar/)\n */\nfunction TimePickerToolbar(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTimePickerToolbar'\n });\n const {\n ampm,\n ampmInClock,\n value,\n isLandscape,\n onChange,\n view,\n onViewChange,\n views,\n disabled,\n readOnly,\n className\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const utils = useUtils();\n const translations = usePickersTranslations();\n const isRtl = useRtl();\n const showAmPmControl = Boolean(ampm && !ampmInClock && views.includes('hours'));\n const {\n meridiemMode,\n handleMeridiemChange\n } = useMeridiemMode(value, ampm, onChange);\n const formatHours = time => ampm ? utils.format(time, 'hours12h') : utils.format(time, 'hours24h');\n const ownerState = _extends({}, props, {\n isRtl\n });\n const classes = useUtilityClasses(ownerState);\n const separator = /*#__PURE__*/_jsx(TimePickerToolbarSeparator, {\n tabIndex: -1,\n value: \":\",\n variant: \"h3\",\n selected: false,\n className: classes.separator\n });\n return /*#__PURE__*/_jsxs(TimePickerToolbarRoot, _extends({\n landscapeDirection: \"row\",\n toolbarTitle: translations.timePickerToolbarTitle,\n isLandscape: isLandscape,\n ownerState: ownerState,\n className: clsx(classes.root, className)\n }, other, {\n children: [/*#__PURE__*/_jsxs(TimePickerToolbarHourMinuteLabel, {\n className: classes.hourMinuteLabel,\n ownerState: ownerState,\n children: [arrayIncludes(views, 'hours') && /*#__PURE__*/_jsx(PickersToolbarButton, {\n tabIndex: -1,\n variant: \"h3\",\n onClick: () => onViewChange('hours'),\n selected: view === 'hours',\n value: value ? formatHours(value) : '--'\n }), arrayIncludes(views, ['hours', 'minutes']) && separator, arrayIncludes(views, 'minutes') && /*#__PURE__*/_jsx(PickersToolbarButton, {\n tabIndex: -1,\n variant: \"h3\",\n onClick: () => onViewChange('minutes'),\n selected: view === 'minutes',\n value: value ? utils.format(value, 'minutes') : '--'\n }), arrayIncludes(views, ['minutes', 'seconds']) && separator, arrayIncludes(views, 'seconds') && /*#__PURE__*/_jsx(PickersToolbarButton, {\n variant: \"h3\",\n onClick: () => onViewChange('seconds'),\n selected: view === 'seconds',\n value: value ? utils.format(value, 'seconds') : '--'\n })]\n }), showAmPmControl && /*#__PURE__*/_jsxs(TimePickerToolbarAmPmSelection, {\n className: classes.ampmSelection,\n ownerState: ownerState,\n children: [/*#__PURE__*/_jsx(PickersToolbarButton, {\n disableRipple: true,\n variant: \"subtitle2\",\n selected: meridiemMode === 'am',\n typographyClassName: classes.ampmLabel,\n value: formatMeridiem(utils, 'am'),\n onClick: readOnly ? undefined : () => handleMeridiemChange('am'),\n disabled: disabled\n }), /*#__PURE__*/_jsx(PickersToolbarButton, {\n disableRipple: true,\n variant: \"subtitle2\",\n selected: meridiemMode === 'pm',\n typographyClassName: classes.ampmLabel,\n value: formatMeridiem(utils, 'pm'),\n onClick: readOnly ? undefined : () => handleMeridiemChange('pm'),\n disabled: disabled\n })]\n })]\n }));\n}\nprocess.env.NODE_ENV !== \"production\" ? TimePickerToolbar.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n ampm: PropTypes.bool,\n ampmInClock: PropTypes.bool,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n disabled: PropTypes.bool,\n /**\n * If `true`, show the toolbar even in desktop mode.\n * @default `true` for Desktop, `false` for Mobile.\n */\n hidden: PropTypes.bool,\n isLandscape: PropTypes.bool.isRequired,\n onChange: PropTypes.func.isRequired,\n /**\n * Callback called when a toolbar is clicked\n * @template TView\n * @param {TView} view The view to open\n */\n onViewChange: PropTypes.func.isRequired,\n readOnly: PropTypes.bool,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n titleId: PropTypes.string,\n /**\n * Toolbar date format.\n */\n toolbarFormat: PropTypes.string,\n /**\n * Toolbar value placeholder—it is displayed when the value is empty.\n * @default \"––\"\n */\n toolbarPlaceholder: PropTypes.node,\n value: PropTypes.object,\n /**\n * Currently visible picker view.\n */\n view: PropTypes.oneOf(['hours', 'meridiem', 'minutes', 'seconds']).isRequired,\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['hours', 'meridiem', 'minutes', 'seconds']).isRequired).isRequired\n} : void 0;\nexport { TimePickerToolbar };","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport { useThemeProps } from '@mui/material/styles';\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { TimePickerToolbar } from \"./TimePickerToolbar.js\";\nimport { applyDefaultViewProps } from \"../internals/utils/views.js\";\nexport function useTimePickerDefaultizedProps(props, name) {\n const utils = useUtils();\n const themeProps = useThemeProps({\n props,\n name\n });\n const ampm = themeProps.ampm ?? utils.is12HourCycleInCurrentLocale();\n const localeText = React.useMemo(() => {\n if (themeProps.localeText?.toolbarTitle == null) {\n return themeProps.localeText;\n }\n return _extends({}, themeProps.localeText, {\n timePickerToolbarTitle: themeProps.localeText.toolbarTitle\n });\n }, [themeProps.localeText]);\n return _extends({}, themeProps, {\n ampm,\n localeText\n }, applyDefaultViewProps({\n views: themeProps.views,\n openTo: themeProps.openTo,\n defaultViews: ['hours', 'minutes'],\n defaultOpenTo: 'hours'\n }), {\n disableFuture: themeProps.disableFuture ?? false,\n disablePast: themeProps.disablePast ?? false,\n slots: _extends({\n toolbar: TimePickerToolbar\n }, themeProps.slots),\n slotProps: _extends({}, themeProps.slotProps, {\n toolbar: _extends({\n ampm,\n ampmInClock: themeProps.ampmInClock\n }, themeProps.slotProps?.toolbar)\n })\n });\n}","import * as React from 'react';\nimport { TimeClock } from \"../TimeClock/index.js\";\nimport { DigitalClock } from \"../DigitalClock/index.js\";\nimport { MultiSectionDigitalClock } from \"../MultiSectionDigitalClock/index.js\";\nimport { isTimeView } from \"../internals/utils/time-utils.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport const renderTimeViewClock = ({\n view,\n onViewChange,\n focusedView,\n onFocusedViewChange,\n views,\n value,\n defaultValue,\n referenceDate,\n onChange,\n className,\n classes,\n disableFuture,\n disablePast,\n minTime,\n maxTime,\n shouldDisableTime,\n minutesStep,\n ampm,\n ampmInClock,\n slots,\n slotProps,\n readOnly,\n disabled,\n sx,\n autoFocus,\n showViewSwitcher,\n disableIgnoringDatePartForTimeValidation,\n timezone\n}) => /*#__PURE__*/_jsx(TimeClock, {\n view: view,\n onViewChange: onViewChange,\n focusedView: focusedView && isTimeView(focusedView) ? focusedView : null,\n onFocusedViewChange: onFocusedViewChange,\n views: views.filter(isTimeView),\n value: value,\n defaultValue: defaultValue,\n referenceDate: referenceDate,\n onChange: onChange,\n className: className,\n classes: classes,\n disableFuture: disableFuture,\n disablePast: disablePast,\n minTime: minTime,\n maxTime: maxTime,\n shouldDisableTime: shouldDisableTime,\n minutesStep: minutesStep,\n ampm: ampm,\n ampmInClock: ampmInClock,\n slots: slots,\n slotProps: slotProps,\n readOnly: readOnly,\n disabled: disabled,\n sx: sx,\n autoFocus: autoFocus,\n showViewSwitcher: showViewSwitcher,\n disableIgnoringDatePartForTimeValidation: disableIgnoringDatePartForTimeValidation,\n timezone: timezone\n});\nexport const renderDigitalClockTimeView = ({\n view,\n onViewChange,\n focusedView,\n onFocusedViewChange,\n views,\n value,\n defaultValue,\n referenceDate,\n onChange,\n className,\n classes,\n disableFuture,\n disablePast,\n minTime,\n maxTime,\n shouldDisableTime,\n minutesStep,\n ampm,\n slots,\n slotProps,\n readOnly,\n disabled,\n sx,\n autoFocus,\n disableIgnoringDatePartForTimeValidation,\n timeSteps,\n skipDisabled,\n timezone\n}) => /*#__PURE__*/_jsx(DigitalClock, {\n view: view,\n onViewChange: onViewChange,\n focusedView: focusedView,\n onFocusedViewChange: onFocusedViewChange,\n views: views.filter(isTimeView),\n value: value,\n defaultValue: defaultValue,\n referenceDate: referenceDate,\n onChange: onChange,\n className: className,\n classes: classes,\n disableFuture: disableFuture,\n disablePast: disablePast,\n minTime: minTime,\n maxTime: maxTime,\n shouldDisableTime: shouldDisableTime,\n minutesStep: minutesStep,\n ampm: ampm,\n slots: slots,\n slotProps: slotProps,\n readOnly: readOnly,\n disabled: disabled,\n sx: sx,\n autoFocus: autoFocus,\n disableIgnoringDatePartForTimeValidation: disableIgnoringDatePartForTimeValidation,\n timeStep: timeSteps?.minutes,\n skipDisabled: skipDisabled,\n timezone: timezone\n});\nexport const renderMultiSectionDigitalClockTimeView = ({\n view,\n onViewChange,\n focusedView,\n onFocusedViewChange,\n views,\n value,\n defaultValue,\n referenceDate,\n onChange,\n className,\n classes,\n disableFuture,\n disablePast,\n minTime,\n maxTime,\n shouldDisableTime,\n minutesStep,\n ampm,\n slots,\n slotProps,\n readOnly,\n disabled,\n sx,\n autoFocus,\n disableIgnoringDatePartForTimeValidation,\n timeSteps,\n skipDisabled,\n timezone\n}) => /*#__PURE__*/_jsx(MultiSectionDigitalClock, {\n view: view,\n onViewChange: onViewChange,\n focusedView: focusedView,\n onFocusedViewChange: onFocusedViewChange,\n views: views.filter(isTimeView),\n value: value,\n defaultValue: defaultValue,\n referenceDate: referenceDate,\n onChange: onChange,\n className: className,\n classes: classes,\n disableFuture: disableFuture,\n disablePast: disablePast,\n minTime: minTime,\n maxTime: maxTime,\n shouldDisableTime: shouldDisableTime,\n minutesStep: minutesStep,\n ampm: ampm,\n slots: slots,\n slotProps: slotProps,\n readOnly: readOnly,\n disabled: disabled,\n sx: sx,\n autoFocus: autoFocus,\n disableIgnoringDatePartForTimeValidation: disableIgnoringDatePartForTimeValidation,\n timeSteps: timeSteps,\n skipDisabled: skipDisabled,\n timezone: timezone\n});","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"views\", \"format\"];\nimport { resolveTimeFormat, isTimeView, isInternalTimeView } from \"./time-utils.js\";\nimport { isDatePickerView, resolveDateFormat } from \"./date-utils.js\";\nexport const resolveDateTimeFormat = (utils, _ref, ignoreDateResolving) => {\n let {\n views,\n format\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (format) {\n return format;\n }\n const dateViews = [];\n const timeViews = [];\n views.forEach(view => {\n if (isTimeView(view)) {\n timeViews.push(view);\n } else if (isDatePickerView(view)) {\n dateViews.push(view);\n }\n });\n if (timeViews.length === 0) {\n return resolveDateFormat(utils, _extends({\n views: dateViews\n }, other), false);\n }\n if (dateViews.length === 0) {\n return resolveTimeFormat(utils, _extends({\n views: timeViews\n }, other));\n }\n const timeFormat = resolveTimeFormat(utils, _extends({\n views: timeViews\n }, other));\n const dateFormat = ignoreDateResolving ? utils.formats.keyboardDate : resolveDateFormat(utils, _extends({\n views: dateViews\n }, other), false);\n return `${dateFormat} ${timeFormat}`;\n};\nconst resolveViews = (ampm, views, shouldUseSingleColumn) => {\n if (shouldUseSingleColumn) {\n return views.filter(view => !isInternalTimeView(view) || view === 'hours');\n }\n return ampm ? [...views, 'meridiem'] : views;\n};\nconst resolveShouldRenderTimeInASingleColumn = (timeSteps, threshold) => 24 * 60 / ((timeSteps.hours ?? 1) * (timeSteps.minutes ?? 5)) <= threshold;\nexport function resolveTimeViewsResponse({\n thresholdToRenderTimeInASingleColumn: inThreshold,\n ampm,\n timeSteps: inTimeSteps,\n views\n}) {\n const thresholdToRenderTimeInASingleColumn = inThreshold ?? 24;\n const timeSteps = _extends({\n hours: 1,\n minutes: 5,\n seconds: 5\n }, inTimeSteps);\n const shouldRenderTimeInASingleColumn = resolveShouldRenderTimeInASingleColumn(timeSteps, thresholdToRenderTimeInASingleColumn);\n return {\n thresholdToRenderTimeInASingleColumn,\n timeSteps,\n shouldRenderTimeInASingleColumn,\n views: resolveViews(ampm, views, shouldRenderTimeInASingleColumn)\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport resolveComponentProps from '@mui/utils/resolveComponentProps';\nimport { refType } from '@mui/utils';\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { TimeField } from \"../TimeField/index.js\";\nimport { useTimePickerDefaultizedProps } from \"../TimePicker/shared.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { extractValidationProps, validateTime } from \"../validation/index.js\";\nimport { ClockIcon } from \"../icons/index.js\";\nimport { useDesktopPicker } from \"../internals/hooks/useDesktopPicker/index.js\";\nimport { renderDigitalClockTimeView, renderMultiSectionDigitalClockTimeView } from \"../timeViewRenderers/index.js\";\nimport { resolveTimeFormat } from \"../internals/utils/time-utils.js\";\nimport { resolveTimeViewsResponse } from \"../internals/utils/date-time-utils.js\";\nimport { buildGetOpenDialogAriaText } from \"../locales/utils/getPickersLocalization.js\";\n/**\n * Demos:\n *\n * - [TimePicker](https://mui.com/x/react-date-pickers/time-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [DesktopTimePicker API](https://mui.com/x/api/date-pickers/desktop-time-picker/)\n */\nconst DesktopTimePicker = /*#__PURE__*/React.forwardRef(function DesktopTimePicker(inProps, ref) {\n const translations = usePickersTranslations();\n const utils = useUtils();\n\n // Props with the default values common to all time pickers\n const defaultizedProps = useTimePickerDefaultizedProps(inProps, 'MuiDesktopTimePicker');\n const {\n shouldRenderTimeInASingleColumn,\n views: resolvedViews,\n timeSteps\n } = resolveTimeViewsResponse(defaultizedProps);\n const renderTimeView = shouldRenderTimeInASingleColumn ? renderDigitalClockTimeView : renderMultiSectionDigitalClockTimeView;\n const viewRenderers = _extends({\n hours: renderTimeView,\n minutes: renderTimeView,\n seconds: renderTimeView,\n meridiem: renderTimeView\n }, defaultizedProps.viewRenderers);\n const ampmInClock = defaultizedProps.ampmInClock ?? true;\n const actionBarActions = shouldRenderTimeInASingleColumn ? [] : ['accept'];\n // Need to avoid adding the `meridiem` view when unexpected renderer is specified\n const shouldHoursRendererContainMeridiemView = viewRenderers.hours?.name === renderMultiSectionDigitalClockTimeView.name;\n const views = !shouldHoursRendererContainMeridiemView ? resolvedViews.filter(view => view !== 'meridiem') : resolvedViews;\n\n // Props with the default values specific to the desktop variant\n const props = _extends({}, defaultizedProps, {\n ampmInClock,\n timeSteps,\n viewRenderers,\n format: resolveTimeFormat(utils, defaultizedProps),\n // Setting only `hours` time view in case of single column time picker\n // Allows for easy view lifecycle management\n views: shouldRenderTimeInASingleColumn ? ['hours'] : views,\n slots: _extends({\n field: TimeField,\n openPickerIcon: ClockIcon\n }, defaultizedProps.slots),\n slotProps: _extends({}, defaultizedProps.slotProps, {\n field: ownerState => _extends({}, resolveComponentProps(defaultizedProps.slotProps?.field, ownerState), extractValidationProps(defaultizedProps), {\n ref\n }),\n toolbar: _extends({\n hidden: true,\n ampmInClock\n }, defaultizedProps.slotProps?.toolbar),\n actionBar: _extends({\n actions: actionBarActions\n }, defaultizedProps.slotProps?.actionBar)\n })\n });\n const {\n renderPicker\n } = useDesktopPicker({\n props,\n valueManager: singleItemValueManager,\n valueType: 'time',\n getOpenDialogAriaText: buildGetOpenDialogAriaText({\n utils,\n formatKey: 'fullTime',\n contextTranslation: translations.openTimePickerDialogue,\n propsTranslation: props.localeText?.openTimePickerDialogue\n }),\n validator: validateTime\n });\n return renderPicker();\n});\nDesktopTimePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * Display ampm controls under the clock (instead of in the toolbar).\n * @default true on desktop, false on mobile\n */\n ampmInClock: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, the popover or modal will close after submitting the full date.\n * @default `true` for desktop, `false` for mobile (based on the chosen wrapper and `desktopModeMediaQuery` prop).\n */\n closeOnSelect: PropTypes.bool,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, the open picker button will not be rendered (renders only the field).\n * @default false\n */\n disableOpenPicker: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.any,\n /**\n * Format of the date when rendered in the input(s).\n * Defaults to localized format based on the used `views`.\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Name attribute used by the `input` element in the Field.\n */\n name: PropTypes.string,\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be closed.\n * Use in controlled mode (see `open`).\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired when the popup requests to be opened.\n * Use in controlled mode (see `open`).\n */\n onOpen: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Control the popup or dialog open state.\n * @default false\n */\n open: PropTypes.bool,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['hours', 'meridiem', 'minutes', 'seconds']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * If `true`, disabled digital clock items will not be rendered.\n * @default false\n */\n skipDisabled: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Amount of time options below or at which the single column time renderer is used.\n * @default 24\n */\n thresholdToRenderTimeInASingleColumn: PropTypes.number,\n /**\n * The time steps between two time unit options.\n * For example, if `timeStep.minutes = 8`, then the available minute options will be `[0, 8, 16, 24, 32, 40, 48, 56]`.\n * When single column time renderer is used, only `timeStep.minutes` will be used.\n * @default{ hours: 1, minutes: 5, seconds: 5 }\n */\n timeSteps: PropTypes.shape({\n hours: PropTypes.number,\n minutes: PropTypes.number,\n seconds: PropTypes.number\n }),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['hours', 'meridiem', 'minutes', 'seconds']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n hours: PropTypes.func,\n meridiem: PropTypes.func,\n minutes: PropTypes.func,\n seconds: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['hours', 'minutes', 'seconds']).isRequired)\n};\nexport { DesktopTimePicker };","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport resolveComponentProps from '@mui/utils/resolveComponentProps';\nimport { refType } from '@mui/utils';\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { TimeField } from \"../TimeField/index.js\";\nimport { useTimePickerDefaultizedProps } from \"../TimePicker/shared.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { extractValidationProps, validateTime } from \"../validation/index.js\";\nimport { useMobilePicker } from \"../internals/hooks/useMobilePicker/index.js\";\nimport { renderTimeViewClock } from \"../timeViewRenderers/index.js\";\nimport { resolveTimeFormat } from \"../internals/utils/time-utils.js\";\nimport { buildGetOpenDialogAriaText } from \"../locales/utils/getPickersLocalization.js\";\n/**\n * Demos:\n *\n * - [TimePicker](https://mui.com/x/react-date-pickers/time-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [MobileTimePicker API](https://mui.com/x/api/date-pickers/mobile-time-picker/)\n */\nconst MobileTimePicker = /*#__PURE__*/React.forwardRef(function MobileTimePicker(inProps, ref) {\n const translations = usePickersTranslations();\n const utils = useUtils();\n\n // Props with the default values common to all time pickers\n const defaultizedProps = useTimePickerDefaultizedProps(inProps, 'MuiMobileTimePicker');\n const viewRenderers = _extends({\n hours: renderTimeViewClock,\n minutes: renderTimeViewClock,\n seconds: renderTimeViewClock\n }, defaultizedProps.viewRenderers);\n const ampmInClock = defaultizedProps.ampmInClock ?? false;\n\n // Props with the default values specific to the mobile variant\n const props = _extends({}, defaultizedProps, {\n ampmInClock,\n viewRenderers,\n format: resolveTimeFormat(utils, defaultizedProps),\n slots: _extends({\n field: TimeField\n }, defaultizedProps.slots),\n slotProps: _extends({}, defaultizedProps.slotProps, {\n field: ownerState => _extends({}, resolveComponentProps(defaultizedProps.slotProps?.field, ownerState), extractValidationProps(defaultizedProps), {\n ref\n }),\n toolbar: _extends({\n hidden: false,\n ampmInClock\n }, defaultizedProps.slotProps?.toolbar)\n })\n });\n const {\n renderPicker\n } = useMobilePicker({\n props,\n valueManager: singleItemValueManager,\n valueType: 'time',\n getOpenDialogAriaText: buildGetOpenDialogAriaText({\n utils,\n formatKey: 'fullTime',\n contextTranslation: translations.openTimePickerDialogue,\n propsTranslation: props.localeText?.openTimePickerDialogue\n }),\n validator: validateTime\n });\n return renderPicker();\n});\nMobileTimePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * Display ampm controls under the clock (instead of in the toolbar).\n * @default true on desktop, false on mobile\n */\n ampmInClock: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, the popover or modal will close after submitting the full date.\n * @default `true` for desktop, `false` for mobile (based on the chosen wrapper and `desktopModeMediaQuery` prop).\n */\n closeOnSelect: PropTypes.bool,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, the open picker button will not be rendered (renders only the field).\n * @default false\n */\n disableOpenPicker: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.any,\n /**\n * Format of the date when rendered in the input(s).\n * Defaults to localized format based on the used `views`.\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Name attribute used by the `input` element in the Field.\n */\n name: PropTypes.string,\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be closed.\n * Use in controlled mode (see `open`).\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired when the popup requests to be opened.\n * Use in controlled mode (see `open`).\n */\n onOpen: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Control the popup or dialog open state.\n * @default false\n */\n open: PropTypes.bool,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['hours', 'minutes', 'seconds']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['hours', 'minutes', 'seconds']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n hours: PropTypes.func,\n minutes: PropTypes.func,\n seconds: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['hours', 'minutes', 'seconds']).isRequired)\n};\nexport { MobileTimePicker };","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"desktopModeMediaQuery\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport useMediaQuery from '@mui/material/useMediaQuery';\nimport { useThemeProps } from '@mui/material/styles';\nimport { refType } from '@mui/utils';\nimport { DesktopTimePicker } from \"../DesktopTimePicker/index.js\";\nimport { MobileTimePicker } from \"../MobileTimePicker/index.js\";\nimport { DEFAULT_DESKTOP_MODE_MEDIA_QUERY } from \"../internals/utils/utils.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\n/**\n * Demos:\n *\n * - [TimePicker](https://mui.com/x/react-date-pickers/time-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [TimePicker API](https://mui.com/x/api/date-pickers/time-picker/)\n */\nconst TimePicker = /*#__PURE__*/React.forwardRef(function TimePicker(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTimePicker'\n });\n const {\n desktopModeMediaQuery = DEFAULT_DESKTOP_MODE_MEDIA_QUERY\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // defaults to `true` in environments where `window.matchMedia` would not be available (i.e. test/jsdom)\n const isDesktop = useMediaQuery(desktopModeMediaQuery, {\n defaultMatches: true\n });\n if (isDesktop) {\n return /*#__PURE__*/_jsx(DesktopTimePicker, _extends({\n ref: ref\n }, other));\n }\n return /*#__PURE__*/_jsx(MobileTimePicker, _extends({\n ref: ref\n }, other));\n});\nprocess.env.NODE_ENV !== \"production\" ? TimePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * Display ampm controls under the clock (instead of in the toolbar).\n * @default true on desktop, false on mobile\n */\n ampmInClock: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, the popover or modal will close after submitting the full date.\n * @default `true` for desktop, `false` for mobile (based on the chosen wrapper and `desktopModeMediaQuery` prop).\n */\n closeOnSelect: PropTypes.bool,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * CSS media query when `Mobile` mode will be changed to `Desktop`.\n * @default '@media (pointer: fine)'\n * @example '@media (min-width: 720px)' or theme.breakpoints.up(\"sm\")\n */\n desktopModeMediaQuery: PropTypes.string,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, the open picker button will not be rendered (renders only the field).\n * @default false\n */\n disableOpenPicker: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.any,\n /**\n * Format of the date when rendered in the input(s).\n * Defaults to localized format based on the used `views`.\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Name attribute used by the `input` element in the Field.\n */\n name: PropTypes.string,\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be closed.\n * Use in controlled mode (see `open`).\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired when the popup requests to be opened.\n * Use in controlled mode (see `open`).\n */\n onOpen: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Control the popup or dialog open state.\n * @default false\n */\n open: PropTypes.bool,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['hours', 'meridiem', 'minutes', 'seconds']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * If `true`, disabled digital clock items will not be rendered.\n * @default false\n */\n skipDisabled: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Amount of time options below or at which the single column time renderer is used.\n * @default 24\n */\n thresholdToRenderTimeInASingleColumn: PropTypes.number,\n /**\n * The time steps between two time unit options.\n * For example, if `timeStep.minutes = 8`, then the available minute options will be `[0, 8, 16, 24, 32, 40, 48, 56]`.\n * When single column time renderer is used, only `timeStep.minutes` will be used.\n * @default{ hours: 1, minutes: 5, seconds: 5 }\n */\n timeSteps: PropTypes.shape({\n hours: PropTypes.number,\n minutes: PropTypes.number,\n seconds: PropTypes.number\n }),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['hours', 'meridiem', 'minutes', 'seconds']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n hours: PropTypes.func,\n meridiem: PropTypes.func,\n minutes: PropTypes.func,\n seconds: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['hours', 'minutes', 'seconds']).isRequired)\n} : void 0;\nexport { TimePicker };","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { useTimePickerDefaultizedProps } from \"../TimePicker/shared.js\";\nimport { renderTimeViewClock } from \"../timeViewRenderers/index.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { useStaticPicker } from \"../internals/hooks/useStaticPicker/index.js\";\nimport { validateTime } from \"../validation/index.js\";\n/**\n * Demos:\n *\n * - [TimePicker](https://mui.com/x/react-date-pickers/time-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [StaticTimePicker API](https://mui.com/x/api/date-pickers/static-time-picker/)\n */\nconst StaticTimePicker = /*#__PURE__*/React.forwardRef(function StaticTimePicker(inProps, ref) {\n const defaultizedProps = useTimePickerDefaultizedProps(inProps, 'MuiStaticTimePicker');\n const displayStaticWrapperAs = defaultizedProps.displayStaticWrapperAs ?? 'mobile';\n const ampmInClock = defaultizedProps.ampmInClock ?? displayStaticWrapperAs === 'desktop';\n const viewRenderers = _extends({\n hours: renderTimeViewClock,\n minutes: renderTimeViewClock,\n seconds: renderTimeViewClock\n }, defaultizedProps.viewRenderers);\n\n // Props with the default values specific to the static variant\n const props = _extends({}, defaultizedProps, {\n viewRenderers,\n displayStaticWrapperAs,\n ampmInClock,\n slotProps: _extends({}, defaultizedProps.slotProps, {\n toolbar: _extends({\n hidden: displayStaticWrapperAs === 'desktop',\n ampmInClock\n }, defaultizedProps.slotProps?.toolbar)\n })\n });\n const {\n renderPicker\n } = useStaticPicker({\n props,\n valueManager: singleItemValueManager,\n valueType: 'time',\n validator: validateTime,\n ref\n });\n return renderPicker();\n});\nStaticTimePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * Display ampm controls under the clock (instead of in the toolbar).\n * @default true on desktop, false on mobile\n */\n ampmInClock: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * Force static wrapper inner components to be rendered in mobile or desktop mode.\n * @default \"mobile\"\n */\n displayStaticWrapperAs: PropTypes.oneOf(['desktop', 'mobile']),\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when component requests to be closed.\n * Can be fired when selecting (by default on `desktop` mode) or clearing a value.\n * @deprecated Please avoid using as it will be removed in next major version.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['hours', 'minutes', 'seconds']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['hours', 'minutes', 'seconds']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n hours: PropTypes.func,\n minutes: PropTypes.func,\n seconds: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['hours', 'minutes', 'seconds']).isRequired)\n};\nexport { StaticTimePicker };","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getDateTimePickerTabsUtilityClass(slot) {\n return generateUtilityClass('MuiDateTimePickerTabs', slot);\n}\nexport const dateTimePickerTabsClasses = generateUtilityClasses('MuiDateTimePickerTabs', ['root']);","'use client';\n\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport PropTypes from 'prop-types';\nimport Tab from '@mui/material/Tab';\nimport Tabs, { tabsClasses } from '@mui/material/Tabs';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport { TimeIcon, DateRangeIcon } from \"../icons/index.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { getDateTimePickerTabsUtilityClass } from \"./dateTimePickerTabsClasses.js\";\nimport { isDatePickerView } from \"../internals/utils/date-utils.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst viewToTab = view => {\n if (isDatePickerView(view)) {\n return 'date';\n }\n return 'time';\n};\nconst tabToView = tab => {\n if (tab === 'date') {\n return 'day';\n }\n return 'hours';\n};\nconst useUtilityClasses = ownerState => {\n const {\n classes\n } = ownerState;\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, getDateTimePickerTabsUtilityClass, classes);\n};\nconst DateTimePickerTabsRoot = styled(Tabs, {\n name: 'MuiDateTimePickerTabs',\n slot: 'Root',\n overridesResolver: (_, styles) => styles.root\n})(({\n theme\n}) => ({\n boxShadow: `0 -1px 0 0 inset ${(theme.vars || theme).palette.divider}`,\n '&:last-child': {\n boxShadow: `0 1px 0 0 inset ${(theme.vars || theme).palette.divider}`,\n [`& .${tabsClasses.indicator}`]: {\n bottom: 'auto',\n top: 0\n }\n }\n}));\n\n/**\n * Demos:\n *\n * - [DateTimePicker](https://mui.com/x/react-date-pickers/date-time-picker/)\n * - [Custom slots and subcomponents](https://mui.com/x/react-date-pickers/custom-components/)\n *\n * API:\n *\n * - [DateTimePickerTabs API](https://mui.com/x/api/date-pickers/date-time-picker-tabs/)\n */\nconst DateTimePickerTabs = function DateTimePickerTabs(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiDateTimePickerTabs'\n });\n const {\n dateIcon = /*#__PURE__*/_jsx(DateRangeIcon, {}),\n onViewChange,\n timeIcon = /*#__PURE__*/_jsx(TimeIcon, {}),\n view,\n hidden = typeof window === 'undefined' || window.innerHeight < 667,\n className,\n sx\n } = props;\n const translations = usePickersTranslations();\n const classes = useUtilityClasses(props);\n const handleChange = (event, value) => {\n onViewChange(tabToView(value));\n };\n if (hidden) {\n return null;\n }\n return /*#__PURE__*/_jsxs(DateTimePickerTabsRoot, {\n ownerState: props,\n variant: \"fullWidth\",\n value: viewToTab(view),\n onChange: handleChange,\n className: clsx(className, classes.root),\n sx: sx,\n children: [/*#__PURE__*/_jsx(Tab, {\n value: \"date\",\n \"aria-label\": translations.dateTableLabel,\n icon: /*#__PURE__*/_jsx(React.Fragment, {\n children: dateIcon\n })\n }), /*#__PURE__*/_jsx(Tab, {\n value: \"time\",\n \"aria-label\": translations.timeTableLabel,\n icon: /*#__PURE__*/_jsx(React.Fragment, {\n children: timeIcon\n })\n })]\n });\n};\nprocess.env.NODE_ENV !== \"production\" ? DateTimePickerTabs.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n /**\n * Date tab icon.\n * @default DateRange\n */\n dateIcon: PropTypes.node,\n /**\n * Toggles visibility of the tabs allowing view switching.\n * @default `window.innerHeight < 667` for `DesktopDateTimePicker` and `MobileDateTimePicker`, `displayStaticWrapperAs === 'desktop'` for `StaticDateTimePicker`\n */\n hidden: PropTypes.bool,\n /**\n * Callback called when a tab is clicked.\n * @template TView\n * @param {TView} view The view to open\n */\n onViewChange: PropTypes.func.isRequired,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Time tab icon.\n * @default Time\n */\n timeIcon: PropTypes.node,\n /**\n * Currently visible picker view.\n */\n view: PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']).isRequired\n} : void 0;\nexport { DateTimePickerTabs };","import { unstable_generateUtilityClass as generateUtilityClass, unstable_generateUtilityClasses as generateUtilityClasses } from '@mui/utils';\nexport function getDateTimePickerToolbarUtilityClass(slot) {\n return generateUtilityClass('MuiDateTimePickerToolbar', slot);\n}\nexport const dateTimePickerToolbarClasses = generateUtilityClasses('MuiDateTimePickerToolbar', ['root', 'dateContainer', 'timeContainer', 'timeDigitsContainer', 'separator', 'timeLabelReverse', 'ampmSelection', 'ampmLandscape', 'ampmLabel']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ampm\", \"ampmInClock\", \"value\", \"onChange\", \"view\", \"isLandscape\", \"onViewChange\", \"toolbarFormat\", \"toolbarPlaceholder\", \"views\", \"disabled\", \"readOnly\", \"toolbarVariant\", \"toolbarTitle\", \"className\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { styled, useThemeProps } from '@mui/material/styles';\nimport composeClasses from '@mui/utils/composeClasses';\nimport clsx from 'clsx';\nimport { PickersToolbarText } from \"../internals/components/PickersToolbarText.js\";\nimport { PickersToolbar } from \"../internals/components/PickersToolbar.js\";\nimport { PickersToolbarButton } from \"../internals/components/PickersToolbarButton.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { dateTimePickerToolbarClasses, getDateTimePickerToolbarUtilityClass } from \"./dateTimePickerToolbarClasses.js\";\nimport { useMeridiemMode } from \"../internals/hooks/date-helpers-hooks.js\";\nimport { MULTI_SECTION_CLOCK_SECTION_WIDTH } from \"../internals/constants/dimensions.js\";\nimport { formatMeridiem } from \"../internals/utils/date-utils.js\";\nimport { pickersToolbarTextClasses } from \"../internals/components/pickersToolbarTextClasses.js\";\nimport { pickersToolbarClasses } from \"../internals/components/pickersToolbarClasses.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n isLandscape,\n isRtl\n } = ownerState;\n const slots = {\n root: ['root'],\n dateContainer: ['dateContainer'],\n timeContainer: ['timeContainer', isRtl && 'timeLabelReverse'],\n timeDigitsContainer: ['timeDigitsContainer', isRtl && 'timeLabelReverse'],\n separator: ['separator'],\n ampmSelection: ['ampmSelection', isLandscape && 'ampmLandscape'],\n ampmLabel: ['ampmLabel']\n };\n return composeClasses(slots, getDateTimePickerToolbarUtilityClass, classes);\n};\nconst DateTimePickerToolbarRoot = styled(PickersToolbar, {\n name: 'MuiDateTimePickerToolbar',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})(({\n theme\n}) => ({\n paddingLeft: 16,\n paddingRight: 16,\n justifyContent: 'space-around',\n position: 'relative',\n variants: [{\n props: {\n toolbarVariant: 'desktop'\n },\n style: {\n borderBottom: `1px solid ${(theme.vars || theme).palette.divider}`,\n [`& .${pickersToolbarClasses.content} .${pickersToolbarTextClasses.selected}`]: {\n color: (theme.vars || theme).palette.primary.main,\n fontWeight: theme.typography.fontWeightBold\n }\n }\n }, {\n props: {\n toolbarVariant: 'desktop',\n isLandscape: true\n },\n style: {\n borderRight: `1px solid ${(theme.vars || theme).palette.divider}`\n }\n }, {\n props: {\n toolbarVariant: 'desktop',\n isLandscape: false\n },\n style: {\n paddingLeft: 24,\n paddingRight: 0\n }\n }]\n}));\nconst DateTimePickerToolbarDateContainer = styled('div', {\n name: 'MuiDateTimePickerToolbar',\n slot: 'DateContainer',\n overridesResolver: (props, styles) => styles.dateContainer\n})({\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'flex-start'\n});\nconst DateTimePickerToolbarTimeContainer = styled('div', {\n name: 'MuiDateTimePickerToolbar',\n slot: 'TimeContainer',\n overridesResolver: (props, styles) => styles.timeContainer\n})({\n display: 'flex',\n flexDirection: 'row',\n variants: [{\n props: {\n isRtl: true\n },\n style: {\n flexDirection: 'row-reverse'\n }\n }, {\n props: {\n toolbarVariant: 'desktop',\n isLandscape: false\n },\n style: {\n gap: 9,\n marginRight: 4,\n alignSelf: 'flex-end'\n }\n }, {\n props: ({\n isLandscape,\n toolbarVariant\n }) => isLandscape && toolbarVariant !== 'desktop',\n style: {\n flexDirection: 'column'\n }\n }, {\n props: ({\n isLandscape,\n toolbarVariant,\n isRtl\n }) => isLandscape && toolbarVariant !== 'desktop' && isRtl,\n style: {\n flexDirection: 'column-reverse'\n }\n }]\n});\nconst DateTimePickerToolbarTimeDigitsContainer = styled('div', {\n name: 'MuiDateTimePickerToolbar',\n slot: 'TimeDigitsContainer',\n overridesResolver: (props, styles) => styles.timeDigitsContainer\n})({\n display: 'flex',\n variants: [{\n props: {\n isRtl: true\n },\n style: {\n flexDirection: 'row-reverse'\n }\n }, {\n props: {\n toolbarVariant: 'desktop'\n },\n style: {\n gap: 1.5\n }\n }]\n});\nconst DateTimePickerToolbarSeparator = styled(PickersToolbarText, {\n name: 'MuiDateTimePickerToolbar',\n slot: 'Separator',\n overridesResolver: (props, styles) => styles.separator\n})({\n margin: '0 4px 0 2px',\n cursor: 'default',\n variants: [{\n props: {\n toolbarVariant: 'desktop'\n },\n style: {\n margin: 0\n }\n }]\n});\n\n// Taken from TimePickerToolbar\nconst DateTimePickerToolbarAmPmSelection = styled('div', {\n name: 'MuiDateTimePickerToolbar',\n slot: 'AmPmSelection',\n overridesResolver: (props, styles) => [{\n [`.${dateTimePickerToolbarClasses.ampmLabel}`]: styles.ampmLabel\n }, {\n [`&.${dateTimePickerToolbarClasses.ampmLandscape}`]: styles.ampmLandscape\n }, styles.ampmSelection]\n})({\n display: 'flex',\n flexDirection: 'column',\n marginRight: 'auto',\n marginLeft: 12,\n [`& .${dateTimePickerToolbarClasses.ampmLabel}`]: {\n fontSize: 17\n },\n variants: [{\n props: {\n isLandscape: true\n },\n style: {\n margin: '4px 0 auto',\n flexDirection: 'row',\n justifyContent: 'space-around',\n width: '100%'\n }\n }]\n});\n\n/**\n * Demos:\n *\n * - [DateTimePicker](https://mui.com/x/react-date-pickers/date-time-picker/)\n * - [Custom components](https://mui.com/x/react-date-pickers/custom-components/)\n *\n * API:\n *\n * - [DateTimePickerToolbar API](https://mui.com/x/api/date-pickers/date-time-picker-toolbar/)\n */\nfunction DateTimePickerToolbar(inProps) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiDateTimePickerToolbar'\n });\n const {\n ampm,\n ampmInClock,\n value,\n onChange,\n view,\n isLandscape,\n onViewChange,\n toolbarFormat,\n toolbarPlaceholder = '––',\n views,\n disabled,\n readOnly,\n toolbarVariant = 'mobile',\n toolbarTitle: inToolbarTitle,\n className\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const isRtl = useRtl();\n const ownerState = _extends({}, props, {\n isRtl\n });\n const utils = useUtils();\n const {\n meridiemMode,\n handleMeridiemChange\n } = useMeridiemMode(value, ampm, onChange);\n const showAmPmControl = Boolean(ampm && !ampmInClock);\n const isDesktop = toolbarVariant === 'desktop';\n const translations = usePickersTranslations();\n const classes = useUtilityClasses(ownerState);\n const toolbarTitle = inToolbarTitle ?? translations.dateTimePickerToolbarTitle;\n const formatHours = time => ampm ? utils.format(time, 'hours12h') : utils.format(time, 'hours24h');\n const dateText = React.useMemo(() => {\n if (!value) {\n return toolbarPlaceholder;\n }\n if (toolbarFormat) {\n return utils.formatByString(value, toolbarFormat);\n }\n return utils.format(value, 'shortDate');\n }, [value, toolbarFormat, toolbarPlaceholder, utils]);\n return /*#__PURE__*/_jsxs(DateTimePickerToolbarRoot, _extends({\n isLandscape: isLandscape,\n className: clsx(classes.root, className),\n toolbarTitle: toolbarTitle\n }, other, {\n ownerState: ownerState,\n children: [/*#__PURE__*/_jsxs(DateTimePickerToolbarDateContainer, {\n className: classes.dateContainer,\n ownerState: ownerState,\n children: [views.includes('year') && /*#__PURE__*/_jsx(PickersToolbarButton, {\n tabIndex: -1,\n variant: \"subtitle1\",\n onClick: () => onViewChange('year'),\n selected: view === 'year',\n value: value ? utils.format(value, 'year') : '–'\n }), views.includes('day') && /*#__PURE__*/_jsx(PickersToolbarButton, {\n tabIndex: -1,\n variant: isDesktop ? 'h5' : 'h4',\n onClick: () => onViewChange('day'),\n selected: view === 'day',\n value: dateText\n })]\n }), /*#__PURE__*/_jsxs(DateTimePickerToolbarTimeContainer, {\n className: classes.timeContainer,\n ownerState: ownerState,\n children: [/*#__PURE__*/_jsxs(DateTimePickerToolbarTimeDigitsContainer, {\n className: classes.timeDigitsContainer,\n ownerState: ownerState,\n children: [views.includes('hours') && /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/_jsx(PickersToolbarButton, {\n variant: isDesktop ? 'h5' : 'h3',\n width: isDesktop && !isLandscape ? MULTI_SECTION_CLOCK_SECTION_WIDTH : undefined,\n onClick: () => onViewChange('hours'),\n selected: view === 'hours',\n value: value ? formatHours(value) : '--'\n }), /*#__PURE__*/_jsx(DateTimePickerToolbarSeparator, {\n variant: isDesktop ? 'h5' : 'h3',\n value: \":\",\n className: classes.separator,\n ownerState: ownerState\n }), /*#__PURE__*/_jsx(PickersToolbarButton, {\n variant: isDesktop ? 'h5' : 'h3',\n width: isDesktop && !isLandscape ? MULTI_SECTION_CLOCK_SECTION_WIDTH : undefined,\n onClick: () => onViewChange('minutes'),\n selected: view === 'minutes' || !views.includes('minutes') && view === 'hours',\n value: value ? utils.format(value, 'minutes') : '--',\n disabled: !views.includes('minutes')\n })]\n }), views.includes('seconds') && /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/_jsx(DateTimePickerToolbarSeparator, {\n variant: isDesktop ? 'h5' : 'h3',\n value: \":\",\n className: classes.separator,\n ownerState: ownerState\n }), /*#__PURE__*/_jsx(PickersToolbarButton, {\n variant: isDesktop ? 'h5' : 'h3',\n width: isDesktop && !isLandscape ? MULTI_SECTION_CLOCK_SECTION_WIDTH : undefined,\n onClick: () => onViewChange('seconds'),\n selected: view === 'seconds',\n value: value ? utils.format(value, 'seconds') : '--'\n })]\n })]\n }), showAmPmControl && !isDesktop && /*#__PURE__*/_jsxs(DateTimePickerToolbarAmPmSelection, {\n className: classes.ampmSelection,\n ownerState: ownerState,\n children: [/*#__PURE__*/_jsx(PickersToolbarButton, {\n variant: \"subtitle2\",\n selected: meridiemMode === 'am',\n typographyClassName: classes.ampmLabel,\n value: formatMeridiem(utils, 'am'),\n onClick: readOnly ? undefined : () => handleMeridiemChange('am'),\n disabled: disabled\n }), /*#__PURE__*/_jsx(PickersToolbarButton, {\n variant: \"subtitle2\",\n selected: meridiemMode === 'pm',\n typographyClassName: classes.ampmLabel,\n value: formatMeridiem(utils, 'pm'),\n onClick: readOnly ? undefined : () => handleMeridiemChange('pm'),\n disabled: disabled\n })]\n }), ampm && isDesktop && /*#__PURE__*/_jsx(PickersToolbarButton, {\n variant: \"h5\",\n onClick: () => onViewChange('meridiem'),\n selected: view === 'meridiem',\n value: value && meridiemMode ? formatMeridiem(utils, meridiemMode) : '--',\n width: MULTI_SECTION_CLOCK_SECTION_WIDTH\n })]\n })]\n }));\n}\nprocess.env.NODE_ENV !== \"production\" ? DateTimePickerToolbar.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n ampm: PropTypes.bool,\n ampmInClock: PropTypes.bool,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n disabled: PropTypes.bool,\n /**\n * If `true`, show the toolbar even in desktop mode.\n * @default `true` for Desktop, `false` for Mobile.\n */\n hidden: PropTypes.bool,\n isLandscape: PropTypes.bool.isRequired,\n onChange: PropTypes.func.isRequired,\n /**\n * Callback called when a toolbar is clicked\n * @template TView\n * @param {TView} view The view to open\n */\n onViewChange: PropTypes.func.isRequired,\n readOnly: PropTypes.bool,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n titleId: PropTypes.string,\n /**\n * Toolbar date format.\n */\n toolbarFormat: PropTypes.string,\n /**\n * Toolbar value placeholder—it is displayed when the value is empty.\n * @default \"––\"\n */\n toolbarPlaceholder: PropTypes.node,\n /**\n * If provided, it will be used instead of `dateTimePickerToolbarTitle` from localization.\n */\n toolbarTitle: PropTypes.node,\n toolbarVariant: PropTypes.oneOf(['desktop', 'mobile']),\n value: PropTypes.object,\n /**\n * Currently visible picker view.\n */\n view: PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']).isRequired).isRequired\n} : void 0;\nexport { DateTimePickerToolbar };","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport { useThemeProps } from '@mui/material/styles';\nimport { useDefaultDates, useUtils } from \"../internals/hooks/useUtils.js\";\nimport { applyDefaultDate } from \"../internals/utils/date-utils.js\";\nimport { DateTimePickerTabs } from \"./DateTimePickerTabs.js\";\nimport { DateTimePickerToolbar } from \"./DateTimePickerToolbar.js\";\nimport { applyDefaultViewProps } from \"../internals/utils/views.js\";\nexport function useDateTimePickerDefaultizedProps(props, name) {\n const utils = useUtils();\n const defaultDates = useDefaultDates();\n const themeProps = useThemeProps({\n props,\n name\n });\n const ampm = themeProps.ampm ?? utils.is12HourCycleInCurrentLocale();\n const localeText = React.useMemo(() => {\n if (themeProps.localeText?.toolbarTitle == null) {\n return themeProps.localeText;\n }\n return _extends({}, themeProps.localeText, {\n dateTimePickerToolbarTitle: themeProps.localeText.toolbarTitle\n });\n }, [themeProps.localeText]);\n return _extends({}, themeProps, applyDefaultViewProps({\n views: themeProps.views,\n openTo: themeProps.openTo,\n defaultViews: ['year', 'day', 'hours', 'minutes'],\n defaultOpenTo: 'day'\n }), {\n ampm,\n localeText,\n orientation: themeProps.orientation ?? 'portrait',\n // TODO: Remove from public API\n disableIgnoringDatePartForTimeValidation: themeProps.disableIgnoringDatePartForTimeValidation ?? Boolean(themeProps.minDateTime || themeProps.maxDateTime ||\n // allow time clock to correctly check time validity: https://github.com/mui/mui-x/issues/8520\n themeProps.disablePast || themeProps.disableFuture),\n disableFuture: themeProps.disableFuture ?? false,\n disablePast: themeProps.disablePast ?? false,\n minDate: applyDefaultDate(utils, themeProps.minDateTime ?? themeProps.minDate, defaultDates.minDate),\n maxDate: applyDefaultDate(utils, themeProps.maxDateTime ?? themeProps.maxDate, defaultDates.maxDate),\n minTime: themeProps.minDateTime ?? themeProps.minTime,\n maxTime: themeProps.maxDateTime ?? themeProps.maxTime,\n slots: _extends({\n toolbar: DateTimePickerToolbar,\n tabs: DateTimePickerTabs\n }, themeProps.slots),\n slotProps: _extends({}, themeProps.slotProps, {\n toolbar: _extends({\n ampm\n }, themeProps.slotProps?.toolbar)\n })\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport Divider from '@mui/material/Divider';\nimport { PickersLayoutContentWrapper, PickersLayoutRoot, pickersLayoutClasses, usePickerLayout } from \"../PickersLayout/index.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\n/**\n * @ignore - internal component.\n */\nconst DesktopDateTimePickerLayout = /*#__PURE__*/React.forwardRef(function DesktopDateTimePickerLayout(props, ref) {\n const isRtl = useRtl();\n const {\n toolbar,\n tabs,\n content,\n actionBar,\n shortcuts\n } = usePickerLayout(props);\n const {\n sx,\n className,\n isLandscape,\n classes\n } = props;\n const isActionBarVisible = actionBar && (actionBar.props.actions?.length ?? 0) > 0;\n const ownerState = _extends({}, props, {\n isRtl\n });\n return /*#__PURE__*/_jsxs(PickersLayoutRoot, {\n ref: ref,\n className: clsx(pickersLayoutClasses.root, classes?.root, className),\n sx: [{\n [`& .${pickersLayoutClasses.tabs}`]: {\n gridRow: 4,\n gridColumn: '1 / 4'\n },\n [`& .${pickersLayoutClasses.actionBar}`]: {\n gridRow: 5\n }\n }, ...(Array.isArray(sx) ? sx : [sx])],\n ownerState: ownerState,\n children: [isLandscape ? shortcuts : toolbar, isLandscape ? toolbar : shortcuts, /*#__PURE__*/_jsxs(PickersLayoutContentWrapper, {\n className: clsx(pickersLayoutClasses.contentWrapper, classes?.contentWrapper),\n sx: {\n display: 'grid'\n },\n children: [content, tabs, isActionBarVisible && /*#__PURE__*/_jsx(Divider, {\n sx: {\n gridRow: 3,\n gridColumn: '1 / 4'\n }\n })]\n }), actionBar]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? DesktopDateTimePickerLayout.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n className: PropTypes.string,\n disabled: PropTypes.bool,\n isLandscape: PropTypes.bool.isRequired,\n /**\n * `true` if the application is in right-to-left direction.\n */\n isRtl: PropTypes.bool.isRequired,\n isValid: PropTypes.func.isRequired,\n onAccept: PropTypes.func.isRequired,\n onCancel: PropTypes.func.isRequired,\n onChange: PropTypes.func.isRequired,\n onClear: PropTypes.func.isRequired,\n onClose: PropTypes.func.isRequired,\n onDismiss: PropTypes.func.isRequired,\n onOpen: PropTypes.func.isRequired,\n onSelectShortcut: PropTypes.func.isRequired,\n onSetToday: PropTypes.func.isRequired,\n onViewChange: PropTypes.func.isRequired,\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n value: PropTypes.any,\n view: PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']),\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']).isRequired).isRequired,\n wrapperVariant: PropTypes.oneOf(['desktop', 'mobile'])\n} : void 0;\nexport { DesktopDateTimePickerLayout };","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"openTo\", \"focusedView\", \"timeViewsCount\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport resolveComponentProps from '@mui/utils/resolveComponentProps';\nimport { refType } from '@mui/utils';\nimport Divider from '@mui/material/Divider';\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { DateTimeField } from \"../DateTimeField/index.js\";\nimport { useDateTimePickerDefaultizedProps } from \"../DateTimePicker/shared.js\";\nimport { renderDateViewCalendar } from \"../dateViewRenderers/dateViewRenderers.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { validateDateTime, extractValidationProps } from \"../validation/index.js\";\nimport { CalendarIcon } from \"../icons/index.js\";\nimport { useDesktopPicker } from \"../internals/hooks/useDesktopPicker/index.js\";\nimport { resolveDateTimeFormat, resolveTimeViewsResponse } from \"../internals/utils/date-time-utils.js\";\nimport { renderDigitalClockTimeView, renderMultiSectionDigitalClockTimeView } from \"../timeViewRenderers/index.js\";\nimport { multiSectionDigitalClockClasses, multiSectionDigitalClockSectionClasses } from \"../MultiSectionDigitalClock/index.js\";\nimport { digitalClockClasses } from \"../DigitalClock/index.js\";\nimport { DesktopDateTimePickerLayout } from \"./DesktopDateTimePickerLayout.js\";\nimport { VIEW_HEIGHT } from \"../internals/constants/dimensions.js\";\nimport { isInternalTimeView } from \"../internals/utils/time-utils.js\";\nimport { isDatePickerView } from \"../internals/utils/date-utils.js\";\nimport { buildGetOpenDialogAriaText } from \"../locales/utils/getPickersLocalization.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst rendererInterceptor = function rendererInterceptor(inViewRenderers, popperView, rendererProps) {\n const {\n openTo,\n focusedView,\n timeViewsCount\n } = rendererProps,\n otherProps = _objectWithoutPropertiesLoose(rendererProps, _excluded);\n const finalProps = _extends({}, otherProps, {\n focusedView: null,\n sx: [{\n [`&.${multiSectionDigitalClockClasses.root}`]: {\n borderBottom: 0\n },\n [`&.${multiSectionDigitalClockClasses.root}, .${multiSectionDigitalClockSectionClasses.root}, &.${digitalClockClasses.root}`]: {\n maxHeight: VIEW_HEIGHT\n }\n }]\n });\n const isTimeViewActive = isInternalTimeView(popperView);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [inViewRenderers[!isTimeViewActive ? popperView : 'day']?.(_extends({}, rendererProps, {\n view: !isTimeViewActive ? popperView : 'day',\n focusedView: focusedView && isDatePickerView(focusedView) ? focusedView : null,\n views: rendererProps.views.filter(isDatePickerView),\n sx: [{\n gridColumn: 1\n }, ...finalProps.sx]\n })), timeViewsCount > 0 && /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/_jsx(Divider, {\n orientation: \"vertical\",\n sx: {\n gridColumn: 2\n }\n }), inViewRenderers[isTimeViewActive ? popperView : 'hours']?.(_extends({}, finalProps, {\n view: isTimeViewActive ? popperView : 'hours',\n focusedView: focusedView && isInternalTimeView(focusedView) ? focusedView : null,\n openTo: isInternalTimeView(openTo) ? openTo : 'hours',\n views: rendererProps.views.filter(isInternalTimeView),\n sx: [{\n gridColumn: 3\n }, ...finalProps.sx]\n }))]\n })]\n });\n};\n/**\n * Demos:\n *\n * - [DateTimePicker](https://mui.com/x/react-date-pickers/date-time-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [DesktopDateTimePicker API](https://mui.com/x/api/date-pickers/desktop-date-time-picker/)\n */\nconst DesktopDateTimePicker = /*#__PURE__*/React.forwardRef(function DesktopDateTimePicker(inProps, ref) {\n const translations = usePickersTranslations();\n const utils = useUtils();\n\n // Props with the default values common to all date time pickers\n const defaultizedProps = useDateTimePickerDefaultizedProps(inProps, 'MuiDesktopDateTimePicker');\n const {\n shouldRenderTimeInASingleColumn,\n thresholdToRenderTimeInASingleColumn,\n views: resolvedViews,\n timeSteps\n } = resolveTimeViewsResponse(defaultizedProps);\n const renderTimeView = shouldRenderTimeInASingleColumn ? renderDigitalClockTimeView : renderMultiSectionDigitalClockTimeView;\n const viewRenderers = _extends({\n day: renderDateViewCalendar,\n month: renderDateViewCalendar,\n year: renderDateViewCalendar,\n hours: renderTimeView,\n minutes: renderTimeView,\n seconds: renderTimeView,\n meridiem: renderTimeView\n }, defaultizedProps.viewRenderers);\n const ampmInClock = defaultizedProps.ampmInClock ?? true;\n // Need to avoid adding the `meridiem` view when unexpected renderer is specified\n const shouldHoursRendererContainMeridiemView = viewRenderers.hours?.name === renderMultiSectionDigitalClockTimeView.name;\n const views = !shouldHoursRendererContainMeridiemView ? resolvedViews.filter(view => view !== 'meridiem') : resolvedViews;\n const actionBarActions = shouldRenderTimeInASingleColumn ? [] : ['accept'];\n\n // Props with the default values specific to the desktop variant\n const props = _extends({}, defaultizedProps, {\n viewRenderers,\n format: resolveDateTimeFormat(utils, defaultizedProps),\n views,\n yearsPerRow: defaultizedProps.yearsPerRow ?? 4,\n ampmInClock,\n timeSteps,\n thresholdToRenderTimeInASingleColumn,\n shouldRenderTimeInASingleColumn,\n slots: _extends({\n field: DateTimeField,\n layout: DesktopDateTimePickerLayout,\n openPickerIcon: CalendarIcon\n }, defaultizedProps.slots),\n slotProps: _extends({}, defaultizedProps.slotProps, {\n field: ownerState => _extends({}, resolveComponentProps(defaultizedProps.slotProps?.field, ownerState), extractValidationProps(defaultizedProps), {\n ref\n }),\n toolbar: _extends({\n hidden: true,\n ampmInClock,\n toolbarVariant: 'desktop'\n }, defaultizedProps.slotProps?.toolbar),\n tabs: _extends({\n hidden: true\n }, defaultizedProps.slotProps?.tabs),\n actionBar: ownerState => _extends({\n actions: actionBarActions\n }, resolveComponentProps(defaultizedProps.slotProps?.actionBar, ownerState))\n })\n });\n const {\n renderPicker\n } = useDesktopPicker({\n props,\n valueManager: singleItemValueManager,\n valueType: 'date-time',\n getOpenDialogAriaText: buildGetOpenDialogAriaText({\n utils,\n formatKey: 'fullDate',\n contextTranslation: translations.openDatePickerDialogue,\n propsTranslation: props.localeText?.openDatePickerDialogue\n }),\n validator: validateDateTime,\n rendererInterceptor\n });\n return renderPicker();\n});\nDesktopDateTimePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * Display ampm controls under the clock (instead of in the toolbar).\n * @default true on desktop, false on mobile\n */\n ampmInClock: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, the popover or modal will close after submitting the full date.\n * @default `true` for desktop, `false` for mobile (based on the chosen wrapper and `desktopModeMediaQuery` prop).\n */\n closeOnSelect: PropTypes.bool,\n /**\n * Formats the day of week displayed in the calendar header.\n * @param {TDate} date The date of the day of week provided by the adapter.\n * @returns {string} The name to display.\n * @default (date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()\n */\n dayOfWeekFormatter: PropTypes.func,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, the open picker button will not be rendered (renders only the field).\n * @default false\n */\n disableOpenPicker: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * If `true`, the week number will be display in the calendar.\n */\n displayWeekNumber: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.any,\n /**\n * The day view will show as many weeks as needed after the end of the current month to match this value.\n * Put it to 6 to have a fixed number of weeks in Gregorian calendars\n */\n fixedWeekNumber: PropTypes.number,\n /**\n * Format of the date when rendered in the input(s).\n * Defaults to localized format based on the used `views`.\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * If `true`, calls `renderLoading` instead of rendering the day calendar.\n * Can be used to preload information and show it in calendar.\n * @default false\n */\n loading: PropTypes.bool,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Maximal selectable moment of time with binding to date, to set max time in each day use `maxTime`.\n */\n maxDateTime: PropTypes.object,\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Minimal selectable moment of time with binding to date, to set min time in each day use `minTime`.\n */\n minDateTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Months rendered per row.\n * @default 3\n */\n monthsPerRow: PropTypes.oneOf([3, 4]),\n /**\n * Name attribute used by the `input` element in the Field.\n */\n name: PropTypes.string,\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be closed.\n * Use in controlled mode (see `open`).\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired on month change.\n * @template TDate\n * @param {TDate} month The new month.\n */\n onMonthChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be opened.\n * Use in controlled mode (see `open`).\n */\n onOpen: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Callback fired on year change.\n * @template TDate\n * @param {TDate} year The new year.\n */\n onYearChange: PropTypes.func,\n /**\n * Control the popup or dialog open state.\n * @default false\n */\n open: PropTypes.bool,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * Component displaying when passed `loading` true.\n * @returns {React.ReactNode} The node to render when loading.\n * @default () => ...\n */\n renderLoading: PropTypes.func,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, days outside the current month are rendered:\n *\n * - if `fixedWeekNumber` is defined, renders days to have the weeks requested.\n *\n * - if `fixedWeekNumber` is not defined, renders day to fill the first and last week of the current month.\n *\n * - ignored if `calendars` equals more than `1` on range pickers.\n * @default false\n */\n showDaysOutsideCurrentMonth: PropTypes.bool,\n /**\n * If `true`, disabled digital clock items will not be rendered.\n * @default false\n */\n skipDisabled: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Amount of time options below or at which the single column time renderer is used.\n * @default 24\n */\n thresholdToRenderTimeInASingleColumn: PropTypes.number,\n /**\n * The time steps between two time unit options.\n * For example, if `timeStep.minutes = 8`, then the available minute options will be `[0, 8, 16, 24, 32, 40, 48, 56]`.\n * When single column time renderer is used, only `timeStep.minutes` will be used.\n * @default{ hours: 1, minutes: 5, seconds: 5 }\n */\n timeSteps: PropTypes.shape({\n hours: PropTypes.number,\n minutes: PropTypes.number,\n seconds: PropTypes.number\n }),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n day: PropTypes.func,\n hours: PropTypes.func,\n meridiem: PropTypes.func,\n minutes: PropTypes.func,\n month: PropTypes.func,\n seconds: PropTypes.func,\n year: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'hours', 'minutes', 'month', 'seconds', 'year']).isRequired),\n /**\n * Years are displayed in ascending (chronological) order by default.\n * If `desc`, years are displayed in descending order.\n * @default 'asc'\n */\n yearsOrder: PropTypes.oneOf(['asc', 'desc']),\n /**\n * Years rendered per row.\n * @default 4\n */\n yearsPerRow: PropTypes.oneOf([3, 4])\n};\nexport { DesktopDateTimePicker };","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport resolveComponentProps from '@mui/utils/resolveComponentProps';\nimport { refType } from '@mui/utils';\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { DateTimeField } from \"../DateTimeField/index.js\";\nimport { useDateTimePickerDefaultizedProps } from \"../DateTimePicker/shared.js\";\nimport { usePickersTranslations } from \"../hooks/usePickersTranslations.js\";\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { extractValidationProps, validateDateTime } from \"../validation/index.js\";\nimport { useMobilePicker } from \"../internals/hooks/useMobilePicker/index.js\";\nimport { renderDateViewCalendar } from \"../dateViewRenderers/index.js\";\nimport { renderTimeViewClock } from \"../timeViewRenderers/index.js\";\nimport { resolveDateTimeFormat } from \"../internals/utils/date-time-utils.js\";\nimport { buildGetOpenDialogAriaText } from \"../locales/utils/getPickersLocalization.js\";\n/**\n * Demos:\n *\n * - [DateTimePicker](https://mui.com/x/react-date-pickers/date-time-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [MobileDateTimePicker API](https://mui.com/x/api/date-pickers/mobile-date-time-picker/)\n */\nconst MobileDateTimePicker = /*#__PURE__*/React.forwardRef(function MobileDateTimePicker(inProps, ref) {\n const translations = usePickersTranslations();\n const utils = useUtils();\n\n // Props with the default values common to all date time pickers\n const defaultizedProps = useDateTimePickerDefaultizedProps(inProps, 'MuiMobileDateTimePicker');\n const viewRenderers = _extends({\n day: renderDateViewCalendar,\n month: renderDateViewCalendar,\n year: renderDateViewCalendar,\n hours: renderTimeViewClock,\n minutes: renderTimeViewClock,\n seconds: renderTimeViewClock\n }, defaultizedProps.viewRenderers);\n const ampmInClock = defaultizedProps.ampmInClock ?? false;\n\n // Props with the default values specific to the mobile variant\n const props = _extends({}, defaultizedProps, {\n viewRenderers,\n format: resolveDateTimeFormat(utils, defaultizedProps),\n ampmInClock,\n slots: _extends({\n field: DateTimeField\n }, defaultizedProps.slots),\n slotProps: _extends({}, defaultizedProps.slotProps, {\n field: ownerState => _extends({}, resolveComponentProps(defaultizedProps.slotProps?.field, ownerState), extractValidationProps(defaultizedProps), {\n ref\n }),\n toolbar: _extends({\n hidden: false,\n ampmInClock\n }, defaultizedProps.slotProps?.toolbar),\n tabs: _extends({\n hidden: false\n }, defaultizedProps.slotProps?.tabs)\n })\n });\n const {\n renderPicker\n } = useMobilePicker({\n props,\n valueManager: singleItemValueManager,\n valueType: 'date-time',\n getOpenDialogAriaText: buildGetOpenDialogAriaText({\n utils,\n formatKey: 'fullDate',\n contextTranslation: translations.openDatePickerDialogue,\n propsTranslation: props.localeText?.openDatePickerDialogue\n }),\n validator: validateDateTime\n });\n return renderPicker();\n});\nMobileDateTimePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * Display ampm controls under the clock (instead of in the toolbar).\n * @default true on desktop, false on mobile\n */\n ampmInClock: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, the popover or modal will close after submitting the full date.\n * @default `true` for desktop, `false` for mobile (based on the chosen wrapper and `desktopModeMediaQuery` prop).\n */\n closeOnSelect: PropTypes.bool,\n /**\n * Formats the day of week displayed in the calendar header.\n * @param {TDate} date The date of the day of week provided by the adapter.\n * @returns {string} The name to display.\n * @default (date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()\n */\n dayOfWeekFormatter: PropTypes.func,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, the open picker button will not be rendered (renders only the field).\n * @default false\n */\n disableOpenPicker: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * If `true`, the week number will be display in the calendar.\n */\n displayWeekNumber: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.any,\n /**\n * The day view will show as many weeks as needed after the end of the current month to match this value.\n * Put it to 6 to have a fixed number of weeks in Gregorian calendars\n */\n fixedWeekNumber: PropTypes.number,\n /**\n * Format of the date when rendered in the input(s).\n * Defaults to localized format based on the used `views`.\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * If `true`, calls `renderLoading` instead of rendering the day calendar.\n * Can be used to preload information and show it in calendar.\n * @default false\n */\n loading: PropTypes.bool,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Maximal selectable moment of time with binding to date, to set max time in each day use `maxTime`.\n */\n maxDateTime: PropTypes.object,\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Minimal selectable moment of time with binding to date, to set min time in each day use `minTime`.\n */\n minDateTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Months rendered per row.\n * @default 3\n */\n monthsPerRow: PropTypes.oneOf([3, 4]),\n /**\n * Name attribute used by the `input` element in the Field.\n */\n name: PropTypes.string,\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be closed.\n * Use in controlled mode (see `open`).\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired on month change.\n * @template TDate\n * @param {TDate} month The new month.\n */\n onMonthChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be opened.\n * Use in controlled mode (see `open`).\n */\n onOpen: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Callback fired on year change.\n * @template TDate\n * @param {TDate} year The new year.\n */\n onYearChange: PropTypes.func,\n /**\n * Control the popup or dialog open state.\n * @default false\n */\n open: PropTypes.bool,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['day', 'hours', 'minutes', 'month', 'seconds', 'year']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * Component displaying when passed `loading` true.\n * @returns {React.ReactNode} The node to render when loading.\n * @default () => ...\n */\n renderLoading: PropTypes.func,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, days outside the current month are rendered:\n *\n * - if `fixedWeekNumber` is defined, renders days to have the weeks requested.\n *\n * - if `fixedWeekNumber` is not defined, renders day to fill the first and last week of the current month.\n *\n * - ignored if `calendars` equals more than `1` on range pickers.\n * @default false\n */\n showDaysOutsideCurrentMonth: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['day', 'hours', 'minutes', 'month', 'seconds', 'year']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n day: PropTypes.func,\n hours: PropTypes.func,\n minutes: PropTypes.func,\n month: PropTypes.func,\n seconds: PropTypes.func,\n year: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'hours', 'minutes', 'month', 'seconds', 'year']).isRequired),\n /**\n * Years are displayed in ascending (chronological) order by default.\n * If `desc`, years are displayed in descending order.\n * @default 'asc'\n */\n yearsOrder: PropTypes.oneOf(['asc', 'desc']),\n /**\n * Years rendered per row.\n * @default 3\n */\n yearsPerRow: PropTypes.oneOf([3, 4])\n};\nexport { MobileDateTimePicker };","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"desktopModeMediaQuery\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport useMediaQuery from '@mui/material/useMediaQuery';\nimport { useThemeProps } from '@mui/material/styles';\nimport { refType } from '@mui/utils';\nimport { DesktopDateTimePicker } from \"../DesktopDateTimePicker/index.js\";\nimport { MobileDateTimePicker } from \"../MobileDateTimePicker/index.js\";\nimport { DEFAULT_DESKTOP_MODE_MEDIA_QUERY } from \"../internals/utils/utils.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\n/**\n * Demos:\n *\n * - [DateTimePicker](https://mui.com/x/react-date-pickers/date-time-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [DateTimePicker API](https://mui.com/x/api/date-pickers/date-time-picker/)\n */\nconst DateTimePicker = /*#__PURE__*/React.forwardRef(function DateTimePicker(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiDateTimePicker'\n });\n const {\n desktopModeMediaQuery = DEFAULT_DESKTOP_MODE_MEDIA_QUERY\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // defaults to `true` in environments where `window.matchMedia` would not be available (i.e. test/jsdom)\n const isDesktop = useMediaQuery(desktopModeMediaQuery, {\n defaultMatches: true\n });\n if (isDesktop) {\n return /*#__PURE__*/_jsx(DesktopDateTimePicker, _extends({\n ref: ref\n }, other));\n }\n return /*#__PURE__*/_jsx(MobileDateTimePicker, _extends({\n ref: ref\n }, other));\n});\nprocess.env.NODE_ENV !== \"production\" ? DateTimePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * Display ampm controls under the clock (instead of in the toolbar).\n * @default true on desktop, false on mobile\n */\n ampmInClock: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * If `true`, the popover or modal will close after submitting the full date.\n * @default `true` for desktop, `false` for mobile (based on the chosen wrapper and `desktopModeMediaQuery` prop).\n */\n closeOnSelect: PropTypes.bool,\n /**\n * Formats the day of week displayed in the calendar header.\n * @param {TDate} date The date of the day of week provided by the adapter.\n * @returns {string} The name to display.\n * @default (date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()\n */\n dayOfWeekFormatter: PropTypes.func,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * CSS media query when `Mobile` mode will be changed to `Desktop`.\n * @default '@media (pointer: fine)'\n * @example '@media (min-width: 720px)' or theme.breakpoints.up(\"sm\")\n */\n desktopModeMediaQuery: PropTypes.string,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, the open picker button will not be rendered (renders only the field).\n * @default false\n */\n disableOpenPicker: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * If `true`, the week number will be display in the calendar.\n */\n displayWeekNumber: PropTypes.bool,\n /**\n * @default false\n */\n enableAccessibleFieldDOMStructure: PropTypes.any,\n /**\n * The day view will show as many weeks as needed after the end of the current month to match this value.\n * Put it to 6 to have a fixed number of weeks in Gregorian calendars\n */\n fixedWeekNumber: PropTypes.number,\n /**\n * Format of the date when rendered in the input(s).\n * Defaults to localized format based on the used `views`.\n */\n format: PropTypes.string,\n /**\n * Density of the format when rendered in the input.\n * Setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character.\n * @default \"dense\"\n */\n formatDensity: PropTypes.oneOf(['dense', 'spacious']),\n /**\n * Pass a ref to the `input` element.\n */\n inputRef: refType,\n /**\n * The label content.\n */\n label: PropTypes.node,\n /**\n * If `true`, calls `renderLoading` instead of rendering the day calendar.\n * Can be used to preload information and show it in calendar.\n * @default false\n */\n loading: PropTypes.bool,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Maximal selectable moment of time with binding to date, to set max time in each day use `maxTime`.\n */\n maxDateTime: PropTypes.object,\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Minimal selectable moment of time with binding to date, to set min time in each day use `minTime`.\n */\n minDateTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Months rendered per row.\n * @default 3\n */\n monthsPerRow: PropTypes.oneOf([3, 4]),\n /**\n * Name attribute used by the `input` element in the Field.\n */\n name: PropTypes.string,\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be closed.\n * Use in controlled mode (see `open`).\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired on month change.\n * @template TDate\n * @param {TDate} month The new month.\n */\n onMonthChange: PropTypes.func,\n /**\n * Callback fired when the popup requests to be opened.\n * Use in controlled mode (see `open`).\n */\n onOpen: PropTypes.func,\n /**\n * Callback fired when the selected sections change.\n * @param {FieldSelectedSections} newValue The new selected sections.\n */\n onSelectedSectionsChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Callback fired on year change.\n * @template TDate\n * @param {TDate} year The new year.\n */\n onYearChange: PropTypes.func,\n /**\n * Control the popup or dialog open state.\n * @default false\n */\n open: PropTypes.bool,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * Component displaying when passed `loading` true.\n * @returns {React.ReactNode} The node to render when loading.\n * @default () => ...\n */\n renderLoading: PropTypes.func,\n /**\n * The currently selected sections.\n * This prop accepts four formats:\n * 1. If a number is provided, the section at this index will be selected.\n * 2. If a string of type `FieldSectionType` is provided, the first section with that name will be selected.\n * 3. If `\"all\"` is provided, all the sections will be selected.\n * 4. If `null` is provided, no section will be selected.\n * If not provided, the selected sections will be handled internally.\n */\n selectedSections: PropTypes.oneOfType([PropTypes.oneOf(['all', 'day', 'empty', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'weekDay', 'year']), PropTypes.number]),\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, days outside the current month are rendered:\n *\n * - if `fixedWeekNumber` is defined, renders days to have the weeks requested.\n *\n * - if `fixedWeekNumber` is not defined, renders day to fill the first and last week of the current month.\n *\n * - ignored if `calendars` equals more than `1` on range pickers.\n * @default false\n */\n showDaysOutsideCurrentMonth: PropTypes.bool,\n /**\n * If `true`, disabled digital clock items will not be rendered.\n * @default false\n */\n skipDisabled: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Amount of time options below or at which the single column time renderer is used.\n * @default 24\n */\n thresholdToRenderTimeInASingleColumn: PropTypes.number,\n /**\n * The time steps between two time unit options.\n * For example, if `timeStep.minutes = 8`, then the available minute options will be `[0, 8, 16, 24, 32, 40, 48, 56]`.\n * When single column time renderer is used, only `timeStep.minutes` will be used.\n * @default{ hours: 1, minutes: 5, seconds: 5 }\n */\n timeSteps: PropTypes.shape({\n hours: PropTypes.number,\n minutes: PropTypes.number,\n seconds: PropTypes.number\n }),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['day', 'hours', 'meridiem', 'minutes', 'month', 'seconds', 'year']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n day: PropTypes.func,\n hours: PropTypes.func,\n meridiem: PropTypes.func,\n minutes: PropTypes.func,\n month: PropTypes.func,\n seconds: PropTypes.func,\n year: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'hours', 'minutes', 'month', 'seconds', 'year']).isRequired),\n /**\n * Years are displayed in ascending (chronological) order by default.\n * If `desc`, years are displayed in descending order.\n * @default 'asc'\n */\n yearsOrder: PropTypes.oneOf(['asc', 'desc']),\n /**\n * Years rendered per row.\n * @default 4 on desktop, 3 on mobile\n */\n yearsPerRow: PropTypes.oneOf([3, 4])\n} : void 0;\nexport { DateTimePicker };","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { useDateTimePickerDefaultizedProps } from \"../DateTimePicker/shared.js\";\nimport { renderTimeViewClock } from \"../timeViewRenderers/index.js\";\nimport { renderDateViewCalendar } from \"../dateViewRenderers/index.js\";\nimport { singleItemValueManager } from \"../internals/utils/valueManagers.js\";\nimport { useStaticPicker } from \"../internals/hooks/useStaticPicker/index.js\";\nimport { validateDateTime } from \"../validation/index.js\";\n/**\n * Demos:\n *\n * - [DateTimePicker](https://mui.com/x/react-date-pickers/date-time-picker/)\n * - [Validation](https://mui.com/x/react-date-pickers/validation/)\n *\n * API:\n *\n * - [StaticDateTimePicker API](https://mui.com/x/api/date-pickers/static-date-time-picker/)\n */\nconst StaticDateTimePicker = /*#__PURE__*/React.forwardRef(function StaticDateTimePicker(inProps, ref) {\n const defaultizedProps = useDateTimePickerDefaultizedProps(inProps, 'MuiStaticDateTimePicker');\n const displayStaticWrapperAs = defaultizedProps.displayStaticWrapperAs ?? 'mobile';\n const ampmInClock = defaultizedProps.ampmInClock ?? displayStaticWrapperAs === 'desktop';\n const viewRenderers = _extends({\n day: renderDateViewCalendar,\n month: renderDateViewCalendar,\n year: renderDateViewCalendar,\n hours: renderTimeViewClock,\n minutes: renderTimeViewClock,\n seconds: renderTimeViewClock\n }, defaultizedProps.viewRenderers);\n\n // Props with the default values specific to the static variant\n const props = _extends({}, defaultizedProps, {\n viewRenderers,\n displayStaticWrapperAs,\n ampmInClock,\n yearsPerRow: defaultizedProps.yearsPerRow ?? (displayStaticWrapperAs === 'mobile' ? 3 : 4),\n slotProps: _extends({}, defaultizedProps.slotProps, {\n tabs: _extends({\n hidden: displayStaticWrapperAs === 'desktop'\n }, defaultizedProps.slotProps?.tabs),\n toolbar: _extends({\n hidden: displayStaticWrapperAs === 'desktop',\n ampmInClock\n }, defaultizedProps.slotProps?.toolbar)\n })\n });\n const {\n renderPicker\n } = useStaticPicker({\n props,\n valueManager: singleItemValueManager,\n valueType: 'date-time',\n validator: validateDateTime,\n ref\n });\n return renderPicker();\n});\nStaticDateTimePicker.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the TypeScript types and run \"pnpm proptypes\" |\n // ----------------------------------------------------------------------\n /**\n * 12h/24h view for hour selection clock.\n * @default utils.is12HourCycleInCurrentLocale()\n */\n ampm: PropTypes.bool,\n /**\n * Display ampm controls under the clock (instead of in the toolbar).\n * @default true on desktop, false on mobile\n */\n ampmInClock: PropTypes.bool,\n /**\n * If `true`, the main element is focused during the first mount.\n * This main element is:\n * - the element chosen by the visible view if any (i.e: the selected day on the `day` view).\n * - the `input` element if there is a field rendered.\n */\n autoFocus: PropTypes.bool,\n className: PropTypes.string,\n /**\n * Formats the day of week displayed in the calendar header.\n * @param {TDate} date The date of the day of week provided by the adapter.\n * @returns {string} The name to display.\n * @default (date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()\n */\n dayOfWeekFormatter: PropTypes.func,\n /**\n * The default value.\n * Used when the component is not controlled.\n */\n defaultValue: PropTypes.object,\n /**\n * If `true`, the picker and text field are disabled.\n * @default false\n */\n disabled: PropTypes.bool,\n /**\n * If `true`, disable values after the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disableFuture: PropTypes.bool,\n /**\n * If `true`, today's date is rendering without highlighting with circle.\n * @default false\n */\n disableHighlightToday: PropTypes.bool,\n /**\n * Do not ignore date part when validating min/max time.\n * @default false\n */\n disableIgnoringDatePartForTimeValidation: PropTypes.bool,\n /**\n * If `true`, disable values before the current date for date components, time for time components and both for date time components.\n * @default false\n */\n disablePast: PropTypes.bool,\n /**\n * Force static wrapper inner components to be rendered in mobile or desktop mode.\n * @default \"mobile\"\n */\n displayStaticWrapperAs: PropTypes.oneOf(['desktop', 'mobile']),\n /**\n * If `true`, the week number will be display in the calendar.\n */\n displayWeekNumber: PropTypes.bool,\n /**\n * The day view will show as many weeks as needed after the end of the current month to match this value.\n * Put it to 6 to have a fixed number of weeks in Gregorian calendars\n */\n fixedWeekNumber: PropTypes.number,\n /**\n * If `true`, calls `renderLoading` instead of rendering the day calendar.\n * Can be used to preload information and show it in calendar.\n * @default false\n */\n loading: PropTypes.bool,\n /**\n * Locale for components texts.\n * Allows overriding texts coming from `LocalizationProvider` and `theme`.\n */\n localeText: PropTypes.object,\n /**\n * Maximal selectable date.\n * @default 2099-12-31\n */\n maxDate: PropTypes.object,\n /**\n * Maximal selectable moment of time with binding to date, to set max time in each day use `maxTime`.\n */\n maxDateTime: PropTypes.object,\n /**\n * Maximal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n maxTime: PropTypes.object,\n /**\n * Minimal selectable date.\n * @default 1900-01-01\n */\n minDate: PropTypes.object,\n /**\n * Minimal selectable moment of time with binding to date, to set min time in each day use `minTime`.\n */\n minDateTime: PropTypes.object,\n /**\n * Minimal selectable time.\n * The date part of the object will be ignored unless `props.disableIgnoringDatePartForTimeValidation === true`.\n */\n minTime: PropTypes.object,\n /**\n * Step over minutes.\n * @default 1\n */\n minutesStep: PropTypes.number,\n /**\n * Months rendered per row.\n * @default 3\n */\n monthsPerRow: PropTypes.oneOf([3, 4]),\n /**\n * Callback fired when the value is accepted.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The value that was just accepted.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onAccept: PropTypes.func,\n /**\n * Callback fired when the value changes.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @param {TValue} value The new value.\n * @param {FieldChangeHandlerContext} context The context containing the validation result of the current value.\n */\n onChange: PropTypes.func,\n /**\n * Callback fired when component requests to be closed.\n * Can be fired when selecting (by default on `desktop` mode) or clearing a value.\n * @deprecated Please avoid using as it will be removed in next major version.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the error associated with the current value changes.\n * When a validation error is detected, the `error` parameter contains a non-null value.\n * This can be used to render an appropriate form error.\n * @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.\n * @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.\n * @param {TError} error The reason why the current value is not valid.\n * @param {TValue} value The value associated with the error.\n */\n onError: PropTypes.func,\n /**\n * Callback fired on month change.\n * @template TDate\n * @param {TDate} month The new month.\n */\n onMonthChange: PropTypes.func,\n /**\n * Callback fired on view change.\n * @template TView\n * @param {TView} view The new view.\n */\n onViewChange: PropTypes.func,\n /**\n * Callback fired on year change.\n * @template TDate\n * @param {TDate} year The new year.\n */\n onYearChange: PropTypes.func,\n /**\n * The default visible view.\n * Used when the component view is not controlled.\n * Must be a valid option from `views` list.\n */\n openTo: PropTypes.oneOf(['day', 'hours', 'minutes', 'month', 'seconds', 'year']),\n /**\n * Force rendering in particular orientation.\n */\n orientation: PropTypes.oneOf(['landscape', 'portrait']),\n readOnly: PropTypes.bool,\n /**\n * If `true`, disable heavy animations.\n * @default `@media(prefers-reduced-motion: reduce)` || `navigator.userAgent` matches Android <10 or iOS <13\n */\n reduceAnimations: PropTypes.bool,\n /**\n * The date used to generate the new value when both `value` and `defaultValue` are empty.\n * @default The closest valid date-time using the validation props, except callbacks like `shouldDisable<...>`.\n */\n referenceDate: PropTypes.object,\n /**\n * Component displaying when passed `loading` true.\n * @returns {React.ReactNode} The node to render when loading.\n * @default () => ...\n */\n renderLoading: PropTypes.func,\n /**\n * Disable specific date.\n *\n * Warning: This function can be called multiple times (for example when rendering date calendar, checking if focus can be moved to a certain date, etc.). Expensive computations can impact performance.\n *\n * @template TDate\n * @param {TDate} day The date to test.\n * @returns {boolean} If `true` the date will be disabled.\n */\n shouldDisableDate: PropTypes.func,\n /**\n * Disable specific month.\n * @template TDate\n * @param {TDate} month The month to test.\n * @returns {boolean} If `true`, the month will be disabled.\n */\n shouldDisableMonth: PropTypes.func,\n /**\n * Disable specific time.\n * @template TDate\n * @param {TDate} value The value to check.\n * @param {TimeView} view The clock type of the timeValue.\n * @returns {boolean} If `true` the time will be disabled.\n */\n shouldDisableTime: PropTypes.func,\n /**\n * Disable specific year.\n * @template TDate\n * @param {TDate} year The year to test.\n * @returns {boolean} If `true`, the year will be disabled.\n */\n shouldDisableYear: PropTypes.func,\n /**\n * If `true`, days outside the current month are rendered:\n *\n * - if `fixedWeekNumber` is defined, renders days to have the weeks requested.\n *\n * - if `fixedWeekNumber` is not defined, renders day to fill the first and last week of the current month.\n *\n * - ignored if `calendars` equals more than `1` on range pickers.\n * @default false\n */\n showDaysOutsideCurrentMonth: PropTypes.bool,\n /**\n * The props used for each component slot.\n * @default {}\n */\n slotProps: PropTypes.object,\n /**\n * Overridable component slots.\n * @default {}\n */\n slots: PropTypes.object,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Choose which timezone to use for the value.\n * Example: \"default\", \"system\", \"UTC\", \"America/New_York\".\n * If you pass values from other timezones to some props, they will be converted to this timezone before being used.\n * @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.\n * @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.\n */\n timezone: PropTypes.string,\n /**\n * The selected value.\n * Used when the component is controlled.\n */\n value: PropTypes.object,\n /**\n * The visible view.\n * Used when the component view is controlled.\n * Must be a valid option from `views` list.\n */\n view: PropTypes.oneOf(['day', 'hours', 'minutes', 'month', 'seconds', 'year']),\n /**\n * Define custom view renderers for each section.\n * If `null`, the section will only have field editing.\n * If `undefined`, internally defined view will be used.\n */\n viewRenderers: PropTypes.shape({\n day: PropTypes.func,\n hours: PropTypes.func,\n minutes: PropTypes.func,\n month: PropTypes.func,\n seconds: PropTypes.func,\n year: PropTypes.func\n }),\n /**\n * Available views.\n */\n views: PropTypes.arrayOf(PropTypes.oneOf(['day', 'hours', 'minutes', 'month', 'seconds', 'year']).isRequired),\n /**\n * Years are displayed in ascending (chronological) order by default.\n * If `desc`, years are displayed in descending order.\n * @default 'asc'\n */\n yearsOrder: PropTypes.oneOf(['asc', 'desc']),\n /**\n * Years rendered per row.\n * @default `4` when `displayStaticWrapperAs === 'desktop'`, `3` otherwise.\n */\n yearsPerRow: PropTypes.oneOf([3, 4])\n};\nexport { StaticDateTimePicker };","'use client';\n\nimport * as React from 'react';\nimport { useRtl } from '@mui/system/RtlProvider';\nimport { useUtils } from \"../internals/hooks/useUtils.js\";\nimport { buildSectionsFromFormat } from \"../internals/hooks/useField/buildSectionsFromFormat.js\";\nimport { getLocalizedDigits } from \"../internals/hooks/useField/useField.utils.js\";\nimport { usePickersTranslations } from \"./usePickersTranslations.js\";\n/**\n * Returns the parsed format to be rendered in the field when there is no value or in other parts of the Picker.\n * This format is localized (e.g: `AAAA` for the year with the French locale) and cannot be parsed by your date library.\n * @param {object} The parameters needed to build the placeholder.\n * @param {string} params.format Format of the date to use.\n * @param {'dense' | 'spacious'} params.formatDensity Density of the format (setting `formatDensity` to `\"spacious\"` will add a space before and after each `/`, `-` and `.` character).\n * @param {boolean} params.shouldRespectLeadingZeros If `true`, the format will respect the leading zeroes, if `false`, the format will always add leading zeroes.\n * @returns\n */\nexport const useParsedFormat = parameters => {\n const {\n format,\n formatDensity = 'dense',\n shouldRespectLeadingZeros = false\n } = parameters;\n const utils = useUtils();\n const isRtl = useRtl();\n const translations = usePickersTranslations();\n const localizedDigits = React.useMemo(() => getLocalizedDigits(utils), [utils]);\n return React.useMemo(() => {\n const sections = buildSectionsFromFormat({\n utils,\n format,\n formatDensity,\n isRtl,\n shouldRespectLeadingZeros,\n localeText: translations,\n localizedDigits,\n date: null,\n // TODO v9: Make sure we still don't reverse in `buildSectionsFromFormat` when using `useParsedFormat`.\n enableAccessibleFieldDOMStructure: false\n });\n return sections.map(section => `${section.startSeparator}${section.placeholder}${section.endSeparator}`).join('');\n }, [utils, isRtl, translations, localizedDigits, format, formatDensity, shouldRespectLeadingZeros]);\n};","'use client';\n\nimport * as React from 'react';\nimport { PickersContext } from \"../internals/components/PickersProvider.js\";\n\n/**\n * Returns the context passed by the picker that wraps the current component.\n */\nexport const usePickersContext = () => {\n const value = React.useContext(PickersContext);\n if (value == null) {\n throw new Error(['MUI X: The `usePickersContext` can only be called in fields that are used as a slot of a picker component'].join('\\n'));\n }\n return value;\n};","/**\n * @mui/x-date-pickers v7.23.1\n *\n * @license MIT\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n// Clocks\nexport * from \"./TimeClock/index.js\";\nexport * from \"./DigitalClock/index.js\";\nexport * from \"./MultiSectionDigitalClock/index.js\";\nexport * from \"./LocalizationProvider/index.js\";\nexport * from \"./PickersDay/index.js\";\nexport * from \"./locales/utils/pickersLocaleTextApi.js\";\n\n// Fields\nexport * from \"./DateField/index.js\";\nexport * from \"./TimeField/index.js\";\nexport * from \"./DateTimeField/index.js\";\n\n// Calendars\nexport * from \"./DateCalendar/index.js\";\nexport * from \"./MonthCalendar/index.js\";\nexport * from \"./YearCalendar/index.js\";\nexport * from \"./DayCalendarSkeleton/index.js\";\n\n// New Pickers\nexport * from \"./DatePicker/index.js\";\nexport * from \"./DesktopDatePicker/index.js\";\nexport * from \"./MobileDatePicker/index.js\";\nexport * from \"./StaticDatePicker/index.js\";\nexport * from \"./TimePicker/index.js\";\nexport * from \"./DesktopTimePicker/index.js\";\nexport * from \"./MobileTimePicker/index.js\";\nexport * from \"./StaticTimePicker/index.js\";\nexport * from \"./DateTimePicker/index.js\";\nexport * from \"./DesktopDateTimePicker/index.js\";\nexport * from \"./MobileDateTimePicker/index.js\";\nexport * from \"./StaticDateTimePicker/index.js\";\n\n// View renderers\nexport * from \"./dateViewRenderers/index.js\";\nexport * from \"./timeViewRenderers/index.js\";\n\n// Layout\nexport * from \"./PickersLayout/index.js\";\nexport * from \"./PickersActionBar/index.js\";\nexport * from \"./PickersShortcuts/index.js\";\n\n// Other slots\nexport * from \"./PickersCalendarHeader/index.js\";\n\n// Field utilities\nexport * from \"./PickersTextField/index.js\";\nexport * from \"./PickersSectionList/index.js\";\nexport { DEFAULT_DESKTOP_MODE_MEDIA_QUERY } from \"./internals/utils/utils.js\";\nexport * from \"./models/index.js\";\nexport * from \"./icons/index.js\";\nexport * from \"./hooks/index.js\";\nexport * from \"./validation/index.js\";"],"names":["_excluded","MuiPickersAdapterContext","LocalizationProvider","inProps","inLocaleText","otherInProps","parentUtils","parentLocaleText","props","useThemeProps","children","DateAdapter","dateFormats","dateLibInstance","adapterLocale","themeLocaleText","localeText","utils","adapter","defaultDates","contextValue","getPickersLocalization","pickersTranslations","buildGetOpenDialogAriaText","params","formatKey","contextTranslation","propsTranslation","value","formattedValue","enUSPickers","view","time","formattedTime","hours","minutes","seconds","weekNumber","formattedDate","DEFAULT_LOCALE","enUS","useLocalizationContext","localization","useUtils","useDefaultDates","useNow","timezone","now","usePickersTranslations","ArrowDropDownIcon","createSvgIcon","ArrowLeftIcon","ArrowRightIcon","CalendarIcon","ClockIcon","DateRangeIcon","TimeIcon","ClearIcon","getPickersArrowSwitcherUtilityClass","slot","generateUtilityClass","pickersArrowSwitcherClasses","generateUtilityClasses","_excluded2","_excluded3","PickersArrowSwitcherRoot","styled","styles","PickersArrowSwitcherSpacer","theme","PickersArrowSwitcherButton","useUtilityClasses","ownerState","classes","slots","composeClasses","PickersArrowSwitcher","ref","isRtl","className","slotProps","isNextDisabled","isNextHidden","onGoToNext","nextLabel","isPreviousDisabled","isPreviousHidden","onGoToPrevious","previousLabel","labelId","other","nextProps","previousProps","PreviousIconButton","previousIconButtonProps","useSlotProps","clsx","NextIconButton","nextIconButtonProps","LeftArrowIcon","_useSlotProps","leftArrowIconProps","RightArrowIcon","_useSlotProps2","rightArrowIconProps","Typography","areViewsEqual","views","expectedViews","expectedView","applyDefaultViewProps","openTo","defaultOpenTo","defaultViews","viewsWithDefault","openToWithDefault","timeViews","isTimeView","isInternalTimeView","getMeridiem","date","convertValueToMeridiem","meridiem","ampm","convertToMeridiem","newHoursAmount","getSecondsInDay","createIsAfterIgnoreDatePart","disableIgnoringDatePartForTimeValidation","dateLeft","dateRight","resolveTimeFormat","format","formats","warnedOnceNotValidView","useViews","onChange","onViewChange","inView","autoFocus","inFocusedView","onFocusedViewChange","previousOpenTo","previousViews","defaultView","setView","useControlled","defaultFocusedView","focusedView","setFocusedView","previousView","viewIndex","nextView","handleFocusedViewChange","useEventCallback","viewToFocus","hasFocus","prevFocusedView","handleChangeView","newView","goToNextView","setValueAndGoToNextView","currentViewSelectionState","selectedView","isSelectionFinishedOnCurrentView","hasMoreViews","nextViewAfterSelected","useNextMonthDisabled","month","disableFuture","maxDate","lastEnabledMonth","usePreviousMonthDisabled","disablePast","minDate","firstEnabledMonth","useMeridiemMode","selectionState","meridiemMode","handleMeridiemChange","mode","timeWithMeridiem","DAY_SIZE","DAY_MARGIN","DIALOG_WIDTH","MAX_CALENDAR_HEIGHT","VIEW_HEIGHT","DIGITAL_CLOCK_VIEW_HEIGHT","MULTI_SECTION_CLOCK_SECTION_WIDTH","PickerViewRoot","getTimeClockUtilityClass","timeClockClasses","CLOCK_WIDTH","CLOCK_HOUR_WIDTH","clockCenter","baseClockPoint","cx","cy","rad2deg","rad","getAngleValue","step","offsetX","offsetY","x","y","atan","deg","delta","distance","getMinutes","angleStep","getHours","hour","getClockPointerUtilityClass","clockPointerClasses","ClockPointerRoot","_","ClockPointerThumb","ClockPointer","isInner","type","viewValue","previousType","getAngleStyle","angle","getClockUtilityClass","clockClasses","mergeDateAndTime","dateParam","timeParam","mergedDate","findClosestEnabledDate","isDateDisabled","today","forward","backward","replaceInvalidDateByNull","applyDefaultDate","defaultValue","areDatesEqual","a","b","getMonthsInYear","year","months","prevMonth","getTodayDate","valueType","formatMeridiem","dateViews","isDatePickerView","resolveDateFormat","isInToolbar","getWeekdays","start","diff","ClockRoot","ClockClock","ClockWrapper","ClockSquareMask","ClockPin","meridiemButtonCommonStyles","ClockAmButton","ClockPmButton","ClockMeridiemText","Clock","ampmInClock","isTimeDisabled","minutesStep","selectedId","disabled","readOnly","translations","isMoving","isSelectedTimeDisabled","isPointerInner","handleValueChange","newValue","isFinish","setTime","event","rect","newSelectedValue","handleTouchSelection","handleTouchEnd","handleMouseMove","handleMouseUp","hasSelected","keyboardControlStep","listboxRef","useEnhancedEffect","handleKeyDown","getClockNumberUtilityClass","clockNumberClasses","selected","ClockNumberRoot","ClockNumber","index","inner","label","length","getHourNumbers","getClockNumberText","isDisabled","currentHours","hourNumbers","startHour","endHour","isSelected","getMinutesNumbers","f","numberValue","useValueWithTimezone","timezoneProp","valueProp","referenceDate","valueManager","firstDefaultValue","inputValue","inputTimezone","setInputTimezone","timezoneToRender","valueWithTimezoneToRender","otherParams","newValueWithInputTimezone","useControlledValueWithTimezone","name","onChangeProp","valueWithInputTimezone","setValue","SECTION_TYPE_GRANULARITY","getSectionTypeGranularity","sections","section","roundDate","granularity","roundedDate","getDefaultReferenceDate","inGetTodayDate","isAfter","getDateSectionConfigFromFormatToken","formatToken","config","getDeltaFromKeyCode","keyCode","getDaysInWeekStr","elements","startDate","endDate","current","weekDay","getLetterEditingOptions","sectionType","FORMAT_SECONDS_NO_LEADING_ZEROS","NON_LOCALIZED_DIGITS","getLocalizedDigits","removeLocalizedDigits","valueStr","localizedDigits","digits","currentFormattedDigit","i","matchingDigitIndex","applyLocalizedDigits","char","isStringNumber","nonLocalizedValueStr","cleanLeadingZeros","size","cleanValueStr","cleanDigitSectionValue","sectionBoundaries","adjustSectionValue","sectionsValueBoundaries","activeDate","stepsAttributes","isStart","isEnd","shouldSetAbsolute","adjustDigitSection","getCleanValue","newSectionValueNumber","adjustLetterSection","options","clampedIndex","getSectionVisibleValue","target","hasLeadingZeros","changeSectionValueFormat","currentFormat","newFormat","isFourDigitYearFormat","doesSectionFormatHaveLeadingZeros","contentType","getDateFromDateSections","shouldSkipWeekDays","sectionFormats","sectionValues","formatWithoutSeparator","dateWithoutSeparatorStr","createDateStrForV7HiddenInputFromSections","createDateStrForV6InputFromSections","dateStr","dateValue","getSectionsBoundaries","endOfYear","endOfDay","maxDaysInMonth","longestMonth","acc","daysInMonth","currentDate","daysInWeek","lastHourInDay","warnedOnceInvalidSection","validateSections","transferDateSectionValue","dateToTransferFrom","dateToTransferTo","formattedDaysInWeek","dayInWeekStrOfActiveDate","dayInWeekOfActiveDate","isAM","mergedDateHours","reliableSectionModificationOrder","mergeDateIntoReferenceDate","shouldLimitToEditedSections","isAndroid","getSectionOrder","shouldApplyRTL","neighbors","leftIndex","rightIndex","rtl2ltr","ltr2rtl","groupedSectionsStart","groupedSectionsEnd","RTLIndex","rtlIndex","parseSelectedSections","selectedSections","getSectionValueText","parsedDate","getSectionValueNow","singleItemValueManager","_ref","error","singleItemFieldValueManager","prevReferenceValue","prevSections","getSectionsFromDate","state","newActiveDate","referenceValue","parseDate","useClockReferenceDate","referenceDateProp","TimeClockRoot","TimeClockArrowSwitcher","TIME_CLOCK_DEFAULT_VIEWS","TimeClock","maxTime","minTime","shouldDisableTime","showViewSwitcher","valueOrReferenceDate","rawValue","viewType","shouldCheckPastEnd","containsValidTime","end","isValidValue","timeValue","valueWithMeridiem","dateWithNewHours","dateWithNewMinutes","dateWithNewSeconds","useId","viewProps","handleHoursChange","hourValue","minutesValue","handleMinutesChange","minuteValue","secondsValue","handleSecondsChange","secondValue","getDigitalClockUtilityClass","digitalClockClasses","arrayIncludes","array","itemOrItems","item","onSpaceOrEnter","innerFn","externalEvent","executeInTheNextEventLoopTick","fn","getActiveElement","root","activeEl","getFocusedListItemIndex","listElement","DEFAULT_DESKTOP_MODE_MEDIA_QUERY","DigitalClockRoot","DigitalClockList","MenuList","DigitalClockItem","MenuItem","DigitalClock","containerRef","handleRef","useForkRef","listRef","timeStep","skipDisabled","handleRawValueChange","ClockItem","clockItemProps","handleItemSelect","activeItem","offsetTop","valueToCheck","timeOptions","result","nextTimeStepOption","focusedOptionIndex","option","newIndex","newFocusedIndex","childToFocus","tabIndex","getMultiSectionDigitalClockUtilityClass","multiSectionDigitalClockClasses","getMultiSectionDigitalClockSectionUtilityClass","multiSectionDigitalClockSectionClasses","MultiSectionDigitalClockSectionRoot","MultiSectionDigitalClockSectionItem","MultiSectionDigitalClockSection","previousActive","items","active","DigitalClockSectionItem","isItemDisabled","getHourSectionOptions","resolveAriaLabel","overriddenCurrentHours","resolvedCurrentHours","isFocused","ariaLabel","getTimeSectionOptions","resolveLabel","hasValue","MultiSectionDigitalClockRoot","MultiSectionDigitalClock","inTimeSteps","inViews","timeSteps","handleMeridiemValueChange","buildViewProps","viewToBuild","amLabel","pmLabel","viewsToRender","digitViews","v","viewTimeOptions","currentView","timeView","getPickersDayUtilityClass","pickersDayClasses","disableMargin","disableHighlightToday","outsideCurrentMonth","showDaysOutsideCurrentMonth","isHiddenDaySpacingFiller","styleArg","overridesResolver","PickersDayRoot","ButtonBase","PickersDayFiller","noop","PickersDayRaw","forwardedRef","day","isAnimating","onClick","onDaySelect","onFocus","onBlur","onKeyDown","onMouseDown","onMouseEnter","isToday","handleMouseDown","handleClick","PickersDay","useValidation","validator","onError","previousValidationErrorRef","validationError","hasValidationError","getValidationErrorForNewValue","expandFormat","formatExpansionOverflow","prevFormat","nextFormat","getEscapedPartsFromFormat","expandedFormat","escapedParts","startChar","endChar","regExp","match","getSectionPlaceholder","sectionConfig","sectionFormat","createSection","shouldRespectLeadingZeros","token","startSeparator","hasLeadingZerosInFormat","hasLeadingZerosInInput","isValidDate","sectionValue","maxLength","buildSections","validTokens","regExpFirstWordInFormat","regExpWordOnlyComposedOfTokens","regExpFirstTokenInWord","getEscapedPartOfCurrentChar","escapeIndex","escapedPartOfCurrentChar","isEscapedChar","firstWordInFormat","word","firstWord","postProcessSections","formatDensity","cleanSeparator","separator","cleanedSeparator","buildSectionsFromFormat","useFieldState","fieldValueManager","internalProps","selectedSectionsProp","onSelectedSectionsChange","enableAccessibleFieldDOMStructure","valueFromTheOutside","getSectionsFromValue","fallbackSections","setState","stateWithoutReferenceDate","innerSetSelectedSections","setSelectedSections","newSelectedSections","parsedSelectedSections","activeSectionIndex","publishValue","prevState","context","setSectionValue","sectionIndex","newSectionValue","newSections","clearValue","clearActiveSection","activeSection","activeDateManager","hasNoOtherNonEmptySections","newValues","updateValueFromValueStr","parseDateStr","newReferenceValue","updateSectionValue","shouldGoToNextSection","newActiveDateSections","values","shouldPublish","setTempAndroidValueStr","tempValueStrAndroid","prev","shouldUpdate","QUERY_LIFE_DURATION_MS","isQueryResponseWithoutValue","response","useFieldCharacterEditing","query","setQuery","resetQuery","timeout","applyQuery","keyPressed","getFirstSectionValueMatchingWithQuery","isValidQueryValue","cleanKeyPressed","concatenatedQueryValue","queryResponse","applyLetterEditing","findMatchingOptions","queryValue","matchingValues","testQueryOnFormatAndFallbackFormat","fallbackFormat","formatFallbackValue","getOptions","fallbackOptions","fallbackValue","applyNumericEditing","getNewSectionValue","cleanQueryValue","queryValueNumber","useFieldV7TextField","inSectionListRef","onInput","onPaste","focusedProp","applyCharacterEditing","resetCharacterQuery","sectionOrder","areAllSectionsEmpty","sectionListRef","handleSectionListRef","id","focused","setFocused","interactions","selection","range","activeElement","newParsedSelectedSections","revertDOMSectionChange","handleContainerClick","args","cursorPosition","cursorOnStartOfSection","handleContainerInput","handleContainerPaste","pastedValue","handleContainerFocus","handleContainerBlur","getInputContainerClickHandler","handleInputContentMouseUp","getInputContentFocusHandler","handleInputContentPaste","lettersOnly","digitsOnly","digitsAndLetterOnly","handleInputContentDragOver","handleInputContentInput","inputType","domElement","next","isContainerEditable","isEditable","handleValueStrChange","cleanString","dirtyString","addPositionPropertiesToSections","position","positionInInput","renderedValue","sectionStr","sectionLength","sectionLengthInInput","cleanedValue","startInInput","endInInput","useFieldV6TextField","focusTimeoutRef","selectionSyncTimeoutRef","inputRefProp","inPlaceholder","inputRef","currentScrollTop","selectedSection","selectionStart","selectionEnd","browserStartIndex","browserEndIndex","nextSectionIndex","newSelectedSection","syncSelectionFromDOM","handleInputFocus","input","handleInputClick","handleInputPaste","handleInputChange","targetValue","eventData","shouldUseEventData","prevValueStr","startOfDiffIndex","endOfDiffIndex","activeSectionEndRelativeToNewValue","placeholder","inputMode","shouldShowPlaceholder","useField","unstableFieldRef","clearable","onClear","stateResponse","characterEditingResponse","useFieldTextField","returnedValue","handleContainerKeyDown","inputError","handleClearValue","commonForwardedProps","commonAdditionalProps","validateDate","shouldDisableDate","shouldDisableMonth","shouldDisableYear","DATE_VALIDATION_PROP_NAMES","TIME_VALIDATION_PROP_NAMES","DATE_TIME_VALIDATION_PROP_NAMES","VALIDATION_PROP_NAMES","extractValidationProps","extractedProps","propName","SHARED_FIELD_INTERNAL_PROP_NAMES","useSplitFieldProps","forwardedProps","extractProp","useDefaultizedDateField","useDefaultizedTimeField","defaultFormat","useDefaultizedDateTimeField","useDateField","useClearableField","InputProps","sx","IconButton","iconButtonProps","EndClearIcon","endClearIconProps","getPickersTextFieldUtilityClass","pickersTextFieldClasses","getPickersInputBaseUtilityClass","pickersInputBaseClasses","getPickersOutlinedInputUtilityClass","pickersOutlinedInputClasses","OutlineRoot","borderColor","OutlineLabel","OutlineLegend","Outline","withLabel","getPickersSectionListUtilityClass","pickersSectionListClasses","PickersSectionListRoot","PickersSectionListSection","PickersSectionListSectionSeparator","PickersSectionListSectionContent","PickersSection","element","Section","sectionProps","SectionContent","sectionContentProps","SectionSeparator","sectionSeparatorBeforeProps","sectionSeparatorAfterProps","PickersSectionList","rootRef","handleRootRef","getRoot","methodName","sectionContainer","Root","rootProps","content","before","after","elementIndex","round","PickersInputBaseRoot","PickersInputBaseSectionsContainer","adornedStart","filled","PickersInputBaseSection","PickersInputBaseSectionContent","PickersInputBaseSectionSeparator","PickersInputBaseInput","visuallyHidden","fullWidth","color","endAdornment","startAdornment","capitalize","PickersInputBase","renderSuffix","contentEditable","inputProps","handleInputRef","muiFormControl","useFormControl","InputRoot","inputRootProps","InputSectionsContainer","PickersOutlinedInputRoot","key","PickersOutlinedInputSectionsContainer","composedClasses","PickersOutlinedInput","ownerStateProp","notched","getPickersFilledInputUtilityClass","pickersFilledInputClasses","PickersFilledInputRoot","prop","light","bottomLineColor","backgroundColor","hoverBackground","disabledBackground","PickersFilledSectionsContainer","disableUnderline","PickersFilledInput","getPickersInputUtilityClass","pickersInputClasses","PickersInputRoot","PickersInput","VARIANT_COMPONENT","PickersTextFieldRoot","FormControl","required","PickersTextField","variant","onKeyUp","idProp","helperText","FormHelperTextProps","InputLabelProps","helperTextId","inputLabelId","PickersInputComponent","InputLabel","FormHelperText","convertFieldResponseIntoMuiTextFieldProps","fieldResponse","DateField","inRef","themeProps","TextField","textFieldProps","convertedFieldResponse","processedFieldProps","validateTime","useTimeField","TimeField","validateDateTime","dateValidationResult","useDateTimeField","DateTimeField","useIsDateDisabled","createCalendarStateReducer","reduceAnimations","disableSwitchToMonthOnDayFocus","action","newTimezone","newCurrentMonth","needMonthSwitch","useCalendarState","onMonthChange","reducerFn","calendarState","dispatch","handleChangeMonth","payload","changeMonth","newDate","newDateRequested","onMonthSwitchingAnimationEnd","changeFocusedDay","newFocusedDate","withoutMonthSwitchingAnimation","getPickersFadeTransitionGroupUtilityClass","pickersFadeTransitionGroupClasses","PickersFadeTransitionGroupRoot","TransitionGroup","PickersFadeTransitionGroup","transKey","useTheme","Fade","hasClass","replaceClassName","origClass","classToRemove","_addClass","node","c","removeClass","CSSTransition","_React$Component","_this","_len","_key","maybeNode","maybeAppearing","_this$resolveArgument","appearing","_this$resolveArgument2","_this$resolveArgument3","_this$resolveArgument4","_this$resolveArgument5","_this$resolveArgument6","classNames","isStringClassNames","prefix","baseClassName","activeClassName","doneClassName","_proto","phase","_this$getClassNames","_this$appliedClasses$","_this$props","Transition","getPickersSlideTransitionUtilityClass","pickersSlideTransitionClasses","slideDirection","PickersSlideTransitionRoot","slideTransition","PickersSlideTransition","transitionClasses","getDayCalendarUtilityClass","dayCalendarClasses","weeksContainerHeight","PickersCalendarDayRoot","PickersCalendarDayHeader","PickersCalendarWeekDayLabel","PickersCalendarWeekNumberLabel","PickersCalendarWeekNumber","PickersCalendarLoadingContainer","PickersCalendarSlideTransition","PickersCalendarWeekContainer","PickersCalendarWeek","WrappedDay","parentProps","focusableDay","selectedDays","currentMonthNumber","isViewFocused","isMonthSwitchingAnimating","isFocusableDay","selectedDay","Day","dayProps","isFirstVisibleCell","startOfMonth","isLastVisibleCell","endOfMonth","DayCalendar","onFocusedDayChange","currentMonth","focusedDay","loading","onSelectedDaysChange","renderLoading","TransitionProps","dayOfWeekFormatter","gridLabelId","displayWeekNumber","fixedWeekNumber","internalHasFocus","setInternalHasFocus","internalFocusedDay","setInternalFocusedDay","handleDaySelect","focusDay","newFocusedDayDefault","nextAvailableMonth","closestDayToFocus","handleFocus","handleBlur","currentYearNumber","validSelectedDays","transitionKey","slideNodeRef","weeksToDisplay","toDisplay","nextMonth","additionalWeeks","hasCommonWeek","week","weekday","dayIndex","getPickersMonthUtilityClass","pickersMonthClasses","PickersMonthRoot","MonthCalendarButton","PickersMonth","ariaCurrent","MonthButton","monthButtonProps","getMonthCalendarUtilityClass","monthCalendarClasses","useMonthCalendarDefaultizedProps","MonthCalendarRoot","MonthCalendar","onMonthFocus","monthsPerRow","todayMonth","selectedMonth","focusedMonth","setFocusedMonth","changeHasFocus","newHasFocus","isMonthDisabled","dateToValidate","monthToValidate","handleMonthSelection","focusMonth","prevFocusedMonth","handleMonthFocus","handleMonthBlur","monthNumber","monthText","monthLabel","getPickersYearUtilityClass","pickersYearClasses","PickersYearRoot","YearCalendarButton","PickersYear","YearButton","yearButtonProps","getYearCalendarUtilityClass","yearCalendarClasses","useYearCalendarDefaultizedProps","YearCalendarRoot","YearCalendar","onYearFocus","yearsOrder","yearsPerRow","todayYear","selectedYear","focusedYear","setFocusedYear","isYearDisabled","yearToValidate","handleYearSelection","focusYear","prevFocusedYear","verticalDirection","horizontalDirection","handleYearFocus","handleYearBlur","scrollerRef","tabbableButton","offsetHeight","clientHeight","scrollTop","elementBottom","yearRange","yearNumber","getPickersCalendarHeaderUtilityClass","pickersCalendarHeaderClasses","PickersCalendarHeaderRoot","PickersCalendarHeaderLabelContainer","PickersCalendarHeaderLabel","PickersCalendarHeaderSwitchViewButton","PickersCalendarHeaderSwitchViewIcon","PickersCalendarHeader","SwitchViewButton","switchViewButtonProps","SwitchViewIcon","switchViewIconProps","selectNextMonth","selectPreviousMonth","isNextMonthDisabled","isPreviousMonthDisabled","handleToggleView","el","nextIndexToOpen","PREFERS_REDUCED_MOTION","mobileVersionMatches","androidVersion","iOSVersion","slowAnimationDevices","useDefaultReduceAnimations","useMediaQuery","getDateCalendarUtilityClass","dateCalendarClasses","useDateCalendarDefaultizedProps","defaultReduceAnimations","DateCalendarRoot","DateCalendarViewTransitionContainer","DateCalendar","onYearChange","minDateWithDisabled","maxDateWithDisabled","CalendarHeader","calendarHeaderProps","newMonth","direction","handleDateMonthChange","closestEnabledDate","handleDateYearChange","startOfYear","handleSelectedDayChange","baseDateValidationProps","commonViewProps","prevOpenViewRef","getDayCalendarSkeletonUtilityClass","dayCalendarSkeletonClasses","DayCalendarSkeletonRoot","DayCalendarSkeletonWeek","DayCalendarSkeletonDay","Skeleton","monthMap","DayCalendarSkeleton","index2","getPickersToolbarUtilityClass","pickersToolbarClasses","PickersToolbarRoot","PickersToolbarContent","PickersToolbar","toolbarTitle","hidden","titleId","getDatePickerToolbarUtilityClass","datePickerToolbarClasses","DatePickerToolbarRoot","DatePickerToolbarTitle","DatePickerToolbar","isLandscape","toolbarFormat","toolbarPlaceholder","dateText","formatFromViews","useDatePickerDefaultizedProps","getPickersPopperUtilityClass","pickersPopperClasses","PickersPopperRoot","PickersPopperPaper","placement","clickedRootScrollbar","doc","useClickAwayListener","onClickAway","movedRef","syntheticEventRef","nodeRef","activatedRef","armClickAwayListener","handleClickAway","insideReactTree","ownerDocument","insideDOM","handleSynthetic","handleTouchMove","PickersPopperPaperWrapper","PaperComponent","popperPlacement","inOwnerState","paperSlotProps","paperClasses","onPaperClick","onPaperTouchStart","paperProps","PickersPopper","anchorEl","shouldRestoreFocus","onDismiss","open","role","inReduceAnimations","nativeEvent","lastFocusedElementRef","clickAwayRef","paperRef","handlePaperRef","Grow","FocusTrap","Paper","Popper","popperProps","useOpenState","onOpen","onClose","isControllingOpenProp","openState","setIsOpenState","setIsOpen","newIsOpen","shouldPublishValue","hasChanged","dateState","isControlled","isCurrentValueTheDefaultValue","shouldCommitValue","closeOnSelect","shouldClosePicker","usePickerValue","wrapperVariant","onAccept","inValueWithoutRenderTimezone","inDefaultValue","previousTimezoneProp","setPreviousTimezoneProp","isOpen","inValueWithTimezoneToRender","setDateState","initialValue","timezoneFromDraftValue","updateDate","updaterParams","comparison","shouldCommit","shouldClose","cachedContext","getContext","isUpdateComingFromPicker","handleClear","handleAccept","handleDismiss","handleCancel","handleSetToday","handleOpen","handleClose","handleChange","handleSelectShortcut","changeImportance","shortcut","handleChangeFromField","actions","viewResponse","isValid","testedValue","layoutResponse","usePickerViews","propsFromPickerValue","additionalViewProps","autoFocusView","rendererInterceptor","fieldRef","viewRenderers","propsToForwardToView","hasUIView","viewModeLookup","viewForReduce","viewMode","timeViewsCount","currentViewMode","popperView","setPopperView","renderer","rendererProps","getOrientation","useIsLandscape","customOrientation","orientation","setOrientation","eventHandler","usePickerLayoutProps","propsFromPickerViews","usePickerOwnerState","parameters","pickerValueResponse","usePicker","pickerViewsResponse","pickerLayoutResponse","pickerOwnerState","getPickersLayoutUtilityClass","pickersLayoutClasses","PickersActionBar","onCancel","onSetToday","buttons","actionType","Button","DialogActions","PickersShortcuts","resolvedItems","getValue","List","ListItem","Chip","toolbarHasView","toolbarProps","onSelectShortcut","ActionBar","actionBarProps","actionBar","Toolbar","toolbar","Tabs","tabs","Shortcuts","shortcutsProps","shortcuts","PickersLayoutRoot","PickersLayoutContentWrapper","PickersLayout","PickersContext","PickersProvider","useDesktopPicker","getOpenDialogAriaText","pickerParams","innerSlotProps","isToolbarHidden","layoutProps","renderCurrentView","pickerFieldProps","InputAdornment","inputAdornmentProps","OpenPickerButton","openPickerButtonProps","OpenPickerIcon","openPickerIconProps","Field","fieldProps","slotsForField","Layout","labelledById","handleFieldRef","renderDateViewCalendar","DesktopDatePicker","defaultizedProps","resolveComponentProps","renderPicker","PickersModalDialogRoot","dialogClasses","PickersModalDialogContent","DialogContent","PickersModalDialog","Dialog","useMobilePicker","MobileDatePicker","DatePicker","desktopModeMediaQuery","PickerStaticLayout","useStaticPicker","displayStaticWrapperAs","StaticDatePicker","getPickersToolbarTextUtilityClass","pickersToolbarTextClasses","PickersToolbarTextRoot","PickersToolbarText","PickersToolbarButtonRoot","PickersToolbarButton","align","typographyClassName","width","getTimePickerToolbarUtilityClass","timePickerToolbarClasses","TimePickerToolbarRoot","TimePickerToolbarSeparator","TimePickerToolbarHourMinuteLabel","TimePickerToolbarAmPmSelection","TimePickerToolbar","showAmPmControl","formatHours","useTimePickerDefaultizedProps","renderTimeViewClock","renderDigitalClockTimeView","renderMultiSectionDigitalClockTimeView","resolveDateTimeFormat","ignoreDateResolving","timeFormat","resolveViews","shouldUseSingleColumn","resolveShouldRenderTimeInASingleColumn","threshold","resolveTimeViewsResponse","inThreshold","thresholdToRenderTimeInASingleColumn","shouldRenderTimeInASingleColumn","DesktopTimePicker","resolvedViews","renderTimeView","actionBarActions","MobileTimePicker","TimePicker","StaticTimePicker","getDateTimePickerTabsUtilityClass","dateTimePickerTabsClasses","viewToTab","tabToView","tab","DateTimePickerTabsRoot","tabsClasses","DateTimePickerTabs","dateIcon","timeIcon","Tab","getDateTimePickerToolbarUtilityClass","dateTimePickerToolbarClasses","DateTimePickerToolbarRoot","DateTimePickerToolbarDateContainer","DateTimePickerToolbarTimeContainer","toolbarVariant","DateTimePickerToolbarTimeDigitsContainer","DateTimePickerToolbarSeparator","DateTimePickerToolbarAmPmSelection","DateTimePickerToolbar","inToolbarTitle","isDesktop","useDateTimePickerDefaultizedProps","DesktopDateTimePickerLayout","isActionBarVisible","Divider","inViewRenderers","otherProps","finalProps","isTimeViewActive","DesktopDateTimePicker","MobileDateTimePicker","DateTimePicker","StaticDateTimePicker","useParsedFormat","usePickersContext"],"sourceRoot":""} \ No newline at end of file diff --git a/admin/custom/static/js/vendors-node_modules_react-color_es_index_js.4d1bf1cc.chunk.js b/admin/custom/static/js/vendors-node_modules_react-color_es_index_js.4d1bf1cc.chunk.js new file mode 100644 index 0000000..9ab0356 --- /dev/null +++ b/admin/custom/static/js/vendors-node_modules_react-color_es_index_js.4d1bf1cc.chunk.js @@ -0,0 +1,29 @@ +(self.webpackChunk_iobroker_admin_component_easy_access=self.webpackChunk_iobroker_admin_component_easy_access||[]).push([["vendors-node_modules_react-color_es_index_js"],{4694:(u,g,i)=>{"use strict";var s;s={value:!0};var a=Object.assign||function(d){for(var m=1;m=0||Object.prototype.hasOwnProperty.call(d,C)&&(S[C]=d[C]);return S}var x=24;g.A=function(d){var m=d.fill,S=m===void 0?"currentColor":m,C=d.width,A=C===void 0?x:C,P=d.height,F=P===void 0?x:P,H=d.style,R=H===void 0?{}:H,D=v(d,["fill","width","height","style"]);return p.default.createElement("svg",a({viewBox:"0 0 "+x+" "+x,style:a({fill:S,width:A,height:F},R)},D),p.default.createElement("path",{d:"M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"}))}},3499:(u,g,i)=>{"use strict";var s;s={value:!0};var a=Object.assign||function(d){for(var m=1;m=0||Object.prototype.hasOwnProperty.call(d,C)&&(S[C]=d[C]);return S}var x=24;g.A=function(d){var m=d.fill,S=m===void 0?"currentColor":m,C=d.width,A=C===void 0?x:C,P=d.height,F=P===void 0?x:P,H=d.style,R=H===void 0?{}:H,D=v(d,["fill","width","height","style"]);return p.default.createElement("svg",a({viewBox:"0 0 "+x+" "+x,style:a({fill:S,width:A,height:F},R)},D),p.default.createElement("path",{d:"M12,18.17L8.83,15L7.42,16.41L12,21L16.59,16.41L15.17,15M12,5.83L15.17,9L16.58,7.59L12,3L7.41,7.59L8.83,9L12,5.83Z"}))}},7230:(u,g,i)=>{var s=i(3984),a=i(9107),l=s(a,"DataView");u.exports=l},3435:(u,g,i)=>{var s=i(6890),a=i(9484),l=i(7215),p=i(7811),h=i(747);function v(x){var d=-1,m=x==null?0:x.length;for(this.clear();++d{var s=i(4412),a=i(8522),l=i(469),p=i(1161),h=i(1441);function v(x){var d=-1,m=x==null?0:x.length;for(this.clear();++d{var s=i(3984),a=i(9107),l=s(a,"Map");u.exports=l},3287:(u,g,i)=>{var s=i(8206),a=i(9768),l=i(6827),p=i(663),h=i(5135);function v(x){var d=-1,m=x==null?0:x.length;for(this.clear();++d{var s=i(3984),a=i(9107),l=s(a,"Promise");u.exports=l},5963:(u,g,i)=>{var s=i(3984),a=i(9107),l=s(a,"Set");u.exports=l},1641:(u,g,i)=>{var s=i(3287),a=i(2486),l=i(9361);function p(h){var v=-1,x=h==null?0:h.length;for(this.__data__=new s;++v{var s=i(5217),a=i(8658),l=i(3844),p=i(6503),h=i(1563),v=i(259);function x(d){var m=this.__data__=new s(d);this.size=m.size}x.prototype.clear=a,x.prototype.delete=l,x.prototype.get=p,x.prototype.has=h,x.prototype.set=v,u.exports=x},6711:(u,g,i)=>{var s=i(9107),a=s.Symbol;u.exports=a},9282:(u,g,i)=>{var s=i(9107),a=s.Uint8Array;u.exports=a},2850:(u,g,i)=>{var s=i(3984),a=i(9107),l=s(a,"WeakMap");u.exports=l},3643:u=>{function g(i,s){for(var a=-1,l=i==null?0:i.length;++a{function g(i,s){for(var a=-1,l=i==null?0:i.length,p=0,h=[];++a{var s=i(5410),a=i(2382),l=i(2003),p=i(1262),h=i(2615),v=i(9221),x=Object.prototype,d=x.hasOwnProperty;function m(S,C){var A=l(S),P=!A&&a(S),F=!A&&!P&&p(S),H=!A&&!P&&!F&&v(S),R=A||P||F||H,D=R?s(S.length,String):[],k=D.length;for(var L in S)(C||d.call(S,L))&&!(R&&(L=="length"||F&&(L=="offset"||L=="parent")||H&&(L=="buffer"||L=="byteLength"||L=="byteOffset")||h(L,k)))&&D.push(L);return D}u.exports=m},14:u=>{function g(i,s){for(var a=-1,l=i==null?0:i.length,p=Array(l);++a{function g(i,s){for(var a=-1,l=s.length,p=i.length;++a{function g(i,s){for(var a=-1,l=i==null?0:i.length;++a{var s=i(9330),a=i(8330),l=Object.prototype,p=l.hasOwnProperty;function h(v,x,d){var m=v[x];(!(p.call(v,x)&&a(m,d))||d===void 0&&!(x in v))&&s(v,x,d)}u.exports=h},4767:(u,g,i)=>{var s=i(8330);function a(l,p){for(var h=l.length;h--;)if(s(l[h][0],p))return h;return-1}u.exports=a},383:(u,g,i)=>{var s=i(8113),a=i(5304);function l(p,h){return p&&s(h,a(h),p)}u.exports=l},7844:(u,g,i)=>{var s=i(8113),a=i(7495);function l(p,h){return p&&s(h,a(h),p)}u.exports=l},9330:(u,g,i)=>{var s=i(7771);function a(l,p,h){p=="__proto__"&&s?s(l,p,{configurable:!0,enumerable:!0,value:h,writable:!0}):l[p]=h}u.exports=a},1937:(u,g,i)=>{var s=i(6435),a=i(3643),l=i(6645),p=i(383),h=i(7844),v=i(2932),x=i(9061),d=i(709),m=i(8038),S=i(5760),C=i(3183),A=i(695),P=i(9303),F=i(7766),H=i(3991),R=i(2003),D=i(1262),k=i(5652),L=i(5603),U=i(9318),z=i(5304),J=i(7495),K=1,$=2,ee=4,V="[object Arguments]",ae="[object Array]",W="[object Boolean]",ne="[object Date]",ie="[object Error]",G="[object Function]",me="[object GeneratorFunction]",ft="[object Map]",Ut="[object Number]",pt="[object Object]",zt="[object RegExp]",$t="[object Set]",we="[object String]",Wt="[object Symbol]",M="[object WeakMap]",Kt="[object ArrayBuffer]",Xt="[object DataView]",Vt="[object Float32Array]",Re="[object Float64Array]",Yt="[object Int8Array]",rt="[object Int16Array]",Zt="[object Int32Array]",Jt="[object Uint8Array]",Qt="[object Uint8ClampedArray]",qt="[object Uint16Array]",er="[object Uint32Array]",Y={};Y[V]=Y[ae]=Y[Kt]=Y[Xt]=Y[W]=Y[ne]=Y[Vt]=Y[Re]=Y[Yt]=Y[rt]=Y[Zt]=Y[ft]=Y[Ut]=Y[pt]=Y[zt]=Y[$t]=Y[we]=Y[Wt]=Y[Jt]=Y[Qt]=Y[qt]=Y[er]=!0,Y[ie]=Y[G]=Y[M]=!1;function nt(X,Se,Ee,Ce,xe,be){var oe,at=Se&K,ot=Se&$,tr=Seⅇif(Ee&&(oe=xe?Ee(X,Ce,xe,be):Ee(X)),oe!==void 0)return oe;if(!L(X))return X;var Et=R(X);if(Et){if(oe=P(X),!at)return x(X,oe)}else{var _e=A(X),Ct=_e==G||_e==me;if(D(X))return v(X,at);if(_e==pt||_e==V||Ct&&!xe){if(oe=ot||Ct?{}:H(X),!at)return ot?m(X,h(oe,X)):d(X,p(oe,X))}else{if(!Y[_e])return xe?X:{};oe=F(X,_e,at)}}be||(be=new s);var _t=be.get(X);if(_t)return _t;be.set(X,oe),U(X)?X.forEach(function(ve){oe.add(nt(ve,Se,Ee,ve,X,be))}):k(X)&&X.forEach(function(ve,te){oe.set(te,nt(ve,Se,Ee,te,X,be))});var At=tr?ot?C:S:ot?J:z,Ot=Et?void 0:At(X);return a(Ot||X,function(ve,te){Ot&&(te=ve,ve=X[te]),l(oe,te,nt(ve,Se,Ee,te,X,be))}),oe}u.exports=nt},3962:(u,g,i)=>{var s=i(5603),a=Object.create,l=function(){function p(){}return function(h){if(!s(h))return{};if(a)return a(h);p.prototype=h;var v=new p;return p.prototype=void 0,v}}();u.exports=l},7587:(u,g,i)=>{var s=i(427),a=i(3679),l=a(s);u.exports=l},1595:(u,g,i)=>{var s=i(951),a=s();u.exports=a},427:(u,g,i)=>{var s=i(1595),a=i(5304);function l(p,h){return p&&s(p,h,a)}u.exports=l},384:(u,g,i)=>{var s=i(4275),a=i(8059);function l(p,h){h=s(h,p);for(var v=0,x=h.length;p!=null&&v{var s=i(562),a=i(2003);function l(p,h,v){var x=h(p);return a(p)?x:s(x,v(p))}u.exports=l},6522:(u,g,i)=>{var s=i(6711),a=i(905),l=i(2588),p="[object Null]",h="[object Undefined]",v=s?s.toStringTag:void 0;function x(d){return d==null?d===void 0?h:p:v&&v in Object(d)?a(d):l(d)}u.exports=x},6571:u=>{function g(i,s){return i!=null&&s in Object(i)}u.exports=g},2744:(u,g,i)=>{var s=i(6522),a=i(2620),l="[object Arguments]";function p(h){return a(h)&&s(h)==l}u.exports=p},9336:(u,g,i)=>{var s=i(1894),a=i(2620);function l(p,h,v,x,d){return p===h?!0:p==null||h==null||!a(p)&&!a(h)?p!==p&&h!==h:s(p,h,v,x,l,d)}u.exports=l},1894:(u,g,i)=>{var s=i(6435),a=i(1505),l=i(9620),p=i(439),h=i(695),v=i(2003),x=i(1262),d=i(9221),m=1,S="[object Arguments]",C="[object Array]",A="[object Object]",P=Object.prototype,F=P.hasOwnProperty;function H(R,D,k,L,U,z){var J=v(R),K=v(D),$=J?C:h(R),ee=K?C:h(D);$=$==S?A:$,ee=ee==S?A:ee;var V=$==A,ae=ee==A,W=$==ee;if(W&&x(R)){if(!x(D))return!1;J=!0,V=!1}if(W&&!V)return z||(z=new s),J||d(R)?a(R,D,k,L,U,z):l(R,D,$,k,L,U,z);if(!(k&m)){var ne=V&&F.call(R,"__wrapped__"),ie=ae&&F.call(D,"__wrapped__");if(ne||ie){var G=ne?R.value():R,me=ie?D.value():D;return z||(z=new s),U(G,me,k,L,z)}}return W?(z||(z=new s),p(R,D,k,L,U,z)):!1}u.exports=H},8742:(u,g,i)=>{var s=i(695),a=i(2620),l="[object Map]";function p(h){return a(h)&&s(h)==l}u.exports=p},4253:(u,g,i)=>{var s=i(6435),a=i(9336),l=1,p=2;function h(v,x,d,m){var S=d.length,C=S,A=!m;if(v==null)return!C;for(v=Object(v);S--;){var P=d[S];if(A&&P[2]?P[1]!==v[P[0]]:!(P[0]in v))return!1}for(;++S{var s=i(8148),a=i(1398),l=i(5603),p=i(1543),h=/[\\^$.*+?()[\]{}|]/g,v=/^\[object .+?Constructor\]$/,x=Function.prototype,d=Object.prototype,m=x.toString,S=d.hasOwnProperty,C=RegExp("^"+m.call(S).replace(h,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function A(P){if(!l(P)||a(P))return!1;var F=s(P)?C:v;return F.test(p(P))}u.exports=A},5476:(u,g,i)=>{var s=i(695),a=i(2620),l="[object Set]";function p(h){return a(h)&&s(h)==l}u.exports=p},5387:(u,g,i)=>{var s=i(6522),a=i(7164),l=i(2620),p="[object Arguments]",h="[object Array]",v="[object Boolean]",x="[object Date]",d="[object Error]",m="[object Function]",S="[object Map]",C="[object Number]",A="[object Object]",P="[object RegExp]",F="[object Set]",H="[object String]",R="[object WeakMap]",D="[object ArrayBuffer]",k="[object DataView]",L="[object Float32Array]",U="[object Float64Array]",z="[object Int8Array]",J="[object Int16Array]",K="[object Int32Array]",$="[object Uint8Array]",ee="[object Uint8ClampedArray]",V="[object Uint16Array]",ae="[object Uint32Array]",W={};W[L]=W[U]=W[z]=W[J]=W[K]=W[$]=W[ee]=W[V]=W[ae]=!0,W[p]=W[h]=W[D]=W[v]=W[k]=W[x]=W[d]=W[m]=W[S]=W[C]=W[A]=W[P]=W[F]=W[H]=W[R]=!1;function ne(ie){return l(ie)&&a(ie.length)&&!!W[s(ie)]}u.exports=ne},7675:(u,g,i)=>{var s=i(5141),a=i(8476),l=i(1686),p=i(2003),h=i(7093);function v(x){return typeof x=="function"?x:x==null?l:typeof x=="object"?p(x)?a(x[0],x[1]):s(x):h(x)}u.exports=v},4413:(u,g,i)=>{var s=i(6165),a=i(6132),l=Object.prototype,p=l.hasOwnProperty;function h(v){if(!s(v))return a(v);var x=[];for(var d in Object(v))p.call(v,d)&&d!="constructor"&&x.push(d);return x}u.exports=h},8157:(u,g,i)=>{var s=i(5603),a=i(6165),l=i(4555),p=Object.prototype,h=p.hasOwnProperty;function v(x){if(!s(x))return l(x);var d=a(x),m=[];for(var S in x)S=="constructor"&&(d||!h.call(x,S))||m.push(S);return m}u.exports=v},5718:(u,g,i)=>{var s=i(7587),a=i(6316);function l(p,h){var v=-1,x=a(p)?Array(p.length):[];return s(p,function(d,m,S){x[++v]=h(d,m,S)}),x}u.exports=l},5141:(u,g,i)=>{var s=i(4253),a=i(8418),l=i(3591);function p(h){var v=a(h);return v.length==1&&v[0][2]?l(v[0][0],v[0][1]):function(x){return x===h||s(x,h,v)}}u.exports=p},8476:(u,g,i)=>{var s=i(9336),a=i(1214),l=i(8765),p=i(5456),h=i(7030),v=i(3591),x=i(8059),d=1,m=2;function S(C,A){return p(C)&&h(A)?v(x(C),A):function(P){var F=a(P,C);return F===void 0&&F===A?l(P,C):s(A,F,d|m)}}u.exports=S},1171:u=>{function g(i){return function(s){return s==null?void 0:s[i]}}u.exports=g},4589:(u,g,i)=>{var s=i(384);function a(l){return function(p){return s(p,l)}}u.exports=a},5410:u=>{function g(i,s){for(var a=-1,l=Array(i);++a{var s=i(6711),a=i(14),l=i(2003),p=i(6596),h=1/0,v=s?s.prototype:void 0,x=v?v.toString:void 0;function d(m){if(typeof m=="string")return m;if(l(m))return a(m,d)+"";if(p(m))return x?x.call(m):"";var S=m+"";return S=="0"&&1/m==-h?"-0":S}u.exports=d},2347:u=>{function g(i){return function(s){return i(s)}}u.exports=g},7585:u=>{function g(i,s){return i.has(s)}u.exports=g},2072:(u,g,i)=>{var s=i(1686);function a(l){return typeof l=="function"?l:s}u.exports=a},4275:(u,g,i)=>{var s=i(2003),a=i(5456),l=i(5240),p=i(7060);function h(v,x){return s(v)?v:a(v,x)?[v]:l(p(v))}u.exports=h},1987:(u,g,i)=>{var s=i(9282);function a(l){var p=new l.constructor(l.byteLength);return new s(p).set(new s(l)),p}u.exports=a},2932:(u,g,i)=>{u=i.nmd(u);var s=i(9107),a=g&&!g.nodeType&&g,l=a&&!0&&u&&!u.nodeType&&u,p=l&&l.exports===a,h=p?s.Buffer:void 0,v=h?h.allocUnsafe:void 0;function x(d,m){if(m)return d.slice();var S=d.length,C=v?v(S):new d.constructor(S);return d.copy(C),C}u.exports=x},3931:(u,g,i)=>{var s=i(1987);function a(l,p){var h=p?s(l.buffer):l.buffer;return new l.constructor(h,l.byteOffset,l.byteLength)}u.exports=a},3640:u=>{var g=/\w*$/;function i(s){var a=new s.constructor(s.source,g.exec(s));return a.lastIndex=s.lastIndex,a}u.exports=i},6878:(u,g,i)=>{var s=i(6711),a=s?s.prototype:void 0,l=a?a.valueOf:void 0;function p(h){return l?Object(l.call(h)):{}}u.exports=p},3859:(u,g,i)=>{var s=i(1987);function a(l,p){var h=p?s(l.buffer):l.buffer;return new l.constructor(h,l.byteOffset,l.length)}u.exports=a},9061:u=>{function g(i,s){var a=-1,l=i.length;for(s||(s=Array(l));++a{var s=i(6645),a=i(9330);function l(p,h,v,x){var d=!v;v||(v={});for(var m=-1,S=h.length;++m{var s=i(8113),a=i(6806);function l(p,h){return s(p,a(p),h)}u.exports=l},8038:(u,g,i)=>{var s=i(8113),a=i(8718);function l(p,h){return s(p,a(p),h)}u.exports=l},3887:(u,g,i)=>{var s=i(9107),a=s["__core-js_shared__"];u.exports=a},3679:(u,g,i)=>{var s=i(6316);function a(l,p){return function(h,v){if(h==null)return h;if(!s(h))return l(h,v);for(var x=h.length,d=p?x:-1,m=Object(h);(p?d--:++d{function g(i){return function(s,a,l){for(var p=-1,h=Object(s),v=l(s),x=v.length;x--;){var d=v[i?x:++p];if(a(h[d],d,h)===!1)break}return s}}u.exports=g},7771:(u,g,i)=>{var s=i(3984),a=function(){try{var l=s(Object,"defineProperty");return l({},"",{}),l}catch(p){}}();u.exports=a},1505:(u,g,i)=>{var s=i(1641),a=i(9854),l=i(7585),p=1,h=2;function v(x,d,m,S,C,A){var P=m&p,F=x.length,H=d.length;if(F!=H&&!(P&&H>F))return!1;var R=A.get(x),D=A.get(d);if(R&&D)return R==d&&D==x;var k=-1,L=!0,U=m&h?new s:void 0;for(A.set(x,d),A.set(d,x);++k{var s=i(6711),a=i(9282),l=i(8330),p=i(1505),h=i(5483),v=i(5841),x=1,d=2,m="[object Boolean]",S="[object Date]",C="[object Error]",A="[object Map]",P="[object Number]",F="[object RegExp]",H="[object Set]",R="[object String]",D="[object Symbol]",k="[object ArrayBuffer]",L="[object DataView]",U=s?s.prototype:void 0,z=U?U.valueOf:void 0;function J(K,$,ee,V,ae,W,ne){switch(ee){case L:if(K.byteLength!=$.byteLength||K.byteOffset!=$.byteOffset)return!1;K=K.buffer,$=$.buffer;case k:return!(K.byteLength!=$.byteLength||!W(new a(K),new a($)));case m:case S:case P:return l(+K,+$);case C:return K.name==$.name&&K.message==$.message;case F:case R:return K==$+"";case A:var ie=h;case H:var G=V&x;if(ie||(ie=v),K.size!=$.size&&!G)return!1;var me=ne.get(K);if(me)return me==$;V|=d,ne.set(K,$);var ft=p(ie(K),ie($),V,ae,W,ne);return ne.delete(K),ft;case D:if(z)return z.call(K)==z.call($)}return!1}u.exports=J},439:(u,g,i)=>{var s=i(5760),a=1,l=Object.prototype,p=l.hasOwnProperty;function h(v,x,d,m,S,C){var A=d&a,P=s(v),F=P.length,H=s(x),R=H.length;if(F!=R&&!A)return!1;for(var D=F;D--;){var k=P[D];if(!(A?k in x:p.call(x,k)))return!1}var L=C.get(v),U=C.get(x);if(L&&U)return L==x&&U==v;var z=!0;C.set(v,x),C.set(x,v);for(var J=A;++D{var s=typeof i.g=="object"&&i.g&&i.g.Object===Object&&i.g;u.exports=s},5760:(u,g,i)=>{var s=i(8821),a=i(6806),l=i(5304);function p(h){return s(h,l,a)}u.exports=p},3183:(u,g,i)=>{var s=i(8821),a=i(8718),l=i(7495);function p(h){return s(h,l,a)}u.exports=p},6929:(u,g,i)=>{var s=i(9732);function a(l,p){var h=l.__data__;return s(p)?h[typeof p=="string"?"string":"hash"]:h.map}u.exports=a},8418:(u,g,i)=>{var s=i(7030),a=i(5304);function l(p){for(var h=a(p),v=h.length;v--;){var x=h[v],d=p[x];h[v]=[x,d,s(d)]}return h}u.exports=l},3984:(u,g,i)=>{var s=i(2249),a=i(1074);function l(p,h){var v=a(p,h);return s(v)?v:void 0}u.exports=l},5425:(u,g,i)=>{var s=i(889),a=s(Object.getPrototypeOf,Object);u.exports=a},905:(u,g,i)=>{var s=i(6711),a=Object.prototype,l=a.hasOwnProperty,p=a.toString,h=s?s.toStringTag:void 0;function v(x){var d=l.call(x,h),m=x[h];try{x[h]=void 0;var S=!0}catch(A){}var C=p.call(x);return S&&(d?x[h]=m:delete x[h]),C}u.exports=v},6806:(u,g,i)=>{var s=i(3928),a=i(119),l=Object.prototype,p=l.propertyIsEnumerable,h=Object.getOwnPropertySymbols,v=h?function(x){return x==null?[]:(x=Object(x),s(h(x),function(d){return p.call(x,d)}))}:a;u.exports=v},8718:(u,g,i)=>{var s=i(562),a=i(5425),l=i(6806),p=i(119),h=Object.getOwnPropertySymbols,v=h?function(x){for(var d=[];x;)s(d,l(x)),x=a(x);return d}:p;u.exports=v},695:(u,g,i)=>{var s=i(7230),a=i(5661),l=i(9102),p=i(5963),h=i(2850),v=i(6522),x=i(1543),d="[object Map]",m="[object Object]",S="[object Promise]",C="[object Set]",A="[object WeakMap]",P="[object DataView]",F=x(s),H=x(a),R=x(l),D=x(p),k=x(h),L=v;(s&&L(new s(new ArrayBuffer(1)))!=P||a&&L(new a)!=d||l&&L(l.resolve())!=S||p&&L(new p)!=C||h&&L(new h)!=A)&&(L=function(U){var z=v(U),J=z==m?U.constructor:void 0,K=J?x(J):"";if(K)switch(K){case F:return P;case H:return d;case R:return S;case D:return C;case k:return A}return z}),u.exports=L},1074:u=>{function g(i,s){return i==null?void 0:i[s]}u.exports=g},2248:(u,g,i)=>{var s=i(4275),a=i(2382),l=i(2003),p=i(2615),h=i(7164),v=i(8059);function x(d,m,S){m=s(m,d);for(var C=-1,A=m.length,P=!1;++C{var s=i(6060);function a(){this.__data__=s?s(null):{},this.size=0}u.exports=a},9484:u=>{function g(i){var s=this.has(i)&&delete this.__data__[i];return this.size-=s?1:0,s}u.exports=g},7215:(u,g,i)=>{var s=i(6060),a="__lodash_hash_undefined__",l=Object.prototype,p=l.hasOwnProperty;function h(v){var x=this.__data__;if(s){var d=x[v];return d===a?void 0:d}return p.call(x,v)?x[v]:void 0}u.exports=h},7811:(u,g,i)=>{var s=i(6060),a=Object.prototype,l=a.hasOwnProperty;function p(h){var v=this.__data__;return s?v[h]!==void 0:l.call(v,h)}u.exports=p},747:(u,g,i)=>{var s=i(6060),a="__lodash_hash_undefined__";function l(p,h){var v=this.__data__;return this.size+=this.has(p)?0:1,v[p]=s&&h===void 0?a:h,this}u.exports=l},9303:u=>{var g=Object.prototype,i=g.hasOwnProperty;function s(a){var l=a.length,p=new a.constructor(l);return l&&typeof a[0]=="string"&&i.call(a,"index")&&(p.index=a.index,p.input=a.input),p}u.exports=s},7766:(u,g,i)=>{var s=i(1987),a=i(3931),l=i(3640),p=i(6878),h=i(3859),v="[object Boolean]",x="[object Date]",d="[object Map]",m="[object Number]",S="[object RegExp]",C="[object Set]",A="[object String]",P="[object Symbol]",F="[object ArrayBuffer]",H="[object DataView]",R="[object Float32Array]",D="[object Float64Array]",k="[object Int8Array]",L="[object Int16Array]",U="[object Int32Array]",z="[object Uint8Array]",J="[object Uint8ClampedArray]",K="[object Uint16Array]",$="[object Uint32Array]";function ee(V,ae,W){var ne=V.constructor;switch(ae){case F:return s(V);case v:case x:return new ne(+V);case H:return a(V,W);case R:case D:case k:case L:case U:case z:case J:case K:case $:return h(V,W);case d:return new ne;case m:case A:return new ne(V);case S:return l(V);case C:return new ne;case P:return p(V)}}u.exports=ee},3991:(u,g,i)=>{var s=i(3962),a=i(5425),l=i(6165);function p(h){return typeof h.constructor=="function"&&!l(h)?s(a(h)):{}}u.exports=p},2615:u=>{var g=9007199254740991,i=/^(?:0|[1-9]\d*)$/;function s(a,l){var p=typeof a;return l=l==null?g:l,!!l&&(p=="number"||p!="symbol"&&i.test(a))&&a>-1&&a%1==0&&a{var s=i(2003),a=i(6596),l=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,p=/^\w*$/;function h(v,x){if(s(v))return!1;var d=typeof v;return d=="number"||d=="symbol"||d=="boolean"||v==null||a(v)?!0:p.test(v)||!l.test(v)||x!=null&&v in Object(x)}u.exports=h},9732:u=>{function g(i){var s=typeof i;return s=="string"||s=="number"||s=="symbol"||s=="boolean"?i!=="__proto__":i===null}u.exports=g},1398:(u,g,i)=>{var s=i(3887),a=function(){var p=/[^.]+$/.exec(s&&s.keys&&s.keys.IE_PROTO||"");return p?"Symbol(src)_1."+p:""}();function l(p){return!!a&&a in p}u.exports=l},6165:u=>{var g=Object.prototype;function i(s){var a=s&&s.constructor,l=typeof a=="function"&&a.prototype||g;return s===l}u.exports=i},7030:(u,g,i)=>{var s=i(5603);function a(l){return l===l&&!s(l)}u.exports=a},4412:u=>{function g(){this.__data__=[],this.size=0}u.exports=g},8522:(u,g,i)=>{var s=i(4767),a=Array.prototype,l=a.splice;function p(h){var v=this.__data__,x=s(v,h);if(x<0)return!1;var d=v.length-1;return x==d?v.pop():l.call(v,x,1),--this.size,!0}u.exports=p},469:(u,g,i)=>{var s=i(4767);function a(l){var p=this.__data__,h=s(p,l);return h<0?void 0:p[h][1]}u.exports=a},1161:(u,g,i)=>{var s=i(4767);function a(l){return s(this.__data__,l)>-1}u.exports=a},1441:(u,g,i)=>{var s=i(4767);function a(l,p){var h=this.__data__,v=s(h,l);return v<0?(++this.size,h.push([l,p])):h[v][1]=p,this}u.exports=a},8206:(u,g,i)=>{var s=i(3435),a=i(5217),l=i(5661);function p(){this.size=0,this.__data__={hash:new s,map:new(l||a),string:new s}}u.exports=p},9768:(u,g,i)=>{var s=i(6929);function a(l){var p=s(this,l).delete(l);return this.size-=p?1:0,p}u.exports=a},6827:(u,g,i)=>{var s=i(6929);function a(l){return s(this,l).get(l)}u.exports=a},663:(u,g,i)=>{var s=i(6929);function a(l){return s(this,l).has(l)}u.exports=a},5135:(u,g,i)=>{var s=i(6929);function a(l,p){var h=s(this,l),v=h.size;return h.set(l,p),this.size+=h.size==v?0:1,this}u.exports=a},5483:u=>{function g(i){var s=-1,a=Array(i.size);return i.forEach(function(l,p){a[++s]=[p,l]}),a}u.exports=g},3591:u=>{function g(i,s){return function(a){return a==null?!1:a[i]===s&&(s!==void 0||i in Object(a))}}u.exports=g},874:(u,g,i)=>{var s=i(9513),a=500;function l(p){var h=s(p,function(x){return v.size===a&&v.clear(),x}),v=h.cache;return h}u.exports=l},6060:(u,g,i)=>{var s=i(3984),a=s(Object,"create");u.exports=a},6132:(u,g,i)=>{var s=i(889),a=s(Object.keys,Object);u.exports=a},4555:u=>{function g(i){var s=[];if(i!=null)for(var a in Object(i))s.push(a);return s}u.exports=g},8315:(u,g,i)=>{u=i.nmd(u);var s=i(2718),a=g&&!g.nodeType&&g,l=a&&!0&&u&&!u.nodeType&&u,p=l&&l.exports===a,h=p&&s.process,v=function(){try{var x=l&&l.require&&l.require("util").types;return x||h&&h.binding&&h.binding("util")}catch(d){}}();u.exports=v},2588:u=>{var g=Object.prototype,i=g.toString;function s(a){return i.call(a)}u.exports=s},889:u=>{function g(i,s){return function(a){return i(s(a))}}u.exports=g},9107:(u,g,i)=>{var s=i(2718),a=typeof self=="object"&&self&&self.Object===Object&&self,l=s||a||Function("return this")();u.exports=l},2486:u=>{var g="__lodash_hash_undefined__";function i(s){return this.__data__.set(s,g),this}u.exports=i},9361:u=>{function g(i){return this.__data__.has(i)}u.exports=g},5841:u=>{function g(i){var s=-1,a=Array(i.size);return i.forEach(function(l){a[++s]=l}),a}u.exports=g},8658:(u,g,i)=>{var s=i(5217);function a(){this.__data__=new s,this.size=0}u.exports=a},3844:u=>{function g(i){var s=this.__data__,a=s.delete(i);return this.size=s.size,a}u.exports=g},6503:u=>{function g(i){return this.__data__.get(i)}u.exports=g},1563:u=>{function g(i){return this.__data__.has(i)}u.exports=g},259:(u,g,i)=>{var s=i(5217),a=i(5661),l=i(3287),p=200;function h(v,x){var d=this.__data__;if(d instanceof s){var m=d.__data__;if(!a||m.length{var s=i(874),a=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,l=/\\(\\)?/g,p=s(function(h){var v=[];return h.charCodeAt(0)===46&&v.push(""),h.replace(a,function(x,d,m,S){v.push(m?S.replace(l,"$1"):d||x)}),v});u.exports=p},8059:(u,g,i)=>{var s=i(6596),a=1/0;function l(p){if(typeof p=="string"||s(p))return p;var h=p+"";return h=="0"&&1/p==-a?"-0":h}u.exports=l},1543:u=>{var g=Function.prototype,i=g.toString;function s(a){if(a!=null){try{return i.call(a)}catch(l){}try{return a+""}catch(l){}}return""}u.exports=s},5390:(u,g,i)=>{var s=i(1937),a=1,l=4;function p(h){return s(h,a|l)}u.exports=p},8330:u=>{function g(i,s){return i===s||i!==i&&s!==s}u.exports=g},1633:(u,g,i)=>{var s=i(427),a=i(2072);function l(p,h){return p&&s(p,a(h))}u.exports=l},1214:(u,g,i)=>{var s=i(384);function a(l,p,h){var v=l==null?void 0:s(l,p);return v===void 0?h:v}u.exports=a},8765:(u,g,i)=>{var s=i(6571),a=i(2248);function l(p,h){return p!=null&&a(p,h,s)}u.exports=l},1686:u=>{function g(i){return i}u.exports=g},2382:(u,g,i)=>{var s=i(2744),a=i(2620),l=Object.prototype,p=l.hasOwnProperty,h=l.propertyIsEnumerable,v=s(function(){return arguments}())?s:function(x){return a(x)&&p.call(x,"callee")&&!h.call(x,"callee")};u.exports=v},2003:u=>{var g=Array.isArray;u.exports=g},6316:(u,g,i)=>{var s=i(8148),a=i(7164);function l(p){return p!=null&&a(p.length)&&!s(p)}u.exports=l},1262:(u,g,i)=>{u=i.nmd(u);var s=i(9107),a=i(2125),l=g&&!g.nodeType&&g,p=l&&!0&&u&&!u.nodeType&&u,h=p&&p.exports===l,v=h?s.Buffer:void 0,x=v?v.isBuffer:void 0,d=x||a;u.exports=d},8148:(u,g,i)=>{var s=i(6522),a=i(5603),l="[object AsyncFunction]",p="[object Function]",h="[object GeneratorFunction]",v="[object Proxy]";function x(d){if(!a(d))return!1;var m=s(d);return m==p||m==h||m==l||m==v}u.exports=x},7164:u=>{var g=9007199254740991;function i(s){return typeof s=="number"&&s>-1&&s%1==0&&s<=g}u.exports=i},5652:(u,g,i)=>{var s=i(8742),a=i(2347),l=i(8315),p=l&&l.isMap,h=p?a(p):s;u.exports=h},5603:u=>{function g(i){var s=typeof i;return i!=null&&(s=="object"||s=="function")}u.exports=g},2620:u=>{function g(i){return i!=null&&typeof i=="object"}u.exports=g},1449:(u,g,i)=>{var s=i(6522),a=i(5425),l=i(2620),p="[object Object]",h=Function.prototype,v=Object.prototype,x=h.toString,d=v.hasOwnProperty,m=x.call(Object);function S(C){if(!l(C)||s(C)!=p)return!1;var A=a(C);if(A===null)return!0;var P=d.call(A,"constructor")&&A.constructor;return typeof P=="function"&&P instanceof P&&x.call(P)==m}u.exports=S},9318:(u,g,i)=>{var s=i(5476),a=i(2347),l=i(8315),p=l&&l.isSet,h=p?a(p):s;u.exports=h},3085:(u,g,i)=>{var s=i(6522),a=i(2003),l=i(2620),p="[object String]";function h(v){return typeof v=="string"||!a(v)&&l(v)&&s(v)==p}u.exports=h},6596:(u,g,i)=>{var s=i(6522),a=i(2620),l="[object Symbol]";function p(h){return typeof h=="symbol"||a(h)&&s(h)==l}u.exports=p},9221:(u,g,i)=>{var s=i(5387),a=i(2347),l=i(8315),p=l&&l.isTypedArray,h=p?a(p):s;u.exports=h},5304:(u,g,i)=>{var s=i(7137),a=i(4413),l=i(6316);function p(h){return l(h)?s(h):a(h)}u.exports=p},7495:(u,g,i)=>{var s=i(7137),a=i(8157),l=i(6316);function p(h){return l(h)?s(h,!0):a(h)}u.exports=p},7528:(u,g,i)=>{var s=i(14),a=i(7675),l=i(5718),p=i(2003);function h(v,x){var d=p(v)?s:l;return d(v,a(x,3))}u.exports=h},9513:(u,g,i)=>{var s=i(3287),a="Expected a function";function l(p,h){if(typeof p!="function"||h!=null&&typeof h!="function")throw new TypeError(a);var v=function(){var x=arguments,d=h?h.apply(this,x):x[0],m=v.cache;if(m.has(d))return m.get(d);var S=p.apply(this,x);return v.cache=m.set(d,S)||m,S};return v.cache=new(l.Cache||s),v}l.Cache=s,u.exports=l},7093:(u,g,i)=>{var s=i(1171),a=i(4589),l=i(5456),p=i(8059);function h(v){return l(v)?s(p(v)):a(v)}u.exports=h},119:u=>{function g(){return[]}u.exports=g},2125:u=>{function g(){return!1}u.exports=g},7060:(u,g,i)=>{var s=i(8354);function a(l){return l==null?"":s(l)}u.exports=a},5385:(u,g,i)=>{"use strict";i.d(g,{xk:()=>Wf});var s=i(8437),a=i.n(s),l=i(9325),p=function(e,r,n,o,c){var f=c.clientWidth,b=c.clientHeight,y=typeof e.pageX=="number"?e.pageX:e.touches[0].pageX,w=typeof e.pageY=="number"?e.pageY:e.touches[0].pageY,E=y-(c.getBoundingClientRect().left+window.pageXOffset),_=w-(c.getBoundingClientRect().top+window.pageYOffset);if(n==="vertical"){var O=void 0;if(_<0?O=0:_>b?O=1:O=Math.round(_*100/b)/100,r.a!==O)return{h:r.h,s:r.s,l:r.l,a:O,source:"rgb"}}else{var T=void 0;if(E<0?T=0:E>f?T=1:T=Math.round(E*100/f)/100,o!==T)return{h:r.h,s:r.s,l:r.l,a:T,source:"rgb"}}return null},h={},v=function(e,r,n,o){if(typeof document=="undefined"&&!o)return null;var c=o?new o:document.createElement("canvas");c.width=n*2,c.height=n*2;var f=c.getContext("2d");return f?(f.fillStyle=e,f.fillRect(0,0,c.width,c.height),f.fillStyle=r,f.fillRect(0,0,n,n),f.translate(n,n),f.fillRect(0,0,n,n),c.toDataURL()):null},x=function(e,r,n,o){var c=e+"-"+r+"-"+n+(o?"-server":"");if(h[c])return h[c];var f=v(e,r,n,o);return h[c]=f,f},d=Object.assign||function(t){for(var e=1;e-1},W=function(e){return Number(String(e).replace(/%/g,""))},ne=1,ie=function(t){J(e,t);function e(r){U(this,e);var n=z(this,(e.__proto__||Object.getPrototypeOf(e)).call(this));return n.handleBlur=function(){n.state.blurValue&&n.setState({value:n.state.blurValue,blurValue:null})},n.handleChange=function(o){n.setUpdatedValue(o.target.value,o)},n.handleKeyDown=function(o){var c=W(o.target.value);if(!isNaN(c)&&ae(o.keyCode)){var f=n.getArrowOffset(),b=o.keyCode===$?c+f:c-f;n.setUpdatedValue(b,o)}},n.handleDrag=function(o){if(n.props.dragLabel){var c=Math.round(n.props.value+o.movementX);c>=0&&c<=n.props.dragMax&&n.props.onChange&&n.props.onChange(n.getValueObjectWithLabel(c),o)}},n.handleMouseDown=function(o){n.props.dragLabel&&(o.preventDefault(),n.handleDrag(o),window.addEventListener("mousemove",n.handleDrag),window.addEventListener("mouseup",n.handleMouseUp))},n.handleMouseUp=function(){n.unbindEventListeners()},n.unbindEventListeners=function(){window.removeEventListener("mousemove",n.handleDrag),window.removeEventListener("mouseup",n.handleMouseUp)},n.state={value:String(r.value).toUpperCase(),blurValue:String(r.value).toUpperCase()},n.inputId="rc-editable-input-"+ne++,n}return k(e,[{key:"componentDidUpdate",value:function(n,o){this.props.value!==this.state.value&&(n.value!==this.props.value||o.value!==this.state.value)&&(this.input===document.activeElement?this.setState({blurValue:String(this.props.value).toUpperCase()}):this.setState({value:String(this.props.value).toUpperCase(),blurValue:!this.state.blurValue&&String(this.props.value).toUpperCase()}))}},{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"getValueObjectWithLabel",value:function(n){return L({},this.props.label,n)}},{key:"getArrowOffset",value:function(){return this.props.arrowOffset||K}},{key:"setUpdatedValue",value:function(n,o){var c=this.props.label?this.getValueObjectWithLabel(n):n;this.props.onChange&&this.props.onChange(c,o),this.setState({value:n})}},{key:"render",value:function(){var n=this,o=(0,l.Ay)({default:{wrap:{position:"relative"}},"user-override":{wrap:this.props.style&&this.props.style.wrap?this.props.style.wrap:{},input:this.props.style&&this.props.style.input?this.props.style.input:{},label:this.props.style&&this.props.style.label?this.props.style.label:{}},"dragLabel-true":{label:{cursor:"ew-resize"}}},{"user-override":!0},this.props);return a().createElement("div",{style:o.wrap},a().createElement("input",{id:this.inputId,style:o.input,ref:function(f){return n.input=f},value:this.state.value,onKeyDown:this.handleKeyDown,onChange:this.handleChange,onBlur:this.handleBlur,placeholder:this.props.placeholder,spellCheck:"false"}),this.props.label&&!this.props.hideLabel?a().createElement("label",{htmlFor:this.inputId,style:o.label,onMouseDown:this.handleMouseDown},this.props.label):null)}}]),e}(s.PureComponent||s.Component);const G=ie;var me=function(e,r,n,o){var c=o.clientWidth,f=o.clientHeight,b=typeof e.pageX=="number"?e.pageX:e.touches[0].pageX,y=typeof e.pageY=="number"?e.pageY:e.touches[0].pageY,w=b-(o.getBoundingClientRect().left+window.pageXOffset),E=y-(o.getBoundingClientRect().top+window.pageYOffset);if(r==="vertical"){var _=void 0;if(E<0)_=359;else if(E>f)_=0;else{var O=-(E*100/f)+100;_=360*O/100}if(n.h!==_)return{h:_,s:n.s,l:n.l,a:n.a,source:"hsl"}}else{var T=void 0;if(w<0)T=0;else if(w>c)T=359;else{var j=w*100/c;T=360*j/100}if(n.h!==T)return{h:T,s:n.s,l:n.l,a:n.a,source:"hsl"}}return null},ft=function(){function t(e,r){for(var n=0;n-1}const X=nt;function Se(t,e){var r=this.__data__,n=rt(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}const Ee=Se;function Ce(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e-1&&t%1==0&&t<=Jo}const sr=Qo;function qo(t){return t!=null&&sr(t.length)&&!rr(t)}const ct=qo;function ei(t){return Oe(t)&&ct(t)}const ti=ei;function ri(){return!1}const ni=ri;var en=typeof exports=="object"&&exports&&!exports.nodeType&&exports,tn=en&&typeof module=="object"&&module&&!module.nodeType&&module,ai=tn&&tn.exports===en,rn=ai?te.Buffer:void 0,oi=rn?rn.isBuffer:void 0,ii=oi||ni;const Bt=ii;var si="[object Object]",li=Function.prototype,ci=Object.prototype,nn=li.toString,ui=ci.hasOwnProperty,fi=nn.call(Object);function pi(t){if(!Oe(t)||Fe(t)!=si)return!1;var e=Jr(t);if(e===null)return!0;var r=ui.call(e,"constructor")&&e.constructor;return typeof r=="function"&&r instanceof r&&nn.call(r)==fi}const hi=pi;var di="[object Arguments]",gi="[object Array]",bi="[object Boolean]",vi="[object Date]",xi="[object Error]",yi="[object Function]",mi="[object Map]",wi="[object Number]",Si="[object Object]",Ei="[object RegExp]",Ci="[object Set]",_i="[object String]",Ai="[object WeakMap]",Oi="[object ArrayBuffer]",Ti="[object DataView]",Pi="[object Float32Array]",Mi="[object Float64Array]",Ri="[object Int8Array]",Fi="[object Int16Array]",Bi="[object Int32Array]",ji="[object Uint8Array]",Ii="[object Uint8ClampedArray]",Hi="[object Uint16Array]",Di="[object Uint32Array]",Q={};Q[Pi]=Q[Mi]=Q[Ri]=Q[Fi]=Q[Bi]=Q[ji]=Q[Ii]=Q[Hi]=Q[Di]=!0,Q[di]=Q[gi]=Q[Oi]=Q[bi]=Q[Ti]=Q[vi]=Q[xi]=Q[yi]=Q[mi]=Q[wi]=Q[Si]=Q[Ei]=Q[Ci]=Q[_i]=Q[Ai]=!1;function Li(t){return Oe(t)&&sr(t.length)&&!!Q[Fe(t)]}const Ni=Li;function ki(t){return function(e){return t(e)}}const Gi=ki;var an=typeof exports=="object"&&exports&&!exports.nodeType&&exports,vt=an&&typeof module=="object"&&module&&!module.nodeType&&module,Ui=vt&&vt.exports===an,lr=Ui&&At.process,zi=function(){try{var t=vt&&vt.require&&vt.require("util").types;return t||lr&&lr.binding&&lr.binding("util")}catch(e){}}();const on=zi;var sn=on&&on.isTypedArray,$i=sn?Gi(sn):Ni;const cr=$i;function Wi(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}const ur=Wi;var Ki=Object.prototype,Xi=Ki.hasOwnProperty;function Vi(t,e,r){var n=t[e];(!(Xi.call(t,e)&&Re(n,r))||r===void 0&&!(e in t))&&ar(t,e,r)}const Yi=Vi;function Zi(t,e,r,n){var o=!r;r||(r={});for(var c=-1,f=e.length;++c-1&&t%1==0&&t0){if(++e>=Os)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var Rs=Ms(As);const Fs=Rs;function Bs(t,e){return Fs(Ss(t,e,jt),t+"")}const js=Bs;function Is(t,e,r){if(!he(r))return!1;var n=typeof e;return(n=="number"?ct(r)&&fr(e,r.length):n=="string"&&e in r)?Re(r[e],t):!1}const Hs=Is;function Ds(t){return js(function(e,r){var n=-1,o=r.length,c=o>1?r[o-1]:void 0,f=o>2?r[2]:void 0;for(c=t.length>3&&typeof c=="function"?(o--,c):void 0,f&&Hs(r[0],r[1],f)&&(c=o<3?void 0:c,o=1),e=Object(e);++n=e||Me<0||_&&St>=c}function Z(){var re=dr();if(N(re))return fe(re);b=setTimeout(Z,I(re))}function fe(re){return b=void 0,O&&n?T(re):(n=o=void 0,f)}function tt(){b!==void 0&&clearTimeout(b),w=0,n=y=o=b=void 0}function pe(){return b===void 0?f:fe(dr())}function Pe(){var re=dr(),Me=N(re);if(n=arguments,o=this,y=re,Me){if(b===void 0)return j(y);if(_)return clearTimeout(b),b=setTimeout(Z,e),T(y)}return b===void 0&&(b=setTimeout(Z,e)),f}return Pe.cancel=tt,Pe.flush=pe,Pe}const dn=rl;var nl="Expected a function";function al(t,e,r){var n=!0,o=!0;if(typeof t!="function")throw new TypeError(nl);return he(r)&&(n="leading"in r?!!r.leading:n,o="trailing"in r?!!r.trailing:o),dn(t,e,{leading:n,maxWait:e,trailing:o})}const ol=al;var il=function(e,r,n){var o=n.getBoundingClientRect(),c=o.width,f=o.height,b=typeof e.pageX=="number"?e.pageX:e.touches[0].pageX,y=typeof e.pageY=="number"?e.pageY:e.touches[0].pageY,w=b-(n.getBoundingClientRect().left+window.pageXOffset),E=y-(n.getBoundingClientRect().top+window.pageYOffset);w<0?w=0:w>c&&(w=c),E<0?E=0:E>f&&(E=f);var _=w/c,O=1-E/f;return{h:r.h,s:_,v:O,a:r.a,source:"hsv"}},sl=function(){function t(e,r){for(var n=0;n=0,c=!r&&o&&(e==="hex"||e==="hex6"||e==="hex3"||e==="hex4"||e==="hex8"||e==="name");return c?e==="name"&&this._a===0?this.toName():this.toRgbString():(e==="rgb"&&(n=this.toRgbString()),e==="prgb"&&(n=this.toPercentageRgbString()),(e==="hex"||e==="hex6")&&(n=this.toHexString()),e==="hex3"&&(n=this.toHexString(!0)),e==="hex4"&&(n=this.toHex8String(!0)),e==="hex8"&&(n=this.toHex8String()),e==="name"&&(n=this.toName()),e==="hsl"&&(n=this.toHslString()),e==="hsv"&&(n=this.toHsvString()),n||this.toHexString())},clone:function(){return B(this.toString())},_applyModification:function(e,r){var n=e.apply(null,[this].concat([].slice.call(r)));return this._r=n._r,this._g=n._g,this._b=n._b,this.setAlpha(n._a),this},lighten:function(){return this._applyModification(Nl,arguments)},brighten:function(){return this._applyModification(kl,arguments)},darken:function(){return this._applyModification(Gl,arguments)},desaturate:function(){return this._applyModification(Hl,arguments)},saturate:function(){return this._applyModification(Dl,arguments)},greyscale:function(){return this._applyModification(Ll,arguments)},spin:function(){return this._applyModification(Ul,arguments)},_applyCombination:function(e,r){return e.apply(null,[this].concat([].slice.call(r)))},analogous:function(){return this._applyCombination(Wl,arguments)},complement:function(){return this._applyCombination(zl,arguments)},monochromatic:function(){return this._applyCombination(Kl,arguments)},splitcomplement:function(){return this._applyCombination($l,arguments)},triad:function(){return this._applyCombination(mn,[3])},tetrad:function(){return this._applyCombination(mn,[4])}},B.fromRatio=function(t,e){if(Dt(t)=="object"){var r={};for(var n in t)t.hasOwnProperty(n)&&(n==="a"?r[n]=t[n]:r[n]=xt(t[n]));t=r}return B(t,e)};function Rl(t){var e={r:0,g:0,b:0},r=1,n=null,o=null,c=null,f=!1,b=!1;return typeof t=="string"&&(t=Jl(t)),Dt(t)=="object"&&(ye(t.r)&&ye(t.g)&&ye(t.b)?(e=Fl(t.r,t.g,t.b),f=!0,b=String(t.r).substr(-1)==="%"?"prgb":"rgb"):ye(t.h)&&ye(t.s)&&ye(t.v)?(n=xt(t.s),o=xt(t.v),e=jl(t.h,n,o),f=!0,b="hsv"):ye(t.h)&&ye(t.s)&&ye(t.l)&&(n=xt(t.s),c=xt(t.l),e=Bl(t.h,n,c),f=!0,b="hsl"),t.hasOwnProperty("a")&&(r=t.a)),r=wn(r),{ok:f,format:t.format||b,r:Math.min(255,Math.max(e.r,0)),g:Math.min(255,Math.max(e.g,0)),b:Math.min(255,Math.max(e.b,0)),a:r}}function Fl(t,e,r){return{r:q(t,255)*255,g:q(e,255)*255,b:q(r,255)*255}}function bn(t,e,r){t=q(t,255),e=q(e,255),r=q(r,255);var n=Math.max(t,e,r),o=Math.min(t,e,r),c,f,b=(n+o)/2;if(n==o)c=f=0;else{var y=n-o;switch(f=b>.5?y/(2-n-o):y/(n+o),n){case t:c=(e-r)/y+(e1&&(_-=1),_<1/6?w+(E-w)*6*_:_<1/2?E:_<2/3?w+(E-w)*(2/3-_)*6:w}if(e===0)n=o=c=r;else{var b=r<.5?r*(1+e):r+e-r*e,y=2*r-b;n=f(y,b,t+1/3),o=f(y,b,t),c=f(y,b,t-1/3)}return{r:n*255,g:o*255,b:c*255}}function vn(t,e,r){t=q(t,255),e=q(e,255),r=q(r,255);var n=Math.max(t,e,r),o=Math.min(t,e,r),c,f,b=n,y=n-o;if(f=n===0?0:y/n,n==o)c=0;else{switch(n){case t:c=(e-r)/y+(e>1)+720)%360;--e;)n.h=(n.h+o)%360,c.push(B(n));return c}function Kl(t,e){e=e||6;for(var r=B(t).toHsv(),n=r.h,o=r.s,c=r.v,f=[],b=1/e;e--;)f.push(B({h:n,s:o,v:c})),c=(c+b)%1;return f}B.mix=function(t,e,r){r=r===0?0:r||50;var n=B(t).toRgb(),o=B(e).toRgb(),c=r/100,f={r:(o.r-n.r)*c+n.r,g:(o.g-n.g)*c+n.g,b:(o.b-n.b)*c+n.b,a:(o.a-n.a)*c+n.a};return B(f)},B.readability=function(t,e){var r=B(t),n=B(e);return(Math.max(r.getLuminance(),n.getLuminance())+.05)/(Math.min(r.getLuminance(),n.getLuminance())+.05)},B.isReadable=function(t,e,r){var n=B.readability(t,e),o,c;switch(c=!1,o=Ql(r),o.level+o.size){case"AAsmall":case"AAAlarge":c=n>=4.5;break;case"AAlarge":c=n>=3;break;case"AAAsmall":c=n>=7;break}return c},B.mostReadable=function(t,e,r){var n=null,o=0,c,f,b,y;r=r||{},f=r.includeFallbackColors,b=r.level,y=r.size;for(var w=0;wo&&(o=c,n=B(e[w]));return B.isReadable(t,n,{level:b,size:y})||!f?n:(r.includeFallbackColors=!1,B.mostReadable(t,["#fff","#000"],r))};var br=B.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},Xl=B.hexNames=Vl(br);function Vl(t){var e={};for(var r in t)t.hasOwnProperty(r)&&(e[t[r]]=r);return e}function wn(t){return t=parseFloat(t),(isNaN(t)||t<0||t>1)&&(t=1),t}function q(t,e){Yl(t)&&(t="100%");var r=Zl(t);return t=Math.min(e,Math.max(0,parseFloat(t))),r&&(t=parseInt(t*e,10)/100),Math.abs(t-e)<1e-6?1:t%e/parseFloat(e)}function Lt(t){return Math.min(1,Math.max(0,t))}function ue(t){return parseInt(t,16)}function Yl(t){return typeof t=="string"&&t.indexOf(".")!=-1&&parseFloat(t)===1}function Zl(t){return typeof t=="string"&&t.indexOf("%")!=-1}function de(t){return t.length==1?"0"+t:""+t}function xt(t){return t<=1&&(t=t*100+"%"),t}function Sn(t){return Math.round(parseFloat(t)*255).toString(16)}function En(t){return ue(t)/255}var ge=function(){var t="[-\\+]?\\d+%?",e="[-\\+]?\\d*\\.\\d+%?",r="(?:"+e+")|(?:"+t+")",n="[\\s|\\(]+("+r+")[,|\\s]+("+r+")[,|\\s]+("+r+")\\s*\\)?",o="[\\s|\\(]+("+r+")[,|\\s]+("+r+")[,|\\s]+("+r+")[,|\\s]+("+r+")\\s*\\)?";return{CSS_UNIT:new RegExp(r),rgb:new RegExp("rgb"+n),rgba:new RegExp("rgba"+o),hsl:new RegExp("hsl"+n),hsla:new RegExp("hsla"+o),hsv:new RegExp("hsv"+n),hsva:new RegExp("hsva"+o),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function ye(t){return!!ge.CSS_UNIT.exec(t)}function Jl(t){t=t.replace(Pl,"").replace(Ml,"").toLowerCase();var e=!1;if(br[t])t=br[t],e=!0;else if(t=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var r;return(r=ge.rgb.exec(t))?{r:r[1],g:r[2],b:r[3]}:(r=ge.rgba.exec(t))?{r:r[1],g:r[2],b:r[3],a:r[4]}:(r=ge.hsl.exec(t))?{h:r[1],s:r[2],l:r[3]}:(r=ge.hsla.exec(t))?{h:r[1],s:r[2],l:r[3],a:r[4]}:(r=ge.hsv.exec(t))?{h:r[1],s:r[2],v:r[3]}:(r=ge.hsva.exec(t))?{h:r[1],s:r[2],v:r[3],a:r[4]}:(r=ge.hex8.exec(t))?{r:ue(r[1]),g:ue(r[2]),b:ue(r[3]),a:En(r[4]),format:e?"name":"hex8"}:(r=ge.hex6.exec(t))?{r:ue(r[1]),g:ue(r[2]),b:ue(r[3]),format:e?"name":"hex"}:(r=ge.hex4.exec(t))?{r:ue(r[1]+""+r[1]),g:ue(r[2]+""+r[2]),b:ue(r[3]+""+r[3]),a:En(r[4]+""+r[4]),format:e?"name":"hex8"}:(r=ge.hex3.exec(t))?{r:ue(r[1]+""+r[1]),g:ue(r[2]+""+r[2]),b:ue(r[3]+""+r[3]),format:e?"name":"hex"}:!1}function Ql(t){var e,r;return t=t||{level:"AA",size:"small"},e=(t.level||"AA").toUpperCase(),r=(t.size||"small").toLowerCase(),e!=="AA"&&e!=="AAA"&&(e="AA"),r!=="small"&&r!=="large"&&(r="small"),{level:e,size:r}}var Cn=function(e){var r=["r","g","b","a","h","s","l","v"],n=0,o=0;return Tl(r,function(c){if(e[c]&&(n+=1,isNaN(e[c])||(o+=1),c==="s"||c==="l")){var f=/^\d+%$/;f.test(e[c])&&(o+=1)}}),n===o?e:!1},yt=function(e,r){var n=e.hex?B(e.hex):B(e),o=n.toHsl(),c=n.toHsv(),f=n.toRgb(),b=n.toHex();o.s===0&&(o.h=r||0,c.h=r||0);var y=b==="000000"&&f.a===0;return{hsl:o,hex:y?"transparent":"#"+b,rgb:f,hsv:c,oldHue:e.h||r||o.h,source:e.source}},Te=function(e){if(e==="transparent")return!0;var r=String(e).charAt(0)==="#"?1:0;return e.length!==4+r&&e.length<7+r&&B(e).isValid()},vr=function(e){if(!e)return"#fff";var r=yt(e);if(r.hex==="transparent")return"rgba(0,0,0,0.4)";var n=(r.rgb.r*299+r.rgb.g*587+r.rgb.b*114)/1e3;return n>=128?"#000":"#fff"},Lp={hsl:{a:1,h:0,l:.5,s:1},hex:"#ff0000",rgb:{r:255,g:0,b:0,a:1},hsv:{h:0,s:1,v:1,a:1}},xr=function(e,r){var n=e.replace("\xB0","");return B(r+" ("+n+")")._ok},mt=Object.assign||function(t){for(var e=1;e1&&arguments[1]!==void 0?arguments[1]:"span";return function(n){sc(o,n);function o(){var c,f,b,y;ic(this,o);for(var w=arguments.length,E=Array(w),_=0;_b))return!1;var w=c.get(t),E=c.get(e);if(w&&E)return w==e&&E==t;var _=-1,O=!0,T=r&Ac?new mc:void 0;for(c.set(t,e),c.set(e,t);++_1&&(o.a=1),n.props.onChange({h:n.props.hsl.h,s:n.props.hsl.s,l:n.props.hsl.l,a:Math.round(o.a*100)/100,source:"rgb"},c)):(o.h||o.s||o.l)&&(typeof o.s=="string"&&o.s.includes("%")&&(o.s=o.s.replace("%","")),typeof o.l=="string"&&o.l.includes("%")&&(o.l=o.l.replace("%","")),o.s==1?o.s=.01:o.l==1&&(o.l=.01),n.props.onChange({h:o.h||n.props.hsl.h,s:Number(Qn(o.s)?n.props.hsl.s:o.s),l:Number(Qn(o.l)?n.props.hsl.l:o.l),source:"hsl"},c))},n.showHighlight=function(o){o.currentTarget.style.background="#eee"},n.hideHighlight=function(o){o.currentTarget.style.background="transparent"},r.hsl.a!==1&&r.view==="hex"?n.state={view:"rgb"}:n.state={view:r.view},n}return Df(e,[{key:"render",value:function(){var n=this,o=(0,l.Ay)({default:{wrap:{paddingTop:"16px",display:"flex"},fields:{flex:"1",display:"flex",marginLeft:"-6px"},field:{paddingLeft:"6px",width:"100%"},alpha:{paddingLeft:"6px",width:"100%"},toggle:{width:"32px",textAlign:"right",position:"relative"},icon:{marginRight:"-4px",marginTop:"12px",cursor:"pointer",position:"relative"},iconHighlight:{position:"absolute",width:"24px",height:"28px",background:"#eee",borderRadius:"4px",top:"10px",left:"12px",display:"none"},input:{fontSize:"11px",color:"#333",width:"100%",borderRadius:"2px",border:"none",boxShadow:"inset 0 0 0 1px #dadada",height:"21px",textAlign:"center"},label:{textTransform:"uppercase",fontSize:"11px",lineHeight:"11px",color:"#969696",textAlign:"center",display:"block",marginTop:"12px"},svg:{fill:"#333",width:"24px",height:"24px",border:"1px transparent solid",borderRadius:"5px"}},disableAlpha:{alpha:{display:"none"}}},this.props,this.state),c=void 0;return this.state.view==="hex"?c=a().createElement("div",{style:o.fields,className:"flexbox-fix"},a().createElement("div",{style:o.field},a().createElement(G,{style:{input:o.input,label:o.label},label:"hex",value:this.props.hex,onChange:this.handleChange}))):this.state.view==="rgb"?c=a().createElement("div",{style:o.fields,className:"flexbox-fix"},a().createElement("div",{style:o.field},a().createElement(G,{style:{input:o.input,label:o.label},label:"r",value:this.props.rgb.r,onChange:this.handleChange})),a().createElement("div",{style:o.field},a().createElement(G,{style:{input:o.input,label:o.label},label:"g",value:this.props.rgb.g,onChange:this.handleChange})),a().createElement("div",{style:o.field},a().createElement(G,{style:{input:o.input,label:o.label},label:"b",value:this.props.rgb.b,onChange:this.handleChange})),a().createElement("div",{style:o.alpha},a().createElement(G,{style:{input:o.input,label:o.label},label:"a",value:this.props.rgb.a,arrowOffset:.01,onChange:this.handleChange}))):this.state.view==="hsl"&&(c=a().createElement("div",{style:o.fields,className:"flexbox-fix"},a().createElement("div",{style:o.field},a().createElement(G,{style:{input:o.input,label:o.label},label:"h",value:Math.round(this.props.hsl.h),onChange:this.handleChange})),a().createElement("div",{style:o.field},a().createElement(G,{style:{input:o.input,label:o.label},label:"s",value:Math.round(this.props.hsl.s*100)+"%",onChange:this.handleChange})),a().createElement("div",{style:o.field},a().createElement(G,{style:{input:o.input,label:o.label},label:"l",value:Math.round(this.props.hsl.l*100)+"%",onChange:this.handleChange})),a().createElement("div",{style:o.alpha},a().createElement(G,{style:{input:o.input,label:o.label},label:"a",value:this.props.hsl.a,arrowOffset:.01,onChange:this.handleChange})))),a().createElement("div",{style:o.wrap,className:"flexbox-fix"},c,a().createElement("div",{style:o.toggle},a().createElement("div",{style:o.icon,onClick:this.toggleViews,ref:function(b){return n.icon=b}},a().createElement(Hf.A,{style:o.svg,onMouseOver:this.showHighlight,onMouseEnter:this.showHighlight,onMouseOut:this.hideHighlight}))))}}],[{key:"getDerivedStateFromProps",value:function(n,o){return n.hsl.a!==1&&o.view==="hex"?{view:"rgb"}:null}}]),e}(a().Component);qn.defaultProps={view:"hex"};const Gf=qn;var Uf=function(){var e=(0,l.Ay)({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",transform:"translate(-6px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}}});return a().createElement("div",{style:e.picker})};const ea=Uf;var zf=function(){var e=(0,l.Ay)({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",boxShadow:"inset 0 0 0 1px #fff",transform:"translate(-6px, -6px)"}}});return a().createElement("div",{style:e.picker})};const $f=zf;var Tr=function(e){var r=e.width,n=e.onChange,o=e.disableAlpha,c=e.rgb,f=e.hsl,b=e.hsv,y=e.hex,w=e.renderers,E=e.styles,_=E===void 0?{}:E,O=e.className,T=O===void 0?"":O,j=e.defaultView,I=(0,l.Ay)(se({default:{picker:{width:r,background:"#fff",borderRadius:"2px",boxShadow:"0 0 2px rgba(0,0,0,.3), 0 4px 8px rgba(0,0,0,.3)",boxSizing:"initial",fontFamily:"Menlo"},saturation:{width:"100%",paddingBottom:"55%",position:"relative",borderRadius:"2px 2px 0 0",overflow:"hidden"},Saturation:{radius:"2px 2px 0 0"},body:{padding:"16px 16px 12px"},controls:{display:"flex"},color:{width:"32px"},swatch:{marginTop:"6px",width:"16px",height:"16px",borderRadius:"8px",position:"relative",overflow:"hidden"},active:{absolute:"0px 0px 0px 0px",borderRadius:"8px",boxShadow:"inset 0 0 0 1px rgba(0,0,0,.1)",background:"rgba("+c.r+", "+c.g+", "+c.b+", "+c.a+")",zIndex:"2"},toggles:{flex:"1"},hue:{height:"10px",position:"relative",marginBottom:"8px"},Hue:{radius:"2px"},alpha:{height:"10px",position:"relative"},Alpha:{radius:"2px"}},disableAlpha:{color:{width:"22px"},alpha:{display:"none"},hue:{marginBottom:"0px"},swatch:{width:"10px",height:"10px",marginTop:"0px"}}},_),{disableAlpha:o});return a().createElement("div",{style:I.picker,className:"chrome-picker "+T},a().createElement("div",{style:I.saturation},a().createElement(Ht,{style:I.Saturation,hsl:f,hsv:b,pointer:$f,onChange:n})),a().createElement("div",{style:I.body},a().createElement("div",{style:I.controls,className:"flexbox-fix"},a().createElement("div",{style:I.color},a().createElement("div",{style:I.swatch},a().createElement("div",{style:I.active}),a().createElement(S,{renderers:w}))),a().createElement("div",{style:I.toggles},a().createElement("div",{style:I.hue},a().createElement(we,{style:I.Hue,hsl:f,pointer:ea,onChange:n})),a().createElement("div",{style:I.alpha},a().createElement(D,{style:I.Alpha,rgb:c,hsl:f,pointer:ea,renderers:w,onChange:n})))),a().createElement(Gf,{rgb:c,hsl:f,hex:y,view:j,onChange:n,disableAlpha:o})))};Tr.propTypes={width:M().oneOfType([M().string,M().number]),disableAlpha:M().bool,styles:M().object,defaultView:M().oneOf(["hex","rgb","hsl"])},Tr.defaultProps={width:225,disableAlpha:!1,styles:{}};const Wf=le(Tr);var Kf=function(e){var r=e.color,n=e.onClick,o=n===void 0?function(){}:n,c=e.onSwatchHover,f=e.active,b=(0,l.Ay)({default:{color:{background:r,width:"15px",height:"15px",float:"left",marginRight:"5px",marginBottom:"5px",position:"relative",cursor:"pointer"},dot:{absolute:"5px 5px 5px 5px",background:vr(r),borderRadius:"50%",opacity:"0"}},active:{dot:{opacity:"1"}},"color-#FFFFFF":{color:{boxShadow:"inset 0 0 0 1px #ddd"},dot:{background:"#000"}},transparent:{dot:{background:"#000"}}},{active:f,"color-#FFFFFF":r==="#FFFFFF",transparent:r==="transparent"});return a().createElement(Ie,{style:b.color,color:r,onClick:o,onHover:c,focusStyle:{boxShadow:"0 0 4px "+r}},a().createElement("div",{style:b.dot}))};const Xf=Kf;var Vf=function(e){var r=e.hex,n=e.rgb,o=e.onChange,c=(0,l.Ay)({default:{fields:{display:"flex",paddingBottom:"6px",paddingRight:"5px",position:"relative"},active:{position:"absolute",top:"6px",left:"5px",height:"9px",width:"9px",background:r},HEXwrap:{flex:"6",position:"relative"},HEXinput:{width:"80%",padding:"0px",paddingLeft:"20%",border:"none",outline:"none",background:"none",fontSize:"12px",color:"#333",height:"16px"},HEXlabel:{display:"none"},RGBwrap:{flex:"3",position:"relative"},RGBinput:{width:"70%",padding:"0px",paddingLeft:"30%",border:"none",outline:"none",background:"none",fontSize:"12px",color:"#333",height:"16px"},RGBlabel:{position:"absolute",top:"3px",left:"0px",lineHeight:"16px",textTransform:"uppercase",fontSize:"12px",color:"#999"}}}),f=function(y,w){y.r||y.g||y.b?o({r:y.r||n.r,g:y.g||n.g,b:y.b||n.b,source:"rgb"},w):o({hex:y.hex,source:"hex"},w)};return a().createElement("div",{style:c.fields,className:"flexbox-fix"},a().createElement("div",{style:c.active}),a().createElement(G,{style:{wrap:c.HEXwrap,input:c.HEXinput,label:c.HEXlabel},label:"hex",value:r,onChange:f}),a().createElement(G,{style:{wrap:c.RGBwrap,input:c.RGBinput,label:c.RGBlabel},label:"r",value:n.r,onChange:f}),a().createElement(G,{style:{wrap:c.RGBwrap,input:c.RGBinput,label:c.RGBlabel},label:"g",value:n.g,onChange:f}),a().createElement(G,{style:{wrap:c.RGBwrap,input:c.RGBinput,label:c.RGBlabel},label:"b",value:n.b,onChange:f}))};const Yf=Vf;var Pr=function(e){var r=e.onChange,n=e.onSwatchHover,o=e.colors,c=e.hex,f=e.rgb,b=e.styles,y=b===void 0?{}:b,w=e.className,E=w===void 0?"":w,_=(0,l.Ay)(se({default:{Compact:{background:"#f6f6f6",radius:"4px"},compact:{paddingTop:"5px",paddingLeft:"5px",boxSizing:"initial",width:"240px"},clear:{clear:"both"}}},y)),O=function(j,I){j.hex?Te(j.hex)&&r({hex:j.hex,source:"hex"},I):r(j,I)};return a().createElement(hr,{style:_.Compact,styles:y},a().createElement("div",{style:_.compact,className:"compact-picker "+E},a().createElement("div",null,De(o,function(T){return a().createElement(Xf,{key:T,color:T,active:T.toLowerCase()===c,onClick:O,onSwatchHover:n})}),a().createElement("div",{style:_.clear})),a().createElement(Yf,{hex:c,rgb:f,onChange:O})))};Pr.propTypes={colors:M().arrayOf(M().string),styles:M().object},Pr.defaultProps={colors:["#4D4D4D","#999999","#FFFFFF","#F44E3B","#FE9200","#FCDC00","#DBDF00","#A4DD00","#68CCCA","#73D8FF","#AEA1FF","#FDA1FF","#333333","#808080","#cccccc","#D33115","#E27300","#FCC400","#B0BC00","#68BC00","#16A5A5","#009CE0","#7B64FF","#FA28FF","#000000","#666666","#B3B3B3","#9F0500","#C45100","#FB9E00","#808900","#194D33","#0C797D","#0062B1","#653294","#AB149E"],styles:{}};const zp=le(Pr);var Zf=function(e){var r=e.hover,n=e.color,o=e.onClick,c=e.onSwatchHover,f={position:"relative",zIndex:"2",outline:"2px solid #fff",boxShadow:"0 0 5px 2px rgba(0,0,0,0.25)"},b=(0,l.Ay)({default:{swatch:{width:"25px",height:"25px",fontSize:"0"}},hover:{swatch:f}},{hover:r});return a().createElement("div",{style:b.swatch},a().createElement(Ie,{color:n,onClick:o,onHover:c,focusStyle:f}))};const Jf=(0,l.H8)(Zf);var Mr=function(e){var r=e.width,n=e.colors,o=e.onChange,c=e.onSwatchHover,f=e.triangle,b=e.styles,y=b===void 0?{}:b,w=e.className,E=w===void 0?"":w,_=(0,l.Ay)(se({default:{card:{width:r,background:"#fff",border:"1px solid rgba(0,0,0,0.2)",boxShadow:"0 3px 12px rgba(0,0,0,0.15)",borderRadius:"4px",position:"relative",padding:"5px",display:"flex",flexWrap:"wrap"},triangle:{position:"absolute",border:"7px solid transparent",borderBottomColor:"#fff"},triangleShadow:{position:"absolute",border:"8px solid transparent",borderBottomColor:"rgba(0,0,0,0.15)"}},"hide-triangle":{triangle:{display:"none"},triangleShadow:{display:"none"}},"top-left-triangle":{triangle:{top:"-14px",left:"10px"},triangleShadow:{top:"-16px",left:"9px"}},"top-right-triangle":{triangle:{top:"-14px",right:"10px"},triangleShadow:{top:"-16px",right:"9px"}},"bottom-left-triangle":{triangle:{top:"35px",left:"10px",transform:"rotate(180deg)"},triangleShadow:{top:"37px",left:"9px",transform:"rotate(180deg)"}},"bottom-right-triangle":{triangle:{top:"35px",right:"10px",transform:"rotate(180deg)"},triangleShadow:{top:"37px",right:"9px",transform:"rotate(180deg)"}}},y),{"hide-triangle":f==="hide","top-left-triangle":f==="top-left","top-right-triangle":f==="top-right","bottom-left-triangle":f==="bottom-left","bottom-right-triangle":f==="bottom-right"}),O=function(j,I){return o({hex:j,source:"hex"},I)};return a().createElement("div",{style:_.card,className:"github-picker "+E},a().createElement("div",{style:_.triangleShadow}),a().createElement("div",{style:_.triangle}),De(n,function(T){return a().createElement(Jf,{color:T,key:T,onClick:O,onSwatchHover:c})}))};Mr.propTypes={width:M().oneOfType([M().string,M().number]),colors:M().arrayOf(M().string),triangle:M().oneOf(["hide","top-left","top-right","bottom-left","bottom-right"]),styles:M().object},Mr.defaultProps={width:200,colors:["#B80000","#DB3E00","#FCCB00","#008B02","#006B76","#1273DE","#004DCF","#5300EB","#EB9694","#FAD0C3","#FEF3BD","#C1E1C5","#BEDADC","#C4DEF6","#BED3F3","#D4C4FB"],triangle:"top-left",styles:{}};const $p=le(Mr);var Qf=function(e){var r=e.direction,n=(0,l.Ay)({default:{picker:{width:"18px",height:"18px",borderRadius:"50%",transform:"translate(-9px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}},vertical:{picker:{transform:"translate(-3px, -9px)"}}},{vertical:r==="vertical"});return a().createElement("div",{style:n.picker})};const qf=Qf;var ep=Object.assign||function(t){for(var e=1;e.5});return a().createElement("div",{style:n.picker})};const op=ap;var ip=function(){var e=(0,l.Ay)({default:{triangle:{width:0,height:0,borderStyle:"solid",borderWidth:"4px 0 4px 6px",borderColor:"transparent transparent transparent #fff",position:"absolute",top:"1px",left:"1px"},triangleBorder:{width:0,height:0,borderStyle:"solid",borderWidth:"5px 0 5px 8px",borderColor:"transparent transparent transparent #555"},left:{Extend:"triangleBorder",transform:"translate(-13px, -4px)"},leftInside:{Extend:"triangle",transform:"translate(-8px, -5px)"},right:{Extend:"triangleBorder",transform:"translate(20px, -14px) rotate(180deg)"},rightInside:{Extend:"triangle",transform:"translate(-8px, -5px)"}}});return a().createElement("div",{style:e.pointer},a().createElement("div",{style:e.left},a().createElement("div",{style:e.leftInside})),a().createElement("div",{style:e.right},a().createElement("div",{style:e.rightInside})))};const sp=ip;var lp=function(e){var r=e.onClick,n=e.label,o=e.children,c=e.active,f=(0,l.Ay)({default:{button:{backgroundImage:"linear-gradient(-180deg, #FFFFFF 0%, #E6E6E6 100%)",border:"1px solid #878787",borderRadius:"2px",height:"20px",boxShadow:"0 1px 0 0 #EAEAEA",fontSize:"14px",color:"#000",lineHeight:"20px",textAlign:"center",marginBottom:"10px",cursor:"pointer"}},active:{button:{boxShadow:"0 0 0 1px #878787"}}},{active:c});return a().createElement("div",{style:f.button,onClick:r},n||o)};const ta=lp;var cp=function(e){var r=e.rgb,n=e.currentColor,o=(0,l.Ay)({default:{swatches:{border:"1px solid #B3B3B3",borderBottom:"1px solid #F0F0F0",marginBottom:"2px",marginTop:"1px"},new:{height:"34px",background:"rgb("+r.r+","+r.g+", "+r.b+")",boxShadow:"inset 1px 0 0 #000, inset -1px 0 0 #000, inset 0 1px 0 #000"},current:{height:"34px",background:n,boxShadow:"inset 1px 0 0 #000, inset -1px 0 0 #000, inset 0 -1px 0 #000"},label:{fontSize:"14px",color:"#000",textAlign:"center"}}});return a().createElement("div",null,a().createElement("div",{style:o.label},"new"),a().createElement("div",{style:o.swatches},a().createElement("div",{style:o.new}),a().createElement("div",{style:o.current})),a().createElement("div",{style:o.label},"current"))};const up=cp;var fp=function(){function t(e,r){for(var n=0;n100&&(E.a=100),E.a/=100,r({h:o.h,s:o.s,l:o.l,a:E.a,source:"rgb"},_))};return a().createElement("div",{style:b.fields,className:"flexbox-fix"},a().createElement("div",{style:b.double},a().createElement(G,{style:{input:b.input,label:b.label},label:"hex",value:c.replace("#",""),onChange:y})),a().createElement("div",{style:b.single},a().createElement(G,{style:{input:b.input,label:b.label},label:"r",value:n.r,onChange:y,dragLabel:"true",dragMax:"255"})),a().createElement("div",{style:b.single},a().createElement(G,{style:{input:b.input,label:b.label},label:"g",value:n.g,onChange:y,dragLabel:"true",dragMax:"255"})),a().createElement("div",{style:b.single},a().createElement(G,{style:{input:b.input,label:b.label},label:"b",value:n.b,onChange:y,dragLabel:"true",dragMax:"255"})),a().createElement("div",{style:b.alpha},a().createElement(G,{style:{input:b.input,label:b.label},label:"a",value:Math.round(n.a*100),onChange:y,dragLabel:"true",dragMax:"100"})))};const bp=gp;var vp=Object.assign||function(t){for(var e=1;e{"use strict";Object.defineProperty(g,"__esModule",{value:!0}),g.autoprefix=void 0;var s=i(1633),a=p(s),l=Object.assign||function(x){for(var d=1;d{"use strict";Object.defineProperty(g,"__esModule",{value:!0}),g.active=void 0;var s=Object.assign||function(m){for(var S=1;S1&&arguments[1]!==void 0?arguments[1]:"span";return function(A){x(P,A);function P(){var F,H,R,D;h(this,P);for(var k=arguments.length,L=Array(k),U=0;U{"use strict";Object.defineProperty(g,"__esModule",{value:!0}),g.hover=void 0;var s=Object.assign||function(m){for(var S=1;S1&&arguments[1]!==void 0?arguments[1]:"span";return function(A){x(P,A);function P(){var F,H,R,D;h(this,P);for(var k=arguments.length,L=Array(k),U=0;U{"use strict";Object.defineProperty(g,"__esModule",{value:!0}),g.flattenNames=void 0;var s=i(3085),a=m(s),l=i(1633),p=m(l),h=i(1449),v=m(h),x=i(7528),d=m(x);function m(C){return C&&C.__esModule?C:{default:C}}var S=g.flattenNames=function C(){var A=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],P=[];return(0,d.default)(A,function(F){Array.isArray(F)?C(F).map(function(H){return P.push(H)}):(0,v.default)(F)?(0,p.default)(F,function(H,R){H===!0&&P.push(R),P.push(R+"-"+H)}):(0,a.default)(F)&&P.push(F)}),P};g.default=S},9325:(u,g,i)=>{"use strict";var s;s={value:!0},s=s=s=g.H8=s=void 0;var a=i(2471),l=F(a),p=i(3705),h=F(p),v=i(5686),x=F(v),d=i(6444),m=F(d),S=i(9970),C=F(S),A=i(6491),P=F(A);function F(R){return R&&R.__esModule?R:{default:R}}s=m.default,g.H8=m.default,s=C.default,s=P.default;var H=s=function(D){for(var k=arguments.length,L=Array(k>1?k-1:0),U=1;U{"use strict";Object.defineProperty(g,"__esModule",{value:!0});var i=function(a,l){var p={},h=function(x){var d=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;p[x]=d};return a===0&&h("first-child"),a===l-1&&h("last-child"),(a===0||a%2===0)&&h("even"),Math.abs(a%2)===1&&h("odd"),h("nth-child",a),p};g.default=i},3705:(u,g,i)=>{"use strict";Object.defineProperty(g,"__esModule",{value:!0}),g.mergeClasses=void 0;var s=i(1633),a=v(s),l=i(5390),p=v(l),h=Object.assign||function(d){for(var m=1;m1&&arguments[1]!==void 0?arguments[1]:[],C=m.default&&(0,p.default)(m.default)||{};return S.map(function(A){var P=m[A];return P&&(0,a.default)(P,function(F,H){C[H]||(C[H]={}),C[H]=h({},C[H],P[H])}),A}),C};g.default=x}}]); + +//# sourceMappingURL=vendors-node_modules_react-color_es_index_js.4d1bf1cc.chunk.js.map \ No newline at end of file diff --git a/admin/custom/static/js/vendors-node_modules_react-color_es_index_js.4d1bf1cc.chunk.js.map b/admin/custom/static/js/vendors-node_modules_react-color_es_index_js.4d1bf1cc.chunk.js.map new file mode 100644 index 0000000..e800a48 --- /dev/null +++ b/admin/custom/static/js/vendors-node_modules_react-color_es_index_js.4d1bf1cc.chunk.js.map @@ -0,0 +1 @@ +{"version":3,"file":"static/js/vendors-node_modules_react-color_es_index_js.4d1bf1cc.chunk.js","mappings":"8MAEA,EAA6C,CAC3C,MAAO,EACT,EAEA,IAAIA,EAAW,OAAO,QAAU,SAAUC,EAAQ,CAAE,QAASC,EAAI,EAAGA,EAAI,UAAU,OAAQA,IAAK,CAAE,IAAIC,EAAS,UAAUD,CAAC,EAAG,QAASE,KAAOD,EAAc,OAAO,UAAU,eAAe,KAAKA,EAAQC,CAAG,IAAKH,EAAOG,CAAG,EAAID,EAAOC,CAAG,EAAO,CAAE,OAAOH,CAAQ,EAE3PI,EAAS,EAAQ,IAAO,EAExBC,EAAUC,EAAuBF,CAAM,EAE3C,SAASE,EAAuBC,EAAK,CAAE,OAAOA,GAAOA,EAAI,WAAaA,EAAM,CAAE,QAASA,CAAI,CAAG,CAE9F,SAASC,EAAyBD,EAAKE,EAAM,CAAE,IAAIT,EAAS,CAAC,EAAG,QAASC,KAAKM,EAAWE,EAAK,QAAQR,CAAC,GAAK,G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,CAC9C+Y,EAAO/Y,CAAG,IACb+Y,EAAO/Y,CAAG,EAAI,CAAC,GAGjB+Y,EAAO/Y,CAAG,EAAIJ,EAAS,CAAC,EAAGmZ,EAAO/Y,CAAG,EAAGo0B,EAAQp0B,CAAG,CAAC,CACtD,CAAC,EAGI2xB,CACT,CAAC,EACM5Y,CACT,EAEAvY,EAAA,QAAkB2zB,C","sources":["../node_modules/@icons/material/CheckIcon.js","../node_modules/@icons/material/UnfoldMoreHorizontalIcon.js","../node_modules/lodash/_DataView.js","../node_modules/lodash/_Hash.js","../node_modules/lodash/_ListCache.js","../node_modules/lodash/_Map.js","../node_modules/lodash/_MapCache.js","../node_modules/lodash/_Promise.js","../node_modules/lodash/_Set.js","../node_modules/lodash/_SetCache.js","../node_modules/lodash/_Stack.js","../node_modules/lodash/_Symbol.js","../node_modules/lodash/_Uint8Array.js","../node_modules/lodash/_WeakMap.js","../node_modules/lodash/_arrayEach.js","../node_modules/lodash/_arrayFilter.js","../node_modules/lodash/_arrayLikeKeys.js","../node_modules/lodash/_arrayMap.js","../node_modules/lodash/_arrayPush.js","../node_modules/lodash/_arraySome.js","../node_modules/lodash/_assignValue.js","../node_modules/lodash/_assocIndexOf.js","../node_modules/lodash/_baseAssign.js","../node_modules/lodash/_baseAssignIn.js","../node_modules/lodash/_baseAssignValue.js","../node_modules/lodash/_baseClone.js","../node_modules/lodash/_baseCreate.js","../node_modules/lodash/_baseEach.js","../node_modules/lodash/_baseFor.js","../node_modules/lodash/_baseForOwn.js","../node_modules/lodash/_baseGet.js","../node_modules/lodash/_baseGetAllKeys.js","../node_modules/lodash/_baseGetTag.js","../node_modules/lodash/_baseHasIn.js","../node_modules/lodash/_baseIsArguments.js","../node_modules/lodash/_baseIsEqual.js","../node_modules/lodash/_baseIsEqualDeep.js","../node_modules/lodash/_baseIsMap.js","../node_modules/lodash/_baseIsMatch.js","../node_modules/lodash/_baseIsNative.js","../node_modules/lodash/_baseIsSet.js","../node_modules/lodash/_baseIsTypedArray.js","../node_modules/lodash/_baseIteratee.js","../node_modules/lodash/_baseKeys.js","../node_modules/lodash/_baseKeysIn.js","../node_modules/lodash/_baseMap.js","../node_modules/lodash/_baseMatches.js","../node_modules/lodash/_baseMatchesProperty.js","../node_modules/lodash/_baseProperty.js","../node_modules/lodash/_basePropertyDeep.js","../node_modules/lodash/_baseTimes.js","../node_modules/lodash/_baseToString.js","../node_modules/lodash/_baseUnary.js","../node_modules/lodash/_cacheHas.js","../node_modules/lodash/_castFunction.js","../node_modules/lodash/_castPath.js","../node_modules/lodash/_cloneArrayBuffer.js","../node_modules/lodash/_cloneBuffer.js","../node_modules/lodash/_cloneDataView.js","../node_modules/lodash/_cloneRegExp.js","../node_modules/lodash/_cloneSymbol.js","../node_modules/lodash/_cloneTypedArray.js","../node_modules/lodash/_copyArray.js","../node_modules/lodash/_copyObject.js","../node_modules/lodash/_copySymbols.js","../node_modules/lodash/_copySymbolsIn.js","../node_modules/lodash/_coreJsData.js","../node_modules/lodash/_createBaseEach.js","../node_modules/lodash/_createBaseFor.js","../node_modules/lodash/_defineProperty.js","../node_modules/lodash/_equalArrays.js","../node_modules/lodash/_equalByTag.js","../node_modules/lodash/_equalObjects.js","../node_modules/lodash/_freeGlobal.js","../node_modules/lodash/_getAllKeys.js","../node_modules/lodash/_getAllKeysIn.js","../node_modules/lodash/_getMapData.js","../node_modules/lodash/_getMatchData.js","../node_modules/lodash/_getNative.js","../node_modules/lodash/_getPrototype.js","../node_modules/lodash/_getRawTag.js","../node_modules/lodash/_getSymbols.js","../node_modules/lodash/_getSymbolsIn.js","../node_modules/lodash/_getTag.js","../node_modules/lodash/_getValue.js","../node_modules/lodash/_hasPath.js","../node_modules/lodash/_hashClear.js","../node_modules/lodash/_hashDelete.js","../node_modules/lodash/_hashGet.js","../node_modules/lodash/_hashHas.js","../node_modules/lodash/_hashSet.js","../node_modules/lodash/_initCloneArray.js","../node_modules/lodash/_initCloneByTag.js","../node_modules/lodash/_initCloneObject.js","../node_modules/lodash/_isIndex.js","../node_modules/lodash/_isKey.js","../node_modules/lodash/_isKeyable.js","../node_modules/lodash/_isMasked.js","../node_modules/lodash/_isPrototype.js","../node_modules/lodash/_isStrictComparable.js","../node_modules/lodash/_listCacheClear.js","../node_modules/lodash/_listCacheDelete.js","../node_modules/lodash/_listCacheGet.js","../node_modules/lodash/_listCacheHas.js","../node_modules/lodash/_listCacheSet.js","../node_modules/lodash/_mapCacheClear.js","../node_modules/lodash/_mapCacheDelete.js","../node_modules/lodash/_mapCacheGet.js","../node_modules/lodash/_mapCacheHas.js","../node_modules/lodash/_mapCacheSet.js","../node_modules/lodash/_mapToArray.js","../node_modules/lodash/_matchesStrictComparable.js","../node_modules/lodash/_memoizeCapped.js","../node_modules/lodash/_nativeCreate.js","../node_modules/lodash/_nativeKeys.js","../node_modules/lodash/_nativeKeysIn.js","../node_modules/lodash/_nodeUtil.js","../node_modules/lodash/_objectToString.js","../node_modules/lodash/_overArg.js","../node_modules/lodash/_root.js","../node_modules/lodash/_setCacheAdd.js","../node_modules/lodash/_setCacheHas.js","../node_modules/lodash/_setToArray.js","../node_modules/lodash/_stackClear.js","../node_modules/lodash/_stackDelete.js","../node_modules/lodash/_stackGet.js","../node_modules/lodash/_stackHas.js","../node_modules/lodash/_stackSet.js","../node_modules/lodash/_stringToPath.js","../node_modules/lodash/_toKey.js","../node_modules/lodash/_toSource.js","../node_modules/lodash/cloneDeep.js","../node_modules/lodash/eq.js","../node_modules/lodash/forOwn.js","../node_modules/lodash/get.js","../node_modules/lodash/hasIn.js","../node_modules/lodash/identity.js","../node_modules/lodash/isArguments.js","../node_modules/lodash/isArray.js","../node_modules/lodash/isArrayLike.js","../node_modules/lodash/isBuffer.js","../node_modules/lodash/isFunction.js","../node_modules/lodash/isLength.js","../node_modules/lodash/isMap.js","../node_modules/lodash/isObject.js","../node_modules/lodash/isObjectLike.js","../node_modules/lodash/isPlainObject.js","../node_modules/lodash/isSet.js","../node_modules/lodash/isString.js","../node_modules/lodash/isSymbol.js","../node_modules/lodash/isTypedArray.js","../node_modules/lodash/keys.js","../node_modules/lodash/keysIn.js","../node_modules/lodash/map.js","../node_modules/lodash/memoize.js","../node_modules/lodash/property.js","../node_modules/lodash/stubArray.js","../node_modules/lodash/stubFalse.js","../node_modules/lodash/toString.js","../node_modules/react-color/es/helpers/alpha.js","../node_modules/react-color/es/helpers/checkboard.js","../node_modules/react-color/es/components/common/Checkboard.js","../node_modules/react-color/es/components/common/Alpha.js","../node_modules/react-color/es/components/common/EditableInput.js","../node_modules/react-color/es/helpers/hue.js","../node_modules/react-color/es/components/common/Hue.js","../node_modules/lodash-es/_listCacheClear.js","../node_modules/lodash-es/eq.js","../node_modules/lodash-es/_assocIndexOf.js","../node_modules/lodash-es/_listCacheDelete.js","../node_modules/lodash-es/_listCacheGet.js","../node_modules/lodash-es/_listCacheHas.js","../node_modules/lodash-es/_listCacheSet.js","../node_modules/lodash-es/_ListCache.js","../node_modules/lodash-es/_stackClear.js","../node_modules/lodash-es/_stackDelete.js","../node_modules/lodash-es/_stackGet.js","../node_modules/lodash-es/_stackHas.js","../node_modules/lodash-es/_freeGlobal.js","../node_modules/lodash-es/_root.js","../node_modules/lodash-es/_Symbol.js","../node_modules/lodash-es/_getRawTag.js","../node_modules/lodash-es/_objectToString.js","../node_modules/lodash-es/_baseGetTag.js","../node_modules/lodash-es/isObject.js","../node_modules/lodash-es/isFunction.js","../node_modules/lodash-es/_coreJsData.js","../node_modules/lodash-es/_isMasked.js","../node_modules/lodash-es/_toSource.js","../node_modules/lodash-es/_baseIsNative.js","../node_modules/lodash-es/_getValue.js","../node_modules/lodash-es/_getNative.js","../node_modules/lodash-es/_Map.js","../node_modules/lodash-es/_nativeCreate.js","../node_modules/lodash-es/_hashClear.js","../node_modules/lodash-es/_hashDelete.js","../node_modules/lodash-es/_hashGet.js","../node_modules/lodash-es/_hashHas.js","../node_modules/lodash-es/_hashSet.js","../node_modules/lodash-es/_Hash.js","../node_modules/lodash-es/_mapCacheClear.js","../node_modules/lodash-es/_isKeyable.js","../node_modules/lodash-es/_getMapData.js","../node_modules/lodash-es/_mapCacheDelete.js","../node_modules/lodash-es/_mapCacheGet.js","../node_modules/lodash-es/_mapCacheHas.js","../node_modules/lodash-es/_mapCacheSet.js","../node_modules/lodash-es/_MapCache.js","../node_modules/lodash-es/_stackSet.js","../node_modules/lodash-es/_Stack.js","../node_modules/lodash-es/_defineProperty.js","../node_modules/lodash-es/_baseAssignValue.js","../node_modules/lodash-es/_assignMergeValue.js","../node_modules/lodash-es/_createBaseFor.js","../node_modules/lodash-es/_baseFor.js","../node_modules/lodash-es/_cloneBuffer.js","../node_modules/lodash-es/_Uint8Array.js","../node_modules/lodash-es/_cloneArrayBuffer.js","../node_modules/lodash-es/_cloneTypedArray.js","../node_modules/lodash-es/_copyArray.js","../node_modules/lodash-es/_baseCreate.js","../node_modules/lodash-es/_overArg.js","../node_modules/lodash-es/_getPrototype.js","../node_modules/lodash-es/_isPrototype.js","../node_modules/lodash-es/_initCloneObject.js","../node_modules/lodash-es/isObjectLike.js","../node_modules/lodash-es/_baseIsArguments.js","../node_modules/lodash-es/isArguments.js","../node_modules/lodash-es/isArray.js","../node_modules/lodash-es/isLength.js","../node_modules/lodash-es/isArrayLike.js","../node_modules/lodash-es/isArrayLikeObject.js","../node_modules/lodash-es/stubFalse.js","../node_modules/lodash-es/isBuffer.js","../node_modules/lodash-es/isPlainObject.js","../node_modules/lodash-es/_baseIsTypedArray.js","../node_modules/lodash-es/_baseUnary.js","../node_modules/lodash-es/_nodeUtil.js","../node_modules/lodash-es/isTypedArray.js","../node_modules/lodash-es/_safeGet.js","../node_modules/lodash-es/_assignValue.js","../node_modules/lodash-es/_copyObject.js","../node_modules/lodash-es/_baseTimes.js","../node_modules/lodash-es/_isIndex.js","../node_modules/lodash-es/_arrayLikeKeys.js","../node_modules/lodash-es/_nativeKeysIn.js","../node_modules/lodash-es/_baseKeysIn.js","../node_modules/lodash-es/keysIn.js","../node_modules/lodash-es/toPlainObject.js","../node_modules/lodash-es/_baseMergeDeep.js","../node_modules/lodash-es/_baseMerge.js","../node_modules/lodash-es/identity.js","../node_modules/lodash-es/_apply.js","../node_modules/lodash-es/_overRest.js","../node_modules/lodash-es/constant.js","../node_modules/lodash-es/_baseSetToString.js","../node_modules/lodash-es/_shortOut.js","../node_modules/lodash-es/_setToString.js","../node_modules/lodash-es/_baseRest.js","../node_modules/lodash-es/_isIterateeCall.js","../node_modules/lodash-es/_createAssigner.js","../node_modules/lodash-es/merge.js","../node_modules/react-color/es/components/common/Raised.js","../node_modules/lodash-es/now.js","../node_modules/lodash-es/_trimmedEndIndex.js","../node_modules/lodash-es/_baseTrim.js","../node_modules/lodash-es/isSymbol.js","../node_modules/lodash-es/toNumber.js","../node_modules/lodash-es/debounce.js","../node_modules/lodash-es/throttle.js","../node_modules/react-color/es/helpers/saturation.js","../node_modules/react-color/es/components/common/Saturation.js","../node_modules/lodash-es/_arrayEach.js","../node_modules/lodash-es/_nativeKeys.js","../node_modules/lodash-es/_baseKeys.js","../node_modules/lodash-es/keys.js","../node_modules/lodash-es/_baseForOwn.js","../node_modules/lodash-es/_createBaseEach.js","../node_modules/lodash-es/_baseEach.js","../node_modules/lodash-es/_castFunction.js","../node_modules/lodash-es/forEach.js","../node_modules/tinycolor2/esm/tinycolor.js","../node_modules/react-color/es/helpers/color.js","../node_modules/react-color/es/components/common/ColorWrap.js","../node_modules/react-color/es/helpers/interaction.js","../node_modules/react-color/es/components/common/Swatch.js","../node_modules/react-color/es/components/alpha/AlphaPointer.js","../node_modules/react-color/es/components/alpha/Alpha.js","../node_modules/lodash-es/_arrayMap.js","../node_modules/lodash-es/_setCacheAdd.js","../node_modules/lodash-es/_setCacheHas.js","../node_modules/lodash-es/_SetCache.js","../node_modules/lodash-es/_arraySome.js","../node_modules/lodash-es/_cacheHas.js","../node_modules/lodash-es/_equalArrays.js","../node_modules/lodash-es/_mapToArray.js","../node_modules/lodash-es/_setToArray.js","../node_modules/lodash-es/_equalByTag.js","../node_modules/lodash-es/_arrayPush.js","../node_modules/lodash-es/_baseGetAllKeys.js","../node_modules/lodash-es/_arrayFilter.js","../node_modules/lodash-es/stubArray.js","../node_modules/lodash-es/_getSymbols.js","../node_modules/lodash-es/_getAllKeys.js","../node_modules/lodash-es/_equalObjects.js","../node_modules/lodash-es/_DataView.js","../node_modules/lodash-es/_Promise.js","../node_modules/lodash-es/_Set.js","../node_modules/lodash-es/_WeakMap.js","../node_modules/lodash-es/_getTag.js","../node_modules/lodash-es/_baseIsEqualDeep.js","../node_modules/lodash-es/_baseIsEqual.js","../node_modules/lodash-es/_baseIsMatch.js","../node_modules/lodash-es/_isStrictComparable.js","../node_modules/lodash-es/_getMatchData.js","../node_modules/lodash-es/_matchesStrictComparable.js","../node_modules/lodash-es/_baseMatches.js","../node_modules/lodash-es/_isKey.js","../node_modules/lodash-es/memoize.js","../node_modules/lodash-es/_memoizeCapped.js","../node_modules/lodash-es/_stringToPath.js","../node_modules/lodash-es/_baseToString.js","../node_modules/lodash-es/toString.js","../node_modules/lodash-es/_castPath.js","../node_modules/lodash-es/_toKey.js","../node_modules/lodash-es/_baseGet.js","../node_modules/lodash-es/get.js","../node_modules/lodash-es/_baseHasIn.js","../node_modules/lodash-es/_hasPath.js","../node_modules/lodash-es/hasIn.js","../node_modules/lodash-es/_baseMatchesProperty.js","../node_modules/lodash-es/_baseProperty.js","../node_modules/lodash-es/_basePropertyDeep.js","../node_modules/lodash-es/property.js","../node_modules/lodash-es/_baseIteratee.js","../node_modules/lodash-es/_baseMap.js","../node_modules/lodash-es/map.js","../node_modules/react-color/es/components/block/BlockSwatches.js","../node_modules/react-color/es/components/block/Block.js","../node_modules/material-colors/dist/colors.es2015.js","../node_modules/react-color/es/components/circle/CircleSwatch.js","../node_modules/react-color/es/components/circle/Circle.js","../node_modules/lodash-es/isUndefined.js","../node_modules/react-color/es/components/chrome/ChromeFields.js","../node_modules/react-color/es/components/chrome/ChromePointer.js","../node_modules/react-color/es/components/chrome/ChromePointerCircle.js","../node_modules/react-color/es/components/chrome/Chrome.js","../node_modules/react-color/es/components/compact/CompactColor.js","../node_modules/react-color/es/components/compact/CompactFields.js","../node_modules/react-color/es/components/compact/Compact.js","../node_modules/react-color/es/components/github/GithubSwatch.js","../node_modules/react-color/es/components/github/Github.js","../node_modules/react-color/es/components/hue/HuePointer.js","../node_modules/react-color/es/components/hue/Hue.js","../node_modules/react-color/es/components/material/Material.js","../node_modules/react-color/es/components/photoshop/PhotoshopFields.js","../node_modules/react-color/es/components/photoshop/PhotoshopPointerCircle.js","../node_modules/react-color/es/components/photoshop/PhotoshopPointer.js","../node_modules/react-color/es/components/photoshop/PhotoshopButton.js","../node_modules/react-color/es/components/photoshop/PhotoshopPreviews.js","../node_modules/react-color/es/components/photoshop/Photoshop.js","../node_modules/react-color/es/components/sketch/SketchFields.js","../node_modules/react-color/es/components/sketch/SketchPresetColors.js","../node_modules/react-color/es/components/sketch/Sketch.js","../node_modules/react-color/es/components/slider/SliderSwatch.js","../node_modules/react-color/es/components/slider/SliderSwatches.js","../node_modules/react-color/es/components/slider/SliderPointer.js","../node_modules/react-color/es/components/slider/Slider.js","../node_modules/react-color/es/components/swatches/SwatchesColor.js","../node_modules/react-color/es/components/swatches/SwatchesGroup.js","../node_modules/react-color/es/components/swatches/Swatches.js","../node_modules/react-color/es/components/twitter/Twitter.js","../node_modules/react-color/es/components/google/GooglePointerCircle.js","../node_modules/react-color/es/components/google/GooglePointer.js","../node_modules/react-color/es/components/google/GoogleFields.js","../node_modules/react-color/es/components/google/Google.js","../node_modules/reactcss/lib/autoprefix.js","../node_modules/reactcss/lib/components/active.js","../node_modules/reactcss/lib/components/hover.js","../node_modules/reactcss/lib/flattenNames.js","../node_modules/reactcss/lib/index.js","../node_modules/reactcss/lib/loop.js","../node_modules/reactcss/lib/mergeClasses.js"],"sourcesContent":["'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nvar _react = require('react');\n\nvar _react2 = _interopRequireDefault(_react);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }\n\nvar DEFAULT_SIZE = 24;\n\nexports.default = function (_ref) {\n var _ref$fill = _ref.fill,\n fill = _ref$fill === undefined ? 'currentColor' : _ref$fill,\n _ref$width = _ref.width,\n width = _ref$width === undefined ? DEFAULT_SIZE : _ref$width,\n _ref$height = _ref.height,\n height = _ref$height === undefined ? DEFAULT_SIZE : _ref$height,\n _ref$style = _ref.style,\n style = _ref$style === undefined ? {} : _ref$style,\n props = _objectWithoutProperties(_ref, ['fill', 'width', 'height', 'style']);\n\n return _react2.default.createElement(\n 'svg',\n _extends({\n viewBox: '0 0 ' + DEFAULT_SIZE + ' ' + DEFAULT_SIZE,\n style: _extends({ fill: fill, width: width, height: height }, style)\n }, props),\n _react2.default.createElement('path', { d: 'M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z' })\n );\n};","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nvar _react = require('react');\n\nvar _react2 = _interopRequireDefault(_react);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }\n\nvar DEFAULT_SIZE = 24;\n\nexports.default = function (_ref) {\n var _ref$fill = _ref.fill,\n fill = _ref$fill === undefined ? 'currentColor' : _ref$fill,\n _ref$width = _ref.width,\n width = _ref$width === undefined ? DEFAULT_SIZE : _ref$width,\n _ref$height = _ref.height,\n height = _ref$height === undefined ? DEFAULT_SIZE : _ref$height,\n _ref$style = _ref.style,\n style = _ref$style === undefined ? {} : _ref$style,\n props = _objectWithoutProperties(_ref, ['fill', 'width', 'height', 'style']);\n\n return _react2.default.createElement(\n 'svg',\n _extends({\n viewBox: '0 0 ' + DEFAULT_SIZE + ' ' + DEFAULT_SIZE,\n style: _extends({ fill: fill, width: width, height: height }, style)\n }, props),\n _react2.default.createElement('path', { d: 'M12,18.17L8.83,15L7.42,16.41L12,21L16.59,16.41L15.17,15M12,5.83L15.17,9L16.58,7.59L12,3L7.41,7.59L8.83,9L12,5.83Z' })\n );\n};","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nmodule.exports = DataView;\n","var hashClear = require('./_hashClear'),\n hashDelete = require('./_hashDelete'),\n hashGet = require('./_hashGet'),\n hashHas = require('./_hashHas'),\n hashSet = require('./_hashSet');\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nmodule.exports = Hash;\n","var listCacheClear = require('./_listCacheClear'),\n listCacheDelete = require('./_listCacheDelete'),\n listCacheGet = require('./_listCacheGet'),\n listCacheHas = require('./_listCacheHas'),\n listCacheSet = require('./_listCacheSet');\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nmodule.exports = ListCache;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nmodule.exports = Map;\n","var mapCacheClear = require('./_mapCacheClear'),\n mapCacheDelete = require('./_mapCacheDelete'),\n mapCacheGet = require('./_mapCacheGet'),\n mapCacheHas = require('./_mapCacheHas'),\n mapCacheSet = require('./_mapCacheSet');\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nmodule.exports = MapCache;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nmodule.exports = Promise;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nmodule.exports = Set;\n","var MapCache = require('./_MapCache'),\n setCacheAdd = require('./_setCacheAdd'),\n setCacheHas = require('./_setCacheHas');\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nmodule.exports = SetCache;\n","var ListCache = require('./_ListCache'),\n stackClear = require('./_stackClear'),\n stackDelete = require('./_stackDelete'),\n stackGet = require('./_stackGet'),\n stackHas = require('./_stackHas'),\n stackSet = require('./_stackSet');\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nmodule.exports = Stack;\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nmodule.exports = Symbol;\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nmodule.exports = Uint8Array;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nmodule.exports = WeakMap;\n","/**\n * A specialized version of `_.forEach` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns `array`.\n */\nfunction arrayEach(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (iteratee(array[index], index, array) === false) {\n break;\n }\n }\n return array;\n}\n\nmodule.exports = arrayEach;\n","/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\nmodule.exports = arrayFilter;\n","var baseTimes = require('./_baseTimes'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isIndex = require('./_isIndex'),\n isTypedArray = require('./isTypedArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = arrayLikeKeys;\n","/**\n * A specialized version of `_.map` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\nfunction arrayMap(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length,\n result = Array(length);\n\n while (++index < length) {\n result[index] = iteratee(array[index], index, array);\n }\n return result;\n}\n\nmodule.exports = arrayMap;\n","/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n}\n\nmodule.exports = arrayPush;\n","/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\nmodule.exports = arraySome;\n","var baseAssignValue = require('./_baseAssignValue'),\n eq = require('./eq');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Assigns `value` to `key` of `object` if the existing value is not equivalent\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction assignValue(object, key, value) {\n var objValue = object[key];\n if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) ||\n (value === undefined && !(key in object))) {\n baseAssignValue(object, key, value);\n }\n}\n\nmodule.exports = assignValue;\n","var eq = require('./eq');\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nmodule.exports = assocIndexOf;\n","var copyObject = require('./_copyObject'),\n keys = require('./keys');\n\n/**\n * The base implementation of `_.assign` without support for multiple sources\n * or `customizer` functions.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @returns {Object} Returns `object`.\n */\nfunction baseAssign(object, source) {\n return object && copyObject(source, keys(source), object);\n}\n\nmodule.exports = baseAssign;\n","var copyObject = require('./_copyObject'),\n keysIn = require('./keysIn');\n\n/**\n * The base implementation of `_.assignIn` without support for multiple sources\n * or `customizer` functions.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @returns {Object} Returns `object`.\n */\nfunction baseAssignIn(object, source) {\n return object && copyObject(source, keysIn(source), object);\n}\n\nmodule.exports = baseAssignIn;\n","var defineProperty = require('./_defineProperty');\n\n/**\n * The base implementation of `assignValue` and `assignMergeValue` without\n * value checks.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction baseAssignValue(object, key, value) {\n if (key == '__proto__' && defineProperty) {\n defineProperty(object, key, {\n 'configurable': true,\n 'enumerable': true,\n 'value': value,\n 'writable': true\n });\n } else {\n object[key] = value;\n }\n}\n\nmodule.exports = baseAssignValue;\n","var Stack = require('./_Stack'),\n arrayEach = require('./_arrayEach'),\n assignValue = require('./_assignValue'),\n baseAssign = require('./_baseAssign'),\n baseAssignIn = require('./_baseAssignIn'),\n cloneBuffer = require('./_cloneBuffer'),\n copyArray = require('./_copyArray'),\n copySymbols = require('./_copySymbols'),\n copySymbolsIn = require('./_copySymbolsIn'),\n getAllKeys = require('./_getAllKeys'),\n getAllKeysIn = require('./_getAllKeysIn'),\n getTag = require('./_getTag'),\n initCloneArray = require('./_initCloneArray'),\n initCloneByTag = require('./_initCloneByTag'),\n initCloneObject = require('./_initCloneObject'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isMap = require('./isMap'),\n isObject = require('./isObject'),\n isSet = require('./isSet'),\n keys = require('./keys'),\n keysIn = require('./keysIn');\n\n/** Used to compose bitmasks for cloning. */\nvar CLONE_DEEP_FLAG = 1,\n CLONE_FLAT_FLAG = 2,\n CLONE_SYMBOLS_FLAG = 4;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values supported by `_.clone`. */\nvar cloneableTags = {};\ncloneableTags[argsTag] = cloneableTags[arrayTag] =\ncloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] =\ncloneableTags[boolTag] = cloneableTags[dateTag] =\ncloneableTags[float32Tag] = cloneableTags[float64Tag] =\ncloneableTags[int8Tag] = cloneableTags[int16Tag] =\ncloneableTags[int32Tag] = cloneableTags[mapTag] =\ncloneableTags[numberTag] = cloneableTags[objectTag] =\ncloneableTags[regexpTag] = cloneableTags[setTag] =\ncloneableTags[stringTag] = cloneableTags[symbolTag] =\ncloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] =\ncloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;\ncloneableTags[errorTag] = cloneableTags[funcTag] =\ncloneableTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.clone` and `_.cloneDeep` which tracks\n * traversed objects.\n *\n * @private\n * @param {*} value The value to clone.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Deep clone\n * 2 - Flatten inherited properties\n * 4 - Clone symbols\n * @param {Function} [customizer] The function to customize cloning.\n * @param {string} [key] The key of `value`.\n * @param {Object} [object] The parent object of `value`.\n * @param {Object} [stack] Tracks traversed objects and their clone counterparts.\n * @returns {*} Returns the cloned value.\n */\nfunction baseClone(value, bitmask, customizer, key, object, stack) {\n var result,\n isDeep = bitmask & CLONE_DEEP_FLAG,\n isFlat = bitmask & CLONE_FLAT_FLAG,\n isFull = bitmask & CLONE_SYMBOLS_FLAG;\n\n if (customizer) {\n result = object ? customizer(value, key, object, stack) : customizer(value);\n }\n if (result !== undefined) {\n return result;\n }\n if (!isObject(value)) {\n return value;\n }\n var isArr = isArray(value);\n if (isArr) {\n result = initCloneArray(value);\n if (!isDeep) {\n return copyArray(value, result);\n }\n } else {\n var tag = getTag(value),\n isFunc = tag == funcTag || tag == genTag;\n\n if (isBuffer(value)) {\n return cloneBuffer(value, isDeep);\n }\n if (tag == objectTag || tag == argsTag || (isFunc && !object)) {\n result = (isFlat || isFunc) ? {} : initCloneObject(value);\n if (!isDeep) {\n return isFlat\n ? copySymbolsIn(value, baseAssignIn(result, value))\n : copySymbols(value, baseAssign(result, value));\n }\n } else {\n if (!cloneableTags[tag]) {\n return object ? value : {};\n }\n result = initCloneByTag(value, tag, isDeep);\n }\n }\n // Check for circular references and return its corresponding clone.\n stack || (stack = new Stack);\n var stacked = stack.get(value);\n if (stacked) {\n return stacked;\n }\n stack.set(value, result);\n\n if (isSet(value)) {\n value.forEach(function(subValue) {\n result.add(baseClone(subValue, bitmask, customizer, subValue, value, stack));\n });\n } else if (isMap(value)) {\n value.forEach(function(subValue, key) {\n result.set(key, baseClone(subValue, bitmask, customizer, key, value, stack));\n });\n }\n\n var keysFunc = isFull\n ? (isFlat ? getAllKeysIn : getAllKeys)\n : (isFlat ? keysIn : keys);\n\n var props = isArr ? undefined : keysFunc(value);\n arrayEach(props || value, function(subValue, key) {\n if (props) {\n key = subValue;\n subValue = value[key];\n }\n // Recursively populate clone (susceptible to call stack limits).\n assignValue(result, key, baseClone(subValue, bitmask, customizer, key, value, stack));\n });\n return result;\n}\n\nmodule.exports = baseClone;\n","var isObject = require('./isObject');\n\n/** Built-in value references. */\nvar objectCreate = Object.create;\n\n/**\n * The base implementation of `_.create` without support for assigning\n * properties to the created object.\n *\n * @private\n * @param {Object} proto The object to inherit from.\n * @returns {Object} Returns the new object.\n */\nvar baseCreate = (function() {\n function object() {}\n return function(proto) {\n if (!isObject(proto)) {\n return {};\n }\n if (objectCreate) {\n return objectCreate(proto);\n }\n object.prototype = proto;\n var result = new object;\n object.prototype = undefined;\n return result;\n };\n}());\n\nmodule.exports = baseCreate;\n","var baseForOwn = require('./_baseForOwn'),\n createBaseEach = require('./_createBaseEach');\n\n/**\n * The base implementation of `_.forEach` without support for iteratee shorthands.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array|Object} Returns `collection`.\n */\nvar baseEach = createBaseEach(baseForOwn);\n\nmodule.exports = baseEach;\n","var createBaseFor = require('./_createBaseFor');\n\n/**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\nvar baseFor = createBaseFor();\n\nmodule.exports = baseFor;\n","var baseFor = require('./_baseFor'),\n keys = require('./keys');\n\n/**\n * The base implementation of `_.forOwn` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Object} Returns `object`.\n */\nfunction baseForOwn(object, iteratee) {\n return object && baseFor(object, iteratee, keys);\n}\n\nmodule.exports = baseForOwn;\n","var castPath = require('./_castPath'),\n toKey = require('./_toKey');\n\n/**\n * The base implementation of `_.get` without support for default values.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @returns {*} Returns the resolved value.\n */\nfunction baseGet(object, path) {\n path = castPath(path, object);\n\n var index = 0,\n length = path.length;\n\n while (object != null && index < length) {\n object = object[toKey(path[index++])];\n }\n return (index && index == length) ? object : undefined;\n}\n\nmodule.exports = baseGet;\n","var arrayPush = require('./_arrayPush'),\n isArray = require('./isArray');\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nmodule.exports = baseGetAllKeys;\n","var Symbol = require('./_Symbol'),\n getRawTag = require('./_getRawTag'),\n objectToString = require('./_objectToString');\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nmodule.exports = baseGetTag;\n","/**\n * The base implementation of `_.hasIn` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHasIn(object, key) {\n return object != null && key in Object(object);\n}\n\nmodule.exports = baseHasIn;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nmodule.exports = baseIsArguments;\n","var baseIsEqualDeep = require('./_baseIsEqualDeep'),\n isObjectLike = require('./isObjectLike');\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nmodule.exports = baseIsEqual;\n","var Stack = require('./_Stack'),\n equalArrays = require('./_equalArrays'),\n equalByTag = require('./_equalByTag'),\n equalObjects = require('./_equalObjects'),\n getTag = require('./_getTag'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isTypedArray = require('./isTypedArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nmodule.exports = baseIsEqualDeep;\n","var getTag = require('./_getTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]';\n\n/**\n * The base implementation of `_.isMap` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a map, else `false`.\n */\nfunction baseIsMap(value) {\n return isObjectLike(value) && getTag(value) == mapTag;\n}\n\nmodule.exports = baseIsMap;\n","var Stack = require('./_Stack'),\n baseIsEqual = require('./_baseIsEqual');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.isMatch` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @param {Array} matchData The property names, values, and compare flags to match.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n */\nfunction baseIsMatch(object, source, matchData, customizer) {\n var index = matchData.length,\n length = index,\n noCustomizer = !customizer;\n\n if (object == null) {\n return !length;\n }\n object = Object(object);\n while (index--) {\n var data = matchData[index];\n if ((noCustomizer && data[2])\n ? data[1] !== object[data[0]]\n : !(data[0] in object)\n ) {\n return false;\n }\n }\n while (++index < length) {\n data = matchData[index];\n var key = data[0],\n objValue = object[key],\n srcValue = data[1];\n\n if (noCustomizer && data[2]) {\n if (objValue === undefined && !(key in object)) {\n return false;\n }\n } else {\n var stack = new Stack;\n if (customizer) {\n var result = customizer(objValue, srcValue, key, object, source, stack);\n }\n if (!(result === undefined\n ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)\n : result\n )) {\n return false;\n }\n }\n }\n return true;\n}\n\nmodule.exports = baseIsMatch;\n","var isFunction = require('./isFunction'),\n isMasked = require('./_isMasked'),\n isObject = require('./isObject'),\n toSource = require('./_toSource');\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nmodule.exports = baseIsNative;\n","var getTag = require('./_getTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar setTag = '[object Set]';\n\n/**\n * The base implementation of `_.isSet` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a set, else `false`.\n */\nfunction baseIsSet(value) {\n return isObjectLike(value) && getTag(value) == setTag;\n}\n\nmodule.exports = baseIsSet;\n","var baseGetTag = require('./_baseGetTag'),\n isLength = require('./isLength'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nmodule.exports = baseIsTypedArray;\n","var baseMatches = require('./_baseMatches'),\n baseMatchesProperty = require('./_baseMatchesProperty'),\n identity = require('./identity'),\n isArray = require('./isArray'),\n property = require('./property');\n\n/**\n * The base implementation of `_.iteratee`.\n *\n * @private\n * @param {*} [value=_.identity] The value to convert to an iteratee.\n * @returns {Function} Returns the iteratee.\n */\nfunction baseIteratee(value) {\n // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.\n // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.\n if (typeof value == 'function') {\n return value;\n }\n if (value == null) {\n return identity;\n }\n if (typeof value == 'object') {\n return isArray(value)\n ? baseMatchesProperty(value[0], value[1])\n : baseMatches(value);\n }\n return property(value);\n}\n\nmodule.exports = baseIteratee;\n","var isPrototype = require('./_isPrototype'),\n nativeKeys = require('./_nativeKeys');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = baseKeys;\n","var isObject = require('./isObject'),\n isPrototype = require('./_isPrototype'),\n nativeKeysIn = require('./_nativeKeysIn');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeysIn(object) {\n if (!isObject(object)) {\n return nativeKeysIn(object);\n }\n var isProto = isPrototype(object),\n result = [];\n\n for (var key in object) {\n if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = baseKeysIn;\n","var baseEach = require('./_baseEach'),\n isArrayLike = require('./isArrayLike');\n\n/**\n * The base implementation of `_.map` without support for iteratee shorthands.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\nfunction baseMap(collection, iteratee) {\n var index = -1,\n result = isArrayLike(collection) ? Array(collection.length) : [];\n\n baseEach(collection, function(value, key, collection) {\n result[++index] = iteratee(value, key, collection);\n });\n return result;\n}\n\nmodule.exports = baseMap;\n","var baseIsMatch = require('./_baseIsMatch'),\n getMatchData = require('./_getMatchData'),\n matchesStrictComparable = require('./_matchesStrictComparable');\n\n/**\n * The base implementation of `_.matches` which doesn't clone `source`.\n *\n * @private\n * @param {Object} source The object of property values to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatches(source) {\n var matchData = getMatchData(source);\n if (matchData.length == 1 && matchData[0][2]) {\n return matchesStrictComparable(matchData[0][0], matchData[0][1]);\n }\n return function(object) {\n return object === source || baseIsMatch(object, source, matchData);\n };\n}\n\nmodule.exports = baseMatches;\n","var baseIsEqual = require('./_baseIsEqual'),\n get = require('./get'),\n hasIn = require('./hasIn'),\n isKey = require('./_isKey'),\n isStrictComparable = require('./_isStrictComparable'),\n matchesStrictComparable = require('./_matchesStrictComparable'),\n toKey = require('./_toKey');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.\n *\n * @private\n * @param {string} path The path of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatchesProperty(path, srcValue) {\n if (isKey(path) && isStrictComparable(srcValue)) {\n return matchesStrictComparable(toKey(path), srcValue);\n }\n return function(object) {\n var objValue = get(object, path);\n return (objValue === undefined && objValue === srcValue)\n ? hasIn(object, path)\n : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);\n };\n}\n\nmodule.exports = baseMatchesProperty;\n","/**\n * The base implementation of `_.property` without support for deep paths.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction baseProperty(key) {\n return function(object) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = baseProperty;\n","var baseGet = require('./_baseGet');\n\n/**\n * A specialized version of `baseProperty` which supports deep paths.\n *\n * @private\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyDeep(path) {\n return function(object) {\n return baseGet(object, path);\n };\n}\n\nmodule.exports = basePropertyDeep;\n","/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nmodule.exports = baseTimes;\n","var Symbol = require('./_Symbol'),\n arrayMap = require('./_arrayMap'),\n isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n/**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\nfunction baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isArray(value)) {\n // Recursively convert values (susceptible to call stack limits).\n return arrayMap(value, baseToString) + '';\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = baseToString;\n","/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nmodule.exports = baseUnary;\n","/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\nmodule.exports = cacheHas;\n","var identity = require('./identity');\n\n/**\n * Casts `value` to `identity` if it's not a function.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {Function} Returns cast function.\n */\nfunction castFunction(value) {\n return typeof value == 'function' ? value : identity;\n}\n\nmodule.exports = castFunction;\n","var isArray = require('./isArray'),\n isKey = require('./_isKey'),\n stringToPath = require('./_stringToPath'),\n toString = require('./toString');\n\n/**\n * Casts `value` to a path array if it's not one.\n *\n * @private\n * @param {*} value The value to inspect.\n * @param {Object} [object] The object to query keys on.\n * @returns {Array} Returns the cast property path array.\n */\nfunction castPath(value, object) {\n if (isArray(value)) {\n return value;\n }\n return isKey(value, object) ? [value] : stringToPath(toString(value));\n}\n\nmodule.exports = castPath;\n","var Uint8Array = require('./_Uint8Array');\n\n/**\n * Creates a clone of `arrayBuffer`.\n *\n * @private\n * @param {ArrayBuffer} arrayBuffer The array buffer to clone.\n * @returns {ArrayBuffer} Returns the cloned array buffer.\n */\nfunction cloneArrayBuffer(arrayBuffer) {\n var result = new arrayBuffer.constructor(arrayBuffer.byteLength);\n new Uint8Array(result).set(new Uint8Array(arrayBuffer));\n return result;\n}\n\nmodule.exports = cloneArrayBuffer;\n","var root = require('./_root');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined,\n allocUnsafe = Buffer ? Buffer.allocUnsafe : undefined;\n\n/**\n * Creates a clone of `buffer`.\n *\n * @private\n * @param {Buffer} buffer The buffer to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Buffer} Returns the cloned buffer.\n */\nfunction cloneBuffer(buffer, isDeep) {\n if (isDeep) {\n return buffer.slice();\n }\n var length = buffer.length,\n result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);\n\n buffer.copy(result);\n return result;\n}\n\nmodule.exports = cloneBuffer;\n","var cloneArrayBuffer = require('./_cloneArrayBuffer');\n\n/**\n * Creates a clone of `dataView`.\n *\n * @private\n * @param {Object} dataView The data view to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Object} Returns the cloned data view.\n */\nfunction cloneDataView(dataView, isDeep) {\n var buffer = isDeep ? cloneArrayBuffer(dataView.buffer) : dataView.buffer;\n return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength);\n}\n\nmodule.exports = cloneDataView;\n","/** Used to match `RegExp` flags from their coerced string values. */\nvar reFlags = /\\w*$/;\n\n/**\n * Creates a clone of `regexp`.\n *\n * @private\n * @param {Object} regexp The regexp to clone.\n * @returns {Object} Returns the cloned regexp.\n */\nfunction cloneRegExp(regexp) {\n var result = new regexp.constructor(regexp.source, reFlags.exec(regexp));\n result.lastIndex = regexp.lastIndex;\n return result;\n}\n\nmodule.exports = cloneRegExp;\n","var Symbol = require('./_Symbol');\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * Creates a clone of the `symbol` object.\n *\n * @private\n * @param {Object} symbol The symbol object to clone.\n * @returns {Object} Returns the cloned symbol object.\n */\nfunction cloneSymbol(symbol) {\n return symbolValueOf ? Object(symbolValueOf.call(symbol)) : {};\n}\n\nmodule.exports = cloneSymbol;\n","var cloneArrayBuffer = require('./_cloneArrayBuffer');\n\n/**\n * Creates a clone of `typedArray`.\n *\n * @private\n * @param {Object} typedArray The typed array to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Object} Returns the cloned typed array.\n */\nfunction cloneTypedArray(typedArray, isDeep) {\n var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer;\n return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);\n}\n\nmodule.exports = cloneTypedArray;\n","/**\n * Copies the values of `source` to `array`.\n *\n * @private\n * @param {Array} source The array to copy values from.\n * @param {Array} [array=[]] The array to copy values to.\n * @returns {Array} Returns `array`.\n */\nfunction copyArray(source, array) {\n var index = -1,\n length = source.length;\n\n array || (array = Array(length));\n while (++index < length) {\n array[index] = source[index];\n }\n return array;\n}\n\nmodule.exports = copyArray;\n","var assignValue = require('./_assignValue'),\n baseAssignValue = require('./_baseAssignValue');\n\n/**\n * Copies properties of `source` to `object`.\n *\n * @private\n * @param {Object} source The object to copy properties from.\n * @param {Array} props The property identifiers to copy.\n * @param {Object} [object={}] The object to copy properties to.\n * @param {Function} [customizer] The function to customize copied values.\n * @returns {Object} Returns `object`.\n */\nfunction copyObject(source, props, object, customizer) {\n var isNew = !object;\n object || (object = {});\n\n var index = -1,\n length = props.length;\n\n while (++index < length) {\n var key = props[index];\n\n var newValue = customizer\n ? customizer(object[key], source[key], key, object, source)\n : undefined;\n\n if (newValue === undefined) {\n newValue = source[key];\n }\n if (isNew) {\n baseAssignValue(object, key, newValue);\n } else {\n assignValue(object, key, newValue);\n }\n }\n return object;\n}\n\nmodule.exports = copyObject;\n","var copyObject = require('./_copyObject'),\n getSymbols = require('./_getSymbols');\n\n/**\n * Copies own symbols of `source` to `object`.\n *\n * @private\n * @param {Object} source The object to copy symbols from.\n * @param {Object} [object={}] The object to copy symbols to.\n * @returns {Object} Returns `object`.\n */\nfunction copySymbols(source, object) {\n return copyObject(source, getSymbols(source), object);\n}\n\nmodule.exports = copySymbols;\n","var copyObject = require('./_copyObject'),\n getSymbolsIn = require('./_getSymbolsIn');\n\n/**\n * Copies own and inherited symbols of `source` to `object`.\n *\n * @private\n * @param {Object} source The object to copy symbols from.\n * @param {Object} [object={}] The object to copy symbols to.\n * @returns {Object} Returns `object`.\n */\nfunction copySymbolsIn(source, object) {\n return copyObject(source, getSymbolsIn(source), object);\n}\n\nmodule.exports = copySymbolsIn;\n","var root = require('./_root');\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nmodule.exports = coreJsData;\n","var isArrayLike = require('./isArrayLike');\n\n/**\n * Creates a `baseEach` or `baseEachRight` function.\n *\n * @private\n * @param {Function} eachFunc The function to iterate over a collection.\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseEach(eachFunc, fromRight) {\n return function(collection, iteratee) {\n if (collection == null) {\n return collection;\n }\n if (!isArrayLike(collection)) {\n return eachFunc(collection, iteratee);\n }\n var length = collection.length,\n index = fromRight ? length : -1,\n iterable = Object(collection);\n\n while ((fromRight ? index-- : ++index < length)) {\n if (iteratee(iterable[index], index, iterable) === false) {\n break;\n }\n }\n return collection;\n };\n}\n\nmodule.exports = createBaseEach;\n","/**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n}\n\nmodule.exports = createBaseFor;\n","var getNative = require('./_getNative');\n\nvar defineProperty = (function() {\n try {\n var func = getNative(Object, 'defineProperty');\n func({}, '', {});\n return func;\n } catch (e) {}\n}());\n\nmodule.exports = defineProperty;\n","var SetCache = require('./_SetCache'),\n arraySome = require('./_arraySome'),\n cacheHas = require('./_cacheHas');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalArrays;\n","var Symbol = require('./_Symbol'),\n Uint8Array = require('./_Uint8Array'),\n eq = require('./eq'),\n equalArrays = require('./_equalArrays'),\n mapToArray = require('./_mapToArray'),\n setToArray = require('./_setToArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\nmodule.exports = equalByTag;\n","var getAllKeys = require('./_getAllKeys');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalObjects;\n","/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nmodule.exports = freeGlobal;\n","var baseGetAllKeys = require('./_baseGetAllKeys'),\n getSymbols = require('./_getSymbols'),\n keys = require('./keys');\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\nmodule.exports = getAllKeys;\n","var baseGetAllKeys = require('./_baseGetAllKeys'),\n getSymbolsIn = require('./_getSymbolsIn'),\n keysIn = require('./keysIn');\n\n/**\n * Creates an array of own and inherited enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeysIn(object) {\n return baseGetAllKeys(object, keysIn, getSymbolsIn);\n}\n\nmodule.exports = getAllKeysIn;\n","var isKeyable = require('./_isKeyable');\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nmodule.exports = getMapData;\n","var isStrictComparable = require('./_isStrictComparable'),\n keys = require('./keys');\n\n/**\n * Gets the property names, values, and compare flags of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the match data of `object`.\n */\nfunction getMatchData(object) {\n var result = keys(object),\n length = result.length;\n\n while (length--) {\n var key = result[length],\n value = object[key];\n\n result[length] = [key, value, isStrictComparable(value)];\n }\n return result;\n}\n\nmodule.exports = getMatchData;\n","var baseIsNative = require('./_baseIsNative'),\n getValue = require('./_getValue');\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nmodule.exports = getNative;\n","var overArg = require('./_overArg');\n\n/** Built-in value references. */\nvar getPrototype = overArg(Object.getPrototypeOf, Object);\n\nmodule.exports = getPrototype;\n","var Symbol = require('./_Symbol');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nmodule.exports = getRawTag;\n","var arrayFilter = require('./_arrayFilter'),\n stubArray = require('./stubArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\nmodule.exports = getSymbols;\n","var arrayPush = require('./_arrayPush'),\n getPrototype = require('./_getPrototype'),\n getSymbols = require('./_getSymbols'),\n stubArray = require('./stubArray');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own and inherited enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbolsIn = !nativeGetSymbols ? stubArray : function(object) {\n var result = [];\n while (object) {\n arrayPush(result, getSymbols(object));\n object = getPrototype(object);\n }\n return result;\n};\n\nmodule.exports = getSymbolsIn;\n","var DataView = require('./_DataView'),\n Map = require('./_Map'),\n Promise = require('./_Promise'),\n Set = require('./_Set'),\n WeakMap = require('./_WeakMap'),\n baseGetTag = require('./_baseGetTag'),\n toSource = require('./_toSource');\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nmodule.exports = getTag;\n","/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nmodule.exports = getValue;\n","var castPath = require('./_castPath'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isIndex = require('./_isIndex'),\n isLength = require('./isLength'),\n toKey = require('./_toKey');\n\n/**\n * Checks if `path` exists on `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @param {Function} hasFunc The function to check properties.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n */\nfunction hasPath(object, path, hasFunc) {\n path = castPath(path, object);\n\n var index = -1,\n length = path.length,\n result = false;\n\n while (++index < length) {\n var key = toKey(path[index]);\n if (!(result = object != null && hasFunc(object, key))) {\n break;\n }\n object = object[key];\n }\n if (result || ++index != length) {\n return result;\n }\n length = object == null ? 0 : object.length;\n return !!length && isLength(length) && isIndex(key, length) &&\n (isArray(object) || isArguments(object));\n}\n\nmodule.exports = hasPath;\n","var nativeCreate = require('./_nativeCreate');\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nmodule.exports = hashClear;\n","/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = hashDelete;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nmodule.exports = hashGet;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nmodule.exports = hashHas;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nmodule.exports = hashSet;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Initializes an array clone.\n *\n * @private\n * @param {Array} array The array to clone.\n * @returns {Array} Returns the initialized clone.\n */\nfunction initCloneArray(array) {\n var length = array.length,\n result = new array.constructor(length);\n\n // Add properties assigned by `RegExp#exec`.\n if (length && typeof array[0] == 'string' && hasOwnProperty.call(array, 'index')) {\n result.index = array.index;\n result.input = array.input;\n }\n return result;\n}\n\nmodule.exports = initCloneArray;\n","var cloneArrayBuffer = require('./_cloneArrayBuffer'),\n cloneDataView = require('./_cloneDataView'),\n cloneRegExp = require('./_cloneRegExp'),\n cloneSymbol = require('./_cloneSymbol'),\n cloneTypedArray = require('./_cloneTypedArray');\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/**\n * Initializes an object clone based on its `toStringTag`.\n *\n * **Note:** This function only supports cloning values with tags of\n * `Boolean`, `Date`, `Error`, `Map`, `Number`, `RegExp`, `Set`, or `String`.\n *\n * @private\n * @param {Object} object The object to clone.\n * @param {string} tag The `toStringTag` of the object to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Object} Returns the initialized clone.\n */\nfunction initCloneByTag(object, tag, isDeep) {\n var Ctor = object.constructor;\n switch (tag) {\n case arrayBufferTag:\n return cloneArrayBuffer(object);\n\n case boolTag:\n case dateTag:\n return new Ctor(+object);\n\n case dataViewTag:\n return cloneDataView(object, isDeep);\n\n case float32Tag: case float64Tag:\n case int8Tag: case int16Tag: case int32Tag:\n case uint8Tag: case uint8ClampedTag: case uint16Tag: case uint32Tag:\n return cloneTypedArray(object, isDeep);\n\n case mapTag:\n return new Ctor;\n\n case numberTag:\n case stringTag:\n return new Ctor(object);\n\n case regexpTag:\n return cloneRegExp(object);\n\n case setTag:\n return new Ctor;\n\n case symbolTag:\n return cloneSymbol(object);\n }\n}\n\nmodule.exports = initCloneByTag;\n","var baseCreate = require('./_baseCreate'),\n getPrototype = require('./_getPrototype'),\n isPrototype = require('./_isPrototype');\n\n/**\n * Initializes an object clone.\n *\n * @private\n * @param {Object} object The object to clone.\n * @returns {Object} Returns the initialized clone.\n */\nfunction initCloneObject(object) {\n return (typeof object.constructor == 'function' && !isPrototype(object))\n ? baseCreate(getPrototype(object))\n : {};\n}\n\nmodule.exports = initCloneObject;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\nmodule.exports = isIndex;\n","var isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used to match property names within property paths. */\nvar reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\n reIsPlainProp = /^\\w*$/;\n\n/**\n * Checks if `value` is a property name and not a property path.\n *\n * @private\n * @param {*} value The value to check.\n * @param {Object} [object] The object to query keys on.\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\n */\nfunction isKey(value, object) {\n if (isArray(value)) {\n return false;\n }\n var type = typeof value;\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\n value == null || isSymbol(value)) {\n return true;\n }\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\n (object != null && value in Object(object));\n}\n\nmodule.exports = isKey;\n","/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nmodule.exports = isKeyable;\n","var coreJsData = require('./_coreJsData');\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nmodule.exports = isMasked;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nmodule.exports = isPrototype;\n","var isObject = require('./isObject');\n\n/**\n * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` if suitable for strict\n * equality comparisons, else `false`.\n */\nfunction isStrictComparable(value) {\n return value === value && !isObject(value);\n}\n\nmodule.exports = isStrictComparable;\n","/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nmodule.exports = listCacheClear;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nmodule.exports = listCacheDelete;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nmodule.exports = listCacheGet;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nmodule.exports = listCacheHas;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nmodule.exports = listCacheSet;\n","var Hash = require('./_Hash'),\n ListCache = require('./_ListCache'),\n Map = require('./_Map');\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nmodule.exports = mapCacheClear;\n","var getMapData = require('./_getMapData');\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = mapCacheDelete;\n","var getMapData = require('./_getMapData');\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nmodule.exports = mapCacheGet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nmodule.exports = mapCacheHas;\n","var getMapData = require('./_getMapData');\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nmodule.exports = mapCacheSet;\n","/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\nmodule.exports = mapToArray;\n","/**\n * A specialized version of `matchesProperty` for source values suitable\n * for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction matchesStrictComparable(key, srcValue) {\n return function(object) {\n if (object == null) {\n return false;\n }\n return object[key] === srcValue &&\n (srcValue !== undefined || (key in Object(object)));\n };\n}\n\nmodule.exports = matchesStrictComparable;\n","var memoize = require('./memoize');\n\n/** Used as the maximum memoize cache size. */\nvar MAX_MEMOIZE_SIZE = 500;\n\n/**\n * A specialized version of `_.memoize` which clears the memoized function's\n * cache when it exceeds `MAX_MEMOIZE_SIZE`.\n *\n * @private\n * @param {Function} func The function to have its output memoized.\n * @returns {Function} Returns the new memoized function.\n */\nfunction memoizeCapped(func) {\n var result = memoize(func, function(key) {\n if (cache.size === MAX_MEMOIZE_SIZE) {\n cache.clear();\n }\n return key;\n });\n\n var cache = result.cache;\n return result;\n}\n\nmodule.exports = memoizeCapped;\n","var getNative = require('./_getNative');\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nmodule.exports = nativeCreate;\n","var overArg = require('./_overArg');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nmodule.exports = nativeKeys;\n","/**\n * This function is like\n * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * except that it includes inherited enumerable properties.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction nativeKeysIn(object) {\n var result = [];\n if (object != null) {\n for (var key in Object(object)) {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = nativeKeysIn;\n","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nmodule.exports = nodeUtil;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nmodule.exports = objectToString;\n","/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nmodule.exports = overArg;\n","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nmodule.exports = root;\n","/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\nmodule.exports = setCacheAdd;\n","/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\nmodule.exports = setCacheHas;\n","/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\nmodule.exports = setToArray;\n","var ListCache = require('./_ListCache');\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nmodule.exports = stackClear;\n","/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nmodule.exports = stackDelete;\n","/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nmodule.exports = stackGet;\n","/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nmodule.exports = stackHas;\n","var ListCache = require('./_ListCache'),\n Map = require('./_Map'),\n MapCache = require('./_MapCache');\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nmodule.exports = stackSet;\n","var memoizeCapped = require('./_memoizeCapped');\n\n/** Used to match property names within property paths. */\nvar rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\n\n/** Used to match backslashes in property paths. */\nvar reEscapeChar = /\\\\(\\\\)?/g;\n\n/**\n * Converts `string` to a property path array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the property path array.\n */\nvar stringToPath = memoizeCapped(function(string) {\n var result = [];\n if (string.charCodeAt(0) === 46 /* . */) {\n result.push('');\n }\n string.replace(rePropName, function(match, number, quote, subString) {\n result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));\n });\n return result;\n});\n\nmodule.exports = stringToPath;\n","var isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/**\n * Converts `value` to a string key if it's not a string or symbol.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {string|symbol} Returns the key.\n */\nfunction toKey(value) {\n if (typeof value == 'string' || isSymbol(value)) {\n return value;\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = toKey;\n","/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nmodule.exports = toSource;\n","var baseClone = require('./_baseClone');\n\n/** Used to compose bitmasks for cloning. */\nvar CLONE_DEEP_FLAG = 1,\n CLONE_SYMBOLS_FLAG = 4;\n\n/**\n * This method is like `_.clone` except that it recursively clones `value`.\n *\n * @static\n * @memberOf _\n * @since 1.0.0\n * @category Lang\n * @param {*} value The value to recursively clone.\n * @returns {*} Returns the deep cloned value.\n * @see _.clone\n * @example\n *\n * var objects = [{ 'a': 1 }, { 'b': 2 }];\n *\n * var deep = _.cloneDeep(objects);\n * console.log(deep[0] === objects[0]);\n * // => false\n */\nfunction cloneDeep(value) {\n return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG);\n}\n\nmodule.exports = cloneDeep;\n","/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nmodule.exports = eq;\n","var baseForOwn = require('./_baseForOwn'),\n castFunction = require('./_castFunction');\n\n/**\n * Iterates over own enumerable string keyed properties of an object and\n * invokes `iteratee` for each property. The iteratee is invoked with three\n * arguments: (value, key, object). Iteratee functions may exit iteration\n * early by explicitly returning `false`.\n *\n * @static\n * @memberOf _\n * @since 0.3.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns `object`.\n * @see _.forOwnRight\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.forOwn(new Foo, function(value, key) {\n * console.log(key);\n * });\n * // => Logs 'a' then 'b' (iteration order is not guaranteed).\n */\nfunction forOwn(object, iteratee) {\n return object && baseForOwn(object, castFunction(iteratee));\n}\n\nmodule.exports = forOwn;\n","var baseGet = require('./_baseGet');\n\n/**\n * Gets the value at `path` of `object`. If the resolved value is\n * `undefined`, the `defaultValue` is returned in its place.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.get(object, 'a[0].b.c');\n * // => 3\n *\n * _.get(object, ['a', '0', 'b', 'c']);\n * // => 3\n *\n * _.get(object, 'a.b.c', 'default');\n * // => 'default'\n */\nfunction get(object, path, defaultValue) {\n var result = object == null ? undefined : baseGet(object, path);\n return result === undefined ? defaultValue : result;\n}\n\nmodule.exports = get;\n","var baseHasIn = require('./_baseHasIn'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct or inherited property of `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.hasIn(object, 'a');\n * // => true\n *\n * _.hasIn(object, 'a.b');\n * // => true\n *\n * _.hasIn(object, ['a', 'b']);\n * // => true\n *\n * _.hasIn(object, 'b');\n * // => false\n */\nfunction hasIn(object, path) {\n return object != null && hasPath(object, path, baseHasIn);\n}\n\nmodule.exports = hasIn;\n","/**\n * This method returns the first argument it receives.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Util\n * @param {*} value Any value.\n * @returns {*} Returns `value`.\n * @example\n *\n * var object = { 'a': 1 };\n *\n * console.log(_.identity(object) === object);\n * // => true\n */\nfunction identity(value) {\n return value;\n}\n\nmodule.exports = identity;\n","var baseIsArguments = require('./_baseIsArguments'),\n isObjectLike = require('./isObjectLike');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nmodule.exports = isArguments;\n","/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nmodule.exports = isArray;\n","var isFunction = require('./isFunction'),\n isLength = require('./isLength');\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nmodule.exports = isArrayLike;\n","var root = require('./_root'),\n stubFalse = require('./stubFalse');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nmodule.exports = isBuffer;\n","var baseGetTag = require('./_baseGetTag'),\n isObject = require('./isObject');\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nmodule.exports = isFunction;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nmodule.exports = isLength;\n","var baseIsMap = require('./_baseIsMap'),\n baseUnary = require('./_baseUnary'),\n nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsMap = nodeUtil && nodeUtil.isMap;\n\n/**\n * Checks if `value` is classified as a `Map` object.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a map, else `false`.\n * @example\n *\n * _.isMap(new Map);\n * // => true\n *\n * _.isMap(new WeakMap);\n * // => false\n */\nvar isMap = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap;\n\nmodule.exports = isMap;\n","/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nmodule.exports = isObject;\n","/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nmodule.exports = isObjectLike;\n","var baseGetTag = require('./_baseGetTag'),\n getPrototype = require('./_getPrototype'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to infer the `Object` constructor. */\nvar objectCtorString = funcToString.call(Object);\n\n/**\n * Checks if `value` is a plain object, that is, an object created by the\n * `Object` constructor or one with a `[[Prototype]]` of `null`.\n *\n * @static\n * @memberOf _\n * @since 0.8.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a plain object, else `false`.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * }\n *\n * _.isPlainObject(new Foo);\n * // => false\n *\n * _.isPlainObject([1, 2, 3]);\n * // => false\n *\n * _.isPlainObject({ 'x': 0, 'y': 0 });\n * // => true\n *\n * _.isPlainObject(Object.create(null));\n * // => true\n */\nfunction isPlainObject(value) {\n if (!isObjectLike(value) || baseGetTag(value) != objectTag) {\n return false;\n }\n var proto = getPrototype(value);\n if (proto === null) {\n return true;\n }\n var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor;\n return typeof Ctor == 'function' && Ctor instanceof Ctor &&\n funcToString.call(Ctor) == objectCtorString;\n}\n\nmodule.exports = isPlainObject;\n","var baseIsSet = require('./_baseIsSet'),\n baseUnary = require('./_baseUnary'),\n nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsSet = nodeUtil && nodeUtil.isSet;\n\n/**\n * Checks if `value` is classified as a `Set` object.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a set, else `false`.\n * @example\n *\n * _.isSet(new Set);\n * // => true\n *\n * _.isSet(new WeakSet);\n * // => false\n */\nvar isSet = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;\n\nmodule.exports = isSet;\n","var baseGetTag = require('./_baseGetTag'),\n isArray = require('./isArray'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar stringTag = '[object String]';\n\n/**\n * Checks if `value` is classified as a `String` primitive or object.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a string, else `false`.\n * @example\n *\n * _.isString('abc');\n * // => true\n *\n * _.isString(1);\n * // => false\n */\nfunction isString(value) {\n return typeof value == 'string' ||\n (!isArray(value) && isObjectLike(value) && baseGetTag(value) == stringTag);\n}\n\nmodule.exports = isString;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n}\n\nmodule.exports = isSymbol;\n","var baseIsTypedArray = require('./_baseIsTypedArray'),\n baseUnary = require('./_baseUnary'),\n nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nmodule.exports = isTypedArray;\n","var arrayLikeKeys = require('./_arrayLikeKeys'),\n baseKeys = require('./_baseKeys'),\n isArrayLike = require('./isArrayLike');\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nmodule.exports = keys;\n","var arrayLikeKeys = require('./_arrayLikeKeys'),\n baseKeysIn = require('./_baseKeysIn'),\n isArrayLike = require('./isArrayLike');\n\n/**\n * Creates an array of the own and inherited enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keysIn(new Foo);\n * // => ['a', 'b', 'c'] (iteration order is not guaranteed)\n */\nfunction keysIn(object) {\n return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);\n}\n\nmodule.exports = keysIn;\n","var arrayMap = require('./_arrayMap'),\n baseIteratee = require('./_baseIteratee'),\n baseMap = require('./_baseMap'),\n isArray = require('./isArray');\n\n/**\n * Creates an array of values by running each element in `collection` thru\n * `iteratee`. The iteratee is invoked with three arguments:\n * (value, index|key, collection).\n *\n * Many lodash methods are guarded to work as iteratees for methods like\n * `_.every`, `_.filter`, `_.map`, `_.mapValues`, `_.reject`, and `_.some`.\n *\n * The guarded methods are:\n * `ary`, `chunk`, `curry`, `curryRight`, `drop`, `dropRight`, `every`,\n * `fill`, `invert`, `parseInt`, `random`, `range`, `rangeRight`, `repeat`,\n * `sampleSize`, `slice`, `some`, `sortBy`, `split`, `take`, `takeRight`,\n * `template`, `trim`, `trimEnd`, `trimStart`, and `words`\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n * @example\n *\n * function square(n) {\n * return n * n;\n * }\n *\n * _.map([4, 8], square);\n * // => [16, 64]\n *\n * _.map({ 'a': 4, 'b': 8 }, square);\n * // => [16, 64] (iteration order is not guaranteed)\n *\n * var users = [\n * { 'user': 'barney' },\n * { 'user': 'fred' }\n * ];\n *\n * // The `_.property` iteratee shorthand.\n * _.map(users, 'user');\n * // => ['barney', 'fred']\n */\nfunction map(collection, iteratee) {\n var func = isArray(collection) ? arrayMap : baseMap;\n return func(collection, baseIteratee(iteratee, 3));\n}\n\nmodule.exports = map;\n","var MapCache = require('./_MapCache');\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\nfunction memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n}\n\n// Expose `MapCache`.\nmemoize.Cache = MapCache;\n\nmodule.exports = memoize;\n","var baseProperty = require('./_baseProperty'),\n basePropertyDeep = require('./_basePropertyDeep'),\n isKey = require('./_isKey'),\n toKey = require('./_toKey');\n\n/**\n * Creates a function that returns the value at `path` of a given object.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n * @example\n *\n * var objects = [\n * { 'a': { 'b': 2 } },\n * { 'a': { 'b': 1 } }\n * ];\n *\n * _.map(objects, _.property('a.b'));\n * // => [2, 1]\n *\n * _.map(_.sortBy(objects, _.property(['a', 'b'])), 'a.b');\n * // => [1, 2]\n */\nfunction property(path) {\n return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);\n}\n\nmodule.exports = property;\n","/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nmodule.exports = stubArray;\n","/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nmodule.exports = stubFalse;\n","var baseToString = require('./_baseToString');\n\n/**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\nfunction toString(value) {\n return value == null ? '' : baseToString(value);\n}\n\nmodule.exports = toString;\n","export var calculateChange = function calculateChange(e, hsl, direction, initialA, container) {\n var containerWidth = container.clientWidth;\n var containerHeight = container.clientHeight;\n var x = typeof e.pageX === 'number' ? e.pageX : e.touches[0].pageX;\n var y = typeof e.pageY === 'number' ? e.pageY : e.touches[0].pageY;\n var left = x - (container.getBoundingClientRect().left + window.pageXOffset);\n var top = y - (container.getBoundingClientRect().top + window.pageYOffset);\n\n if (direction === 'vertical') {\n var a = void 0;\n if (top < 0) {\n a = 0;\n } else if (top > containerHeight) {\n a = 1;\n } else {\n a = Math.round(top * 100 / containerHeight) / 100;\n }\n\n if (hsl.a !== a) {\n return {\n h: hsl.h,\n s: hsl.s,\n l: hsl.l,\n a: a,\n source: 'rgb'\n };\n }\n } else {\n var _a = void 0;\n if (left < 0) {\n _a = 0;\n } else if (left > containerWidth) {\n _a = 1;\n } else {\n _a = Math.round(left * 100 / containerWidth) / 100;\n }\n\n if (initialA !== _a) {\n return {\n h: hsl.h,\n s: hsl.s,\n l: hsl.l,\n a: _a,\n source: 'rgb'\n };\n }\n }\n return null;\n};","var checkboardCache = {};\n\nexport var render = function render(c1, c2, size, serverCanvas) {\n if (typeof document === 'undefined' && !serverCanvas) {\n return null;\n }\n var canvas = serverCanvas ? new serverCanvas() : document.createElement('canvas');\n canvas.width = size * 2;\n canvas.height = size * 2;\n var ctx = canvas.getContext('2d');\n if (!ctx) {\n return null;\n } // If no context can be found, return early.\n ctx.fillStyle = c1;\n ctx.fillRect(0, 0, canvas.width, canvas.height);\n ctx.fillStyle = c2;\n ctx.fillRect(0, 0, size, size);\n ctx.translate(size, size);\n ctx.fillRect(0, 0, size, size);\n return canvas.toDataURL();\n};\n\nexport var get = function get(c1, c2, size, serverCanvas) {\n var key = c1 + '-' + c2 + '-' + size + (serverCanvas ? '-server' : '');\n\n if (checkboardCache[key]) {\n return checkboardCache[key];\n }\n\n var checkboard = render(c1, c2, size, serverCanvas);\n checkboardCache[key] = checkboard;\n return checkboard;\n};","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nimport React, { isValidElement } from 'react';\nimport reactCSS from 'reactcss';\nimport * as checkboard from '../../helpers/checkboard';\n\nexport var Checkboard = function Checkboard(_ref) {\n var white = _ref.white,\n grey = _ref.grey,\n size = _ref.size,\n renderers = _ref.renderers,\n borderRadius = _ref.borderRadius,\n boxShadow = _ref.boxShadow,\n children = _ref.children;\n\n var styles = reactCSS({\n 'default': {\n grid: {\n borderRadius: borderRadius,\n boxShadow: boxShadow,\n absolute: '0px 0px 0px 0px',\n background: 'url(' + checkboard.get(white, grey, size, renderers.canvas) + ') center left'\n }\n }\n });\n return isValidElement(children) ? React.cloneElement(children, _extends({}, children.props, { style: _extends({}, children.props.style, styles.grid) })) : React.createElement('div', { style: styles.grid });\n};\n\nCheckboard.defaultProps = {\n size: 8,\n white: 'transparent',\n grey: 'rgba(0,0,0,.08)',\n renderers: {}\n};\n\nexport default Checkboard;","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nvar _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\nimport React, { Component, PureComponent } from 'react';\nimport reactCSS from 'reactcss';\nimport * as alpha from '../../helpers/alpha';\n\nimport Checkboard from './Checkboard';\n\nexport var Alpha = function (_ref) {\n _inherits(Alpha, _ref);\n\n function Alpha() {\n var _ref2;\n\n var _temp, _this, _ret;\n\n _classCallCheck(this, Alpha);\n\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref2 = Alpha.__proto__ || Object.getPrototypeOf(Alpha)).call.apply(_ref2, [this].concat(args))), _this), _this.handleChange = function (e) {\n var change = alpha.calculateChange(e, _this.props.hsl, _this.props.direction, _this.props.a, _this.container);\n change && typeof _this.props.onChange === 'function' && _this.props.onChange(change, e);\n }, _this.handleMouseDown = function (e) {\n _this.handleChange(e);\n window.addEventListener('mousemove', _this.handleChange);\n window.addEventListener('mouseup', _this.handleMouseUp);\n }, _this.handleMouseUp = function () {\n _this.unbindEventListeners();\n }, _this.unbindEventListeners = function () {\n window.removeEventListener('mousemove', _this.handleChange);\n window.removeEventListener('mouseup', _this.handleMouseUp);\n }, _temp), _possibleConstructorReturn(_this, _ret);\n }\n\n _createClass(Alpha, [{\n key: 'componentWillUnmount',\n value: function componentWillUnmount() {\n this.unbindEventListeners();\n }\n }, {\n key: 'render',\n value: function render() {\n var _this2 = this;\n\n var rgb = this.props.rgb;\n var styles = reactCSS({\n 'default': {\n alpha: {\n absolute: '0px 0px 0px 0px',\n borderRadius: this.props.radius\n },\n checkboard: {\n absolute: '0px 0px 0px 0px',\n overflow: 'hidden',\n borderRadius: this.props.radius\n },\n gradient: {\n absolute: '0px 0px 0px 0px',\n background: 'linear-gradient(to right, rgba(' + rgb.r + ',' + rgb.g + ',' + rgb.b + ', 0) 0%,\\n rgba(' + rgb.r + ',' + rgb.g + ',' + rgb.b + ', 1) 100%)',\n boxShadow: this.props.shadow,\n borderRadius: this.props.radius\n },\n container: {\n position: 'relative',\n height: '100%',\n margin: '0 3px'\n },\n pointer: {\n position: 'absolute',\n left: rgb.a * 100 + '%'\n },\n slider: {\n width: '4px',\n borderRadius: '1px',\n height: '8px',\n boxShadow: '0 0 2px rgba(0, 0, 0, .6)',\n background: '#fff',\n marginTop: '1px',\n transform: 'translateX(-2px)'\n }\n },\n 'vertical': {\n gradient: {\n background: 'linear-gradient(to bottom, rgba(' + rgb.r + ',' + rgb.g + ',' + rgb.b + ', 0) 0%,\\n rgba(' + rgb.r + ',' + rgb.g + ',' + rgb.b + ', 1) 100%)'\n },\n pointer: {\n left: 0,\n top: rgb.a * 100 + '%'\n }\n },\n 'overwrite': _extends({}, this.props.style)\n }, {\n vertical: this.props.direction === 'vertical',\n overwrite: true\n });\n\n return React.createElement(\n 'div',\n { style: styles.alpha },\n React.createElement(\n 'div',\n { style: styles.checkboard },\n React.createElement(Checkboard, { renderers: this.props.renderers })\n ),\n React.createElement('div', { style: styles.gradient }),\n React.createElement(\n 'div',\n {\n style: styles.container,\n ref: function ref(container) {\n return _this2.container = container;\n },\n onMouseDown: this.handleMouseDown,\n onTouchMove: this.handleChange,\n onTouchStart: this.handleChange\n },\n React.createElement(\n 'div',\n { style: styles.pointer },\n this.props.pointer ? React.createElement(this.props.pointer, this.props) : React.createElement('div', { style: styles.slider })\n )\n )\n );\n }\n }]);\n\n return Alpha;\n}(PureComponent || Component);\n\nexport default Alpha;","var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\nimport React, { Component, PureComponent } from 'react';\nimport reactCSS from 'reactcss';\n\nvar DEFAULT_ARROW_OFFSET = 1;\n\nvar UP_KEY_CODE = 38;\nvar DOWN_KEY_CODE = 40;\nvar VALID_KEY_CODES = [UP_KEY_CODE, DOWN_KEY_CODE];\nvar isValidKeyCode = function isValidKeyCode(keyCode) {\n return VALID_KEY_CODES.indexOf(keyCode) > -1;\n};\nvar getNumberValue = function getNumberValue(value) {\n return Number(String(value).replace(/%/g, ''));\n};\n\nvar idCounter = 1;\n\nexport var EditableInput = function (_ref) {\n _inherits(EditableInput, _ref);\n\n function EditableInput(props) {\n _classCallCheck(this, EditableInput);\n\n var _this = _possibleConstructorReturn(this, (EditableInput.__proto__ || Object.getPrototypeOf(EditableInput)).call(this));\n\n _this.handleBlur = function () {\n if (_this.state.blurValue) {\n _this.setState({ value: _this.state.blurValue, blurValue: null });\n }\n };\n\n _this.handleChange = function (e) {\n _this.setUpdatedValue(e.target.value, e);\n };\n\n _this.handleKeyDown = function (e) {\n // In case `e.target.value` is a percentage remove the `%` character\n // and update accordingly with a percentage\n // https://github.com/casesandberg/react-color/issues/383\n var value = getNumberValue(e.target.value);\n if (!isNaN(value) && isValidKeyCode(e.keyCode)) {\n var offset = _this.getArrowOffset();\n var updatedValue = e.keyCode === UP_KEY_CODE ? value + offset : value - offset;\n\n _this.setUpdatedValue(updatedValue, e);\n }\n };\n\n _this.handleDrag = function (e) {\n if (_this.props.dragLabel) {\n var newValue = Math.round(_this.props.value + e.movementX);\n if (newValue >= 0 && newValue <= _this.props.dragMax) {\n _this.props.onChange && _this.props.onChange(_this.getValueObjectWithLabel(newValue), e);\n }\n }\n };\n\n _this.handleMouseDown = function (e) {\n if (_this.props.dragLabel) {\n e.preventDefault();\n _this.handleDrag(e);\n window.addEventListener('mousemove', _this.handleDrag);\n window.addEventListener('mouseup', _this.handleMouseUp);\n }\n };\n\n _this.handleMouseUp = function () {\n _this.unbindEventListeners();\n };\n\n _this.unbindEventListeners = function () {\n window.removeEventListener('mousemove', _this.handleDrag);\n window.removeEventListener('mouseup', _this.handleMouseUp);\n };\n\n _this.state = {\n value: String(props.value).toUpperCase(),\n blurValue: String(props.value).toUpperCase()\n };\n\n _this.inputId = 'rc-editable-input-' + idCounter++;\n return _this;\n }\n\n _createClass(EditableInput, [{\n key: 'componentDidUpdate',\n value: function componentDidUpdate(prevProps, prevState) {\n if (this.props.value !== this.state.value && (prevProps.value !== this.props.value || prevState.value !== this.state.value)) {\n if (this.input === document.activeElement) {\n this.setState({ blurValue: String(this.props.value).toUpperCase() });\n } else {\n this.setState({ value: String(this.props.value).toUpperCase(), blurValue: !this.state.blurValue && String(this.props.value).toUpperCase() });\n }\n }\n }\n }, {\n key: 'componentWillUnmount',\n value: function componentWillUnmount() {\n this.unbindEventListeners();\n }\n }, {\n key: 'getValueObjectWithLabel',\n value: function getValueObjectWithLabel(value) {\n return _defineProperty({}, this.props.label, value);\n }\n }, {\n key: 'getArrowOffset',\n value: function getArrowOffset() {\n return this.props.arrowOffset || DEFAULT_ARROW_OFFSET;\n }\n }, {\n key: 'setUpdatedValue',\n value: function setUpdatedValue(value, e) {\n var onChangeValue = this.props.label ? this.getValueObjectWithLabel(value) : value;\n this.props.onChange && this.props.onChange(onChangeValue, e);\n\n this.setState({ value: value });\n }\n }, {\n key: 'render',\n value: function render() {\n var _this2 = this;\n\n var styles = reactCSS({\n 'default': {\n wrap: {\n position: 'relative'\n }\n },\n 'user-override': {\n wrap: this.props.style && this.props.style.wrap ? this.props.style.wrap : {},\n input: this.props.style && this.props.style.input ? this.props.style.input : {},\n label: this.props.style && this.props.style.label ? this.props.style.label : {}\n },\n 'dragLabel-true': {\n label: {\n cursor: 'ew-resize'\n }\n }\n }, {\n 'user-override': true\n }, this.props);\n\n return React.createElement(\n 'div',\n { style: styles.wrap },\n React.createElement('input', {\n id: this.inputId,\n style: styles.input,\n ref: function ref(input) {\n return _this2.input = input;\n },\n value: this.state.value,\n onKeyDown: this.handleKeyDown,\n onChange: this.handleChange,\n onBlur: this.handleBlur,\n placeholder: this.props.placeholder,\n spellCheck: 'false'\n }),\n this.props.label && !this.props.hideLabel ? React.createElement(\n 'label',\n {\n htmlFor: this.inputId,\n style: styles.label,\n onMouseDown: this.handleMouseDown\n },\n this.props.label\n ) : null\n );\n }\n }]);\n\n return EditableInput;\n}(PureComponent || Component);\n\nexport default EditableInput;","export var calculateChange = function calculateChange(e, direction, hsl, container) {\n var containerWidth = container.clientWidth;\n var containerHeight = container.clientHeight;\n var x = typeof e.pageX === 'number' ? e.pageX : e.touches[0].pageX;\n var y = typeof e.pageY === 'number' ? e.pageY : e.touches[0].pageY;\n var left = x - (container.getBoundingClientRect().left + window.pageXOffset);\n var top = y - (container.getBoundingClientRect().top + window.pageYOffset);\n\n if (direction === 'vertical') {\n var h = void 0;\n if (top < 0) {\n h = 359;\n } else if (top > containerHeight) {\n h = 0;\n } else {\n var percent = -(top * 100 / containerHeight) + 100;\n h = 360 * percent / 100;\n }\n\n if (hsl.h !== h) {\n return {\n h: h,\n s: hsl.s,\n l: hsl.l,\n a: hsl.a,\n source: 'hsl'\n };\n }\n } else {\n var _h = void 0;\n if (left < 0) {\n _h = 0;\n } else if (left > containerWidth) {\n _h = 359;\n } else {\n var _percent = left * 100 / containerWidth;\n _h = 360 * _percent / 100;\n }\n\n if (hsl.h !== _h) {\n return {\n h: _h,\n s: hsl.s,\n l: hsl.l,\n a: hsl.a,\n source: 'hsl'\n };\n }\n }\n return null;\n};","var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\nimport React, { Component, PureComponent } from 'react';\nimport reactCSS from 'reactcss';\nimport * as hue from '../../helpers/hue';\n\nexport var Hue = function (_ref) {\n _inherits(Hue, _ref);\n\n function Hue() {\n var _ref2;\n\n var _temp, _this, _ret;\n\n _classCallCheck(this, Hue);\n\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref2 = Hue.__proto__ || Object.getPrototypeOf(Hue)).call.apply(_ref2, [this].concat(args))), _this), _this.handleChange = function (e) {\n var change = hue.calculateChange(e, _this.props.direction, _this.props.hsl, _this.container);\n change && typeof _this.props.onChange === 'function' && _this.props.onChange(change, e);\n }, _this.handleMouseDown = function (e) {\n _this.handleChange(e);\n window.addEventListener('mousemove', _this.handleChange);\n window.addEventListener('mouseup', _this.handleMouseUp);\n }, _this.handleMouseUp = function () {\n _this.unbindEventListeners();\n }, _temp), _possibleConstructorReturn(_this, _ret);\n }\n\n _createClass(Hue, [{\n key: 'componentWillUnmount',\n value: function componentWillUnmount() {\n this.unbindEventListeners();\n }\n }, {\n key: 'unbindEventListeners',\n value: function unbindEventListeners() {\n window.removeEventListener('mousemove', this.handleChange);\n window.removeEventListener('mouseup', this.handleMouseUp);\n }\n }, {\n key: 'render',\n value: function render() {\n var _this2 = this;\n\n var _props$direction = this.props.direction,\n direction = _props$direction === undefined ? 'horizontal' : _props$direction;\n\n\n var styles = reactCSS({\n 'default': {\n hue: {\n absolute: '0px 0px 0px 0px',\n borderRadius: this.props.radius,\n boxShadow: this.props.shadow\n },\n container: {\n padding: '0 2px',\n position: 'relative',\n height: '100%',\n borderRadius: this.props.radius\n },\n pointer: {\n position: 'absolute',\n left: this.props.hsl.h * 100 / 360 + '%'\n },\n slider: {\n marginTop: '1px',\n width: '4px',\n borderRadius: '1px',\n height: '8px',\n boxShadow: '0 0 2px rgba(0, 0, 0, .6)',\n background: '#fff',\n transform: 'translateX(-2px)'\n }\n },\n 'vertical': {\n pointer: {\n left: '0px',\n top: -(this.props.hsl.h * 100 / 360) + 100 + '%'\n }\n }\n }, { vertical: direction === 'vertical' });\n\n return React.createElement(\n 'div',\n { style: styles.hue },\n React.createElement(\n 'div',\n {\n className: 'hue-' + direction,\n style: styles.container,\n ref: function ref(container) {\n return _this2.container = container;\n },\n onMouseDown: this.handleMouseDown,\n onTouchMove: this.handleChange,\n onTouchStart: this.handleChange\n },\n React.createElement(\n 'style',\n null,\n '\\n .hue-horizontal {\\n background: linear-gradient(to right, #f00 0%, #ff0 17%, #0f0\\n 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\\n background: -webkit-linear-gradient(to right, #f00 0%, #ff0\\n 17%, #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\\n }\\n\\n .hue-vertical {\\n background: linear-gradient(to top, #f00 0%, #ff0 17%, #0f0 33%,\\n #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\\n background: -webkit-linear-gradient(to top, #f00 0%, #ff0 17%,\\n #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\\n }\\n '\n ),\n React.createElement(\n 'div',\n { style: styles.pointer },\n this.props.pointer ? React.createElement(this.props.pointer, this.props) : React.createElement('div', { style: styles.slider })\n )\n )\n );\n }\n }]);\n\n return Hue;\n}(PureComponent || Component);\n\nexport default Hue;","/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nexport default listCacheClear;\n","/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nexport default eq;\n","import eq from './eq.js';\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nexport default assocIndexOf;\n","import assocIndexOf from './_assocIndexOf.js';\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nexport default listCacheDelete;\n","import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nexport default listCacheGet;\n","import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nexport default listCacheHas;\n","import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nexport default listCacheSet;\n","import listCacheClear from './_listCacheClear.js';\nimport listCacheDelete from './_listCacheDelete.js';\nimport listCacheGet from './_listCacheGet.js';\nimport listCacheHas from './_listCacheHas.js';\nimport listCacheSet from './_listCacheSet.js';\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nexport default ListCache;\n","import ListCache from './_ListCache.js';\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nexport default stackClear;\n","/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nexport default stackDelete;\n","/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nexport default stackGet;\n","/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nexport default stackHas;\n","/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nexport default freeGlobal;\n","import freeGlobal from './_freeGlobal.js';\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nexport default root;\n","import root from './_root.js';\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nexport default Symbol;\n","import Symbol from './_Symbol.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nexport default getRawTag;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nexport default objectToString;\n","import Symbol from './_Symbol.js';\nimport getRawTag from './_getRawTag.js';\nimport objectToString from './_objectToString.js';\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nexport default baseGetTag;\n","/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nexport default isObject;\n","import baseGetTag from './_baseGetTag.js';\nimport isObject from './isObject.js';\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nexport default isFunction;\n","import root from './_root.js';\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nexport default coreJsData;\n","import coreJsData from './_coreJsData.js';\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nexport default isMasked;\n","/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nexport default toSource;\n","import isFunction from './isFunction.js';\nimport isMasked from './_isMasked.js';\nimport isObject from './isObject.js';\nimport toSource from './_toSource.js';\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nexport default baseIsNative;\n","/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nexport default getValue;\n","import baseIsNative from './_baseIsNative.js';\nimport getValue from './_getValue.js';\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nexport default getNative;\n","import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nexport default Map;\n","import getNative from './_getNative.js';\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nexport default nativeCreate;\n","import nativeCreate from './_nativeCreate.js';\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nexport default hashClear;\n","/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nexport default hashDelete;\n","import nativeCreate from './_nativeCreate.js';\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nexport default hashGet;\n","import nativeCreate from './_nativeCreate.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nexport default hashHas;\n","import nativeCreate from './_nativeCreate.js';\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nexport default hashSet;\n","import hashClear from './_hashClear.js';\nimport hashDelete from './_hashDelete.js';\nimport hashGet from './_hashGet.js';\nimport hashHas from './_hashHas.js';\nimport hashSet from './_hashSet.js';\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nexport default Hash;\n","import Hash from './_Hash.js';\nimport ListCache from './_ListCache.js';\nimport Map from './_Map.js';\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nexport default mapCacheClear;\n","/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nexport default isKeyable;\n","import isKeyable from './_isKeyable.js';\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nexport default getMapData;\n","import getMapData from './_getMapData.js';\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nexport default mapCacheDelete;\n","import getMapData from './_getMapData.js';\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nexport default mapCacheGet;\n","import getMapData from './_getMapData.js';\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nexport default mapCacheHas;\n","import getMapData from './_getMapData.js';\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nexport default mapCacheSet;\n","import mapCacheClear from './_mapCacheClear.js';\nimport mapCacheDelete from './_mapCacheDelete.js';\nimport mapCacheGet from './_mapCacheGet.js';\nimport mapCacheHas from './_mapCacheHas.js';\nimport mapCacheSet from './_mapCacheSet.js';\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nexport default MapCache;\n","import ListCache from './_ListCache.js';\nimport Map from './_Map.js';\nimport MapCache from './_MapCache.js';\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nexport default stackSet;\n","import ListCache from './_ListCache.js';\nimport stackClear from './_stackClear.js';\nimport stackDelete from './_stackDelete.js';\nimport stackGet from './_stackGet.js';\nimport stackHas from './_stackHas.js';\nimport stackSet from './_stackSet.js';\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nexport default Stack;\n","import getNative from './_getNative.js';\n\nvar defineProperty = (function() {\n try {\n var func = getNative(Object, 'defineProperty');\n func({}, '', {});\n return func;\n } catch (e) {}\n}());\n\nexport default defineProperty;\n","import defineProperty from './_defineProperty.js';\n\n/**\n * The base implementation of `assignValue` and `assignMergeValue` without\n * value checks.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction baseAssignValue(object, key, value) {\n if (key == '__proto__' && defineProperty) {\n defineProperty(object, key, {\n 'configurable': true,\n 'enumerable': true,\n 'value': value,\n 'writable': true\n });\n } else {\n object[key] = value;\n }\n}\n\nexport default baseAssignValue;\n","import baseAssignValue from './_baseAssignValue.js';\nimport eq from './eq.js';\n\n/**\n * This function is like `assignValue` except that it doesn't assign\n * `undefined` values.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction assignMergeValue(object, key, value) {\n if ((value !== undefined && !eq(object[key], value)) ||\n (value === undefined && !(key in object))) {\n baseAssignValue(object, key, value);\n }\n}\n\nexport default assignMergeValue;\n","/**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n}\n\nexport default createBaseFor;\n","import createBaseFor from './_createBaseFor.js';\n\n/**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\nvar baseFor = createBaseFor();\n\nexport default baseFor;\n","import root from './_root.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined,\n allocUnsafe = Buffer ? Buffer.allocUnsafe : undefined;\n\n/**\n * Creates a clone of `buffer`.\n *\n * @private\n * @param {Buffer} buffer The buffer to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Buffer} Returns the cloned buffer.\n */\nfunction cloneBuffer(buffer, isDeep) {\n if (isDeep) {\n return buffer.slice();\n }\n var length = buffer.length,\n result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);\n\n buffer.copy(result);\n return result;\n}\n\nexport default cloneBuffer;\n","import root from './_root.js';\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nexport default Uint8Array;\n","import Uint8Array from './_Uint8Array.js';\n\n/**\n * Creates a clone of `arrayBuffer`.\n *\n * @private\n * @param {ArrayBuffer} arrayBuffer The array buffer to clone.\n * @returns {ArrayBuffer} Returns the cloned array buffer.\n */\nfunction cloneArrayBuffer(arrayBuffer) {\n var result = new arrayBuffer.constructor(arrayBuffer.byteLength);\n new Uint8Array(result).set(new Uint8Array(arrayBuffer));\n return result;\n}\n\nexport default cloneArrayBuffer;\n","import cloneArrayBuffer from './_cloneArrayBuffer.js';\n\n/**\n * Creates a clone of `typedArray`.\n *\n * @private\n * @param {Object} typedArray The typed array to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Object} Returns the cloned typed array.\n */\nfunction cloneTypedArray(typedArray, isDeep) {\n var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer;\n return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);\n}\n\nexport default cloneTypedArray;\n","/**\n * Copies the values of `source` to `array`.\n *\n * @private\n * @param {Array} source The array to copy values from.\n * @param {Array} [array=[]] The array to copy values to.\n * @returns {Array} Returns `array`.\n */\nfunction copyArray(source, array) {\n var index = -1,\n length = source.length;\n\n array || (array = Array(length));\n while (++index < length) {\n array[index] = source[index];\n }\n return array;\n}\n\nexport default copyArray;\n","import isObject from './isObject.js';\n\n/** Built-in value references. */\nvar objectCreate = Object.create;\n\n/**\n * The base implementation of `_.create` without support for assigning\n * properties to the created object.\n *\n * @private\n * @param {Object} proto The object to inherit from.\n * @returns {Object} Returns the new object.\n */\nvar baseCreate = (function() {\n function object() {}\n return function(proto) {\n if (!isObject(proto)) {\n return {};\n }\n if (objectCreate) {\n return objectCreate(proto);\n }\n object.prototype = proto;\n var result = new object;\n object.prototype = undefined;\n return result;\n };\n}());\n\nexport default baseCreate;\n","/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nexport default overArg;\n","import overArg from './_overArg.js';\n\n/** Built-in value references. */\nvar getPrototype = overArg(Object.getPrototypeOf, Object);\n\nexport default getPrototype;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nexport default isPrototype;\n","import baseCreate from './_baseCreate.js';\nimport getPrototype from './_getPrototype.js';\nimport isPrototype from './_isPrototype.js';\n\n/**\n * Initializes an object clone.\n *\n * @private\n * @param {Object} object The object to clone.\n * @returns {Object} Returns the initialized clone.\n */\nfunction initCloneObject(object) {\n return (typeof object.constructor == 'function' && !isPrototype(object))\n ? baseCreate(getPrototype(object))\n : {};\n}\n\nexport default initCloneObject;\n","/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nexport default isObjectLike;\n","import baseGetTag from './_baseGetTag.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nexport default baseIsArguments;\n","import baseIsArguments from './_baseIsArguments.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nexport default isArguments;\n","/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nexport default isArray;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nexport default isLength;\n","import isFunction from './isFunction.js';\nimport isLength from './isLength.js';\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nexport default isArrayLike;\n","import isArrayLike from './isArrayLike.js';\nimport isObjectLike from './isObjectLike.js';\n\n/**\n * This method is like `_.isArrayLike` except that it also checks if `value`\n * is an object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array-like object,\n * else `false`.\n * @example\n *\n * _.isArrayLikeObject([1, 2, 3]);\n * // => true\n *\n * _.isArrayLikeObject(document.body.children);\n * // => true\n *\n * _.isArrayLikeObject('abc');\n * // => false\n *\n * _.isArrayLikeObject(_.noop);\n * // => false\n */\nfunction isArrayLikeObject(value) {\n return isObjectLike(value) && isArrayLike(value);\n}\n\nexport default isArrayLikeObject;\n","/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nexport default stubFalse;\n","import root from './_root.js';\nimport stubFalse from './stubFalse.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nexport default isBuffer;\n","import baseGetTag from './_baseGetTag.js';\nimport getPrototype from './_getPrototype.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to infer the `Object` constructor. */\nvar objectCtorString = funcToString.call(Object);\n\n/**\n * Checks if `value` is a plain object, that is, an object created by the\n * `Object` constructor or one with a `[[Prototype]]` of `null`.\n *\n * @static\n * @memberOf _\n * @since 0.8.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a plain object, else `false`.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * }\n *\n * _.isPlainObject(new Foo);\n * // => false\n *\n * _.isPlainObject([1, 2, 3]);\n * // => false\n *\n * _.isPlainObject({ 'x': 0, 'y': 0 });\n * // => true\n *\n * _.isPlainObject(Object.create(null));\n * // => true\n */\nfunction isPlainObject(value) {\n if (!isObjectLike(value) || baseGetTag(value) != objectTag) {\n return false;\n }\n var proto = getPrototype(value);\n if (proto === null) {\n return true;\n }\n var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor;\n return typeof Ctor == 'function' && Ctor instanceof Ctor &&\n funcToString.call(Ctor) == objectCtorString;\n}\n\nexport default isPlainObject;\n","import baseGetTag from './_baseGetTag.js';\nimport isLength from './isLength.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nexport default baseIsTypedArray;\n","/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nexport default baseUnary;\n","import freeGlobal from './_freeGlobal.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nexport default nodeUtil;\n","import baseIsTypedArray from './_baseIsTypedArray.js';\nimport baseUnary from './_baseUnary.js';\nimport nodeUtil from './_nodeUtil.js';\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nexport default isTypedArray;\n","/**\n * Gets the value at `key`, unless `key` is \"__proto__\" or \"constructor\".\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction safeGet(object, key) {\n if (key === 'constructor' && typeof object[key] === 'function') {\n return;\n }\n\n if (key == '__proto__') {\n return;\n }\n\n return object[key];\n}\n\nexport default safeGet;\n","import baseAssignValue from './_baseAssignValue.js';\nimport eq from './eq.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Assigns `value` to `key` of `object` if the existing value is not equivalent\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction assignValue(object, key, value) {\n var objValue = object[key];\n if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) ||\n (value === undefined && !(key in object))) {\n baseAssignValue(object, key, value);\n }\n}\n\nexport default assignValue;\n","import assignValue from './_assignValue.js';\nimport baseAssignValue from './_baseAssignValue.js';\n\n/**\n * Copies properties of `source` to `object`.\n *\n * @private\n * @param {Object} source The object to copy properties from.\n * @param {Array} props The property identifiers to copy.\n * @param {Object} [object={}] The object to copy properties to.\n * @param {Function} [customizer] The function to customize copied values.\n * @returns {Object} Returns `object`.\n */\nfunction copyObject(source, props, object, customizer) {\n var isNew = !object;\n object || (object = {});\n\n var index = -1,\n length = props.length;\n\n while (++index < length) {\n var key = props[index];\n\n var newValue = customizer\n ? customizer(object[key], source[key], key, object, source)\n : undefined;\n\n if (newValue === undefined) {\n newValue = source[key];\n }\n if (isNew) {\n baseAssignValue(object, key, newValue);\n } else {\n assignValue(object, key, newValue);\n }\n }\n return object;\n}\n\nexport default copyObject;\n","/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nexport default baseTimes;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\nexport default isIndex;\n","import baseTimes from './_baseTimes.js';\nimport isArguments from './isArguments.js';\nimport isArray from './isArray.js';\nimport isBuffer from './isBuffer.js';\nimport isIndex from './_isIndex.js';\nimport isTypedArray from './isTypedArray.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default arrayLikeKeys;\n","/**\n * This function is like\n * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * except that it includes inherited enumerable properties.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction nativeKeysIn(object) {\n var result = [];\n if (object != null) {\n for (var key in Object(object)) {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default nativeKeysIn;\n","import isObject from './isObject.js';\nimport isPrototype from './_isPrototype.js';\nimport nativeKeysIn from './_nativeKeysIn.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeysIn(object) {\n if (!isObject(object)) {\n return nativeKeysIn(object);\n }\n var isProto = isPrototype(object),\n result = [];\n\n for (var key in object) {\n if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default baseKeysIn;\n","import arrayLikeKeys from './_arrayLikeKeys.js';\nimport baseKeysIn from './_baseKeysIn.js';\nimport isArrayLike from './isArrayLike.js';\n\n/**\n * Creates an array of the own and inherited enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keysIn(new Foo);\n * // => ['a', 'b', 'c'] (iteration order is not guaranteed)\n */\nfunction keysIn(object) {\n return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);\n}\n\nexport default keysIn;\n","import copyObject from './_copyObject.js';\nimport keysIn from './keysIn.js';\n\n/**\n * Converts `value` to a plain object flattening inherited enumerable string\n * keyed properties of `value` to own properties of the plain object.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {Object} Returns the converted plain object.\n * @example\n *\n * function Foo() {\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.assign({ 'a': 1 }, new Foo);\n * // => { 'a': 1, 'b': 2 }\n *\n * _.assign({ 'a': 1 }, _.toPlainObject(new Foo));\n * // => { 'a': 1, 'b': 2, 'c': 3 }\n */\nfunction toPlainObject(value) {\n return copyObject(value, keysIn(value));\n}\n\nexport default toPlainObject;\n","import assignMergeValue from './_assignMergeValue.js';\nimport cloneBuffer from './_cloneBuffer.js';\nimport cloneTypedArray from './_cloneTypedArray.js';\nimport copyArray from './_copyArray.js';\nimport initCloneObject from './_initCloneObject.js';\nimport isArguments from './isArguments.js';\nimport isArray from './isArray.js';\nimport isArrayLikeObject from './isArrayLikeObject.js';\nimport isBuffer from './isBuffer.js';\nimport isFunction from './isFunction.js';\nimport isObject from './isObject.js';\nimport isPlainObject from './isPlainObject.js';\nimport isTypedArray from './isTypedArray.js';\nimport safeGet from './_safeGet.js';\nimport toPlainObject from './toPlainObject.js';\n\n/**\n * A specialized version of `baseMerge` for arrays and objects which performs\n * deep merges and tracks traversed objects enabling objects with circular\n * references to be merged.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @param {string} key The key of the value to merge.\n * @param {number} srcIndex The index of `source`.\n * @param {Function} mergeFunc The function to merge values.\n * @param {Function} [customizer] The function to customize assigned values.\n * @param {Object} [stack] Tracks traversed source values and their merged\n * counterparts.\n */\nfunction baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) {\n var objValue = safeGet(object, key),\n srcValue = safeGet(source, key),\n stacked = stack.get(srcValue);\n\n if (stacked) {\n assignMergeValue(object, key, stacked);\n return;\n }\n var newValue = customizer\n ? customizer(objValue, srcValue, (key + ''), object, source, stack)\n : undefined;\n\n var isCommon = newValue === undefined;\n\n if (isCommon) {\n var isArr = isArray(srcValue),\n isBuff = !isArr && isBuffer(srcValue),\n isTyped = !isArr && !isBuff && isTypedArray(srcValue);\n\n newValue = srcValue;\n if (isArr || isBuff || isTyped) {\n if (isArray(objValue)) {\n newValue = objValue;\n }\n else if (isArrayLikeObject(objValue)) {\n newValue = copyArray(objValue);\n }\n else if (isBuff) {\n isCommon = false;\n newValue = cloneBuffer(srcValue, true);\n }\n else if (isTyped) {\n isCommon = false;\n newValue = cloneTypedArray(srcValue, true);\n }\n else {\n newValue = [];\n }\n }\n else if (isPlainObject(srcValue) || isArguments(srcValue)) {\n newValue = objValue;\n if (isArguments(objValue)) {\n newValue = toPlainObject(objValue);\n }\n else if (!isObject(objValue) || isFunction(objValue)) {\n newValue = initCloneObject(srcValue);\n }\n }\n else {\n isCommon = false;\n }\n }\n if (isCommon) {\n // Recursively merge objects and arrays (susceptible to call stack limits).\n stack.set(srcValue, newValue);\n mergeFunc(newValue, srcValue, srcIndex, customizer, stack);\n stack['delete'](srcValue);\n }\n assignMergeValue(object, key, newValue);\n}\n\nexport default baseMergeDeep;\n","import Stack from './_Stack.js';\nimport assignMergeValue from './_assignMergeValue.js';\nimport baseFor from './_baseFor.js';\nimport baseMergeDeep from './_baseMergeDeep.js';\nimport isObject from './isObject.js';\nimport keysIn from './keysIn.js';\nimport safeGet from './_safeGet.js';\n\n/**\n * The base implementation of `_.merge` without support for multiple sources.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @param {number} srcIndex The index of `source`.\n * @param {Function} [customizer] The function to customize merged values.\n * @param {Object} [stack] Tracks traversed source values and their merged\n * counterparts.\n */\nfunction baseMerge(object, source, srcIndex, customizer, stack) {\n if (object === source) {\n return;\n }\n baseFor(source, function(srcValue, key) {\n stack || (stack = new Stack);\n if (isObject(srcValue)) {\n baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack);\n }\n else {\n var newValue = customizer\n ? customizer(safeGet(object, key), srcValue, (key + ''), object, source, stack)\n : undefined;\n\n if (newValue === undefined) {\n newValue = srcValue;\n }\n assignMergeValue(object, key, newValue);\n }\n }, keysIn);\n}\n\nexport default baseMerge;\n","/**\n * This method returns the first argument it receives.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Util\n * @param {*} value Any value.\n * @returns {*} Returns `value`.\n * @example\n *\n * var object = { 'a': 1 };\n *\n * console.log(_.identity(object) === object);\n * // => true\n */\nfunction identity(value) {\n return value;\n}\n\nexport default identity;\n","/**\n * A faster alternative to `Function#apply`, this function invokes `func`\n * with the `this` binding of `thisArg` and the arguments of `args`.\n *\n * @private\n * @param {Function} func The function to invoke.\n * @param {*} thisArg The `this` binding of `func`.\n * @param {Array} args The arguments to invoke `func` with.\n * @returns {*} Returns the result of `func`.\n */\nfunction apply(func, thisArg, args) {\n switch (args.length) {\n case 0: return func.call(thisArg);\n case 1: return func.call(thisArg, args[0]);\n case 2: return func.call(thisArg, args[0], args[1]);\n case 3: return func.call(thisArg, args[0], args[1], args[2]);\n }\n return func.apply(thisArg, args);\n}\n\nexport default apply;\n","import apply from './_apply.js';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeMax = Math.max;\n\n/**\n * A specialized version of `baseRest` which transforms the rest array.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @param {number} [start=func.length-1] The start position of the rest parameter.\n * @param {Function} transform The rest array transform.\n * @returns {Function} Returns the new function.\n */\nfunction overRest(func, start, transform) {\n start = nativeMax(start === undefined ? (func.length - 1) : start, 0);\n return function() {\n var args = arguments,\n index = -1,\n length = nativeMax(args.length - start, 0),\n array = Array(length);\n\n while (++index < length) {\n array[index] = args[start + index];\n }\n index = -1;\n var otherArgs = Array(start + 1);\n while (++index < start) {\n otherArgs[index] = args[index];\n }\n otherArgs[start] = transform(array);\n return apply(func, this, otherArgs);\n };\n}\n\nexport default overRest;\n","/**\n * Creates a function that returns `value`.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {*} value The value to return from the new function.\n * @returns {Function} Returns the new constant function.\n * @example\n *\n * var objects = _.times(2, _.constant({ 'a': 1 }));\n *\n * console.log(objects);\n * // => [{ 'a': 1 }, { 'a': 1 }]\n *\n * console.log(objects[0] === objects[1]);\n * // => true\n */\nfunction constant(value) {\n return function() {\n return value;\n };\n}\n\nexport default constant;\n","import constant from './constant.js';\nimport defineProperty from './_defineProperty.js';\nimport identity from './identity.js';\n\n/**\n * The base implementation of `setToString` without support for hot loop shorting.\n *\n * @private\n * @param {Function} func The function to modify.\n * @param {Function} string The `toString` result.\n * @returns {Function} Returns `func`.\n */\nvar baseSetToString = !defineProperty ? identity : function(func, string) {\n return defineProperty(func, 'toString', {\n 'configurable': true,\n 'enumerable': false,\n 'value': constant(string),\n 'writable': true\n });\n};\n\nexport default baseSetToString;\n","/** Used to detect hot functions by number of calls within a span of milliseconds. */\nvar HOT_COUNT = 800,\n HOT_SPAN = 16;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeNow = Date.now;\n\n/**\n * Creates a function that'll short out and invoke `identity` instead\n * of `func` when it's called `HOT_COUNT` or more times in `HOT_SPAN`\n * milliseconds.\n *\n * @private\n * @param {Function} func The function to restrict.\n * @returns {Function} Returns the new shortable function.\n */\nfunction shortOut(func) {\n var count = 0,\n lastCalled = 0;\n\n return function() {\n var stamp = nativeNow(),\n remaining = HOT_SPAN - (stamp - lastCalled);\n\n lastCalled = stamp;\n if (remaining > 0) {\n if (++count >= HOT_COUNT) {\n return arguments[0];\n }\n } else {\n count = 0;\n }\n return func.apply(undefined, arguments);\n };\n}\n\nexport default shortOut;\n","import baseSetToString from './_baseSetToString.js';\nimport shortOut from './_shortOut.js';\n\n/**\n * Sets the `toString` method of `func` to return `string`.\n *\n * @private\n * @param {Function} func The function to modify.\n * @param {Function} string The `toString` result.\n * @returns {Function} Returns `func`.\n */\nvar setToString = shortOut(baseSetToString);\n\nexport default setToString;\n","import identity from './identity.js';\nimport overRest from './_overRest.js';\nimport setToString from './_setToString.js';\n\n/**\n * The base implementation of `_.rest` which doesn't validate or coerce arguments.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @param {number} [start=func.length-1] The start position of the rest parameter.\n * @returns {Function} Returns the new function.\n */\nfunction baseRest(func, start) {\n return setToString(overRest(func, start, identity), func + '');\n}\n\nexport default baseRest;\n","import eq from './eq.js';\nimport isArrayLike from './isArrayLike.js';\nimport isIndex from './_isIndex.js';\nimport isObject from './isObject.js';\n\n/**\n * Checks if the given arguments are from an iteratee call.\n *\n * @private\n * @param {*} value The potential iteratee value argument.\n * @param {*} index The potential iteratee index or key argument.\n * @param {*} object The potential iteratee object argument.\n * @returns {boolean} Returns `true` if the arguments are from an iteratee call,\n * else `false`.\n */\nfunction isIterateeCall(value, index, object) {\n if (!isObject(object)) {\n return false;\n }\n var type = typeof index;\n if (type == 'number'\n ? (isArrayLike(object) && isIndex(index, object.length))\n : (type == 'string' && index in object)\n ) {\n return eq(object[index], value);\n }\n return false;\n}\n\nexport default isIterateeCall;\n","import baseRest from './_baseRest.js';\nimport isIterateeCall from './_isIterateeCall.js';\n\n/**\n * Creates a function like `_.assign`.\n *\n * @private\n * @param {Function} assigner The function to assign values.\n * @returns {Function} Returns the new assigner function.\n */\nfunction createAssigner(assigner) {\n return baseRest(function(object, sources) {\n var index = -1,\n length = sources.length,\n customizer = length > 1 ? sources[length - 1] : undefined,\n guard = length > 2 ? sources[2] : undefined;\n\n customizer = (assigner.length > 3 && typeof customizer == 'function')\n ? (length--, customizer)\n : undefined;\n\n if (guard && isIterateeCall(sources[0], sources[1], guard)) {\n customizer = length < 3 ? undefined : customizer;\n length = 1;\n }\n object = Object(object);\n while (++index < length) {\n var source = sources[index];\n if (source) {\n assigner(object, source, index, customizer);\n }\n }\n return object;\n });\n}\n\nexport default createAssigner;\n","import baseMerge from './_baseMerge.js';\nimport createAssigner from './_createAssigner.js';\n\n/**\n * This method is like `_.assign` except that it recursively merges own and\n * inherited enumerable string keyed properties of source objects into the\n * destination object. Source properties that resolve to `undefined` are\n * skipped if a destination value exists. Array and plain object properties\n * are merged recursively. Other objects and value types are overridden by\n * assignment. Source objects are applied from left to right. Subsequent\n * sources overwrite property assignments of previous sources.\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 0.5.0\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} [sources] The source objects.\n * @returns {Object} Returns `object`.\n * @example\n *\n * var object = {\n * 'a': [{ 'b': 2 }, { 'd': 4 }]\n * };\n *\n * var other = {\n * 'a': [{ 'c': 3 }, { 'e': 5 }]\n * };\n *\n * _.merge(object, other);\n * // => { 'a': [{ 'b': 2, 'c': 3 }, { 'd': 4, 'e': 5 }] }\n */\nvar merge = createAssigner(function(object, source, srcIndex) {\n baseMerge(object, source, srcIndex);\n});\n\nexport default merge;\n","import React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport merge from 'lodash-es/merge';\n\nexport var Raised = function Raised(_ref) {\n var zDepth = _ref.zDepth,\n radius = _ref.radius,\n background = _ref.background,\n children = _ref.children,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles;\n\n var styles = reactCSS(merge({\n 'default': {\n wrap: {\n position: 'relative',\n display: 'inline-block'\n },\n content: {\n position: 'relative'\n },\n bg: {\n absolute: '0px 0px 0px 0px',\n boxShadow: '0 ' + zDepth + 'px ' + zDepth * 4 + 'px rgba(0,0,0,.24)',\n borderRadius: radius,\n background: background\n }\n },\n 'zDepth-0': {\n bg: {\n boxShadow: 'none'\n }\n },\n\n 'zDepth-1': {\n bg: {\n boxShadow: '0 2px 10px rgba(0,0,0,.12), 0 2px 5px rgba(0,0,0,.16)'\n }\n },\n 'zDepth-2': {\n bg: {\n boxShadow: '0 6px 20px rgba(0,0,0,.19), 0 8px 17px rgba(0,0,0,.2)'\n }\n },\n 'zDepth-3': {\n bg: {\n boxShadow: '0 17px 50px rgba(0,0,0,.19), 0 12px 15px rgba(0,0,0,.24)'\n }\n },\n 'zDepth-4': {\n bg: {\n boxShadow: '0 25px 55px rgba(0,0,0,.21), 0 16px 28px rgba(0,0,0,.22)'\n }\n },\n 'zDepth-5': {\n bg: {\n boxShadow: '0 40px 77px rgba(0,0,0,.22), 0 27px 24px rgba(0,0,0,.2)'\n }\n },\n 'square': {\n bg: {\n borderRadius: '0'\n }\n },\n 'circle': {\n bg: {\n borderRadius: '50%'\n }\n }\n }, passedStyles), { 'zDepth-1': zDepth === 1 });\n\n return React.createElement(\n 'div',\n { style: styles.wrap },\n React.createElement('div', { style: styles.bg }),\n React.createElement(\n 'div',\n { style: styles.content },\n children\n )\n );\n};\n\nRaised.propTypes = {\n background: PropTypes.string,\n zDepth: PropTypes.oneOf([0, 1, 2, 3, 4, 5]),\n radius: PropTypes.number,\n styles: PropTypes.object\n};\n\nRaised.defaultProps = {\n background: '#fff',\n zDepth: 1,\n radius: 2,\n styles: {}\n};\n\nexport default Raised;","import root from './_root.js';\n\n/**\n * Gets the timestamp of the number of milliseconds that have elapsed since\n * the Unix epoch (1 January 1970 00:00:00 UTC).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Date\n * @returns {number} Returns the timestamp.\n * @example\n *\n * _.defer(function(stamp) {\n * console.log(_.now() - stamp);\n * }, _.now());\n * // => Logs the number of milliseconds it took for the deferred invocation.\n */\nvar now = function() {\n return root.Date.now();\n};\n\nexport default now;\n","/** Used to match a single whitespace character. */\nvar reWhitespace = /\\s/;\n\n/**\n * Used by `_.trim` and `_.trimEnd` to get the index of the last non-whitespace\n * character of `string`.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {number} Returns the index of the last non-whitespace character.\n */\nfunction trimmedEndIndex(string) {\n var index = string.length;\n\n while (index-- && reWhitespace.test(string.charAt(index))) {}\n return index;\n}\n\nexport default trimmedEndIndex;\n","import trimmedEndIndex from './_trimmedEndIndex.js';\n\n/** Used to match leading whitespace. */\nvar reTrimStart = /^\\s+/;\n\n/**\n * The base implementation of `_.trim`.\n *\n * @private\n * @param {string} string The string to trim.\n * @returns {string} Returns the trimmed string.\n */\nfunction baseTrim(string) {\n return string\n ? string.slice(0, trimmedEndIndex(string) + 1).replace(reTrimStart, '')\n : string;\n}\n\nexport default baseTrim;\n","import baseGetTag from './_baseGetTag.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n}\n\nexport default isSymbol;\n","import baseTrim from './_baseTrim.js';\nimport isObject from './isObject.js';\nimport isSymbol from './isSymbol.js';\n\n/** Used as references for various `Number` constants. */\nvar NAN = 0 / 0;\n\n/** Used to detect bad signed hexadecimal string values. */\nvar reIsBadHex = /^[-+]0x[0-9a-f]+$/i;\n\n/** Used to detect binary string values. */\nvar reIsBinary = /^0b[01]+$/i;\n\n/** Used to detect octal string values. */\nvar reIsOctal = /^0o[0-7]+$/i;\n\n/** Built-in method references without a dependency on `root`. */\nvar freeParseInt = parseInt;\n\n/**\n * Converts `value` to a number.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {number} Returns the number.\n * @example\n *\n * _.toNumber(3.2);\n * // => 3.2\n *\n * _.toNumber(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toNumber(Infinity);\n * // => Infinity\n *\n * _.toNumber('3.2');\n * // => 3.2\n */\nfunction toNumber(value) {\n if (typeof value == 'number') {\n return value;\n }\n if (isSymbol(value)) {\n return NAN;\n }\n if (isObject(value)) {\n var other = typeof value.valueOf == 'function' ? value.valueOf() : value;\n value = isObject(other) ? (other + '') : other;\n }\n if (typeof value != 'string') {\n return value === 0 ? value : +value;\n }\n value = baseTrim(value);\n var isBinary = reIsBinary.test(value);\n return (isBinary || reIsOctal.test(value))\n ? freeParseInt(value.slice(2), isBinary ? 2 : 8)\n : (reIsBadHex.test(value) ? NAN : +value);\n}\n\nexport default toNumber;\n","import isObject from './isObject.js';\nimport now from './now.js';\nimport toNumber from './toNumber.js';\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeMax = Math.max,\n nativeMin = Math.min;\n\n/**\n * Creates a debounced function that delays invoking `func` until after `wait`\n * milliseconds have elapsed since the last time the debounced function was\n * invoked. The debounced function comes with a `cancel` method to cancel\n * delayed `func` invocations and a `flush` method to immediately invoke them.\n * Provide `options` to indicate whether `func` should be invoked on the\n * leading and/or trailing edge of the `wait` timeout. The `func` is invoked\n * with the last arguments provided to the debounced function. Subsequent\n * calls to the debounced function return the result of the last `func`\n * invocation.\n *\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\n * invoked on the trailing edge of the timeout only if the debounced function\n * is invoked more than once during the `wait` timeout.\n *\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\n *\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\n * for details over the differences between `_.debounce` and `_.throttle`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to debounce.\n * @param {number} [wait=0] The number of milliseconds to delay.\n * @param {Object} [options={}] The options object.\n * @param {boolean} [options.leading=false]\n * Specify invoking on the leading edge of the timeout.\n * @param {number} [options.maxWait]\n * The maximum time `func` is allowed to be delayed before it's invoked.\n * @param {boolean} [options.trailing=true]\n * Specify invoking on the trailing edge of the timeout.\n * @returns {Function} Returns the new debounced function.\n * @example\n *\n * // Avoid costly calculations while the window size is in flux.\n * jQuery(window).on('resize', _.debounce(calculateLayout, 150));\n *\n * // Invoke `sendMail` when clicked, debouncing subsequent calls.\n * jQuery(element).on('click', _.debounce(sendMail, 300, {\n * 'leading': true,\n * 'trailing': false\n * }));\n *\n * // Ensure `batchLog` is invoked once after 1 second of debounced calls.\n * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 });\n * var source = new EventSource('/stream');\n * jQuery(source).on('message', debounced);\n *\n * // Cancel the trailing debounced invocation.\n * jQuery(window).on('popstate', debounced.cancel);\n */\nfunction debounce(func, wait, options) {\n var lastArgs,\n lastThis,\n maxWait,\n result,\n timerId,\n lastCallTime,\n lastInvokeTime = 0,\n leading = false,\n maxing = false,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n wait = toNumber(wait) || 0;\n if (isObject(options)) {\n leading = !!options.leading;\n maxing = 'maxWait' in options;\n maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n\n function invokeFunc(time) {\n var args = lastArgs,\n thisArg = lastThis;\n\n lastArgs = lastThis = undefined;\n lastInvokeTime = time;\n result = func.apply(thisArg, args);\n return result;\n }\n\n function leadingEdge(time) {\n // Reset any `maxWait` timer.\n lastInvokeTime = time;\n // Start the timer for the trailing edge.\n timerId = setTimeout(timerExpired, wait);\n // Invoke the leading edge.\n return leading ? invokeFunc(time) : result;\n }\n\n function remainingWait(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime,\n timeWaiting = wait - timeSinceLastCall;\n\n return maxing\n ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke)\n : timeWaiting;\n }\n\n function shouldInvoke(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime;\n\n // Either this is the first call, activity has stopped and we're at the\n // trailing edge, the system time has gone backwards and we're treating\n // it as the trailing edge, or we've hit the `maxWait` limit.\n return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||\n (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));\n }\n\n function timerExpired() {\n var time = now();\n if (shouldInvoke(time)) {\n return trailingEdge(time);\n }\n // Restart the timer.\n timerId = setTimeout(timerExpired, remainingWait(time));\n }\n\n function trailingEdge(time) {\n timerId = undefined;\n\n // Only invoke if we have `lastArgs` which means `func` has been\n // debounced at least once.\n if (trailing && lastArgs) {\n return invokeFunc(time);\n }\n lastArgs = lastThis = undefined;\n return result;\n }\n\n function cancel() {\n if (timerId !== undefined) {\n clearTimeout(timerId);\n }\n lastInvokeTime = 0;\n lastArgs = lastCallTime = lastThis = timerId = undefined;\n }\n\n function flush() {\n return timerId === undefined ? result : trailingEdge(now());\n }\n\n function debounced() {\n var time = now(),\n isInvoking = shouldInvoke(time);\n\n lastArgs = arguments;\n lastThis = this;\n lastCallTime = time;\n\n if (isInvoking) {\n if (timerId === undefined) {\n return leadingEdge(lastCallTime);\n }\n if (maxing) {\n // Handle invocations in a tight loop.\n clearTimeout(timerId);\n timerId = setTimeout(timerExpired, wait);\n return invokeFunc(lastCallTime);\n }\n }\n if (timerId === undefined) {\n timerId = setTimeout(timerExpired, wait);\n }\n return result;\n }\n debounced.cancel = cancel;\n debounced.flush = flush;\n return debounced;\n}\n\nexport default debounce;\n","import debounce from './debounce.js';\nimport isObject from './isObject.js';\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/**\n * Creates a throttled function that only invokes `func` at most once per\n * every `wait` milliseconds. The throttled function comes with a `cancel`\n * method to cancel delayed `func` invocations and a `flush` method to\n * immediately invoke them. Provide `options` to indicate whether `func`\n * should be invoked on the leading and/or trailing edge of the `wait`\n * timeout. The `func` is invoked with the last arguments provided to the\n * throttled function. Subsequent calls to the throttled function return the\n * result of the last `func` invocation.\n *\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\n * invoked on the trailing edge of the timeout only if the throttled function\n * is invoked more than once during the `wait` timeout.\n *\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\n *\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\n * for details over the differences between `_.throttle` and `_.debounce`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to throttle.\n * @param {number} [wait=0] The number of milliseconds to throttle invocations to.\n * @param {Object} [options={}] The options object.\n * @param {boolean} [options.leading=true]\n * Specify invoking on the leading edge of the timeout.\n * @param {boolean} [options.trailing=true]\n * Specify invoking on the trailing edge of the timeout.\n * @returns {Function} Returns the new throttled function.\n * @example\n *\n * // Avoid excessively updating the position while scrolling.\n * jQuery(window).on('scroll', _.throttle(updatePosition, 100));\n *\n * // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes.\n * var throttled = _.throttle(renewToken, 300000, { 'trailing': false });\n * jQuery(element).on('click', throttled);\n *\n * // Cancel the trailing throttled invocation.\n * jQuery(window).on('popstate', throttled.cancel);\n */\nfunction throttle(func, wait, options) {\n var leading = true,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n if (isObject(options)) {\n leading = 'leading' in options ? !!options.leading : leading;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n return debounce(func, wait, {\n 'leading': leading,\n 'maxWait': wait,\n 'trailing': trailing\n });\n}\n\nexport default throttle;\n","export var calculateChange = function calculateChange(e, hsl, container) {\n var _container$getBoundin = container.getBoundingClientRect(),\n containerWidth = _container$getBoundin.width,\n containerHeight = _container$getBoundin.height;\n\n var x = typeof e.pageX === 'number' ? e.pageX : e.touches[0].pageX;\n var y = typeof e.pageY === 'number' ? e.pageY : e.touches[0].pageY;\n var left = x - (container.getBoundingClientRect().left + window.pageXOffset);\n var top = y - (container.getBoundingClientRect().top + window.pageYOffset);\n\n if (left < 0) {\n left = 0;\n } else if (left > containerWidth) {\n left = containerWidth;\n }\n\n if (top < 0) {\n top = 0;\n } else if (top > containerHeight) {\n top = containerHeight;\n }\n\n var saturation = left / containerWidth;\n var bright = 1 - top / containerHeight;\n\n return {\n h: hsl.h,\n s: saturation,\n v: bright,\n a: hsl.a,\n source: 'hsv'\n };\n};","var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\nimport React, { Component, PureComponent } from 'react';\nimport reactCSS from 'reactcss';\nimport throttle from 'lodash-es/throttle';\nimport * as saturation from '../../helpers/saturation';\n\nexport var Saturation = function (_ref) {\n _inherits(Saturation, _ref);\n\n function Saturation(props) {\n _classCallCheck(this, Saturation);\n\n var _this = _possibleConstructorReturn(this, (Saturation.__proto__ || Object.getPrototypeOf(Saturation)).call(this, props));\n\n _this.handleChange = function (e) {\n typeof _this.props.onChange === 'function' && _this.throttle(_this.props.onChange, saturation.calculateChange(e, _this.props.hsl, _this.container), e);\n };\n\n _this.handleMouseDown = function (e) {\n _this.handleChange(e);\n var renderWindow = _this.getContainerRenderWindow();\n renderWindow.addEventListener('mousemove', _this.handleChange);\n renderWindow.addEventListener('mouseup', _this.handleMouseUp);\n };\n\n _this.handleMouseUp = function () {\n _this.unbindEventListeners();\n };\n\n _this.throttle = throttle(function (fn, data, e) {\n fn(data, e);\n }, 50);\n return _this;\n }\n\n _createClass(Saturation, [{\n key: 'componentWillUnmount',\n value: function componentWillUnmount() {\n this.throttle.cancel();\n this.unbindEventListeners();\n }\n }, {\n key: 'getContainerRenderWindow',\n value: function getContainerRenderWindow() {\n var container = this.container;\n\n var renderWindow = window;\n while (!renderWindow.document.contains(container) && renderWindow.parent !== renderWindow) {\n renderWindow = renderWindow.parent;\n }\n return renderWindow;\n }\n }, {\n key: 'unbindEventListeners',\n value: function unbindEventListeners() {\n var renderWindow = this.getContainerRenderWindow();\n renderWindow.removeEventListener('mousemove', this.handleChange);\n renderWindow.removeEventListener('mouseup', this.handleMouseUp);\n }\n }, {\n key: 'render',\n value: function render() {\n var _this2 = this;\n\n var _ref2 = this.props.style || {},\n color = _ref2.color,\n white = _ref2.white,\n black = _ref2.black,\n pointer = _ref2.pointer,\n circle = _ref2.circle;\n\n var styles = reactCSS({\n 'default': {\n color: {\n absolute: '0px 0px 0px 0px',\n background: 'hsl(' + this.props.hsl.h + ',100%, 50%)',\n borderRadius: this.props.radius\n },\n white: {\n absolute: '0px 0px 0px 0px',\n borderRadius: this.props.radius\n },\n black: {\n absolute: '0px 0px 0px 0px',\n boxShadow: this.props.shadow,\n borderRadius: this.props.radius\n },\n pointer: {\n position: 'absolute',\n top: -(this.props.hsv.v * 100) + 100 + '%',\n left: this.props.hsv.s * 100 + '%',\n cursor: 'default'\n },\n circle: {\n width: '4px',\n height: '4px',\n boxShadow: '0 0 0 1.5px #fff, inset 0 0 1px 1px rgba(0,0,0,.3),\\n 0 0 1px 2px rgba(0,0,0,.4)',\n borderRadius: '50%',\n cursor: 'hand',\n transform: 'translate(-2px, -2px)'\n }\n },\n 'custom': {\n color: color,\n white: white,\n black: black,\n pointer: pointer,\n circle: circle\n }\n }, { 'custom': !!this.props.style });\n\n return React.createElement(\n 'div',\n {\n style: styles.color,\n ref: function ref(container) {\n return _this2.container = container;\n },\n onMouseDown: this.handleMouseDown,\n onTouchMove: this.handleChange,\n onTouchStart: this.handleChange\n },\n React.createElement(\n 'style',\n null,\n '\\n .saturation-white {\\n background: -webkit-linear-gradient(to right, #fff, rgba(255,255,255,0));\\n background: linear-gradient(to right, #fff, rgba(255,255,255,0));\\n }\\n .saturation-black {\\n background: -webkit-linear-gradient(to top, #000, rgba(0,0,0,0));\\n background: linear-gradient(to top, #000, rgba(0,0,0,0));\\n }\\n '\n ),\n React.createElement(\n 'div',\n { style: styles.white, className: 'saturation-white' },\n React.createElement('div', { style: styles.black, className: 'saturation-black' }),\n React.createElement(\n 'div',\n { style: styles.pointer },\n this.props.pointer ? React.createElement(this.props.pointer, this.props) : React.createElement('div', { style: styles.circle })\n )\n )\n );\n }\n }]);\n\n return Saturation;\n}(PureComponent || Component);\n\nexport default Saturation;","/**\n * A specialized version of `_.forEach` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns `array`.\n */\nfunction arrayEach(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (iteratee(array[index], index, array) === false) {\n break;\n }\n }\n return array;\n}\n\nexport default arrayEach;\n","import overArg from './_overArg.js';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nexport default nativeKeys;\n","import isPrototype from './_isPrototype.js';\nimport nativeKeys from './_nativeKeys.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default baseKeys;\n","import arrayLikeKeys from './_arrayLikeKeys.js';\nimport baseKeys from './_baseKeys.js';\nimport isArrayLike from './isArrayLike.js';\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nexport default keys;\n","import baseFor from './_baseFor.js';\nimport keys from './keys.js';\n\n/**\n * The base implementation of `_.forOwn` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Object} Returns `object`.\n */\nfunction baseForOwn(object, iteratee) {\n return object && baseFor(object, iteratee, keys);\n}\n\nexport default baseForOwn;\n","import isArrayLike from './isArrayLike.js';\n\n/**\n * Creates a `baseEach` or `baseEachRight` function.\n *\n * @private\n * @param {Function} eachFunc The function to iterate over a collection.\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseEach(eachFunc, fromRight) {\n return function(collection, iteratee) {\n if (collection == null) {\n return collection;\n }\n if (!isArrayLike(collection)) {\n return eachFunc(collection, iteratee);\n }\n var length = collection.length,\n index = fromRight ? length : -1,\n iterable = Object(collection);\n\n while ((fromRight ? index-- : ++index < length)) {\n if (iteratee(iterable[index], index, iterable) === false) {\n break;\n }\n }\n return collection;\n };\n}\n\nexport default createBaseEach;\n","import baseForOwn from './_baseForOwn.js';\nimport createBaseEach from './_createBaseEach.js';\n\n/**\n * The base implementation of `_.forEach` without support for iteratee shorthands.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array|Object} Returns `collection`.\n */\nvar baseEach = createBaseEach(baseForOwn);\n\nexport default baseEach;\n","import identity from './identity.js';\n\n/**\n * Casts `value` to `identity` if it's not a function.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {Function} Returns cast function.\n */\nfunction castFunction(value) {\n return typeof value == 'function' ? value : identity;\n}\n\nexport default castFunction;\n","import arrayEach from './_arrayEach.js';\nimport baseEach from './_baseEach.js';\nimport castFunction from './_castFunction.js';\nimport isArray from './isArray.js';\n\n/**\n * Iterates over elements of `collection` and invokes `iteratee` for each element.\n * The iteratee is invoked with three arguments: (value, index|key, collection).\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * **Note:** As with other \"Collections\" methods, objects with a \"length\"\n * property are iterated like arrays. To avoid this behavior use `_.forIn`\n * or `_.forOwn` for object iteration.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @alias each\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Array|Object} Returns `collection`.\n * @see _.forEachRight\n * @example\n *\n * _.forEach([1, 2], function(value) {\n * console.log(value);\n * });\n * // => Logs `1` then `2`.\n *\n * _.forEach({ 'a': 1, 'b': 2 }, function(value, key) {\n * console.log(key);\n * });\n * // => Logs 'a' then 'b' (iteration order is not guaranteed).\n */\nfunction forEach(collection, iteratee) {\n var func = isArray(collection) ? arrayEach : baseEach;\n return func(collection, castFunction(iteratee));\n}\n\nexport default forEach;\n","// This file is autogenerated. It's used to publish ESM to npm.\nfunction _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (obj) {\n return typeof obj;\n } : function (obj) {\n return obj && \"function\" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n }, _typeof(obj);\n}\n\n// https://github.com/bgrins/TinyColor\n// Brian Grinstead, MIT License\n\nvar trimLeft = /^\\s+/;\nvar trimRight = /\\s+$/;\nfunction tinycolor(color, opts) {\n color = color ? color : \"\";\n opts = opts || {};\n\n // If input is already a tinycolor, return itself\n if (color instanceof tinycolor) {\n return color;\n }\n // If we are called as a function, call using new instead\n if (!(this instanceof tinycolor)) {\n return new tinycolor(color, opts);\n }\n var rgb = inputToRGB(color);\n this._originalInput = color, this._r = rgb.r, this._g = rgb.g, this._b = rgb.b, this._a = rgb.a, this._roundA = Math.round(100 * this._a) / 100, this._format = opts.format || rgb.format;\n this._gradientType = opts.gradientType;\n\n // Don't let the range of [0,255] come back in [0,1].\n // Potentially lose a little bit of precision here, but will fix issues where\n // .5 gets interpreted as half of the total, instead of half of 1\n // If it was supposed to be 128, this was already taken care of by `inputToRgb`\n if (this._r < 1) this._r = Math.round(this._r);\n if (this._g < 1) this._g = Math.round(this._g);\n if (this._b < 1) this._b = Math.round(this._b);\n this._ok = rgb.ok;\n}\ntinycolor.prototype = {\n isDark: function isDark() {\n return this.getBrightness() < 128;\n },\n isLight: function isLight() {\n return !this.isDark();\n },\n isValid: function isValid() {\n return this._ok;\n },\n getOriginalInput: function getOriginalInput() {\n return this._originalInput;\n },\n getFormat: function getFormat() {\n return this._format;\n },\n getAlpha: function getAlpha() {\n return this._a;\n },\n getBrightness: function getBrightness() {\n //http://www.w3.org/TR/AERT#color-contrast\n var rgb = this.toRgb();\n return (rgb.r * 299 + rgb.g * 587 + rgb.b * 114) / 1000;\n },\n getLuminance: function getLuminance() {\n //http://www.w3.org/TR/2008/REC-WCAG20-20081211/#relativeluminancedef\n var rgb = this.toRgb();\n var RsRGB, GsRGB, BsRGB, R, G, B;\n RsRGB = rgb.r / 255;\n GsRGB = rgb.g / 255;\n BsRGB = rgb.b / 255;\n if (RsRGB <= 0.03928) R = RsRGB / 12.92;else R = Math.pow((RsRGB + 0.055) / 1.055, 2.4);\n if (GsRGB <= 0.03928) G = GsRGB / 12.92;else G = Math.pow((GsRGB + 0.055) / 1.055, 2.4);\n if (BsRGB <= 0.03928) B = BsRGB / 12.92;else B = Math.pow((BsRGB + 0.055) / 1.055, 2.4);\n return 0.2126 * R + 0.7152 * G + 0.0722 * B;\n },\n setAlpha: function setAlpha(value) {\n this._a = boundAlpha(value);\n this._roundA = Math.round(100 * this._a) / 100;\n return this;\n },\n toHsv: function toHsv() {\n var hsv = rgbToHsv(this._r, this._g, this._b);\n return {\n h: hsv.h * 360,\n s: hsv.s,\n v: hsv.v,\n a: this._a\n };\n },\n toHsvString: function toHsvString() {\n var hsv = rgbToHsv(this._r, this._g, this._b);\n var h = Math.round(hsv.h * 360),\n s = Math.round(hsv.s * 100),\n v = Math.round(hsv.v * 100);\n return this._a == 1 ? \"hsv(\" + h + \", \" + s + \"%, \" + v + \"%)\" : \"hsva(\" + h + \", \" + s + \"%, \" + v + \"%, \" + this._roundA + \")\";\n },\n toHsl: function toHsl() {\n var hsl = rgbToHsl(this._r, this._g, this._b);\n return {\n h: hsl.h * 360,\n s: hsl.s,\n l: hsl.l,\n a: this._a\n };\n },\n toHslString: function toHslString() {\n var hsl = rgbToHsl(this._r, this._g, this._b);\n var h = Math.round(hsl.h * 360),\n s = Math.round(hsl.s * 100),\n l = Math.round(hsl.l * 100);\n return this._a == 1 ? \"hsl(\" + h + \", \" + s + \"%, \" + l + \"%)\" : \"hsla(\" + h + \", \" + s + \"%, \" + l + \"%, \" + this._roundA + \")\";\n },\n toHex: function toHex(allow3Char) {\n return rgbToHex(this._r, this._g, this._b, allow3Char);\n },\n toHexString: function toHexString(allow3Char) {\n return \"#\" + this.toHex(allow3Char);\n },\n toHex8: function toHex8(allow4Char) {\n return rgbaToHex(this._r, this._g, this._b, this._a, allow4Char);\n },\n toHex8String: function toHex8String(allow4Char) {\n return \"#\" + this.toHex8(allow4Char);\n },\n toRgb: function toRgb() {\n return {\n r: Math.round(this._r),\n g: Math.round(this._g),\n b: Math.round(this._b),\n a: this._a\n };\n },\n toRgbString: function toRgbString() {\n return this._a == 1 ? \"rgb(\" + Math.round(this._r) + \", \" + Math.round(this._g) + \", \" + Math.round(this._b) + \")\" : \"rgba(\" + Math.round(this._r) + \", \" + Math.round(this._g) + \", \" + Math.round(this._b) + \", \" + this._roundA + \")\";\n },\n toPercentageRgb: function toPercentageRgb() {\n return {\n r: Math.round(bound01(this._r, 255) * 100) + \"%\",\n g: Math.round(bound01(this._g, 255) * 100) + \"%\",\n b: Math.round(bound01(this._b, 255) * 100) + \"%\",\n a: this._a\n };\n },\n toPercentageRgbString: function toPercentageRgbString() {\n return this._a == 1 ? \"rgb(\" + Math.round(bound01(this._r, 255) * 100) + \"%, \" + Math.round(bound01(this._g, 255) * 100) + \"%, \" + Math.round(bound01(this._b, 255) * 100) + \"%)\" : \"rgba(\" + Math.round(bound01(this._r, 255) * 100) + \"%, \" + Math.round(bound01(this._g, 255) * 100) + \"%, \" + Math.round(bound01(this._b, 255) * 100) + \"%, \" + this._roundA + \")\";\n },\n toName: function toName() {\n if (this._a === 0) {\n return \"transparent\";\n }\n if (this._a < 1) {\n return false;\n }\n return hexNames[rgbToHex(this._r, this._g, this._b, true)] || false;\n },\n toFilter: function toFilter(secondColor) {\n var hex8String = \"#\" + rgbaToArgbHex(this._r, this._g, this._b, this._a);\n var secondHex8String = hex8String;\n var gradientType = this._gradientType ? \"GradientType = 1, \" : \"\";\n if (secondColor) {\n var s = tinycolor(secondColor);\n secondHex8String = \"#\" + rgbaToArgbHex(s._r, s._g, s._b, s._a);\n }\n return \"progid:DXImageTransform.Microsoft.gradient(\" + gradientType + \"startColorstr=\" + hex8String + \",endColorstr=\" + secondHex8String + \")\";\n },\n toString: function toString(format) {\n var formatSet = !!format;\n format = format || this._format;\n var formattedString = false;\n var hasAlpha = this._a < 1 && this._a >= 0;\n var needsAlphaFormat = !formatSet && hasAlpha && (format === \"hex\" || format === \"hex6\" || format === \"hex3\" || format === \"hex4\" || format === \"hex8\" || format === \"name\");\n if (needsAlphaFormat) {\n // Special case for \"transparent\", all other non-alpha formats\n // will return rgba when there is transparency.\n if (format === \"name\" && this._a === 0) {\n return this.toName();\n }\n return this.toRgbString();\n }\n if (format === \"rgb\") {\n formattedString = this.toRgbString();\n }\n if (format === \"prgb\") {\n formattedString = this.toPercentageRgbString();\n }\n if (format === \"hex\" || format === \"hex6\") {\n formattedString = this.toHexString();\n }\n if (format === \"hex3\") {\n formattedString = this.toHexString(true);\n }\n if (format === \"hex4\") {\n formattedString = this.toHex8String(true);\n }\n if (format === \"hex8\") {\n formattedString = this.toHex8String();\n }\n if (format === \"name\") {\n formattedString = this.toName();\n }\n if (format === \"hsl\") {\n formattedString = this.toHslString();\n }\n if (format === \"hsv\") {\n formattedString = this.toHsvString();\n }\n return formattedString || this.toHexString();\n },\n clone: function clone() {\n return tinycolor(this.toString());\n },\n _applyModification: function _applyModification(fn, args) {\n var color = fn.apply(null, [this].concat([].slice.call(args)));\n this._r = color._r;\n this._g = color._g;\n this._b = color._b;\n this.setAlpha(color._a);\n return this;\n },\n lighten: function lighten() {\n return this._applyModification(_lighten, arguments);\n },\n brighten: function brighten() {\n return this._applyModification(_brighten, arguments);\n },\n darken: function darken() {\n return this._applyModification(_darken, arguments);\n },\n desaturate: function desaturate() {\n return this._applyModification(_desaturate, arguments);\n },\n saturate: function saturate() {\n return this._applyModification(_saturate, arguments);\n },\n greyscale: function greyscale() {\n return this._applyModification(_greyscale, arguments);\n },\n spin: function spin() {\n return this._applyModification(_spin, arguments);\n },\n _applyCombination: function _applyCombination(fn, args) {\n return fn.apply(null, [this].concat([].slice.call(args)));\n },\n analogous: function analogous() {\n return this._applyCombination(_analogous, arguments);\n },\n complement: function complement() {\n return this._applyCombination(_complement, arguments);\n },\n monochromatic: function monochromatic() {\n return this._applyCombination(_monochromatic, arguments);\n },\n splitcomplement: function splitcomplement() {\n return this._applyCombination(_splitcomplement, arguments);\n },\n // Disabled until https://github.com/bgrins/TinyColor/issues/254\n // polyad: function (number) {\n // return this._applyCombination(polyad, [number]);\n // },\n triad: function triad() {\n return this._applyCombination(polyad, [3]);\n },\n tetrad: function tetrad() {\n return this._applyCombination(polyad, [4]);\n }\n};\n\n// If input is an object, force 1 into \"1.0\" to handle ratios properly\n// String input requires \"1.0\" as input, so 1 will be treated as 1\ntinycolor.fromRatio = function (color, opts) {\n if (_typeof(color) == \"object\") {\n var newColor = {};\n for (var i in color) {\n if (color.hasOwnProperty(i)) {\n if (i === \"a\") {\n newColor[i] = color[i];\n } else {\n newColor[i] = convertToPercentage(color[i]);\n }\n }\n }\n color = newColor;\n }\n return tinycolor(color, opts);\n};\n\n// Given a string or object, convert that input to RGB\n// Possible string inputs:\n//\n// \"red\"\n// \"#f00\" or \"f00\"\n// \"#ff0000\" or \"ff0000\"\n// \"#ff000000\" or \"ff000000\"\n// \"rgb 255 0 0\" or \"rgb (255, 0, 0)\"\n// \"rgb 1.0 0 0\" or \"rgb (1, 0, 0)\"\n// \"rgba (255, 0, 0, 1)\" or \"rgba 255, 0, 0, 1\"\n// \"rgba (1.0, 0, 0, 1)\" or \"rgba 1.0, 0, 0, 1\"\n// \"hsl(0, 100%, 50%)\" or \"hsl 0 100% 50%\"\n// \"hsla(0, 100%, 50%, 1)\" or \"hsla 0 100% 50%, 1\"\n// \"hsv(0, 100%, 100%)\" or \"hsv 0 100% 100%\"\n//\nfunction inputToRGB(color) {\n var rgb = {\n r: 0,\n g: 0,\n b: 0\n };\n var a = 1;\n var s = null;\n var v = null;\n var l = null;\n var ok = false;\n var format = false;\n if (typeof color == \"string\") {\n color = stringInputToObject(color);\n }\n if (_typeof(color) == \"object\") {\n if (isValidCSSUnit(color.r) && isValidCSSUnit(color.g) && isValidCSSUnit(color.b)) {\n rgb = rgbToRgb(color.r, color.g, color.b);\n ok = true;\n format = String(color.r).substr(-1) === \"%\" ? \"prgb\" : \"rgb\";\n } else if (isValidCSSUnit(color.h) && isValidCSSUnit(color.s) && isValidCSSUnit(color.v)) {\n s = convertToPercentage(color.s);\n v = convertToPercentage(color.v);\n rgb = hsvToRgb(color.h, s, v);\n ok = true;\n format = \"hsv\";\n } else if (isValidCSSUnit(color.h) && isValidCSSUnit(color.s) && isValidCSSUnit(color.l)) {\n s = convertToPercentage(color.s);\n l = convertToPercentage(color.l);\n rgb = hslToRgb(color.h, s, l);\n ok = true;\n format = \"hsl\";\n }\n if (color.hasOwnProperty(\"a\")) {\n a = color.a;\n }\n }\n a = boundAlpha(a);\n return {\n ok: ok,\n format: color.format || format,\n r: Math.min(255, Math.max(rgb.r, 0)),\n g: Math.min(255, Math.max(rgb.g, 0)),\n b: Math.min(255, Math.max(rgb.b, 0)),\n a: a\n };\n}\n\n// Conversion Functions\n// --------------------\n\n// `rgbToHsl`, `rgbToHsv`, `hslToRgb`, `hsvToRgb` modified from:\n// \n\n// `rgbToRgb`\n// Handle bounds / percentage checking to conform to CSS color spec\n// \n// *Assumes:* r, g, b in [0, 255] or [0, 1]\n// *Returns:* { r, g, b } in [0, 255]\nfunction rgbToRgb(r, g, b) {\n return {\n r: bound01(r, 255) * 255,\n g: bound01(g, 255) * 255,\n b: bound01(b, 255) * 255\n };\n}\n\n// `rgbToHsl`\n// Converts an RGB color value to HSL.\n// *Assumes:* r, g, and b are contained in [0, 255] or [0, 1]\n// *Returns:* { h, s, l } in [0,1]\nfunction rgbToHsl(r, g, b) {\n r = bound01(r, 255);\n g = bound01(g, 255);\n b = bound01(b, 255);\n var max = Math.max(r, g, b),\n min = Math.min(r, g, b);\n var h,\n s,\n l = (max + min) / 2;\n if (max == min) {\n h = s = 0; // achromatic\n } else {\n var d = max - min;\n s = l > 0.5 ? d / (2 - max - min) : d / (max + min);\n switch (max) {\n case r:\n h = (g - b) / d + (g < b ? 6 : 0);\n break;\n case g:\n h = (b - r) / d + 2;\n break;\n case b:\n h = (r - g) / d + 4;\n break;\n }\n h /= 6;\n }\n return {\n h: h,\n s: s,\n l: l\n };\n}\n\n// `hslToRgb`\n// Converts an HSL color value to RGB.\n// *Assumes:* h is contained in [0, 1] or [0, 360] and s and l are contained [0, 1] or [0, 100]\n// *Returns:* { r, g, b } in the set [0, 255]\nfunction hslToRgb(h, s, l) {\n var r, g, b;\n h = bound01(h, 360);\n s = bound01(s, 100);\n l = bound01(l, 100);\n function hue2rgb(p, q, t) {\n if (t < 0) t += 1;\n if (t > 1) t -= 1;\n if (t < 1 / 6) return p + (q - p) * 6 * t;\n if (t < 1 / 2) return q;\n if (t < 2 / 3) return p + (q - p) * (2 / 3 - t) * 6;\n return p;\n }\n if (s === 0) {\n r = g = b = l; // achromatic\n } else {\n var q = l < 0.5 ? l * (1 + s) : l + s - l * s;\n var p = 2 * l - q;\n r = hue2rgb(p, q, h + 1 / 3);\n g = hue2rgb(p, q, h);\n b = hue2rgb(p, q, h - 1 / 3);\n }\n return {\n r: r * 255,\n g: g * 255,\n b: b * 255\n };\n}\n\n// `rgbToHsv`\n// Converts an RGB color value to HSV\n// *Assumes:* r, g, and b are contained in the set [0, 255] or [0, 1]\n// *Returns:* { h, s, v } in [0,1]\nfunction rgbToHsv(r, g, b) {\n r = bound01(r, 255);\n g = bound01(g, 255);\n b = bound01(b, 255);\n var max = Math.max(r, g, b),\n min = Math.min(r, g, b);\n var h,\n s,\n v = max;\n var d = max - min;\n s = max === 0 ? 0 : d / max;\n if (max == min) {\n h = 0; // achromatic\n } else {\n switch (max) {\n case r:\n h = (g - b) / d + (g < b ? 6 : 0);\n break;\n case g:\n h = (b - r) / d + 2;\n break;\n case b:\n h = (r - g) / d + 4;\n break;\n }\n h /= 6;\n }\n return {\n h: h,\n s: s,\n v: v\n };\n}\n\n// `hsvToRgb`\n// Converts an HSV color value to RGB.\n// *Assumes:* h is contained in [0, 1] or [0, 360] and s and v are contained in [0, 1] or [0, 100]\n// *Returns:* { r, g, b } in the set [0, 255]\nfunction hsvToRgb(h, s, v) {\n h = bound01(h, 360) * 6;\n s = bound01(s, 100);\n v = bound01(v, 100);\n var i = Math.floor(h),\n f = h - i,\n p = v * (1 - s),\n q = v * (1 - f * s),\n t = v * (1 - (1 - f) * s),\n mod = i % 6,\n r = [v, q, p, p, t, v][mod],\n g = [t, v, v, q, p, p][mod],\n b = [p, p, t, v, v, q][mod];\n return {\n r: r * 255,\n g: g * 255,\n b: b * 255\n };\n}\n\n// `rgbToHex`\n// Converts an RGB color to hex\n// Assumes r, g, and b are contained in the set [0, 255]\n// Returns a 3 or 6 character hex\nfunction rgbToHex(r, g, b, allow3Char) {\n var hex = [pad2(Math.round(r).toString(16)), pad2(Math.round(g).toString(16)), pad2(Math.round(b).toString(16))];\n\n // Return a 3 character hex if possible\n if (allow3Char && hex[0].charAt(0) == hex[0].charAt(1) && hex[1].charAt(0) == hex[1].charAt(1) && hex[2].charAt(0) == hex[2].charAt(1)) {\n return hex[0].charAt(0) + hex[1].charAt(0) + hex[2].charAt(0);\n }\n return hex.join(\"\");\n}\n\n// `rgbaToHex`\n// Converts an RGBA color plus alpha transparency to hex\n// Assumes r, g, b are contained in the set [0, 255] and\n// a in [0, 1]. Returns a 4 or 8 character rgba hex\nfunction rgbaToHex(r, g, b, a, allow4Char) {\n var hex = [pad2(Math.round(r).toString(16)), pad2(Math.round(g).toString(16)), pad2(Math.round(b).toString(16)), pad2(convertDecimalToHex(a))];\n\n // Return a 4 character hex if possible\n if (allow4Char && hex[0].charAt(0) == hex[0].charAt(1) && hex[1].charAt(0) == hex[1].charAt(1) && hex[2].charAt(0) == hex[2].charAt(1) && hex[3].charAt(0) == hex[3].charAt(1)) {\n return hex[0].charAt(0) + hex[1].charAt(0) + hex[2].charAt(0) + hex[3].charAt(0);\n }\n return hex.join(\"\");\n}\n\n// `rgbaToArgbHex`\n// Converts an RGBA color to an ARGB Hex8 string\n// Rarely used, but required for \"toFilter()\"\nfunction rgbaToArgbHex(r, g, b, a) {\n var hex = [pad2(convertDecimalToHex(a)), pad2(Math.round(r).toString(16)), pad2(Math.round(g).toString(16)), pad2(Math.round(b).toString(16))];\n return hex.join(\"\");\n}\n\n// `equals`\n// Can be called with any tinycolor input\ntinycolor.equals = function (color1, color2) {\n if (!color1 || !color2) return false;\n return tinycolor(color1).toRgbString() == tinycolor(color2).toRgbString();\n};\ntinycolor.random = function () {\n return tinycolor.fromRatio({\n r: Math.random(),\n g: Math.random(),\n b: Math.random()\n });\n};\n\n// Modification Functions\n// ----------------------\n// Thanks to less.js for some of the basics here\n// \n\nfunction _desaturate(color, amount) {\n amount = amount === 0 ? 0 : amount || 10;\n var hsl = tinycolor(color).toHsl();\n hsl.s -= amount / 100;\n hsl.s = clamp01(hsl.s);\n return tinycolor(hsl);\n}\nfunction _saturate(color, amount) {\n amount = amount === 0 ? 0 : amount || 10;\n var hsl = tinycolor(color).toHsl();\n hsl.s += amount / 100;\n hsl.s = clamp01(hsl.s);\n return tinycolor(hsl);\n}\nfunction _greyscale(color) {\n return tinycolor(color).desaturate(100);\n}\nfunction _lighten(color, amount) {\n amount = amount === 0 ? 0 : amount || 10;\n var hsl = tinycolor(color).toHsl();\n hsl.l += amount / 100;\n hsl.l = clamp01(hsl.l);\n return tinycolor(hsl);\n}\nfunction _brighten(color, amount) {\n amount = amount === 0 ? 0 : amount || 10;\n var rgb = tinycolor(color).toRgb();\n rgb.r = Math.max(0, Math.min(255, rgb.r - Math.round(255 * -(amount / 100))));\n rgb.g = Math.max(0, Math.min(255, rgb.g - Math.round(255 * -(amount / 100))));\n rgb.b = Math.max(0, Math.min(255, rgb.b - Math.round(255 * -(amount / 100))));\n return tinycolor(rgb);\n}\nfunction _darken(color, amount) {\n amount = amount === 0 ? 0 : amount || 10;\n var hsl = tinycolor(color).toHsl();\n hsl.l -= amount / 100;\n hsl.l = clamp01(hsl.l);\n return tinycolor(hsl);\n}\n\n// Spin takes a positive or negative amount within [-360, 360] indicating the change of hue.\n// Values outside of this range will be wrapped into this range.\nfunction _spin(color, amount) {\n var hsl = tinycolor(color).toHsl();\n var hue = (hsl.h + amount) % 360;\n hsl.h = hue < 0 ? 360 + hue : hue;\n return tinycolor(hsl);\n}\n\n// Combination Functions\n// ---------------------\n// Thanks to jQuery xColor for some of the ideas behind these\n// \n\nfunction _complement(color) {\n var hsl = tinycolor(color).toHsl();\n hsl.h = (hsl.h + 180) % 360;\n return tinycolor(hsl);\n}\nfunction polyad(color, number) {\n if (isNaN(number) || number <= 0) {\n throw new Error(\"Argument to polyad must be a positive number\");\n }\n var hsl = tinycolor(color).toHsl();\n var result = [tinycolor(color)];\n var step = 360 / number;\n for (var i = 1; i < number; i++) {\n result.push(tinycolor({\n h: (hsl.h + i * step) % 360,\n s: hsl.s,\n l: hsl.l\n }));\n }\n return result;\n}\nfunction _splitcomplement(color) {\n var hsl = tinycolor(color).toHsl();\n var h = hsl.h;\n return [tinycolor(color), tinycolor({\n h: (h + 72) % 360,\n s: hsl.s,\n l: hsl.l\n }), tinycolor({\n h: (h + 216) % 360,\n s: hsl.s,\n l: hsl.l\n })];\n}\nfunction _analogous(color, results, slices) {\n results = results || 6;\n slices = slices || 30;\n var hsl = tinycolor(color).toHsl();\n var part = 360 / slices;\n var ret = [tinycolor(color)];\n for (hsl.h = (hsl.h - (part * results >> 1) + 720) % 360; --results;) {\n hsl.h = (hsl.h + part) % 360;\n ret.push(tinycolor(hsl));\n }\n return ret;\n}\nfunction _monochromatic(color, results) {\n results = results || 6;\n var hsv = tinycolor(color).toHsv();\n var h = hsv.h,\n s = hsv.s,\n v = hsv.v;\n var ret = [];\n var modification = 1 / results;\n while (results--) {\n ret.push(tinycolor({\n h: h,\n s: s,\n v: v\n }));\n v = (v + modification) % 1;\n }\n return ret;\n}\n\n// Utility Functions\n// ---------------------\n\ntinycolor.mix = function (color1, color2, amount) {\n amount = amount === 0 ? 0 : amount || 50;\n var rgb1 = tinycolor(color1).toRgb();\n var rgb2 = tinycolor(color2).toRgb();\n var p = amount / 100;\n var rgba = {\n r: (rgb2.r - rgb1.r) * p + rgb1.r,\n g: (rgb2.g - rgb1.g) * p + rgb1.g,\n b: (rgb2.b - rgb1.b) * p + rgb1.b,\n a: (rgb2.a - rgb1.a) * p + rgb1.a\n };\n return tinycolor(rgba);\n};\n\n// Readability Functions\n// ---------------------\n// false\n// tinycolor.isReadable(\"#000\", \"#111\",{level:\"AA\",size:\"large\"}) => false\ntinycolor.isReadable = function (color1, color2, wcag2) {\n var readability = tinycolor.readability(color1, color2);\n var wcag2Parms, out;\n out = false;\n wcag2Parms = validateWCAG2Parms(wcag2);\n switch (wcag2Parms.level + wcag2Parms.size) {\n case \"AAsmall\":\n case \"AAAlarge\":\n out = readability >= 4.5;\n break;\n case \"AAlarge\":\n out = readability >= 3;\n break;\n case \"AAAsmall\":\n out = readability >= 7;\n break;\n }\n return out;\n};\n\n// `mostReadable`\n// Given a base color and a list of possible foreground or background\n// colors for that base, returns the most readable color.\n// Optionally returns Black or White if the most readable color is unreadable.\n// *Example*\n// tinycolor.mostReadable(tinycolor.mostReadable(\"#123\", [\"#124\", \"#125\"],{includeFallbackColors:false}).toHexString(); // \"#112255\"\n// tinycolor.mostReadable(tinycolor.mostReadable(\"#123\", [\"#124\", \"#125\"],{includeFallbackColors:true}).toHexString(); // \"#ffffff\"\n// tinycolor.mostReadable(\"#a8015a\", [\"#faf3f3\"],{includeFallbackColors:true,level:\"AAA\",size:\"large\"}).toHexString(); // \"#faf3f3\"\n// tinycolor.mostReadable(\"#a8015a\", [\"#faf3f3\"],{includeFallbackColors:true,level:\"AAA\",size:\"small\"}).toHexString(); // \"#ffffff\"\ntinycolor.mostReadable = function (baseColor, colorList, args) {\n var bestColor = null;\n var bestScore = 0;\n var readability;\n var includeFallbackColors, level, size;\n args = args || {};\n includeFallbackColors = args.includeFallbackColors;\n level = args.level;\n size = args.size;\n for (var i = 0; i < colorList.length; i++) {\n readability = tinycolor.readability(baseColor, colorList[i]);\n if (readability > bestScore) {\n bestScore = readability;\n bestColor = tinycolor(colorList[i]);\n }\n }\n if (tinycolor.isReadable(baseColor, bestColor, {\n level: level,\n size: size\n }) || !includeFallbackColors) {\n return bestColor;\n } else {\n args.includeFallbackColors = false;\n return tinycolor.mostReadable(baseColor, [\"#fff\", \"#000\"], args);\n }\n};\n\n// Big List of Colors\n// ------------------\n// \nvar names = tinycolor.names = {\n aliceblue: \"f0f8ff\",\n antiquewhite: \"faebd7\",\n aqua: \"0ff\",\n aquamarine: \"7fffd4\",\n azure: \"f0ffff\",\n beige: \"f5f5dc\",\n bisque: \"ffe4c4\",\n black: \"000\",\n blanchedalmond: \"ffebcd\",\n blue: \"00f\",\n blueviolet: \"8a2be2\",\n brown: \"a52a2a\",\n burlywood: \"deb887\",\n burntsienna: \"ea7e5d\",\n cadetblue: \"5f9ea0\",\n chartreuse: \"7fff00\",\n chocolate: \"d2691e\",\n coral: \"ff7f50\",\n cornflowerblue: \"6495ed\",\n cornsilk: \"fff8dc\",\n crimson: \"dc143c\",\n cyan: \"0ff\",\n darkblue: \"00008b\",\n darkcyan: \"008b8b\",\n darkgoldenrod: \"b8860b\",\n darkgray: \"a9a9a9\",\n darkgreen: \"006400\",\n darkgrey: \"a9a9a9\",\n darkkhaki: \"bdb76b\",\n darkmagenta: \"8b008b\",\n darkolivegreen: \"556b2f\",\n darkorange: \"ff8c00\",\n darkorchid: \"9932cc\",\n darkred: \"8b0000\",\n darksalmon: \"e9967a\",\n darkseagreen: \"8fbc8f\",\n darkslateblue: \"483d8b\",\n darkslategray: \"2f4f4f\",\n darkslategrey: \"2f4f4f\",\n darkturquoise: \"00ced1\",\n darkviolet: \"9400d3\",\n deeppink: \"ff1493\",\n deepskyblue: \"00bfff\",\n dimgray: \"696969\",\n dimgrey: \"696969\",\n dodgerblue: \"1e90ff\",\n firebrick: \"b22222\",\n floralwhite: \"fffaf0\",\n forestgreen: \"228b22\",\n fuchsia: \"f0f\",\n gainsboro: \"dcdcdc\",\n ghostwhite: \"f8f8ff\",\n gold: \"ffd700\",\n goldenrod: \"daa520\",\n gray: \"808080\",\n green: \"008000\",\n greenyellow: \"adff2f\",\n grey: \"808080\",\n honeydew: \"f0fff0\",\n hotpink: \"ff69b4\",\n indianred: \"cd5c5c\",\n indigo: \"4b0082\",\n ivory: \"fffff0\",\n khaki: \"f0e68c\",\n lavender: \"e6e6fa\",\n lavenderblush: \"fff0f5\",\n lawngreen: \"7cfc00\",\n lemonchiffon: \"fffacd\",\n lightblue: \"add8e6\",\n lightcoral: \"f08080\",\n lightcyan: \"e0ffff\",\n lightgoldenrodyellow: \"fafad2\",\n lightgray: \"d3d3d3\",\n lightgreen: \"90ee90\",\n lightgrey: \"d3d3d3\",\n lightpink: \"ffb6c1\",\n lightsalmon: \"ffa07a\",\n lightseagreen: \"20b2aa\",\n lightskyblue: \"87cefa\",\n lightslategray: \"789\",\n lightslategrey: \"789\",\n lightsteelblue: \"b0c4de\",\n lightyellow: \"ffffe0\",\n lime: \"0f0\",\n limegreen: \"32cd32\",\n linen: \"faf0e6\",\n magenta: \"f0f\",\n maroon: \"800000\",\n mediumaquamarine: \"66cdaa\",\n mediumblue: \"0000cd\",\n mediumorchid: \"ba55d3\",\n mediumpurple: \"9370db\",\n mediumseagreen: \"3cb371\",\n mediumslateblue: \"7b68ee\",\n mediumspringgreen: \"00fa9a\",\n mediumturquoise: \"48d1cc\",\n mediumvioletred: \"c71585\",\n midnightblue: \"191970\",\n mintcream: \"f5fffa\",\n mistyrose: \"ffe4e1\",\n moccasin: \"ffe4b5\",\n navajowhite: \"ffdead\",\n navy: \"000080\",\n oldlace: \"fdf5e6\",\n olive: \"808000\",\n olivedrab: \"6b8e23\",\n orange: \"ffa500\",\n orangered: \"ff4500\",\n orchid: \"da70d6\",\n palegoldenrod: \"eee8aa\",\n palegreen: \"98fb98\",\n paleturquoise: \"afeeee\",\n palevioletred: \"db7093\",\n papayawhip: \"ffefd5\",\n peachpuff: \"ffdab9\",\n peru: \"cd853f\",\n pink: \"ffc0cb\",\n plum: \"dda0dd\",\n powderblue: \"b0e0e6\",\n purple: \"800080\",\n rebeccapurple: \"663399\",\n red: \"f00\",\n rosybrown: \"bc8f8f\",\n royalblue: \"4169e1\",\n saddlebrown: \"8b4513\",\n salmon: \"fa8072\",\n sandybrown: \"f4a460\",\n seagreen: \"2e8b57\",\n seashell: \"fff5ee\",\n sienna: \"a0522d\",\n silver: \"c0c0c0\",\n skyblue: \"87ceeb\",\n slateblue: \"6a5acd\",\n slategray: \"708090\",\n slategrey: \"708090\",\n snow: \"fffafa\",\n springgreen: \"00ff7f\",\n steelblue: \"4682b4\",\n tan: \"d2b48c\",\n teal: \"008080\",\n thistle: \"d8bfd8\",\n tomato: \"ff6347\",\n turquoise: \"40e0d0\",\n violet: \"ee82ee\",\n wheat: \"f5deb3\",\n white: \"fff\",\n whitesmoke: \"f5f5f5\",\n yellow: \"ff0\",\n yellowgreen: \"9acd32\"\n};\n\n// Make it easy to access colors via `hexNames[hex]`\nvar hexNames = tinycolor.hexNames = flip(names);\n\n// Utilities\n// ---------\n\n// `{ 'name1': 'val1' }` becomes `{ 'val1': 'name1' }`\nfunction flip(o) {\n var flipped = {};\n for (var i in o) {\n if (o.hasOwnProperty(i)) {\n flipped[o[i]] = i;\n }\n }\n return flipped;\n}\n\n// Return a valid alpha value [0,1] with all invalid values being set to 1\nfunction boundAlpha(a) {\n a = parseFloat(a);\n if (isNaN(a) || a < 0 || a > 1) {\n a = 1;\n }\n return a;\n}\n\n// Take input from [0, n] and return it as [0, 1]\nfunction bound01(n, max) {\n if (isOnePointZero(n)) n = \"100%\";\n var processPercent = isPercentage(n);\n n = Math.min(max, Math.max(0, parseFloat(n)));\n\n // Automatically convert percentage into number\n if (processPercent) {\n n = parseInt(n * max, 10) / 100;\n }\n\n // Handle floating point rounding errors\n if (Math.abs(n - max) < 0.000001) {\n return 1;\n }\n\n // Convert into [0, 1] range if it isn't already\n return n % max / parseFloat(max);\n}\n\n// Force a number between 0 and 1\nfunction clamp01(val) {\n return Math.min(1, Math.max(0, val));\n}\n\n// Parse a base-16 hex value into a base-10 integer\nfunction parseIntFromHex(val) {\n return parseInt(val, 16);\n}\n\n// Need to handle 1.0 as 100%, since once it is a number, there is no difference between it and 1\n// \nfunction isOnePointZero(n) {\n return typeof n == \"string\" && n.indexOf(\".\") != -1 && parseFloat(n) === 1;\n}\n\n// Check to see if string passed in is a percentage\nfunction isPercentage(n) {\n return typeof n === \"string\" && n.indexOf(\"%\") != -1;\n}\n\n// Force a hex value to have 2 characters\nfunction pad2(c) {\n return c.length == 1 ? \"0\" + c : \"\" + c;\n}\n\n// Replace a decimal with it's percentage value\nfunction convertToPercentage(n) {\n if (n <= 1) {\n n = n * 100 + \"%\";\n }\n return n;\n}\n\n// Converts a decimal to a hex value\nfunction convertDecimalToHex(d) {\n return Math.round(parseFloat(d) * 255).toString(16);\n}\n// Converts a hex value to a decimal\nfunction convertHexToDecimal(h) {\n return parseIntFromHex(h) / 255;\n}\nvar matchers = function () {\n // \n var CSS_INTEGER = \"[-\\\\+]?\\\\d+%?\";\n\n // \n var CSS_NUMBER = \"[-\\\\+]?\\\\d*\\\\.\\\\d+%?\";\n\n // Allow positive/negative integer/number. Don't capture the either/or, just the entire outcome.\n var CSS_UNIT = \"(?:\" + CSS_NUMBER + \")|(?:\" + CSS_INTEGER + \")\";\n\n // Actual matching.\n // Parentheses and commas are optional, but not required.\n // Whitespace can take the place of commas or opening paren\n var PERMISSIVE_MATCH3 = \"[\\\\s|\\\\(]+(\" + CSS_UNIT + \")[,|\\\\s]+(\" + CSS_UNIT + \")[,|\\\\s]+(\" + CSS_UNIT + \")\\\\s*\\\\)?\";\n var PERMISSIVE_MATCH4 = \"[\\\\s|\\\\(]+(\" + CSS_UNIT + \")[,|\\\\s]+(\" + CSS_UNIT + \")[,|\\\\s]+(\" + CSS_UNIT + \")[,|\\\\s]+(\" + CSS_UNIT + \")\\\\s*\\\\)?\";\n return {\n CSS_UNIT: new RegExp(CSS_UNIT),\n rgb: new RegExp(\"rgb\" + PERMISSIVE_MATCH3),\n rgba: new RegExp(\"rgba\" + PERMISSIVE_MATCH4),\n hsl: new RegExp(\"hsl\" + PERMISSIVE_MATCH3),\n hsla: new RegExp(\"hsla\" + PERMISSIVE_MATCH4),\n hsv: new RegExp(\"hsv\" + PERMISSIVE_MATCH3),\n hsva: new RegExp(\"hsva\" + PERMISSIVE_MATCH4),\n hex3: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,\n hex6: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,\n hex4: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,\n hex8: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/\n };\n}();\n\n// `isValidCSSUnit`\n// Take in a single string / number and check to see if it looks like a CSS unit\n// (see `matchers` above for definition).\nfunction isValidCSSUnit(color) {\n return !!matchers.CSS_UNIT.exec(color);\n}\n\n// `stringInputToObject`\n// Permissive string parsing. Take in a number of formats, and output an object\n// based on detected format. Returns `{ r, g, b }` or `{ h, s, l }` or `{ h, s, v}`\nfunction stringInputToObject(color) {\n color = color.replace(trimLeft, \"\").replace(trimRight, \"\").toLowerCase();\n var named = false;\n if (names[color]) {\n color = names[color];\n named = true;\n } else if (color == \"transparent\") {\n return {\n r: 0,\n g: 0,\n b: 0,\n a: 0,\n format: \"name\"\n };\n }\n\n // Try to match string input using regular expressions.\n // Keep most of the number bounding out of this function - don't worry about [0,1] or [0,100] or [0,360]\n // Just return an object and let the conversion functions handle that.\n // This way the result will be the same whether the tinycolor is initialized with string or object.\n var match;\n if (match = matchers.rgb.exec(color)) {\n return {\n r: match[1],\n g: match[2],\n b: match[3]\n };\n }\n if (match = matchers.rgba.exec(color)) {\n return {\n r: match[1],\n g: match[2],\n b: match[3],\n a: match[4]\n };\n }\n if (match = matchers.hsl.exec(color)) {\n return {\n h: match[1],\n s: match[2],\n l: match[3]\n };\n }\n if (match = matchers.hsla.exec(color)) {\n return {\n h: match[1],\n s: match[2],\n l: match[3],\n a: match[4]\n };\n }\n if (match = matchers.hsv.exec(color)) {\n return {\n h: match[1],\n s: match[2],\n v: match[3]\n };\n }\n if (match = matchers.hsva.exec(color)) {\n return {\n h: match[1],\n s: match[2],\n v: match[3],\n a: match[4]\n };\n }\n if (match = matchers.hex8.exec(color)) {\n return {\n r: parseIntFromHex(match[1]),\n g: parseIntFromHex(match[2]),\n b: parseIntFromHex(match[3]),\n a: convertHexToDecimal(match[4]),\n format: named ? \"name\" : \"hex8\"\n };\n }\n if (match = matchers.hex6.exec(color)) {\n return {\n r: parseIntFromHex(match[1]),\n g: parseIntFromHex(match[2]),\n b: parseIntFromHex(match[3]),\n format: named ? \"name\" : \"hex\"\n };\n }\n if (match = matchers.hex4.exec(color)) {\n return {\n r: parseIntFromHex(match[1] + \"\" + match[1]),\n g: parseIntFromHex(match[2] + \"\" + match[2]),\n b: parseIntFromHex(match[3] + \"\" + match[3]),\n a: convertHexToDecimal(match[4] + \"\" + match[4]),\n format: named ? \"name\" : \"hex8\"\n };\n }\n if (match = matchers.hex3.exec(color)) {\n return {\n r: parseIntFromHex(match[1] + \"\" + match[1]),\n g: parseIntFromHex(match[2] + \"\" + match[2]),\n b: parseIntFromHex(match[3] + \"\" + match[3]),\n format: named ? \"name\" : \"hex\"\n };\n }\n return false;\n}\nfunction validateWCAG2Parms(parms) {\n // return valid WCAG2 parms for isReadable.\n // If input parms are invalid, return {\"level\":\"AA\", \"size\":\"small\"}\n var level, size;\n parms = parms || {\n level: \"AA\",\n size: \"small\"\n };\n level = (parms.level || \"AA\").toUpperCase();\n size = (parms.size || \"small\").toLowerCase();\n if (level !== \"AA\" && level !== \"AAA\") {\n level = \"AA\";\n }\n if (size !== \"small\" && size !== \"large\") {\n size = \"small\";\n }\n return {\n level: level,\n size: size\n };\n}\n\nexport { tinycolor as default };\n","import each from 'lodash-es/each';\nimport tinycolor from 'tinycolor2';\n\nexport var simpleCheckForValidColor = function simpleCheckForValidColor(data) {\n var keysToCheck = ['r', 'g', 'b', 'a', 'h', 's', 'l', 'v'];\n var checked = 0;\n var passed = 0;\n each(keysToCheck, function (letter) {\n if (data[letter]) {\n checked += 1;\n if (!isNaN(data[letter])) {\n passed += 1;\n }\n if (letter === 's' || letter === 'l') {\n var percentPatt = /^\\d+%$/;\n if (percentPatt.test(data[letter])) {\n passed += 1;\n }\n }\n }\n });\n return checked === passed ? data : false;\n};\n\nexport var toState = function toState(data, oldHue) {\n var color = data.hex ? tinycolor(data.hex) : tinycolor(data);\n var hsl = color.toHsl();\n var hsv = color.toHsv();\n var rgb = color.toRgb();\n var hex = color.toHex();\n if (hsl.s === 0) {\n hsl.h = oldHue || 0;\n hsv.h = oldHue || 0;\n }\n var transparent = hex === '000000' && rgb.a === 0;\n\n return {\n hsl: hsl,\n hex: transparent ? 'transparent' : '#' + hex,\n rgb: rgb,\n hsv: hsv,\n oldHue: data.h || oldHue || hsl.h,\n source: data.source\n };\n};\n\nexport var isValidHex = function isValidHex(hex) {\n if (hex === 'transparent') {\n return true;\n }\n // disable hex4 and hex8\n var lh = String(hex).charAt(0) === '#' ? 1 : 0;\n return hex.length !== 4 + lh && hex.length < 7 + lh && tinycolor(hex).isValid();\n};\n\nexport var getContrastingColor = function getContrastingColor(data) {\n if (!data) {\n return '#fff';\n }\n var col = toState(data);\n if (col.hex === 'transparent') {\n return 'rgba(0,0,0,0.4)';\n }\n var yiq = (col.rgb.r * 299 + col.rgb.g * 587 + col.rgb.b * 114) / 1000;\n return yiq >= 128 ? '#000' : '#fff';\n};\n\nexport var red = {\n hsl: { a: 1, h: 0, l: 0.5, s: 1 },\n hex: '#ff0000',\n rgb: { r: 255, g: 0, b: 0, a: 1 },\n hsv: { h: 0, s: 1, v: 1, a: 1 }\n};\n\nexport var isvalidColorString = function isvalidColorString(string, type) {\n var stringWithoutDegree = string.replace('°', '');\n return tinycolor(type + ' (' + stringWithoutDegree + ')')._ok;\n};","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nvar _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\nimport React, { Component, PureComponent } from 'react';\nimport debounce from 'lodash-es/debounce';\nimport * as color from '../../helpers/color';\n\nexport var ColorWrap = function ColorWrap(Picker) {\n var ColorPicker = function (_ref) {\n _inherits(ColorPicker, _ref);\n\n function ColorPicker(props) {\n _classCallCheck(this, ColorPicker);\n\n var _this = _possibleConstructorReturn(this, (ColorPicker.__proto__ || Object.getPrototypeOf(ColorPicker)).call(this));\n\n _this.handleChange = function (data, event) {\n var isValidColor = color.simpleCheckForValidColor(data);\n if (isValidColor) {\n var colors = color.toState(data, data.h || _this.state.oldHue);\n _this.setState(colors);\n _this.props.onChangeComplete && _this.debounce(_this.props.onChangeComplete, colors, event);\n _this.props.onChange && _this.props.onChange(colors, event);\n }\n };\n\n _this.handleSwatchHover = function (data, event) {\n var isValidColor = color.simpleCheckForValidColor(data);\n if (isValidColor) {\n var colors = color.toState(data, data.h || _this.state.oldHue);\n _this.props.onSwatchHover && _this.props.onSwatchHover(colors, event);\n }\n };\n\n _this.state = _extends({}, color.toState(props.color, 0));\n\n _this.debounce = debounce(function (fn, data, event) {\n fn(data, event);\n }, 100);\n return _this;\n }\n\n _createClass(ColorPicker, [{\n key: 'render',\n value: function render() {\n var optionalEvents = {};\n if (this.props.onSwatchHover) {\n optionalEvents.onSwatchHover = this.handleSwatchHover;\n }\n\n return React.createElement(Picker, _extends({}, this.props, this.state, {\n onChange: this.handleChange\n }, optionalEvents));\n }\n }], [{\n key: 'getDerivedStateFromProps',\n value: function getDerivedStateFromProps(nextProps, state) {\n return _extends({}, color.toState(nextProps.color, state.oldHue));\n }\n }]);\n\n return ColorPicker;\n }(PureComponent || Component);\n\n ColorPicker.propTypes = _extends({}, Picker.propTypes);\n\n ColorPicker.defaultProps = _extends({}, Picker.defaultProps, {\n color: {\n h: 250,\n s: 0.50,\n l: 0.20,\n a: 1\n }\n });\n\n return ColorPicker;\n};\n\nexport default ColorWrap;","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nvar _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\n/* eslint-disable no-invalid-this */\nimport React from 'react';\n\nexport var handleFocus = function handleFocus(Component) {\n var Span = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'span';\n return function (_React$Component) {\n _inherits(Focus, _React$Component);\n\n function Focus() {\n var _ref;\n\n var _temp, _this, _ret;\n\n _classCallCheck(this, Focus);\n\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = Focus.__proto__ || Object.getPrototypeOf(Focus)).call.apply(_ref, [this].concat(args))), _this), _this.state = { focus: false }, _this.handleFocus = function () {\n return _this.setState({ focus: true });\n }, _this.handleBlur = function () {\n return _this.setState({ focus: false });\n }, _temp), _possibleConstructorReturn(_this, _ret);\n }\n\n _createClass(Focus, [{\n key: 'render',\n value: function render() {\n return React.createElement(\n Span,\n { onFocus: this.handleFocus, onBlur: this.handleBlur },\n React.createElement(Component, _extends({}, this.props, this.state))\n );\n }\n }]);\n\n return Focus;\n }(React.Component);\n};","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nimport React from 'react';\nimport reactCSS from 'reactcss';\nimport { handleFocus } from '../../helpers/interaction';\n\nimport Checkboard from './Checkboard';\n\nvar ENTER = 13;\n\nexport var Swatch = function Swatch(_ref) {\n var color = _ref.color,\n style = _ref.style,\n _ref$onClick = _ref.onClick,\n onClick = _ref$onClick === undefined ? function () {} : _ref$onClick,\n onHover = _ref.onHover,\n _ref$title = _ref.title,\n title = _ref$title === undefined ? color : _ref$title,\n children = _ref.children,\n focus = _ref.focus,\n _ref$focusStyle = _ref.focusStyle,\n focusStyle = _ref$focusStyle === undefined ? {} : _ref$focusStyle;\n\n var transparent = color === 'transparent';\n var styles = reactCSS({\n default: {\n swatch: _extends({\n background: color,\n height: '100%',\n width: '100%',\n cursor: 'pointer',\n position: 'relative',\n outline: 'none'\n }, style, focus ? focusStyle : {})\n }\n });\n\n var handleClick = function handleClick(e) {\n return onClick(color, e);\n };\n var handleKeyDown = function handleKeyDown(e) {\n return e.keyCode === ENTER && onClick(color, e);\n };\n var handleHover = function handleHover(e) {\n return onHover(color, e);\n };\n\n var optionalEvents = {};\n if (onHover) {\n optionalEvents.onMouseOver = handleHover;\n }\n\n return React.createElement(\n 'div',\n _extends({\n style: styles.swatch,\n onClick: handleClick,\n title: title,\n tabIndex: 0,\n onKeyDown: handleKeyDown\n }, optionalEvents),\n children,\n transparent && React.createElement(Checkboard, {\n borderRadius: styles.swatch.borderRadius,\n boxShadow: 'inset 0 0 0 1px rgba(0,0,0,0.1)'\n })\n );\n};\n\nexport default handleFocus(Swatch);","import React from 'react';\nimport reactCSS from 'reactcss';\n\nexport var AlphaPointer = function AlphaPointer(_ref) {\n var direction = _ref.direction;\n\n var styles = reactCSS({\n 'default': {\n picker: {\n width: '18px',\n height: '18px',\n borderRadius: '50%',\n transform: 'translate(-9px, -1px)',\n backgroundColor: 'rgb(248, 248, 248)',\n boxShadow: '0 1px 4px 0 rgba(0, 0, 0, 0.37)'\n }\n },\n 'vertical': {\n picker: {\n transform: 'translate(-3px, -9px)'\n }\n }\n }, { vertical: direction === 'vertical' });\n\n return React.createElement('div', { style: styles.picker });\n};\n\nexport default AlphaPointer;","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nimport React from 'react';\nimport reactCSS from 'reactcss';\n\nimport { ColorWrap, Alpha } from '../common';\nimport AlphaPointer from './AlphaPointer';\n\nexport var AlphaPicker = function AlphaPicker(_ref) {\n var rgb = _ref.rgb,\n hsl = _ref.hsl,\n width = _ref.width,\n height = _ref.height,\n onChange = _ref.onChange,\n direction = _ref.direction,\n style = _ref.style,\n renderers = _ref.renderers,\n pointer = _ref.pointer,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS({\n 'default': {\n picker: {\n position: 'relative',\n width: width,\n height: height\n },\n alpha: {\n radius: '2px',\n style: style\n }\n }\n });\n\n return React.createElement(\n 'div',\n { style: styles.picker, className: 'alpha-picker ' + className },\n React.createElement(Alpha, _extends({}, styles.alpha, {\n rgb: rgb,\n hsl: hsl,\n pointer: pointer,\n renderers: renderers,\n onChange: onChange,\n direction: direction\n }))\n );\n};\n\nAlphaPicker.defaultProps = {\n width: '316px',\n height: '16px',\n direction: 'horizontal',\n pointer: AlphaPointer\n};\n\nexport default ColorWrap(AlphaPicker);","/**\n * A specialized version of `_.map` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\nfunction arrayMap(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length,\n result = Array(length);\n\n while (++index < length) {\n result[index] = iteratee(array[index], index, array);\n }\n return result;\n}\n\nexport default arrayMap;\n","/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\nexport default setCacheAdd;\n","/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\nexport default setCacheHas;\n","import MapCache from './_MapCache.js';\nimport setCacheAdd from './_setCacheAdd.js';\nimport setCacheHas from './_setCacheHas.js';\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nexport default SetCache;\n","/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\nexport default arraySome;\n","/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\nexport default cacheHas;\n","import SetCache from './_SetCache.js';\nimport arraySome from './_arraySome.js';\nimport cacheHas from './_cacheHas.js';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\nexport default equalArrays;\n","/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\nexport default mapToArray;\n","/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\nexport default setToArray;\n","import Symbol from './_Symbol.js';\nimport Uint8Array from './_Uint8Array.js';\nimport eq from './eq.js';\nimport equalArrays from './_equalArrays.js';\nimport mapToArray from './_mapToArray.js';\nimport setToArray from './_setToArray.js';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\nexport default equalByTag;\n","/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n}\n\nexport default arrayPush;\n","import arrayPush from './_arrayPush.js';\nimport isArray from './isArray.js';\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nexport default baseGetAllKeys;\n","/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\nexport default arrayFilter;\n","/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nexport default stubArray;\n","import arrayFilter from './_arrayFilter.js';\nimport stubArray from './stubArray.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\nexport default getSymbols;\n","import baseGetAllKeys from './_baseGetAllKeys.js';\nimport getSymbols from './_getSymbols.js';\nimport keys from './keys.js';\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\nexport default getAllKeys;\n","import getAllKeys from './_getAllKeys.js';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\nexport default equalObjects;\n","import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nexport default DataView;\n","import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nexport default Promise;\n","import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nexport default Set;\n","import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nexport default WeakMap;\n","import DataView from './_DataView.js';\nimport Map from './_Map.js';\nimport Promise from './_Promise.js';\nimport Set from './_Set.js';\nimport WeakMap from './_WeakMap.js';\nimport baseGetTag from './_baseGetTag.js';\nimport toSource from './_toSource.js';\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nexport default getTag;\n","import Stack from './_Stack.js';\nimport equalArrays from './_equalArrays.js';\nimport equalByTag from './_equalByTag.js';\nimport equalObjects from './_equalObjects.js';\nimport getTag from './_getTag.js';\nimport isArray from './isArray.js';\nimport isBuffer from './isBuffer.js';\nimport isTypedArray from './isTypedArray.js';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nexport default baseIsEqualDeep;\n","import baseIsEqualDeep from './_baseIsEqualDeep.js';\nimport isObjectLike from './isObjectLike.js';\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nexport default baseIsEqual;\n","import Stack from './_Stack.js';\nimport baseIsEqual from './_baseIsEqual.js';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.isMatch` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @param {Array} matchData The property names, values, and compare flags to match.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n */\nfunction baseIsMatch(object, source, matchData, customizer) {\n var index = matchData.length,\n length = index,\n noCustomizer = !customizer;\n\n if (object == null) {\n return !length;\n }\n object = Object(object);\n while (index--) {\n var data = matchData[index];\n if ((noCustomizer && data[2])\n ? data[1] !== object[data[0]]\n : !(data[0] in object)\n ) {\n return false;\n }\n }\n while (++index < length) {\n data = matchData[index];\n var key = data[0],\n objValue = object[key],\n srcValue = data[1];\n\n if (noCustomizer && data[2]) {\n if (objValue === undefined && !(key in object)) {\n return false;\n }\n } else {\n var stack = new Stack;\n if (customizer) {\n var result = customizer(objValue, srcValue, key, object, source, stack);\n }\n if (!(result === undefined\n ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)\n : result\n )) {\n return false;\n }\n }\n }\n return true;\n}\n\nexport default baseIsMatch;\n","import isObject from './isObject.js';\n\n/**\n * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` if suitable for strict\n * equality comparisons, else `false`.\n */\nfunction isStrictComparable(value) {\n return value === value && !isObject(value);\n}\n\nexport default isStrictComparable;\n","import isStrictComparable from './_isStrictComparable.js';\nimport keys from './keys.js';\n\n/**\n * Gets the property names, values, and compare flags of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the match data of `object`.\n */\nfunction getMatchData(object) {\n var result = keys(object),\n length = result.length;\n\n while (length--) {\n var key = result[length],\n value = object[key];\n\n result[length] = [key, value, isStrictComparable(value)];\n }\n return result;\n}\n\nexport default getMatchData;\n","/**\n * A specialized version of `matchesProperty` for source values suitable\n * for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction matchesStrictComparable(key, srcValue) {\n return function(object) {\n if (object == null) {\n return false;\n }\n return object[key] === srcValue &&\n (srcValue !== undefined || (key in Object(object)));\n };\n}\n\nexport default matchesStrictComparable;\n","import baseIsMatch from './_baseIsMatch.js';\nimport getMatchData from './_getMatchData.js';\nimport matchesStrictComparable from './_matchesStrictComparable.js';\n\n/**\n * The base implementation of `_.matches` which doesn't clone `source`.\n *\n * @private\n * @param {Object} source The object of property values to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatches(source) {\n var matchData = getMatchData(source);\n if (matchData.length == 1 && matchData[0][2]) {\n return matchesStrictComparable(matchData[0][0], matchData[0][1]);\n }\n return function(object) {\n return object === source || baseIsMatch(object, source, matchData);\n };\n}\n\nexport default baseMatches;\n","import isArray from './isArray.js';\nimport isSymbol from './isSymbol.js';\n\n/** Used to match property names within property paths. */\nvar reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\n reIsPlainProp = /^\\w*$/;\n\n/**\n * Checks if `value` is a property name and not a property path.\n *\n * @private\n * @param {*} value The value to check.\n * @param {Object} [object] The object to query keys on.\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\n */\nfunction isKey(value, object) {\n if (isArray(value)) {\n return false;\n }\n var type = typeof value;\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\n value == null || isSymbol(value)) {\n return true;\n }\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\n (object != null && value in Object(object));\n}\n\nexport default isKey;\n","import MapCache from './_MapCache.js';\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\nfunction memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n}\n\n// Expose `MapCache`.\nmemoize.Cache = MapCache;\n\nexport default memoize;\n","import memoize from './memoize.js';\n\n/** Used as the maximum memoize cache size. */\nvar MAX_MEMOIZE_SIZE = 500;\n\n/**\n * A specialized version of `_.memoize` which clears the memoized function's\n * cache when it exceeds `MAX_MEMOIZE_SIZE`.\n *\n * @private\n * @param {Function} func The function to have its output memoized.\n * @returns {Function} Returns the new memoized function.\n */\nfunction memoizeCapped(func) {\n var result = memoize(func, function(key) {\n if (cache.size === MAX_MEMOIZE_SIZE) {\n cache.clear();\n }\n return key;\n });\n\n var cache = result.cache;\n return result;\n}\n\nexport default memoizeCapped;\n","import memoizeCapped from './_memoizeCapped.js';\n\n/** Used to match property names within property paths. */\nvar rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\n\n/** Used to match backslashes in property paths. */\nvar reEscapeChar = /\\\\(\\\\)?/g;\n\n/**\n * Converts `string` to a property path array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the property path array.\n */\nvar stringToPath = memoizeCapped(function(string) {\n var result = [];\n if (string.charCodeAt(0) === 46 /* . */) {\n result.push('');\n }\n string.replace(rePropName, function(match, number, quote, subString) {\n result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));\n });\n return result;\n});\n\nexport default stringToPath;\n","import Symbol from './_Symbol.js';\nimport arrayMap from './_arrayMap.js';\nimport isArray from './isArray.js';\nimport isSymbol from './isSymbol.js';\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n/**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\nfunction baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isArray(value)) {\n // Recursively convert values (susceptible to call stack limits).\n return arrayMap(value, baseToString) + '';\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nexport default baseToString;\n","import baseToString from './_baseToString.js';\n\n/**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\nfunction toString(value) {\n return value == null ? '' : baseToString(value);\n}\n\nexport default toString;\n","import isArray from './isArray.js';\nimport isKey from './_isKey.js';\nimport stringToPath from './_stringToPath.js';\nimport toString from './toString.js';\n\n/**\n * Casts `value` to a path array if it's not one.\n *\n * @private\n * @param {*} value The value to inspect.\n * @param {Object} [object] The object to query keys on.\n * @returns {Array} Returns the cast property path array.\n */\nfunction castPath(value, object) {\n if (isArray(value)) {\n return value;\n }\n return isKey(value, object) ? [value] : stringToPath(toString(value));\n}\n\nexport default castPath;\n","import isSymbol from './isSymbol.js';\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/**\n * Converts `value` to a string key if it's not a string or symbol.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {string|symbol} Returns the key.\n */\nfunction toKey(value) {\n if (typeof value == 'string' || isSymbol(value)) {\n return value;\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nexport default toKey;\n","import castPath from './_castPath.js';\nimport toKey from './_toKey.js';\n\n/**\n * The base implementation of `_.get` without support for default values.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @returns {*} Returns the resolved value.\n */\nfunction baseGet(object, path) {\n path = castPath(path, object);\n\n var index = 0,\n length = path.length;\n\n while (object != null && index < length) {\n object = object[toKey(path[index++])];\n }\n return (index && index == length) ? object : undefined;\n}\n\nexport default baseGet;\n","import baseGet from './_baseGet.js';\n\n/**\n * Gets the value at `path` of `object`. If the resolved value is\n * `undefined`, the `defaultValue` is returned in its place.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.get(object, 'a[0].b.c');\n * // => 3\n *\n * _.get(object, ['a', '0', 'b', 'c']);\n * // => 3\n *\n * _.get(object, 'a.b.c', 'default');\n * // => 'default'\n */\nfunction get(object, path, defaultValue) {\n var result = object == null ? undefined : baseGet(object, path);\n return result === undefined ? defaultValue : result;\n}\n\nexport default get;\n","/**\n * The base implementation of `_.hasIn` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHasIn(object, key) {\n return object != null && key in Object(object);\n}\n\nexport default baseHasIn;\n","import castPath from './_castPath.js';\nimport isArguments from './isArguments.js';\nimport isArray from './isArray.js';\nimport isIndex from './_isIndex.js';\nimport isLength from './isLength.js';\nimport toKey from './_toKey.js';\n\n/**\n * Checks if `path` exists on `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @param {Function} hasFunc The function to check properties.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n */\nfunction hasPath(object, path, hasFunc) {\n path = castPath(path, object);\n\n var index = -1,\n length = path.length,\n result = false;\n\n while (++index < length) {\n var key = toKey(path[index]);\n if (!(result = object != null && hasFunc(object, key))) {\n break;\n }\n object = object[key];\n }\n if (result || ++index != length) {\n return result;\n }\n length = object == null ? 0 : object.length;\n return !!length && isLength(length) && isIndex(key, length) &&\n (isArray(object) || isArguments(object));\n}\n\nexport default hasPath;\n","import baseHasIn from './_baseHasIn.js';\nimport hasPath from './_hasPath.js';\n\n/**\n * Checks if `path` is a direct or inherited property of `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.hasIn(object, 'a');\n * // => true\n *\n * _.hasIn(object, 'a.b');\n * // => true\n *\n * _.hasIn(object, ['a', 'b']);\n * // => true\n *\n * _.hasIn(object, 'b');\n * // => false\n */\nfunction hasIn(object, path) {\n return object != null && hasPath(object, path, baseHasIn);\n}\n\nexport default hasIn;\n","import baseIsEqual from './_baseIsEqual.js';\nimport get from './get.js';\nimport hasIn from './hasIn.js';\nimport isKey from './_isKey.js';\nimport isStrictComparable from './_isStrictComparable.js';\nimport matchesStrictComparable from './_matchesStrictComparable.js';\nimport toKey from './_toKey.js';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.\n *\n * @private\n * @param {string} path The path of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatchesProperty(path, srcValue) {\n if (isKey(path) && isStrictComparable(srcValue)) {\n return matchesStrictComparable(toKey(path), srcValue);\n }\n return function(object) {\n var objValue = get(object, path);\n return (objValue === undefined && objValue === srcValue)\n ? hasIn(object, path)\n : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);\n };\n}\n\nexport default baseMatchesProperty;\n","/**\n * The base implementation of `_.property` without support for deep paths.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction baseProperty(key) {\n return function(object) {\n return object == null ? undefined : object[key];\n };\n}\n\nexport default baseProperty;\n","import baseGet from './_baseGet.js';\n\n/**\n * A specialized version of `baseProperty` which supports deep paths.\n *\n * @private\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyDeep(path) {\n return function(object) {\n return baseGet(object, path);\n };\n}\n\nexport default basePropertyDeep;\n","import baseProperty from './_baseProperty.js';\nimport basePropertyDeep from './_basePropertyDeep.js';\nimport isKey from './_isKey.js';\nimport toKey from './_toKey.js';\n\n/**\n * Creates a function that returns the value at `path` of a given object.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n * @example\n *\n * var objects = [\n * { 'a': { 'b': 2 } },\n * { 'a': { 'b': 1 } }\n * ];\n *\n * _.map(objects, _.property('a.b'));\n * // => [2, 1]\n *\n * _.map(_.sortBy(objects, _.property(['a', 'b'])), 'a.b');\n * // => [1, 2]\n */\nfunction property(path) {\n return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);\n}\n\nexport default property;\n","import baseMatches from './_baseMatches.js';\nimport baseMatchesProperty from './_baseMatchesProperty.js';\nimport identity from './identity.js';\nimport isArray from './isArray.js';\nimport property from './property.js';\n\n/**\n * The base implementation of `_.iteratee`.\n *\n * @private\n * @param {*} [value=_.identity] The value to convert to an iteratee.\n * @returns {Function} Returns the iteratee.\n */\nfunction baseIteratee(value) {\n // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.\n // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.\n if (typeof value == 'function') {\n return value;\n }\n if (value == null) {\n return identity;\n }\n if (typeof value == 'object') {\n return isArray(value)\n ? baseMatchesProperty(value[0], value[1])\n : baseMatches(value);\n }\n return property(value);\n}\n\nexport default baseIteratee;\n","import baseEach from './_baseEach.js';\nimport isArrayLike from './isArrayLike.js';\n\n/**\n * The base implementation of `_.map` without support for iteratee shorthands.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\nfunction baseMap(collection, iteratee) {\n var index = -1,\n result = isArrayLike(collection) ? Array(collection.length) : [];\n\n baseEach(collection, function(value, key, collection) {\n result[++index] = iteratee(value, key, collection);\n });\n return result;\n}\n\nexport default baseMap;\n","import arrayMap from './_arrayMap.js';\nimport baseIteratee from './_baseIteratee.js';\nimport baseMap from './_baseMap.js';\nimport isArray from './isArray.js';\n\n/**\n * Creates an array of values by running each element in `collection` thru\n * `iteratee`. The iteratee is invoked with three arguments:\n * (value, index|key, collection).\n *\n * Many lodash methods are guarded to work as iteratees for methods like\n * `_.every`, `_.filter`, `_.map`, `_.mapValues`, `_.reject`, and `_.some`.\n *\n * The guarded methods are:\n * `ary`, `chunk`, `curry`, `curryRight`, `drop`, `dropRight`, `every`,\n * `fill`, `invert`, `parseInt`, `random`, `range`, `rangeRight`, `repeat`,\n * `sampleSize`, `slice`, `some`, `sortBy`, `split`, `take`, `takeRight`,\n * `template`, `trim`, `trimEnd`, `trimStart`, and `words`\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n * @example\n *\n * function square(n) {\n * return n * n;\n * }\n *\n * _.map([4, 8], square);\n * // => [16, 64]\n *\n * _.map({ 'a': 4, 'b': 8 }, square);\n * // => [16, 64] (iteration order is not guaranteed)\n *\n * var users = [\n * { 'user': 'barney' },\n * { 'user': 'fred' }\n * ];\n *\n * // The `_.property` iteratee shorthand.\n * _.map(users, 'user');\n * // => ['barney', 'fred']\n */\nfunction map(collection, iteratee) {\n var func = isArray(collection) ? arrayMap : baseMap;\n return func(collection, baseIteratee(iteratee, 3));\n}\n\nexport default map;\n","import React from 'react';\nimport reactCSS from 'reactcss';\nimport map from 'lodash-es/map';\n\nimport { Swatch } from '../common';\n\nexport var BlockSwatches = function BlockSwatches(_ref) {\n var colors = _ref.colors,\n onClick = _ref.onClick,\n onSwatchHover = _ref.onSwatchHover;\n\n var styles = reactCSS({\n 'default': {\n swatches: {\n marginRight: '-10px'\n },\n swatch: {\n width: '22px',\n height: '22px',\n float: 'left',\n marginRight: '10px',\n marginBottom: '10px',\n borderRadius: '4px'\n },\n clear: {\n clear: 'both'\n }\n }\n });\n\n return React.createElement(\n 'div',\n { style: styles.swatches },\n map(colors, function (c) {\n return React.createElement(Swatch, {\n key: c,\n color: c,\n style: styles.swatch,\n onClick: onClick,\n onHover: onSwatchHover,\n focusStyle: {\n boxShadow: '0 0 4px ' + c\n }\n });\n }),\n React.createElement('div', { style: styles.clear })\n );\n};\n\nexport default BlockSwatches;","import React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport merge from 'lodash-es/merge';\nimport * as color from '../../helpers/color';\n\nimport { ColorWrap, EditableInput, Checkboard } from '../common';\nimport BlockSwatches from './BlockSwatches';\n\nexport var Block = function Block(_ref) {\n var onChange = _ref.onChange,\n onSwatchHover = _ref.onSwatchHover,\n hex = _ref.hex,\n colors = _ref.colors,\n width = _ref.width,\n triangle = _ref.triangle,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var transparent = hex === 'transparent';\n var handleChange = function handleChange(hexCode, e) {\n color.isValidHex(hexCode) && onChange({\n hex: hexCode,\n source: 'hex'\n }, e);\n };\n\n var styles = reactCSS(merge({\n 'default': {\n card: {\n width: width,\n background: '#fff',\n boxShadow: '0 1px rgba(0,0,0,.1)',\n borderRadius: '6px',\n position: 'relative'\n },\n head: {\n height: '110px',\n background: hex,\n borderRadius: '6px 6px 0 0',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n position: 'relative'\n },\n body: {\n padding: '10px'\n },\n label: {\n fontSize: '18px',\n color: color.getContrastingColor(hex),\n position: 'relative'\n },\n triangle: {\n width: '0px',\n height: '0px',\n borderStyle: 'solid',\n borderWidth: '0 10px 10px 10px',\n borderColor: 'transparent transparent ' + hex + ' transparent',\n position: 'absolute',\n top: '-10px',\n left: '50%',\n marginLeft: '-10px'\n },\n input: {\n width: '100%',\n fontSize: '12px',\n color: '#666',\n border: '0px',\n outline: 'none',\n height: '22px',\n boxShadow: 'inset 0 0 0 1px #ddd',\n borderRadius: '4px',\n padding: '0 7px',\n boxSizing: 'border-box'\n }\n },\n 'hide-triangle': {\n triangle: {\n display: 'none'\n }\n }\n }, passedStyles), { 'hide-triangle': triangle === 'hide' });\n\n return React.createElement(\n 'div',\n { style: styles.card, className: 'block-picker ' + className },\n React.createElement('div', { style: styles.triangle }),\n React.createElement(\n 'div',\n { style: styles.head },\n transparent && React.createElement(Checkboard, { borderRadius: '6px 6px 0 0' }),\n React.createElement(\n 'div',\n { style: styles.label },\n hex\n )\n ),\n React.createElement(\n 'div',\n { style: styles.body },\n React.createElement(BlockSwatches, { colors: colors, onClick: handleChange, onSwatchHover: onSwatchHover }),\n React.createElement(EditableInput, {\n style: { input: styles.input },\n value: hex,\n onChange: handleChange\n })\n )\n );\n};\n\nBlock.propTypes = {\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n colors: PropTypes.arrayOf(PropTypes.string),\n triangle: PropTypes.oneOf(['top', 'hide']),\n styles: PropTypes.object\n};\n\nBlock.defaultProps = {\n width: 170,\n colors: ['#D9E3F0', '#F47373', '#697689', '#37D67A', '#2CCCE4', '#555555', '#dce775', '#ff8a65', '#ba68c8'],\n triangle: 'top',\n styles: {}\n};\n\nexport default ColorWrap(Block);","export var red = {\"50\":\"#ffebee\",\"100\":\"#ffcdd2\",\"200\":\"#ef9a9a\",\"300\":\"#e57373\",\"400\":\"#ef5350\",\"500\":\"#f44336\",\"600\":\"#e53935\",\"700\":\"#d32f2f\",\"800\":\"#c62828\",\"900\":\"#b71c1c\",\"a100\":\"#ff8a80\",\"a200\":\"#ff5252\",\"a400\":\"#ff1744\",\"a700\":\"#d50000\"};\nexport var pink = {\"50\":\"#fce4ec\",\"100\":\"#f8bbd0\",\"200\":\"#f48fb1\",\"300\":\"#f06292\",\"400\":\"#ec407a\",\"500\":\"#e91e63\",\"600\":\"#d81b60\",\"700\":\"#c2185b\",\"800\":\"#ad1457\",\"900\":\"#880e4f\",\"a100\":\"#ff80ab\",\"a200\":\"#ff4081\",\"a400\":\"#f50057\",\"a700\":\"#c51162\"};\nexport var purple = {\"50\":\"#f3e5f5\",\"100\":\"#e1bee7\",\"200\":\"#ce93d8\",\"300\":\"#ba68c8\",\"400\":\"#ab47bc\",\"500\":\"#9c27b0\",\"600\":\"#8e24aa\",\"700\":\"#7b1fa2\",\"800\":\"#6a1b9a\",\"900\":\"#4a148c\",\"a100\":\"#ea80fc\",\"a200\":\"#e040fb\",\"a400\":\"#d500f9\",\"a700\":\"#aa00ff\"};\nexport var deepPurple = {\"50\":\"#ede7f6\",\"100\":\"#d1c4e9\",\"200\":\"#b39ddb\",\"300\":\"#9575cd\",\"400\":\"#7e57c2\",\"500\":\"#673ab7\",\"600\":\"#5e35b1\",\"700\":\"#512da8\",\"800\":\"#4527a0\",\"900\":\"#311b92\",\"a100\":\"#b388ff\",\"a200\":\"#7c4dff\",\"a400\":\"#651fff\",\"a700\":\"#6200ea\"};\nexport var indigo = {\"50\":\"#e8eaf6\",\"100\":\"#c5cae9\",\"200\":\"#9fa8da\",\"300\":\"#7986cb\",\"400\":\"#5c6bc0\",\"500\":\"#3f51b5\",\"600\":\"#3949ab\",\"700\":\"#303f9f\",\"800\":\"#283593\",\"900\":\"#1a237e\",\"a100\":\"#8c9eff\",\"a200\":\"#536dfe\",\"a400\":\"#3d5afe\",\"a700\":\"#304ffe\"};\nexport var blue = {\"50\":\"#e3f2fd\",\"100\":\"#bbdefb\",\"200\":\"#90caf9\",\"300\":\"#64b5f6\",\"400\":\"#42a5f5\",\"500\":\"#2196f3\",\"600\":\"#1e88e5\",\"700\":\"#1976d2\",\"800\":\"#1565c0\",\"900\":\"#0d47a1\",\"a100\":\"#82b1ff\",\"a200\":\"#448aff\",\"a400\":\"#2979ff\",\"a700\":\"#2962ff\"};\nexport var lightBlue = {\"50\":\"#e1f5fe\",\"100\":\"#b3e5fc\",\"200\":\"#81d4fa\",\"300\":\"#4fc3f7\",\"400\":\"#29b6f6\",\"500\":\"#03a9f4\",\"600\":\"#039be5\",\"700\":\"#0288d1\",\"800\":\"#0277bd\",\"900\":\"#01579b\",\"a100\":\"#80d8ff\",\"a200\":\"#40c4ff\",\"a400\":\"#00b0ff\",\"a700\":\"#0091ea\"};\nexport var cyan = {\"50\":\"#e0f7fa\",\"100\":\"#b2ebf2\",\"200\":\"#80deea\",\"300\":\"#4dd0e1\",\"400\":\"#26c6da\",\"500\":\"#00bcd4\",\"600\":\"#00acc1\",\"700\":\"#0097a7\",\"800\":\"#00838f\",\"900\":\"#006064\",\"a100\":\"#84ffff\",\"a200\":\"#18ffff\",\"a400\":\"#00e5ff\",\"a700\":\"#00b8d4\"};\nexport var teal = {\"50\":\"#e0f2f1\",\"100\":\"#b2dfdb\",\"200\":\"#80cbc4\",\"300\":\"#4db6ac\",\"400\":\"#26a69a\",\"500\":\"#009688\",\"600\":\"#00897b\",\"700\":\"#00796b\",\"800\":\"#00695c\",\"900\":\"#004d40\",\"a100\":\"#a7ffeb\",\"a200\":\"#64ffda\",\"a400\":\"#1de9b6\",\"a700\":\"#00bfa5\"};\nexport var green = {\"50\":\"#e8f5e9\",\"100\":\"#c8e6c9\",\"200\":\"#a5d6a7\",\"300\":\"#81c784\",\"400\":\"#66bb6a\",\"500\":\"#4caf50\",\"600\":\"#43a047\",\"700\":\"#388e3c\",\"800\":\"#2e7d32\",\"900\":\"#1b5e20\",\"a100\":\"#b9f6ca\",\"a200\":\"#69f0ae\",\"a400\":\"#00e676\",\"a700\":\"#00c853\"};\nexport var lightGreen = {\"50\":\"#f1f8e9\",\"100\":\"#dcedc8\",\"200\":\"#c5e1a5\",\"300\":\"#aed581\",\"400\":\"#9ccc65\",\"500\":\"#8bc34a\",\"600\":\"#7cb342\",\"700\":\"#689f38\",\"800\":\"#558b2f\",\"900\":\"#33691e\",\"a100\":\"#ccff90\",\"a200\":\"#b2ff59\",\"a400\":\"#76ff03\",\"a700\":\"#64dd17\"};\nexport var lime = {\"50\":\"#f9fbe7\",\"100\":\"#f0f4c3\",\"200\":\"#e6ee9c\",\"300\":\"#dce775\",\"400\":\"#d4e157\",\"500\":\"#cddc39\",\"600\":\"#c0ca33\",\"700\":\"#afb42b\",\"800\":\"#9e9d24\",\"900\":\"#827717\",\"a100\":\"#f4ff81\",\"a200\":\"#eeff41\",\"a400\":\"#c6ff00\",\"a700\":\"#aeea00\"};\nexport var yellow = {\"50\":\"#fffde7\",\"100\":\"#fff9c4\",\"200\":\"#fff59d\",\"300\":\"#fff176\",\"400\":\"#ffee58\",\"500\":\"#ffeb3b\",\"600\":\"#fdd835\",\"700\":\"#fbc02d\",\"800\":\"#f9a825\",\"900\":\"#f57f17\",\"a100\":\"#ffff8d\",\"a200\":\"#ffff00\",\"a400\":\"#ffea00\",\"a700\":\"#ffd600\"};\nexport var amber = {\"50\":\"#fff8e1\",\"100\":\"#ffecb3\",\"200\":\"#ffe082\",\"300\":\"#ffd54f\",\"400\":\"#ffca28\",\"500\":\"#ffc107\",\"600\":\"#ffb300\",\"700\":\"#ffa000\",\"800\":\"#ff8f00\",\"900\":\"#ff6f00\",\"a100\":\"#ffe57f\",\"a200\":\"#ffd740\",\"a400\":\"#ffc400\",\"a700\":\"#ffab00\"};\nexport var orange = {\"50\":\"#fff3e0\",\"100\":\"#ffe0b2\",\"200\":\"#ffcc80\",\"300\":\"#ffb74d\",\"400\":\"#ffa726\",\"500\":\"#ff9800\",\"600\":\"#fb8c00\",\"700\":\"#f57c00\",\"800\":\"#ef6c00\",\"900\":\"#e65100\",\"a100\":\"#ffd180\",\"a200\":\"#ffab40\",\"a400\":\"#ff9100\",\"a700\":\"#ff6d00\"};\nexport var deepOrange = {\"50\":\"#fbe9e7\",\"100\":\"#ffccbc\",\"200\":\"#ffab91\",\"300\":\"#ff8a65\",\"400\":\"#ff7043\",\"500\":\"#ff5722\",\"600\":\"#f4511e\",\"700\":\"#e64a19\",\"800\":\"#d84315\",\"900\":\"#bf360c\",\"a100\":\"#ff9e80\",\"a200\":\"#ff6e40\",\"a400\":\"#ff3d00\",\"a700\":\"#dd2c00\"};\nexport var brown = {\"50\":\"#efebe9\",\"100\":\"#d7ccc8\",\"200\":\"#bcaaa4\",\"300\":\"#a1887f\",\"400\":\"#8d6e63\",\"500\":\"#795548\",\"600\":\"#6d4c41\",\"700\":\"#5d4037\",\"800\":\"#4e342e\",\"900\":\"#3e2723\"};\nexport var grey = {\"50\":\"#fafafa\",\"100\":\"#f5f5f5\",\"200\":\"#eeeeee\",\"300\":\"#e0e0e0\",\"400\":\"#bdbdbd\",\"500\":\"#9e9e9e\",\"600\":\"#757575\",\"700\":\"#616161\",\"800\":\"#424242\",\"900\":\"#212121\"};\nexport var blueGrey = {\"50\":\"#eceff1\",\"100\":\"#cfd8dc\",\"200\":\"#b0bec5\",\"300\":\"#90a4ae\",\"400\":\"#78909c\",\"500\":\"#607d8b\",\"600\":\"#546e7a\",\"700\":\"#455a64\",\"800\":\"#37474f\",\"900\":\"#263238\"};\nexport var darkText = {\"primary\":\"rgba(0, 0, 0, 0.87)\",\"secondary\":\"rgba(0, 0, 0, 0.54)\",\"disabled\":\"rgba(0, 0, 0, 0.38)\",\"dividers\":\"rgba(0, 0, 0, 0.12)\"};\nexport var lightText = {\"primary\":\"rgba(255, 255, 255, 1)\",\"secondary\":\"rgba(255, 255, 255, 0.7)\",\"disabled\":\"rgba(255, 255, 255, 0.5)\",\"dividers\":\"rgba(255, 255, 255, 0.12)\"};\nexport var darkIcons = {\"active\":\"rgba(0, 0, 0, 0.54)\",\"inactive\":\"rgba(0, 0, 0, 0.38)\"};\nexport var lightIcons = {\"active\":\"rgba(255, 255, 255, 1)\",\"inactive\":\"rgba(255, 255, 255, 0.5)\"};\nexport var white = \"#ffffff\";\nexport var black = \"#000000\";\n\nexport default {\n red: red,\n pink: pink,\n purple: purple,\n deepPurple: deepPurple,\n indigo: indigo,\n blue: blue,\n lightBlue: lightBlue,\n cyan: cyan,\n teal: teal,\n green: green,\n lightGreen: lightGreen,\n lime: lime,\n yellow: yellow,\n amber: amber,\n orange: orange,\n deepOrange: deepOrange,\n brown: brown,\n grey: grey,\n blueGrey: blueGrey,\n darkText: darkText,\n lightText: lightText,\n darkIcons: darkIcons,\n lightIcons: lightIcons,\n white: white,\n black: black\n};\n","import React from 'react';\nimport reactCSS, { handleHover } from 'reactcss';\n\nimport { Swatch } from '../common';\n\nexport var CircleSwatch = function CircleSwatch(_ref) {\n var color = _ref.color,\n onClick = _ref.onClick,\n onSwatchHover = _ref.onSwatchHover,\n hover = _ref.hover,\n active = _ref.active,\n circleSize = _ref.circleSize,\n circleSpacing = _ref.circleSpacing;\n\n var styles = reactCSS({\n 'default': {\n swatch: {\n width: circleSize,\n height: circleSize,\n marginRight: circleSpacing,\n marginBottom: circleSpacing,\n transform: 'scale(1)',\n transition: '100ms transform ease'\n },\n Swatch: {\n borderRadius: '50%',\n background: 'transparent',\n boxShadow: 'inset 0 0 0 ' + (circleSize / 2 + 1) + 'px ' + color,\n transition: '100ms box-shadow ease'\n }\n },\n 'hover': {\n swatch: {\n transform: 'scale(1.2)'\n }\n },\n 'active': {\n Swatch: {\n boxShadow: 'inset 0 0 0 3px ' + color\n }\n }\n }, { hover: hover, active: active });\n\n return React.createElement(\n 'div',\n { style: styles.swatch },\n React.createElement(Swatch, {\n style: styles.Swatch,\n color: color,\n onClick: onClick,\n onHover: onSwatchHover,\n focusStyle: { boxShadow: styles.Swatch.boxShadow + ', 0 0 5px ' + color }\n })\n );\n};\n\nCircleSwatch.defaultProps = {\n circleSize: 28,\n circleSpacing: 14\n};\n\nexport default handleHover(CircleSwatch);","import React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport map from 'lodash-es/map';\nimport merge from 'lodash-es/merge';\nimport * as material from 'material-colors';\n\nimport { ColorWrap } from '../common';\nimport CircleSwatch from './CircleSwatch';\n\nexport var Circle = function Circle(_ref) {\n var width = _ref.width,\n onChange = _ref.onChange,\n onSwatchHover = _ref.onSwatchHover,\n colors = _ref.colors,\n hex = _ref.hex,\n circleSize = _ref.circleSize,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n circleSpacing = _ref.circleSpacing,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS(merge({\n 'default': {\n card: {\n width: width,\n display: 'flex',\n flexWrap: 'wrap',\n marginRight: -circleSpacing,\n marginBottom: -circleSpacing\n }\n }\n }, passedStyles));\n\n var handleChange = function handleChange(hexCode, e) {\n return onChange({ hex: hexCode, source: 'hex' }, e);\n };\n\n return React.createElement(\n 'div',\n { style: styles.card, className: 'circle-picker ' + className },\n map(colors, function (c) {\n return React.createElement(CircleSwatch, {\n key: c,\n color: c,\n onClick: handleChange,\n onSwatchHover: onSwatchHover,\n active: hex === c.toLowerCase(),\n circleSize: circleSize,\n circleSpacing: circleSpacing\n });\n })\n );\n};\n\nCircle.propTypes = {\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n circleSize: PropTypes.number,\n circleSpacing: PropTypes.number,\n styles: PropTypes.object\n};\n\nCircle.defaultProps = {\n width: 252,\n circleSize: 28,\n circleSpacing: 14,\n colors: [material.red['500'], material.pink['500'], material.purple['500'], material.deepPurple['500'], material.indigo['500'], material.blue['500'], material.lightBlue['500'], material.cyan['500'], material.teal['500'], material.green['500'], material.lightGreen['500'], material.lime['500'], material.yellow['500'], material.amber['500'], material.orange['500'], material.deepOrange['500'], material.brown['500'], material.blueGrey['500']],\n styles: {}\n};\n\nexport default ColorWrap(Circle);","/**\n * Checks if `value` is `undefined`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is `undefined`, else `false`.\n * @example\n *\n * _.isUndefined(void 0);\n * // => true\n *\n * _.isUndefined(null);\n * // => false\n */\nfunction isUndefined(value) {\n return value === undefined;\n}\n\nexport default isUndefined;\n","var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\n/* eslint-disable react/no-did-mount-set-state, no-param-reassign */\n\nimport React from 'react';\nimport reactCSS from 'reactcss';\nimport * as color from '../../helpers/color';\nimport isUndefined from 'lodash-es/isUndefined';\n\nimport { EditableInput } from '../common';\nimport UnfoldMoreHorizontalIcon from '@icons/material/UnfoldMoreHorizontalIcon';\n\nexport var ChromeFields = function (_React$Component) {\n _inherits(ChromeFields, _React$Component);\n\n function ChromeFields(props) {\n _classCallCheck(this, ChromeFields);\n\n var _this = _possibleConstructorReturn(this, (ChromeFields.__proto__ || Object.getPrototypeOf(ChromeFields)).call(this));\n\n _this.toggleViews = function () {\n if (_this.state.view === 'hex') {\n _this.setState({ view: 'rgb' });\n } else if (_this.state.view === 'rgb') {\n _this.setState({ view: 'hsl' });\n } else if (_this.state.view === 'hsl') {\n if (_this.props.hsl.a === 1) {\n _this.setState({ view: 'hex' });\n } else {\n _this.setState({ view: 'rgb' });\n }\n }\n };\n\n _this.handleChange = function (data, e) {\n if (data.hex) {\n color.isValidHex(data.hex) && _this.props.onChange({\n hex: data.hex,\n source: 'hex'\n }, e);\n } else if (data.r || data.g || data.b) {\n _this.props.onChange({\n r: data.r || _this.props.rgb.r,\n g: data.g || _this.props.rgb.g,\n b: data.b || _this.props.rgb.b,\n source: 'rgb'\n }, e);\n } else if (data.a) {\n if (data.a < 0) {\n data.a = 0;\n } else if (data.a > 1) {\n data.a = 1;\n }\n\n _this.props.onChange({\n h: _this.props.hsl.h,\n s: _this.props.hsl.s,\n l: _this.props.hsl.l,\n a: Math.round(data.a * 100) / 100,\n source: 'rgb'\n }, e);\n } else if (data.h || data.s || data.l) {\n // Remove any occurances of '%'.\n if (typeof data.s === 'string' && data.s.includes('%')) {\n data.s = data.s.replace('%', '');\n }\n if (typeof data.l === 'string' && data.l.includes('%')) {\n data.l = data.l.replace('%', '');\n }\n\n // We store HSL as a unit interval so we need to override the 1 input to 0.01\n if (data.s == 1) {\n data.s = 0.01;\n } else if (data.l == 1) {\n data.l = 0.01;\n }\n\n _this.props.onChange({\n h: data.h || _this.props.hsl.h,\n s: Number(!isUndefined(data.s) ? data.s : _this.props.hsl.s),\n l: Number(!isUndefined(data.l) ? data.l : _this.props.hsl.l),\n source: 'hsl'\n }, e);\n }\n };\n\n _this.showHighlight = function (e) {\n e.currentTarget.style.background = '#eee';\n };\n\n _this.hideHighlight = function (e) {\n e.currentTarget.style.background = 'transparent';\n };\n\n if (props.hsl.a !== 1 && props.view === \"hex\") {\n _this.state = {\n view: \"rgb\"\n };\n } else {\n _this.state = {\n view: props.view\n };\n }\n return _this;\n }\n\n _createClass(ChromeFields, [{\n key: 'render',\n value: function render() {\n var _this2 = this;\n\n var styles = reactCSS({\n 'default': {\n wrap: {\n paddingTop: '16px',\n display: 'flex'\n },\n fields: {\n flex: '1',\n display: 'flex',\n marginLeft: '-6px'\n },\n field: {\n paddingLeft: '6px',\n width: '100%'\n },\n alpha: {\n paddingLeft: '6px',\n width: '100%'\n },\n toggle: {\n width: '32px',\n textAlign: 'right',\n position: 'relative'\n },\n icon: {\n marginRight: '-4px',\n marginTop: '12px',\n cursor: 'pointer',\n position: 'relative'\n },\n iconHighlight: {\n position: 'absolute',\n width: '24px',\n height: '28px',\n background: '#eee',\n borderRadius: '4px',\n top: '10px',\n left: '12px',\n display: 'none'\n },\n input: {\n fontSize: '11px',\n color: '#333',\n width: '100%',\n borderRadius: '2px',\n border: 'none',\n boxShadow: 'inset 0 0 0 1px #dadada',\n height: '21px',\n textAlign: 'center'\n },\n label: {\n textTransform: 'uppercase',\n fontSize: '11px',\n lineHeight: '11px',\n color: '#969696',\n textAlign: 'center',\n display: 'block',\n marginTop: '12px'\n },\n svg: {\n fill: '#333',\n width: '24px',\n height: '24px',\n border: '1px transparent solid',\n borderRadius: '5px'\n }\n },\n 'disableAlpha': {\n alpha: {\n display: 'none'\n }\n }\n }, this.props, this.state);\n\n var fields = void 0;\n if (this.state.view === 'hex') {\n fields = React.createElement(\n 'div',\n { style: styles.fields, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.field },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'hex', value: this.props.hex,\n onChange: this.handleChange\n })\n )\n );\n } else if (this.state.view === 'rgb') {\n fields = React.createElement(\n 'div',\n { style: styles.fields, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.field },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'r',\n value: this.props.rgb.r,\n onChange: this.handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.field },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'g',\n value: this.props.rgb.g,\n onChange: this.handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.field },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'b',\n value: this.props.rgb.b,\n onChange: this.handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.alpha },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'a',\n value: this.props.rgb.a,\n arrowOffset: 0.01,\n onChange: this.handleChange\n })\n )\n );\n } else if (this.state.view === 'hsl') {\n fields = React.createElement(\n 'div',\n { style: styles.fields, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.field },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'h',\n value: Math.round(this.props.hsl.h),\n onChange: this.handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.field },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 's',\n value: Math.round(this.props.hsl.s * 100) + '%',\n onChange: this.handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.field },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'l',\n value: Math.round(this.props.hsl.l * 100) + '%',\n onChange: this.handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.alpha },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'a',\n value: this.props.hsl.a,\n arrowOffset: 0.01,\n onChange: this.handleChange\n })\n )\n );\n }\n\n return React.createElement(\n 'div',\n { style: styles.wrap, className: 'flexbox-fix' },\n fields,\n React.createElement(\n 'div',\n { style: styles.toggle },\n React.createElement(\n 'div',\n { style: styles.icon, onClick: this.toggleViews, ref: function ref(icon) {\n return _this2.icon = icon;\n } },\n React.createElement(UnfoldMoreHorizontalIcon, {\n style: styles.svg,\n onMouseOver: this.showHighlight,\n onMouseEnter: this.showHighlight,\n onMouseOut: this.hideHighlight\n })\n )\n )\n );\n }\n }], [{\n key: 'getDerivedStateFromProps',\n value: function getDerivedStateFromProps(nextProps, state) {\n if (nextProps.hsl.a !== 1 && state.view === 'hex') {\n return { view: 'rgb' };\n }\n return null;\n }\n }]);\n\n return ChromeFields;\n}(React.Component);\n\nChromeFields.defaultProps = {\n view: \"hex\"\n};\n\nexport default ChromeFields;","import React from 'react';\nimport reactCSS from 'reactcss';\n\nexport var ChromePointer = function ChromePointer() {\n var styles = reactCSS({\n 'default': {\n picker: {\n width: '12px',\n height: '12px',\n borderRadius: '6px',\n transform: 'translate(-6px, -1px)',\n backgroundColor: 'rgb(248, 248, 248)',\n boxShadow: '0 1px 4px 0 rgba(0, 0, 0, 0.37)'\n }\n }\n });\n\n return React.createElement('div', { style: styles.picker });\n};\n\nexport default ChromePointer;","import React from 'react';\nimport reactCSS from 'reactcss';\n\nexport var ChromePointerCircle = function ChromePointerCircle() {\n var styles = reactCSS({\n 'default': {\n picker: {\n width: '12px',\n height: '12px',\n borderRadius: '6px',\n boxShadow: 'inset 0 0 0 1px #fff',\n transform: 'translate(-6px, -6px)'\n }\n }\n });\n\n return React.createElement('div', { style: styles.picker });\n};\n\nexport default ChromePointerCircle;","import React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport merge from 'lodash-es/merge';\n\nimport { ColorWrap, Saturation, Hue, Alpha, Checkboard } from '../common';\nimport ChromeFields from './ChromeFields';\nimport ChromePointer from './ChromePointer';\nimport ChromePointerCircle from './ChromePointerCircle';\n\nexport var Chrome = function Chrome(_ref) {\n var width = _ref.width,\n onChange = _ref.onChange,\n disableAlpha = _ref.disableAlpha,\n rgb = _ref.rgb,\n hsl = _ref.hsl,\n hsv = _ref.hsv,\n hex = _ref.hex,\n renderers = _ref.renderers,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className,\n defaultView = _ref.defaultView;\n\n var styles = reactCSS(merge({\n 'default': {\n picker: {\n width: width,\n background: '#fff',\n borderRadius: '2px',\n boxShadow: '0 0 2px rgba(0,0,0,.3), 0 4px 8px rgba(0,0,0,.3)',\n boxSizing: 'initial',\n fontFamily: 'Menlo'\n },\n saturation: {\n width: '100%',\n paddingBottom: '55%',\n position: 'relative',\n borderRadius: '2px 2px 0 0',\n overflow: 'hidden'\n },\n Saturation: {\n radius: '2px 2px 0 0'\n },\n body: {\n padding: '16px 16px 12px'\n },\n controls: {\n display: 'flex'\n },\n color: {\n width: '32px'\n },\n swatch: {\n marginTop: '6px',\n width: '16px',\n height: '16px',\n borderRadius: '8px',\n position: 'relative',\n overflow: 'hidden'\n },\n active: {\n absolute: '0px 0px 0px 0px',\n borderRadius: '8px',\n boxShadow: 'inset 0 0 0 1px rgba(0,0,0,.1)',\n background: 'rgba(' + rgb.r + ', ' + rgb.g + ', ' + rgb.b + ', ' + rgb.a + ')',\n zIndex: '2'\n },\n toggles: {\n flex: '1'\n },\n hue: {\n height: '10px',\n position: 'relative',\n marginBottom: '8px'\n },\n Hue: {\n radius: '2px'\n },\n alpha: {\n height: '10px',\n position: 'relative'\n },\n Alpha: {\n radius: '2px'\n }\n },\n 'disableAlpha': {\n color: {\n width: '22px'\n },\n alpha: {\n display: 'none'\n },\n hue: {\n marginBottom: '0px'\n },\n swatch: {\n width: '10px',\n height: '10px',\n marginTop: '0px'\n }\n }\n }, passedStyles), { disableAlpha: disableAlpha });\n\n return React.createElement(\n 'div',\n { style: styles.picker, className: 'chrome-picker ' + className },\n React.createElement(\n 'div',\n { style: styles.saturation },\n React.createElement(Saturation, {\n style: styles.Saturation,\n hsl: hsl,\n hsv: hsv,\n pointer: ChromePointerCircle,\n onChange: onChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.body },\n React.createElement(\n 'div',\n { style: styles.controls, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.color },\n React.createElement(\n 'div',\n { style: styles.swatch },\n React.createElement('div', { style: styles.active }),\n React.createElement(Checkboard, { renderers: renderers })\n )\n ),\n React.createElement(\n 'div',\n { style: styles.toggles },\n React.createElement(\n 'div',\n { style: styles.hue },\n React.createElement(Hue, {\n style: styles.Hue,\n hsl: hsl,\n pointer: ChromePointer,\n onChange: onChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.alpha },\n React.createElement(Alpha, {\n style: styles.Alpha,\n rgb: rgb,\n hsl: hsl,\n pointer: ChromePointer,\n renderers: renderers,\n onChange: onChange\n })\n )\n )\n ),\n React.createElement(ChromeFields, {\n rgb: rgb,\n hsl: hsl,\n hex: hex,\n view: defaultView,\n onChange: onChange,\n disableAlpha: disableAlpha\n })\n )\n );\n};\n\nChrome.propTypes = {\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n disableAlpha: PropTypes.bool,\n styles: PropTypes.object,\n defaultView: PropTypes.oneOf([\"hex\", \"rgb\", \"hsl\"])\n};\n\nChrome.defaultProps = {\n width: 225,\n disableAlpha: false,\n styles: {}\n};\n\nexport default ColorWrap(Chrome);","import React from 'react';\nimport reactCSS from 'reactcss';\nimport * as colorUtils from '../../helpers/color';\n\nimport { Swatch } from '../common';\n\nexport var CompactColor = function CompactColor(_ref) {\n var color = _ref.color,\n _ref$onClick = _ref.onClick,\n onClick = _ref$onClick === undefined ? function () {} : _ref$onClick,\n onSwatchHover = _ref.onSwatchHover,\n active = _ref.active;\n\n var styles = reactCSS({\n 'default': {\n color: {\n background: color,\n width: '15px',\n height: '15px',\n float: 'left',\n marginRight: '5px',\n marginBottom: '5px',\n position: 'relative',\n cursor: 'pointer'\n },\n dot: {\n absolute: '5px 5px 5px 5px',\n background: colorUtils.getContrastingColor(color),\n borderRadius: '50%',\n opacity: '0'\n }\n },\n 'active': {\n dot: {\n opacity: '1'\n }\n },\n 'color-#FFFFFF': {\n color: {\n boxShadow: 'inset 0 0 0 1px #ddd'\n },\n dot: {\n background: '#000'\n }\n },\n 'transparent': {\n dot: {\n background: '#000'\n }\n }\n }, { active: active, 'color-#FFFFFF': color === '#FFFFFF', 'transparent': color === 'transparent' });\n\n return React.createElement(\n Swatch,\n {\n style: styles.color,\n color: color,\n onClick: onClick,\n onHover: onSwatchHover,\n focusStyle: { boxShadow: '0 0 4px ' + color }\n },\n React.createElement('div', { style: styles.dot })\n );\n};\n\nexport default CompactColor;","import React from 'react';\nimport reactCSS from 'reactcss';\n\nimport { EditableInput } from '../common';\n\nexport var CompactFields = function CompactFields(_ref) {\n var hex = _ref.hex,\n rgb = _ref.rgb,\n onChange = _ref.onChange;\n\n var styles = reactCSS({\n 'default': {\n fields: {\n display: 'flex',\n paddingBottom: '6px',\n paddingRight: '5px',\n position: 'relative'\n },\n active: {\n position: 'absolute',\n top: '6px',\n left: '5px',\n height: '9px',\n width: '9px',\n background: hex\n },\n HEXwrap: {\n flex: '6',\n position: 'relative'\n },\n HEXinput: {\n width: '80%',\n padding: '0px',\n paddingLeft: '20%',\n border: 'none',\n outline: 'none',\n background: 'none',\n fontSize: '12px',\n color: '#333',\n height: '16px'\n },\n HEXlabel: {\n display: 'none'\n },\n RGBwrap: {\n flex: '3',\n position: 'relative'\n },\n RGBinput: {\n width: '70%',\n padding: '0px',\n paddingLeft: '30%',\n border: 'none',\n outline: 'none',\n background: 'none',\n fontSize: '12px',\n color: '#333',\n height: '16px'\n },\n RGBlabel: {\n position: 'absolute',\n top: '3px',\n left: '0px',\n lineHeight: '16px',\n textTransform: 'uppercase',\n fontSize: '12px',\n color: '#999'\n }\n }\n });\n\n var handleChange = function handleChange(data, e) {\n if (data.r || data.g || data.b) {\n onChange({\n r: data.r || rgb.r,\n g: data.g || rgb.g,\n b: data.b || rgb.b,\n source: 'rgb'\n }, e);\n } else {\n onChange({\n hex: data.hex,\n source: 'hex'\n }, e);\n }\n };\n\n return React.createElement(\n 'div',\n { style: styles.fields, className: 'flexbox-fix' },\n React.createElement('div', { style: styles.active }),\n React.createElement(EditableInput, {\n style: { wrap: styles.HEXwrap, input: styles.HEXinput, label: styles.HEXlabel },\n label: 'hex',\n value: hex,\n onChange: handleChange\n }),\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'r',\n value: rgb.r,\n onChange: handleChange\n }),\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'g',\n value: rgb.g,\n onChange: handleChange\n }),\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'b',\n value: rgb.b,\n onChange: handleChange\n })\n );\n};\n\nexport default CompactFields;","import React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport map from 'lodash-es/map';\nimport merge from 'lodash-es/merge';\nimport * as color from '../../helpers/color';\n\nimport { ColorWrap, Raised } from '../common';\nimport CompactColor from './CompactColor';\nimport CompactFields from './CompactFields';\n\nexport var Compact = function Compact(_ref) {\n var onChange = _ref.onChange,\n onSwatchHover = _ref.onSwatchHover,\n colors = _ref.colors,\n hex = _ref.hex,\n rgb = _ref.rgb,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS(merge({\n 'default': {\n Compact: {\n background: '#f6f6f6',\n radius: '4px'\n },\n compact: {\n paddingTop: '5px',\n paddingLeft: '5px',\n boxSizing: 'initial',\n width: '240px'\n },\n clear: {\n clear: 'both'\n }\n }\n }, passedStyles));\n\n var handleChange = function handleChange(data, e) {\n if (data.hex) {\n color.isValidHex(data.hex) && onChange({\n hex: data.hex,\n source: 'hex'\n }, e);\n } else {\n onChange(data, e);\n }\n };\n\n return React.createElement(\n Raised,\n { style: styles.Compact, styles: passedStyles },\n React.createElement(\n 'div',\n { style: styles.compact, className: 'compact-picker ' + className },\n React.createElement(\n 'div',\n null,\n map(colors, function (c) {\n return React.createElement(CompactColor, {\n key: c,\n color: c,\n active: c.toLowerCase() === hex,\n onClick: handleChange,\n onSwatchHover: onSwatchHover\n });\n }),\n React.createElement('div', { style: styles.clear })\n ),\n React.createElement(CompactFields, { hex: hex, rgb: rgb, onChange: handleChange })\n )\n );\n};\n\nCompact.propTypes = {\n colors: PropTypes.arrayOf(PropTypes.string),\n styles: PropTypes.object\n};\n\nCompact.defaultProps = {\n colors: ['#4D4D4D', '#999999', '#FFFFFF', '#F44E3B', '#FE9200', '#FCDC00', '#DBDF00', '#A4DD00', '#68CCCA', '#73D8FF', '#AEA1FF', '#FDA1FF', '#333333', '#808080', '#cccccc', '#D33115', '#E27300', '#FCC400', '#B0BC00', '#68BC00', '#16A5A5', '#009CE0', '#7B64FF', '#FA28FF', '#000000', '#666666', '#B3B3B3', '#9F0500', '#C45100', '#FB9E00', '#808900', '#194D33', '#0C797D', '#0062B1', '#653294', '#AB149E'],\n styles: {}\n};\n\nexport default ColorWrap(Compact);","import React from 'react';\nimport reactCSS, { handleHover } from 'reactcss';\n\nimport { Swatch } from '../common';\n\nexport var GithubSwatch = function GithubSwatch(_ref) {\n var hover = _ref.hover,\n color = _ref.color,\n onClick = _ref.onClick,\n onSwatchHover = _ref.onSwatchHover;\n\n var hoverSwatch = {\n position: 'relative',\n zIndex: '2',\n outline: '2px solid #fff',\n boxShadow: '0 0 5px 2px rgba(0,0,0,0.25)'\n };\n\n var styles = reactCSS({\n 'default': {\n swatch: {\n width: '25px',\n height: '25px',\n fontSize: '0'\n }\n },\n 'hover': {\n swatch: hoverSwatch\n }\n }, { hover: hover });\n\n return React.createElement(\n 'div',\n { style: styles.swatch },\n React.createElement(Swatch, {\n color: color,\n onClick: onClick,\n onHover: onSwatchHover,\n focusStyle: hoverSwatch\n })\n );\n};\n\nexport default handleHover(GithubSwatch);","import React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport map from 'lodash-es/map';\nimport merge from 'lodash-es/merge';\n\nimport { ColorWrap } from '../common';\nimport GithubSwatch from './GithubSwatch';\n\nexport var Github = function Github(_ref) {\n var width = _ref.width,\n colors = _ref.colors,\n onChange = _ref.onChange,\n onSwatchHover = _ref.onSwatchHover,\n triangle = _ref.triangle,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS(merge({\n 'default': {\n card: {\n width: width,\n background: '#fff',\n border: '1px solid rgba(0,0,0,0.2)',\n boxShadow: '0 3px 12px rgba(0,0,0,0.15)',\n borderRadius: '4px',\n position: 'relative',\n padding: '5px',\n display: 'flex',\n flexWrap: 'wrap'\n },\n triangle: {\n position: 'absolute',\n border: '7px solid transparent',\n borderBottomColor: '#fff'\n },\n triangleShadow: {\n position: 'absolute',\n border: '8px solid transparent',\n borderBottomColor: 'rgba(0,0,0,0.15)'\n }\n },\n 'hide-triangle': {\n triangle: {\n display: 'none'\n },\n triangleShadow: {\n display: 'none'\n }\n },\n 'top-left-triangle': {\n triangle: {\n top: '-14px',\n left: '10px'\n },\n triangleShadow: {\n top: '-16px',\n left: '9px'\n }\n },\n 'top-right-triangle': {\n triangle: {\n top: '-14px',\n right: '10px'\n },\n triangleShadow: {\n top: '-16px',\n right: '9px'\n }\n },\n 'bottom-left-triangle': {\n triangle: {\n top: '35px',\n left: '10px',\n transform: 'rotate(180deg)'\n },\n triangleShadow: {\n top: '37px',\n left: '9px',\n transform: 'rotate(180deg)'\n }\n },\n 'bottom-right-triangle': {\n triangle: {\n top: '35px',\n right: '10px',\n transform: 'rotate(180deg)'\n },\n triangleShadow: {\n top: '37px',\n right: '9px',\n transform: 'rotate(180deg)'\n }\n }\n }, passedStyles), {\n 'hide-triangle': triangle === 'hide',\n 'top-left-triangle': triangle === 'top-left',\n 'top-right-triangle': triangle === 'top-right',\n 'bottom-left-triangle': triangle === 'bottom-left',\n 'bottom-right-triangle': triangle === 'bottom-right'\n });\n\n var handleChange = function handleChange(hex, e) {\n return onChange({ hex: hex, source: 'hex' }, e);\n };\n\n return React.createElement(\n 'div',\n { style: styles.card, className: 'github-picker ' + className },\n React.createElement('div', { style: styles.triangleShadow }),\n React.createElement('div', { style: styles.triangle }),\n map(colors, function (c) {\n return React.createElement(GithubSwatch, {\n color: c,\n key: c,\n onClick: handleChange,\n onSwatchHover: onSwatchHover\n });\n })\n );\n};\n\nGithub.propTypes = {\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n colors: PropTypes.arrayOf(PropTypes.string),\n triangle: PropTypes.oneOf(['hide', 'top-left', 'top-right', 'bottom-left', 'bottom-right']),\n styles: PropTypes.object\n};\n\nGithub.defaultProps = {\n width: 200,\n colors: ['#B80000', '#DB3E00', '#FCCB00', '#008B02', '#006B76', '#1273DE', '#004DCF', '#5300EB', '#EB9694', '#FAD0C3', '#FEF3BD', '#C1E1C5', '#BEDADC', '#C4DEF6', '#BED3F3', '#D4C4FB'],\n triangle: 'top-left',\n styles: {}\n};\n\nexport default ColorWrap(Github);","import React from 'react';\nimport reactCSS from 'reactcss';\n\nexport var SliderPointer = function SliderPointer(_ref) {\n var direction = _ref.direction;\n\n var styles = reactCSS({\n 'default': {\n picker: {\n width: '18px',\n height: '18px',\n borderRadius: '50%',\n transform: 'translate(-9px, -1px)',\n backgroundColor: 'rgb(248, 248, 248)',\n boxShadow: '0 1px 4px 0 rgba(0, 0, 0, 0.37)'\n }\n },\n 'vertical': {\n picker: {\n transform: 'translate(-3px, -9px)'\n }\n }\n }, { vertical: direction === 'vertical' });\n\n return React.createElement('div', { style: styles.picker });\n};\n\nexport default SliderPointer;","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport merge from 'lodash-es/merge';\n\nimport { ColorWrap, Hue } from '../common';\nimport HuePointer from './HuePointer';\n\nexport var HuePicker = function HuePicker(_ref) {\n var width = _ref.width,\n height = _ref.height,\n onChange = _ref.onChange,\n hsl = _ref.hsl,\n direction = _ref.direction,\n pointer = _ref.pointer,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS(merge({\n 'default': {\n picker: {\n position: 'relative',\n width: width,\n height: height\n },\n hue: {\n radius: '2px'\n }\n }\n }, passedStyles));\n\n // Overwrite to provide pure hue color\n var handleChange = function handleChange(data) {\n return onChange({ a: 1, h: data.h, l: 0.5, s: 1 });\n };\n\n return React.createElement(\n 'div',\n { style: styles.picker, className: 'hue-picker ' + className },\n React.createElement(Hue, _extends({}, styles.hue, {\n hsl: hsl,\n pointer: pointer,\n onChange: handleChange,\n direction: direction\n }))\n );\n};\n\nHuePicker.propTypes = {\n styles: PropTypes.object\n};\nHuePicker.defaultProps = {\n width: '316px',\n height: '16px',\n direction: 'horizontal',\n pointer: HuePointer,\n styles: {}\n};\n\nexport default ColorWrap(HuePicker);","import React from 'react';\nimport reactCSS from 'reactcss';\nimport merge from 'lodash-es/merge';\nimport * as color from '../../helpers/color';\n\nimport { ColorWrap, EditableInput, Raised } from '../common';\n\nexport var Material = function Material(_ref) {\n var onChange = _ref.onChange,\n hex = _ref.hex,\n rgb = _ref.rgb,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS(merge({\n 'default': {\n material: {\n width: '98px',\n height: '98px',\n padding: '16px',\n fontFamily: 'Roboto'\n },\n HEXwrap: {\n position: 'relative'\n },\n HEXinput: {\n width: '100%',\n marginTop: '12px',\n fontSize: '15px',\n color: '#333',\n padding: '0px',\n border: '0px',\n borderBottom: '2px solid ' + hex,\n outline: 'none',\n height: '30px'\n },\n HEXlabel: {\n position: 'absolute',\n top: '0px',\n left: '0px',\n fontSize: '11px',\n color: '#999999',\n textTransform: 'capitalize'\n },\n Hex: {\n style: {}\n },\n RGBwrap: {\n position: 'relative'\n },\n RGBinput: {\n width: '100%',\n marginTop: '12px',\n fontSize: '15px',\n color: '#333',\n padding: '0px',\n border: '0px',\n borderBottom: '1px solid #eee',\n outline: 'none',\n height: '30px'\n },\n RGBlabel: {\n position: 'absolute',\n top: '0px',\n left: '0px',\n fontSize: '11px',\n color: '#999999',\n textTransform: 'capitalize'\n },\n split: {\n display: 'flex',\n marginRight: '-10px',\n paddingTop: '11px'\n },\n third: {\n flex: '1',\n paddingRight: '10px'\n }\n }\n }, passedStyles));\n\n var handleChange = function handleChange(data, e) {\n if (data.hex) {\n color.isValidHex(data.hex) && onChange({\n hex: data.hex,\n source: 'hex'\n }, e);\n } else if (data.r || data.g || data.b) {\n onChange({\n r: data.r || rgb.r,\n g: data.g || rgb.g,\n b: data.b || rgb.b,\n source: 'rgb'\n }, e);\n }\n };\n\n return React.createElement(\n Raised,\n { styles: passedStyles },\n React.createElement(\n 'div',\n { style: styles.material, className: 'material-picker ' + className },\n React.createElement(EditableInput, {\n style: { wrap: styles.HEXwrap, input: styles.HEXinput, label: styles.HEXlabel },\n label: 'hex',\n value: hex,\n onChange: handleChange\n }),\n React.createElement(\n 'div',\n { style: styles.split, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.third },\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'r', value: rgb.r,\n onChange: handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.third },\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'g',\n value: rgb.g,\n onChange: handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.third },\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'b',\n value: rgb.b,\n onChange: handleChange\n })\n )\n )\n )\n );\n};\n\nexport default ColorWrap(Material);","import React from 'react';\nimport reactCSS from 'reactcss';\nimport * as color from '../../helpers/color';\n\nimport { EditableInput } from '../common';\n\nexport var PhotoshopPicker = function PhotoshopPicker(_ref) {\n var onChange = _ref.onChange,\n rgb = _ref.rgb,\n hsv = _ref.hsv,\n hex = _ref.hex;\n\n var styles = reactCSS({\n 'default': {\n fields: {\n paddingTop: '5px',\n paddingBottom: '9px',\n width: '80px',\n position: 'relative'\n },\n divider: {\n height: '5px'\n },\n RGBwrap: {\n position: 'relative'\n },\n RGBinput: {\n marginLeft: '40%',\n width: '40%',\n height: '18px',\n border: '1px solid #888888',\n boxShadow: 'inset 0 1px 1px rgba(0,0,0,.1), 0 1px 0 0 #ECECEC',\n marginBottom: '5px',\n fontSize: '13px',\n paddingLeft: '3px',\n marginRight: '10px'\n },\n RGBlabel: {\n left: '0px',\n top: '0px',\n width: '34px',\n textTransform: 'uppercase',\n fontSize: '13px',\n height: '18px',\n lineHeight: '22px',\n position: 'absolute'\n },\n HEXwrap: {\n position: 'relative'\n },\n HEXinput: {\n marginLeft: '20%',\n width: '80%',\n height: '18px',\n border: '1px solid #888888',\n boxShadow: 'inset 0 1px 1px rgba(0,0,0,.1), 0 1px 0 0 #ECECEC',\n marginBottom: '6px',\n fontSize: '13px',\n paddingLeft: '3px'\n },\n HEXlabel: {\n position: 'absolute',\n top: '0px',\n left: '0px',\n width: '14px',\n textTransform: 'uppercase',\n fontSize: '13px',\n height: '18px',\n lineHeight: '22px'\n },\n fieldSymbols: {\n position: 'absolute',\n top: '5px',\n right: '-7px',\n fontSize: '13px'\n },\n symbol: {\n height: '20px',\n lineHeight: '22px',\n paddingBottom: '7px'\n }\n }\n });\n\n var handleChange = function handleChange(data, e) {\n if (data['#']) {\n color.isValidHex(data['#']) && onChange({\n hex: data['#'],\n source: 'hex'\n }, e);\n } else if (data.r || data.g || data.b) {\n onChange({\n r: data.r || rgb.r,\n g: data.g || rgb.g,\n b: data.b || rgb.b,\n source: 'rgb'\n }, e);\n } else if (data.h || data.s || data.v) {\n onChange({\n h: data.h || hsv.h,\n s: data.s || hsv.s,\n v: data.v || hsv.v,\n source: 'hsv'\n }, e);\n }\n };\n\n return React.createElement(\n 'div',\n { style: styles.fields },\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'h',\n value: Math.round(hsv.h),\n onChange: handleChange\n }),\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 's',\n value: Math.round(hsv.s * 100),\n onChange: handleChange\n }),\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'v',\n value: Math.round(hsv.v * 100),\n onChange: handleChange\n }),\n React.createElement('div', { style: styles.divider }),\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'r',\n value: rgb.r,\n onChange: handleChange\n }),\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'g',\n value: rgb.g,\n onChange: handleChange\n }),\n React.createElement(EditableInput, {\n style: { wrap: styles.RGBwrap, input: styles.RGBinput, label: styles.RGBlabel },\n label: 'b',\n value: rgb.b,\n onChange: handleChange\n }),\n React.createElement('div', { style: styles.divider }),\n React.createElement(EditableInput, {\n style: { wrap: styles.HEXwrap, input: styles.HEXinput, label: styles.HEXlabel },\n label: '#',\n value: hex.replace('#', ''),\n onChange: handleChange\n }),\n React.createElement(\n 'div',\n { style: styles.fieldSymbols },\n React.createElement(\n 'div',\n { style: styles.symbol },\n '\\xB0'\n ),\n React.createElement(\n 'div',\n { style: styles.symbol },\n '%'\n ),\n React.createElement(\n 'div',\n { style: styles.symbol },\n '%'\n )\n )\n );\n};\n\nexport default PhotoshopPicker;","import React from 'react';\nimport reactCSS from 'reactcss';\n\nexport var PhotoshopPointerCircle = function PhotoshopPointerCircle(_ref) {\n var hsl = _ref.hsl;\n\n var styles = reactCSS({\n 'default': {\n picker: {\n width: '12px',\n height: '12px',\n borderRadius: '6px',\n boxShadow: 'inset 0 0 0 1px #fff',\n transform: 'translate(-6px, -6px)'\n }\n },\n 'black-outline': {\n picker: {\n boxShadow: 'inset 0 0 0 1px #000'\n }\n }\n }, { 'black-outline': hsl.l > 0.5 });\n\n return React.createElement('div', { style: styles.picker });\n};\n\nexport default PhotoshopPointerCircle;","import React from 'react';\nimport reactCSS from 'reactcss';\n\nexport var PhotoshopPointerCircle = function PhotoshopPointerCircle() {\n var styles = reactCSS({\n 'default': {\n triangle: {\n width: 0,\n height: 0,\n borderStyle: 'solid',\n borderWidth: '4px 0 4px 6px',\n borderColor: 'transparent transparent transparent #fff',\n position: 'absolute',\n top: '1px',\n left: '1px'\n },\n triangleBorder: {\n width: 0,\n height: 0,\n borderStyle: 'solid',\n borderWidth: '5px 0 5px 8px',\n borderColor: 'transparent transparent transparent #555'\n },\n\n left: {\n Extend: 'triangleBorder',\n transform: 'translate(-13px, -4px)'\n },\n leftInside: {\n Extend: 'triangle',\n transform: 'translate(-8px, -5px)'\n },\n\n right: {\n Extend: 'triangleBorder',\n transform: 'translate(20px, -14px) rotate(180deg)'\n },\n rightInside: {\n Extend: 'triangle',\n transform: 'translate(-8px, -5px)'\n }\n }\n });\n\n return React.createElement(\n 'div',\n { style: styles.pointer },\n React.createElement(\n 'div',\n { style: styles.left },\n React.createElement('div', { style: styles.leftInside })\n ),\n React.createElement(\n 'div',\n { style: styles.right },\n React.createElement('div', { style: styles.rightInside })\n )\n );\n};\n\nexport default PhotoshopPointerCircle;","import React from 'react';\nimport reactCSS from 'reactcss';\n\nexport var PhotoshopButton = function PhotoshopButton(_ref) {\n var onClick = _ref.onClick,\n label = _ref.label,\n children = _ref.children,\n active = _ref.active;\n\n var styles = reactCSS({\n 'default': {\n button: {\n backgroundImage: 'linear-gradient(-180deg, #FFFFFF 0%, #E6E6E6 100%)',\n border: '1px solid #878787',\n borderRadius: '2px',\n height: '20px',\n boxShadow: '0 1px 0 0 #EAEAEA',\n fontSize: '14px',\n color: '#000',\n lineHeight: '20px',\n textAlign: 'center',\n marginBottom: '10px',\n cursor: 'pointer'\n }\n },\n 'active': {\n button: {\n boxShadow: '0 0 0 1px #878787'\n }\n }\n }, { active: active });\n\n return React.createElement(\n 'div',\n { style: styles.button, onClick: onClick },\n label || children\n );\n};\n\nexport default PhotoshopButton;","import React from 'react';\nimport reactCSS from 'reactcss';\n\nexport var PhotoshopPreviews = function PhotoshopPreviews(_ref) {\n var rgb = _ref.rgb,\n currentColor = _ref.currentColor;\n\n var styles = reactCSS({\n 'default': {\n swatches: {\n border: '1px solid #B3B3B3',\n borderBottom: '1px solid #F0F0F0',\n marginBottom: '2px',\n marginTop: '1px'\n },\n new: {\n height: '34px',\n background: 'rgb(' + rgb.r + ',' + rgb.g + ', ' + rgb.b + ')',\n boxShadow: 'inset 1px 0 0 #000, inset -1px 0 0 #000, inset 0 1px 0 #000'\n },\n current: {\n height: '34px',\n background: currentColor,\n boxShadow: 'inset 1px 0 0 #000, inset -1px 0 0 #000, inset 0 -1px 0 #000'\n },\n label: {\n fontSize: '14px',\n color: '#000',\n textAlign: 'center'\n }\n }\n });\n\n return React.createElement(\n 'div',\n null,\n React.createElement(\n 'div',\n { style: styles.label },\n 'new'\n ),\n React.createElement(\n 'div',\n { style: styles.swatches },\n React.createElement('div', { style: styles.new }),\n React.createElement('div', { style: styles.current })\n ),\n React.createElement(\n 'div',\n { style: styles.label },\n 'current'\n )\n );\n};\n\nexport default PhotoshopPreviews;","var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport merge from 'lodash-es/merge';\n\nimport { ColorWrap, Saturation, Hue } from '../common';\nimport PhotoshopFields from './PhotoshopFields';\nimport PhotoshopPointerCircle from './PhotoshopPointerCircle';\nimport PhotoshopPointer from './PhotoshopPointer';\nimport PhotoshopButton from './PhotoshopButton';\nimport PhotoshopPreviews from './PhotoshopPreviews';\n\nexport var Photoshop = function (_React$Component) {\n _inherits(Photoshop, _React$Component);\n\n function Photoshop(props) {\n _classCallCheck(this, Photoshop);\n\n var _this = _possibleConstructorReturn(this, (Photoshop.__proto__ || Object.getPrototypeOf(Photoshop)).call(this));\n\n _this.state = {\n currentColor: props.hex\n };\n return _this;\n }\n\n _createClass(Photoshop, [{\n key: 'render',\n value: function render() {\n var _props = this.props,\n _props$styles = _props.styles,\n passedStyles = _props$styles === undefined ? {} : _props$styles,\n _props$className = _props.className,\n className = _props$className === undefined ? '' : _props$className;\n\n var styles = reactCSS(merge({\n 'default': {\n picker: {\n background: '#DCDCDC',\n borderRadius: '4px',\n boxShadow: '0 0 0 1px rgba(0,0,0,.25), 0 8px 16px rgba(0,0,0,.15)',\n boxSizing: 'initial',\n width: '513px'\n },\n head: {\n backgroundImage: 'linear-gradient(-180deg, #F0F0F0 0%, #D4D4D4 100%)',\n borderBottom: '1px solid #B1B1B1',\n boxShadow: 'inset 0 1px 0 0 rgba(255,255,255,.2), inset 0 -1px 0 0 rgba(0,0,0,.02)',\n height: '23px',\n lineHeight: '24px',\n borderRadius: '4px 4px 0 0',\n fontSize: '13px',\n color: '#4D4D4D',\n textAlign: 'center'\n },\n body: {\n padding: '15px 15px 0',\n display: 'flex'\n },\n saturation: {\n width: '256px',\n height: '256px',\n position: 'relative',\n border: '2px solid #B3B3B3',\n borderBottom: '2px solid #F0F0F0',\n overflow: 'hidden'\n },\n hue: {\n position: 'relative',\n height: '256px',\n width: '19px',\n marginLeft: '10px',\n border: '2px solid #B3B3B3',\n borderBottom: '2px solid #F0F0F0'\n },\n controls: {\n width: '180px',\n marginLeft: '10px'\n },\n top: {\n display: 'flex'\n },\n previews: {\n width: '60px'\n },\n actions: {\n flex: '1',\n marginLeft: '20px'\n }\n }\n }, passedStyles));\n\n return React.createElement(\n 'div',\n { style: styles.picker, className: 'photoshop-picker ' + className },\n React.createElement(\n 'div',\n { style: styles.head },\n this.props.header\n ),\n React.createElement(\n 'div',\n { style: styles.body, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.saturation },\n React.createElement(Saturation, {\n hsl: this.props.hsl,\n hsv: this.props.hsv,\n pointer: PhotoshopPointerCircle,\n onChange: this.props.onChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.hue },\n React.createElement(Hue, {\n direction: 'vertical',\n hsl: this.props.hsl,\n pointer: PhotoshopPointer,\n onChange: this.props.onChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.controls },\n React.createElement(\n 'div',\n { style: styles.top, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.previews },\n React.createElement(PhotoshopPreviews, {\n rgb: this.props.rgb,\n currentColor: this.state.currentColor\n })\n ),\n React.createElement(\n 'div',\n { style: styles.actions },\n React.createElement(PhotoshopButton, { label: 'OK', onClick: this.props.onAccept, active: true }),\n React.createElement(PhotoshopButton, { label: 'Cancel', onClick: this.props.onCancel }),\n React.createElement(PhotoshopFields, {\n onChange: this.props.onChange,\n rgb: this.props.rgb,\n hsv: this.props.hsv,\n hex: this.props.hex\n })\n )\n )\n )\n )\n );\n }\n }]);\n\n return Photoshop;\n}(React.Component);\n\nPhotoshop.propTypes = {\n header: PropTypes.string,\n styles: PropTypes.object\n};\n\nPhotoshop.defaultProps = {\n header: 'Color Picker',\n styles: {}\n};\n\nexport default ColorWrap(Photoshop);","/* eslint-disable no-param-reassign */\n\nimport React from 'react';\nimport reactCSS from 'reactcss';\nimport * as color from '../../helpers/color';\n\nimport { EditableInput } from '../common';\n\nexport var SketchFields = function SketchFields(_ref) {\n var onChange = _ref.onChange,\n rgb = _ref.rgb,\n hsl = _ref.hsl,\n hex = _ref.hex,\n disableAlpha = _ref.disableAlpha;\n\n var styles = reactCSS({\n 'default': {\n fields: {\n display: 'flex',\n paddingTop: '4px'\n },\n single: {\n flex: '1',\n paddingLeft: '6px'\n },\n alpha: {\n flex: '1',\n paddingLeft: '6px'\n },\n double: {\n flex: '2'\n },\n input: {\n width: '80%',\n padding: '4px 10% 3px',\n border: 'none',\n boxShadow: 'inset 0 0 0 1px #ccc',\n fontSize: '11px'\n },\n label: {\n display: 'block',\n textAlign: 'center',\n fontSize: '11px',\n color: '#222',\n paddingTop: '3px',\n paddingBottom: '4px',\n textTransform: 'capitalize'\n }\n },\n 'disableAlpha': {\n alpha: {\n display: 'none'\n }\n }\n }, { disableAlpha: disableAlpha });\n\n var handleChange = function handleChange(data, e) {\n if (data.hex) {\n color.isValidHex(data.hex) && onChange({\n hex: data.hex,\n source: 'hex'\n }, e);\n } else if (data.r || data.g || data.b) {\n onChange({\n r: data.r || rgb.r,\n g: data.g || rgb.g,\n b: data.b || rgb.b,\n a: rgb.a,\n source: 'rgb'\n }, e);\n } else if (data.a) {\n if (data.a < 0) {\n data.a = 0;\n } else if (data.a > 100) {\n data.a = 100;\n }\n\n data.a /= 100;\n onChange({\n h: hsl.h,\n s: hsl.s,\n l: hsl.l,\n a: data.a,\n source: 'rgb'\n }, e);\n }\n };\n\n return React.createElement(\n 'div',\n { style: styles.fields, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.double },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'hex',\n value: hex.replace('#', ''),\n onChange: handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.single },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'r',\n value: rgb.r,\n onChange: handleChange,\n dragLabel: 'true',\n dragMax: '255'\n })\n ),\n React.createElement(\n 'div',\n { style: styles.single },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'g',\n value: rgb.g,\n onChange: handleChange,\n dragLabel: 'true',\n dragMax: '255'\n })\n ),\n React.createElement(\n 'div',\n { style: styles.single },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'b',\n value: rgb.b,\n onChange: handleChange,\n dragLabel: 'true',\n dragMax: '255'\n })\n ),\n React.createElement(\n 'div',\n { style: styles.alpha },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'a',\n value: Math.round(rgb.a * 100),\n onChange: handleChange,\n dragLabel: 'true',\n dragMax: '100'\n })\n )\n );\n};\n\nexport default SketchFields;","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\n\nimport { Swatch } from '../common';\n\nexport var SketchPresetColors = function SketchPresetColors(_ref) {\n var colors = _ref.colors,\n _ref$onClick = _ref.onClick,\n onClick = _ref$onClick === undefined ? function () {} : _ref$onClick,\n onSwatchHover = _ref.onSwatchHover;\n\n var styles = reactCSS({\n 'default': {\n colors: {\n margin: '0 -10px',\n padding: '10px 0 0 10px',\n borderTop: '1px solid #eee',\n display: 'flex',\n flexWrap: 'wrap',\n position: 'relative'\n },\n swatchWrap: {\n width: '16px',\n height: '16px',\n margin: '0 10px 10px 0'\n },\n swatch: {\n borderRadius: '3px',\n boxShadow: 'inset 0 0 0 1px rgba(0,0,0,.15)'\n }\n },\n 'no-presets': {\n colors: {\n display: 'none'\n }\n }\n }, {\n 'no-presets': !colors || !colors.length\n });\n\n var handleClick = function handleClick(hex, e) {\n onClick({\n hex: hex,\n source: 'hex'\n }, e);\n };\n\n return React.createElement(\n 'div',\n { style: styles.colors, className: 'flexbox-fix' },\n colors.map(function (colorObjOrString) {\n var c = typeof colorObjOrString === 'string' ? { color: colorObjOrString } : colorObjOrString;\n var key = '' + c.color + (c.title || '');\n return React.createElement(\n 'div',\n { key: key, style: styles.swatchWrap },\n React.createElement(Swatch, _extends({}, c, {\n style: styles.swatch,\n onClick: handleClick,\n onHover: onSwatchHover,\n focusStyle: {\n boxShadow: 'inset 0 0 0 1px rgba(0,0,0,.15), 0 0 4px ' + c.color\n }\n }))\n );\n })\n );\n};\n\nSketchPresetColors.propTypes = {\n colors: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n color: PropTypes.string,\n title: PropTypes.string\n })])).isRequired\n};\n\nexport default SketchPresetColors;","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport merge from 'lodash-es/merge';\n\nimport { ColorWrap, Saturation, Hue, Alpha, Checkboard } from '../common';\nimport SketchFields from './SketchFields';\nimport SketchPresetColors from './SketchPresetColors';\n\nexport var Sketch = function Sketch(_ref) {\n var width = _ref.width,\n rgb = _ref.rgb,\n hex = _ref.hex,\n hsv = _ref.hsv,\n hsl = _ref.hsl,\n onChange = _ref.onChange,\n onSwatchHover = _ref.onSwatchHover,\n disableAlpha = _ref.disableAlpha,\n presetColors = _ref.presetColors,\n renderers = _ref.renderers,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS(merge({\n 'default': _extends({\n picker: {\n width: width,\n padding: '10px 10px 0',\n boxSizing: 'initial',\n background: '#fff',\n borderRadius: '4px',\n boxShadow: '0 0 0 1px rgba(0,0,0,.15), 0 8px 16px rgba(0,0,0,.15)'\n },\n saturation: {\n width: '100%',\n paddingBottom: '75%',\n position: 'relative',\n overflow: 'hidden'\n },\n Saturation: {\n radius: '3px',\n shadow: 'inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)'\n },\n controls: {\n display: 'flex'\n },\n sliders: {\n padding: '4px 0',\n flex: '1'\n },\n color: {\n width: '24px',\n height: '24px',\n position: 'relative',\n marginTop: '4px',\n marginLeft: '4px',\n borderRadius: '3px'\n },\n activeColor: {\n absolute: '0px 0px 0px 0px',\n borderRadius: '2px',\n background: 'rgba(' + rgb.r + ',' + rgb.g + ',' + rgb.b + ',' + rgb.a + ')',\n boxShadow: 'inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)'\n },\n hue: {\n position: 'relative',\n height: '10px',\n overflow: 'hidden'\n },\n Hue: {\n radius: '2px',\n shadow: 'inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)'\n },\n\n alpha: {\n position: 'relative',\n height: '10px',\n marginTop: '4px',\n overflow: 'hidden'\n },\n Alpha: {\n radius: '2px',\n shadow: 'inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)'\n }\n }, passedStyles),\n 'disableAlpha': {\n color: {\n height: '10px'\n },\n hue: {\n height: '10px'\n },\n alpha: {\n display: 'none'\n }\n }\n }, passedStyles), { disableAlpha: disableAlpha });\n\n return React.createElement(\n 'div',\n { style: styles.picker, className: 'sketch-picker ' + className },\n React.createElement(\n 'div',\n { style: styles.saturation },\n React.createElement(Saturation, {\n style: styles.Saturation,\n hsl: hsl,\n hsv: hsv,\n onChange: onChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.controls, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.sliders },\n React.createElement(\n 'div',\n { style: styles.hue },\n React.createElement(Hue, {\n style: styles.Hue,\n hsl: hsl,\n onChange: onChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.alpha },\n React.createElement(Alpha, {\n style: styles.Alpha,\n rgb: rgb,\n hsl: hsl,\n renderers: renderers,\n onChange: onChange\n })\n )\n ),\n React.createElement(\n 'div',\n { style: styles.color },\n React.createElement(Checkboard, null),\n React.createElement('div', { style: styles.activeColor })\n )\n ),\n React.createElement(SketchFields, {\n rgb: rgb,\n hsl: hsl,\n hex: hex,\n onChange: onChange,\n disableAlpha: disableAlpha\n }),\n React.createElement(SketchPresetColors, {\n colors: presetColors,\n onClick: onChange,\n onSwatchHover: onSwatchHover\n })\n );\n};\n\nSketch.propTypes = {\n disableAlpha: PropTypes.bool,\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n styles: PropTypes.object\n};\n\nSketch.defaultProps = {\n disableAlpha: false,\n width: 200,\n styles: {},\n presetColors: ['#D0021B', '#F5A623', '#F8E71C', '#8B572A', '#7ED321', '#417505', '#BD10E0', '#9013FE', '#4A90E2', '#50E3C2', '#B8E986', '#000000', '#4A4A4A', '#9B9B9B', '#FFFFFF']\n};\n\nexport default ColorWrap(Sketch);","import React from 'react';\nimport reactCSS from 'reactcss';\n\nexport var SliderSwatch = function SliderSwatch(_ref) {\n var hsl = _ref.hsl,\n offset = _ref.offset,\n _ref$onClick = _ref.onClick,\n onClick = _ref$onClick === undefined ? function () {} : _ref$onClick,\n active = _ref.active,\n first = _ref.first,\n last = _ref.last;\n\n var styles = reactCSS({\n 'default': {\n swatch: {\n height: '12px',\n background: 'hsl(' + hsl.h + ', 50%, ' + offset * 100 + '%)',\n cursor: 'pointer'\n }\n },\n 'first': {\n swatch: {\n borderRadius: '2px 0 0 2px'\n }\n },\n 'last': {\n swatch: {\n borderRadius: '0 2px 2px 0'\n }\n },\n 'active': {\n swatch: {\n transform: 'scaleY(1.8)',\n borderRadius: '3.6px/2px'\n }\n }\n }, { active: active, first: first, last: last });\n\n var handleClick = function handleClick(e) {\n return onClick({\n h: hsl.h,\n s: 0.5,\n l: offset,\n source: 'hsl'\n }, e);\n };\n\n return React.createElement('div', { style: styles.swatch, onClick: handleClick });\n};\n\nexport default SliderSwatch;","import React from 'react';\nimport reactCSS from 'reactcss';\n\nimport SliderSwatch from './SliderSwatch';\n\nexport var SliderSwatches = function SliderSwatches(_ref) {\n var onClick = _ref.onClick,\n hsl = _ref.hsl;\n\n var styles = reactCSS({\n 'default': {\n swatches: {\n marginTop: '20px'\n },\n swatch: {\n boxSizing: 'border-box',\n width: '20%',\n paddingRight: '1px',\n float: 'left'\n },\n clear: {\n clear: 'both'\n }\n }\n });\n\n // Acceptible difference in floating point equality\n var epsilon = 0.1;\n\n return React.createElement(\n 'div',\n { style: styles.swatches },\n React.createElement(\n 'div',\n { style: styles.swatch },\n React.createElement(SliderSwatch, {\n hsl: hsl,\n offset: '.80',\n active: Math.abs(hsl.l - 0.80) < epsilon && Math.abs(hsl.s - 0.50) < epsilon,\n onClick: onClick,\n first: true\n })\n ),\n React.createElement(\n 'div',\n { style: styles.swatch },\n React.createElement(SliderSwatch, {\n hsl: hsl,\n offset: '.65',\n active: Math.abs(hsl.l - 0.65) < epsilon && Math.abs(hsl.s - 0.50) < epsilon,\n onClick: onClick\n })\n ),\n React.createElement(\n 'div',\n { style: styles.swatch },\n React.createElement(SliderSwatch, {\n hsl: hsl,\n offset: '.50',\n active: Math.abs(hsl.l - 0.50) < epsilon && Math.abs(hsl.s - 0.50) < epsilon,\n onClick: onClick\n })\n ),\n React.createElement(\n 'div',\n { style: styles.swatch },\n React.createElement(SliderSwatch, {\n hsl: hsl,\n offset: '.35',\n active: Math.abs(hsl.l - 0.35) < epsilon && Math.abs(hsl.s - 0.50) < epsilon,\n onClick: onClick\n })\n ),\n React.createElement(\n 'div',\n { style: styles.swatch },\n React.createElement(SliderSwatch, {\n hsl: hsl,\n offset: '.20',\n active: Math.abs(hsl.l - 0.20) < epsilon && Math.abs(hsl.s - 0.50) < epsilon,\n onClick: onClick,\n last: true\n })\n ),\n React.createElement('div', { style: styles.clear })\n );\n};\n\nexport default SliderSwatches;","import React from 'react';\nimport reactCSS from 'reactcss';\n\nexport var SliderPointer = function SliderPointer() {\n var styles = reactCSS({\n 'default': {\n picker: {\n width: '14px',\n height: '14px',\n borderRadius: '6px',\n transform: 'translate(-7px, -1px)',\n backgroundColor: 'rgb(248, 248, 248)',\n boxShadow: '0 1px 4px 0 rgba(0, 0, 0, 0.37)'\n }\n }\n });\n\n return React.createElement('div', { style: styles.picker });\n};\n\nexport default SliderPointer;","import React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport merge from 'lodash-es/merge';\n\nimport { ColorWrap, Hue } from '../common';\nimport SliderSwatches from './SliderSwatches';\nimport SliderPointer from './SliderPointer';\n\nexport var Slider = function Slider(_ref) {\n var hsl = _ref.hsl,\n onChange = _ref.onChange,\n pointer = _ref.pointer,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS(merge({\n 'default': {\n hue: {\n height: '12px',\n position: 'relative'\n },\n Hue: {\n radius: '2px'\n }\n }\n }, passedStyles));\n\n return React.createElement(\n 'div',\n { style: styles.wrap || {}, className: 'slider-picker ' + className },\n React.createElement(\n 'div',\n { style: styles.hue },\n React.createElement(Hue, {\n style: styles.Hue,\n hsl: hsl,\n pointer: pointer,\n onChange: onChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.swatches },\n React.createElement(SliderSwatches, { hsl: hsl, onClick: onChange })\n )\n );\n};\n\nSlider.propTypes = {\n styles: PropTypes.object\n};\nSlider.defaultProps = {\n pointer: SliderPointer,\n styles: {}\n};\n\nexport default ColorWrap(Slider);","import React from 'react';\nimport reactCSS from 'reactcss';\nimport * as colorUtils from '../../helpers/color';\n\nimport { Swatch } from '../common';\nimport CheckIcon from '@icons/material/CheckIcon';\n\nexport var SwatchesColor = function SwatchesColor(_ref) {\n var color = _ref.color,\n _ref$onClick = _ref.onClick,\n onClick = _ref$onClick === undefined ? function () {} : _ref$onClick,\n onSwatchHover = _ref.onSwatchHover,\n first = _ref.first,\n last = _ref.last,\n active = _ref.active;\n\n var styles = reactCSS({\n 'default': {\n color: {\n width: '40px',\n height: '24px',\n cursor: 'pointer',\n background: color,\n marginBottom: '1px'\n },\n check: {\n color: colorUtils.getContrastingColor(color),\n marginLeft: '8px',\n display: 'none'\n }\n },\n 'first': {\n color: {\n overflow: 'hidden',\n borderRadius: '2px 2px 0 0'\n }\n },\n 'last': {\n color: {\n overflow: 'hidden',\n borderRadius: '0 0 2px 2px'\n }\n },\n 'active': {\n check: {\n display: 'block'\n }\n },\n 'color-#FFFFFF': {\n color: {\n boxShadow: 'inset 0 0 0 1px #ddd'\n },\n check: {\n color: '#333'\n }\n },\n 'transparent': {\n check: {\n color: '#333'\n }\n }\n }, {\n first: first,\n last: last,\n active: active,\n 'color-#FFFFFF': color === '#FFFFFF',\n 'transparent': color === 'transparent'\n });\n\n return React.createElement(\n Swatch,\n {\n color: color,\n style: styles.color,\n onClick: onClick,\n onHover: onSwatchHover,\n focusStyle: { boxShadow: '0 0 4px ' + color }\n },\n React.createElement(\n 'div',\n { style: styles.check },\n React.createElement(CheckIcon, null)\n )\n );\n};\n\nexport default SwatchesColor;","import React from 'react';\nimport reactCSS from 'reactcss';\nimport map from 'lodash-es/map';\n\nimport SwatchesColor from './SwatchesColor';\n\nexport var SwatchesGroup = function SwatchesGroup(_ref) {\n var onClick = _ref.onClick,\n onSwatchHover = _ref.onSwatchHover,\n group = _ref.group,\n active = _ref.active;\n\n var styles = reactCSS({\n 'default': {\n group: {\n paddingBottom: '10px',\n width: '40px',\n float: 'left',\n marginRight: '10px'\n }\n }\n });\n\n return React.createElement(\n 'div',\n { style: styles.group },\n map(group, function (color, i) {\n return React.createElement(SwatchesColor, {\n key: color,\n color: color,\n active: color.toLowerCase() === active,\n first: i === 0,\n last: i === group.length - 1,\n onClick: onClick,\n onSwatchHover: onSwatchHover\n });\n })\n );\n};\n\nexport default SwatchesGroup;","import React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport map from 'lodash-es/map';\nimport merge from 'lodash-es/merge';\nimport * as material from 'material-colors';\n\nimport { ColorWrap, Raised } from '../common';\nimport SwatchesGroup from './SwatchesGroup';\n\nexport var Swatches = function Swatches(_ref) {\n var width = _ref.width,\n height = _ref.height,\n onChange = _ref.onChange,\n onSwatchHover = _ref.onSwatchHover,\n colors = _ref.colors,\n hex = _ref.hex,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS(merge({\n 'default': {\n picker: {\n width: width,\n height: height\n },\n overflow: {\n height: height,\n overflowY: 'scroll'\n },\n body: {\n padding: '16px 0 6px 16px'\n },\n clear: {\n clear: 'both'\n }\n }\n }, passedStyles));\n\n var handleChange = function handleChange(data, e) {\n return onChange({ hex: data, source: 'hex' }, e);\n };\n\n return React.createElement(\n 'div',\n { style: styles.picker, className: 'swatches-picker ' + className },\n React.createElement(\n Raised,\n null,\n React.createElement(\n 'div',\n { style: styles.overflow },\n React.createElement(\n 'div',\n { style: styles.body },\n map(colors, function (group) {\n return React.createElement(SwatchesGroup, {\n key: group.toString(),\n group: group,\n active: hex,\n onClick: handleChange,\n onSwatchHover: onSwatchHover\n });\n }),\n React.createElement('div', { style: styles.clear })\n )\n )\n )\n );\n};\n\nSwatches.propTypes = {\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n height: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n colors: PropTypes.arrayOf(PropTypes.arrayOf(PropTypes.string)),\n styles: PropTypes.object\n\n /* eslint-disable max-len */\n};Swatches.defaultProps = {\n width: 320,\n height: 240,\n colors: [[material.red['900'], material.red['700'], material.red['500'], material.red['300'], material.red['100']], [material.pink['900'], material.pink['700'], material.pink['500'], material.pink['300'], material.pink['100']], [material.purple['900'], material.purple['700'], material.purple['500'], material.purple['300'], material.purple['100']], [material.deepPurple['900'], material.deepPurple['700'], material.deepPurple['500'], material.deepPurple['300'], material.deepPurple['100']], [material.indigo['900'], material.indigo['700'], material.indigo['500'], material.indigo['300'], material.indigo['100']], [material.blue['900'], material.blue['700'], material.blue['500'], material.blue['300'], material.blue['100']], [material.lightBlue['900'], material.lightBlue['700'], material.lightBlue['500'], material.lightBlue['300'], material.lightBlue['100']], [material.cyan['900'], material.cyan['700'], material.cyan['500'], material.cyan['300'], material.cyan['100']], [material.teal['900'], material.teal['700'], material.teal['500'], material.teal['300'], material.teal['100']], ['#194D33', material.green['700'], material.green['500'], material.green['300'], material.green['100']], [material.lightGreen['900'], material.lightGreen['700'], material.lightGreen['500'], material.lightGreen['300'], material.lightGreen['100']], [material.lime['900'], material.lime['700'], material.lime['500'], material.lime['300'], material.lime['100']], [material.yellow['900'], material.yellow['700'], material.yellow['500'], material.yellow['300'], material.yellow['100']], [material.amber['900'], material.amber['700'], material.amber['500'], material.amber['300'], material.amber['100']], [material.orange['900'], material.orange['700'], material.orange['500'], material.orange['300'], material.orange['100']], [material.deepOrange['900'], material.deepOrange['700'], material.deepOrange['500'], material.deepOrange['300'], material.deepOrange['100']], [material.brown['900'], material.brown['700'], material.brown['500'], material.brown['300'], material.brown['100']], [material.blueGrey['900'], material.blueGrey['700'], material.blueGrey['500'], material.blueGrey['300'], material.blueGrey['100']], ['#000000', '#525252', '#969696', '#D9D9D9', '#FFFFFF']],\n styles: {}\n};\n\nexport default ColorWrap(Swatches);","import React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport map from 'lodash-es/map';\nimport merge from 'lodash-es/merge';\nimport * as color from '../../helpers/color';\n\nimport { ColorWrap, EditableInput, Swatch } from '../common';\n\nexport var Twitter = function Twitter(_ref) {\n var onChange = _ref.onChange,\n onSwatchHover = _ref.onSwatchHover,\n hex = _ref.hex,\n colors = _ref.colors,\n width = _ref.width,\n triangle = _ref.triangle,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS(merge({\n 'default': {\n card: {\n width: width,\n background: '#fff',\n border: '0 solid rgba(0,0,0,0.25)',\n boxShadow: '0 1px 4px rgba(0,0,0,0.25)',\n borderRadius: '4px',\n position: 'relative'\n },\n body: {\n padding: '15px 9px 9px 15px'\n },\n label: {\n fontSize: '18px',\n color: '#fff'\n },\n triangle: {\n width: '0px',\n height: '0px',\n borderStyle: 'solid',\n borderWidth: '0 9px 10px 9px',\n borderColor: 'transparent transparent #fff transparent',\n position: 'absolute'\n },\n triangleShadow: {\n width: '0px',\n height: '0px',\n borderStyle: 'solid',\n borderWidth: '0 9px 10px 9px',\n borderColor: 'transparent transparent rgba(0,0,0,.1) transparent',\n position: 'absolute'\n },\n hash: {\n background: '#F0F0F0',\n height: '30px',\n width: '30px',\n borderRadius: '4px 0 0 4px',\n float: 'left',\n color: '#98A1A4',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center'\n },\n input: {\n width: '100px',\n fontSize: '14px',\n color: '#666',\n border: '0px',\n outline: 'none',\n height: '28px',\n boxShadow: 'inset 0 0 0 1px #F0F0F0',\n boxSizing: 'content-box',\n borderRadius: '0 4px 4px 0',\n float: 'left',\n paddingLeft: '8px'\n },\n swatch: {\n width: '30px',\n height: '30px',\n float: 'left',\n borderRadius: '4px',\n margin: '0 6px 6px 0'\n },\n clear: {\n clear: 'both'\n }\n },\n 'hide-triangle': {\n triangle: {\n display: 'none'\n },\n triangleShadow: {\n display: 'none'\n }\n },\n 'top-left-triangle': {\n triangle: {\n top: '-10px',\n left: '12px'\n },\n triangleShadow: {\n top: '-11px',\n left: '12px'\n }\n },\n 'top-right-triangle': {\n triangle: {\n top: '-10px',\n right: '12px'\n },\n triangleShadow: {\n top: '-11px',\n right: '12px'\n }\n }\n }, passedStyles), {\n 'hide-triangle': triangle === 'hide',\n 'top-left-triangle': triangle === 'top-left',\n 'top-right-triangle': triangle === 'top-right'\n });\n\n var handleChange = function handleChange(hexcode, e) {\n color.isValidHex(hexcode) && onChange({\n hex: hexcode,\n source: 'hex'\n }, e);\n };\n\n return React.createElement(\n 'div',\n { style: styles.card, className: 'twitter-picker ' + className },\n React.createElement('div', { style: styles.triangleShadow }),\n React.createElement('div', { style: styles.triangle }),\n React.createElement(\n 'div',\n { style: styles.body },\n map(colors, function (c, i) {\n return React.createElement(Swatch, {\n key: i,\n color: c,\n hex: c,\n style: styles.swatch,\n onClick: handleChange,\n onHover: onSwatchHover,\n focusStyle: {\n boxShadow: '0 0 4px ' + c\n }\n });\n }),\n React.createElement(\n 'div',\n { style: styles.hash },\n '#'\n ),\n React.createElement(EditableInput, {\n label: null,\n style: { input: styles.input },\n value: hex.replace('#', ''),\n onChange: handleChange\n }),\n React.createElement('div', { style: styles.clear })\n )\n );\n};\n\nTwitter.propTypes = {\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n triangle: PropTypes.oneOf(['hide', 'top-left', 'top-right']),\n colors: PropTypes.arrayOf(PropTypes.string),\n styles: PropTypes.object\n};\n\nTwitter.defaultProps = {\n width: 276,\n colors: ['#FF6900', '#FCB900', '#7BDCB5', '#00D084', '#8ED1FC', '#0693E3', '#ABB8C3', '#EB144C', '#F78DA7', '#9900EF'],\n triangle: 'top-left',\n styles: {}\n};\n\nexport default ColorWrap(Twitter);","import React from 'react';\nimport reactCSS from 'reactcss';\nimport PropTypes from 'prop-types';\n\nexport var GooglePointerCircle = function GooglePointerCircle(props) {\n var styles = reactCSS({\n 'default': {\n picker: {\n width: '20px',\n height: '20px',\n borderRadius: '22px',\n border: '2px #fff solid',\n transform: 'translate(-12px, -13px)',\n background: 'hsl(' + Math.round(props.hsl.h) + ', ' + Math.round(props.hsl.s * 100) + '%, ' + Math.round(props.hsl.l * 100) + '%)'\n }\n }\n });\n\n return React.createElement('div', { style: styles.picker });\n};\n\nGooglePointerCircle.propTypes = {\n hsl: PropTypes.shape({\n h: PropTypes.number,\n s: PropTypes.number,\n l: PropTypes.number,\n a: PropTypes.number\n })\n};\n\nGooglePointerCircle.defaultProps = {\n hsl: { a: 1, h: 249.94, l: 0.2, s: 0.50 }\n};\n\nexport default GooglePointerCircle;","import React from 'react';\nimport reactCSS from 'reactcss';\nimport PropTypes from 'prop-types';\n\nexport var GooglePointer = function GooglePointer(props) {\n var styles = reactCSS({\n 'default': {\n picker: {\n width: '20px',\n height: '20px',\n borderRadius: '22px',\n transform: 'translate(-10px, -7px)',\n background: 'hsl(' + Math.round(props.hsl.h) + ', 100%, 50%)',\n border: '2px white solid'\n }\n }\n });\n\n return React.createElement('div', { style: styles.picker });\n};\n\nGooglePointer.propTypes = {\n hsl: PropTypes.shape({\n h: PropTypes.number,\n s: PropTypes.number,\n l: PropTypes.number,\n a: PropTypes.number\n })\n};\n\nGooglePointer.defaultProps = {\n hsl: { a: 1, h: 249.94, l: 0.2, s: 0.50 }\n};\n\nexport default GooglePointer;","import React from 'react';\nimport reactCSS from 'reactcss';\nimport * as color from '../../helpers/color';\nimport { EditableInput } from '../common';\n\nexport var GoogleFields = function GoogleFields(_ref) {\n var onChange = _ref.onChange,\n rgb = _ref.rgb,\n hsl = _ref.hsl,\n hex = _ref.hex,\n hsv = _ref.hsv;\n\n\n var handleChange = function handleChange(data, e) {\n if (data.hex) {\n color.isValidHex(data.hex) && onChange({\n hex: data.hex,\n source: 'hex'\n }, e);\n } else if (data.rgb) {\n var values = data.rgb.split(',');\n color.isvalidColorString(data.rgb, 'rgb') && onChange({\n r: values[0],\n g: values[1],\n b: values[2],\n a: 1,\n source: 'rgb'\n }, e);\n } else if (data.hsv) {\n var _values = data.hsv.split(',');\n if (color.isvalidColorString(data.hsv, 'hsv')) {\n _values[2] = _values[2].replace('%', '');\n _values[1] = _values[1].replace('%', '');\n _values[0] = _values[0].replace('°', '');\n if (_values[1] == 1) {\n _values[1] = 0.01;\n } else if (_values[2] == 1) {\n _values[2] = 0.01;\n }\n onChange({\n h: Number(_values[0]),\n s: Number(_values[1]),\n v: Number(_values[2]),\n source: 'hsv'\n }, e);\n }\n } else if (data.hsl) {\n var _values2 = data.hsl.split(',');\n if (color.isvalidColorString(data.hsl, 'hsl')) {\n _values2[2] = _values2[2].replace('%', '');\n _values2[1] = _values2[1].replace('%', '');\n _values2[0] = _values2[0].replace('°', '');\n if (hsvValue[1] == 1) {\n hsvValue[1] = 0.01;\n } else if (hsvValue[2] == 1) {\n hsvValue[2] = 0.01;\n }\n onChange({\n h: Number(_values2[0]),\n s: Number(_values2[1]),\n v: Number(_values2[2]),\n source: 'hsl'\n }, e);\n }\n }\n };\n\n var styles = reactCSS({\n 'default': {\n wrap: {\n display: 'flex',\n height: '100px',\n marginTop: '4px'\n },\n fields: {\n width: '100%'\n },\n column: {\n paddingTop: '10px',\n display: 'flex',\n justifyContent: 'space-between'\n },\n double: {\n padding: '0px 4.4px',\n boxSizing: 'border-box'\n },\n input: {\n width: '100%',\n height: '38px',\n boxSizing: 'border-box',\n padding: '4px 10% 3px',\n textAlign: 'center',\n border: '1px solid #dadce0',\n fontSize: '11px',\n textTransform: 'lowercase',\n borderRadius: '5px',\n outline: 'none',\n fontFamily: 'Roboto,Arial,sans-serif'\n },\n input2: {\n height: '38px',\n width: '100%',\n border: '1px solid #dadce0',\n boxSizing: 'border-box',\n fontSize: '11px',\n textTransform: 'lowercase',\n borderRadius: '5px',\n outline: 'none',\n paddingLeft: '10px',\n fontFamily: 'Roboto,Arial,sans-serif'\n },\n label: {\n textAlign: 'center',\n fontSize: '12px',\n background: '#fff',\n position: 'absolute',\n textTransform: 'uppercase',\n color: '#3c4043',\n width: '35px',\n top: '-6px',\n left: '0',\n right: '0',\n marginLeft: 'auto',\n marginRight: 'auto',\n fontFamily: 'Roboto,Arial,sans-serif'\n },\n label2: {\n left: '10px',\n textAlign: 'center',\n fontSize: '12px',\n background: '#fff',\n position: 'absolute',\n textTransform: 'uppercase',\n color: '#3c4043',\n width: '32px',\n top: '-6px',\n fontFamily: 'Roboto,Arial,sans-serif'\n },\n single: {\n flexGrow: '1',\n margin: '0px 4.4px'\n }\n }\n });\n\n var rgbValue = rgb.r + ', ' + rgb.g + ', ' + rgb.b;\n var hslValue = Math.round(hsl.h) + '\\xB0, ' + Math.round(hsl.s * 100) + '%, ' + Math.round(hsl.l * 100) + '%';\n var hsvValue = Math.round(hsv.h) + '\\xB0, ' + Math.round(hsv.s * 100) + '%, ' + Math.round(hsv.v * 100) + '%';\n\n return React.createElement(\n 'div',\n { style: styles.wrap, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.fields },\n React.createElement(\n 'div',\n { style: styles.double },\n React.createElement(EditableInput, {\n style: { input: styles.input, label: styles.label },\n label: 'hex',\n value: hex,\n onChange: handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.column },\n React.createElement(\n 'div',\n { style: styles.single },\n React.createElement(EditableInput, {\n style: { input: styles.input2, label: styles.label2 },\n label: 'rgb',\n value: rgbValue,\n onChange: handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.single },\n React.createElement(EditableInput, {\n style: { input: styles.input2, label: styles.label2 },\n label: 'hsv',\n value: hsvValue,\n onChange: handleChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.single },\n React.createElement(EditableInput, {\n style: { input: styles.input2, label: styles.label2 },\n label: 'hsl',\n value: hslValue,\n onChange: handleChange\n })\n )\n )\n )\n );\n};\n\nexport default GoogleFields;","import React from 'react';\nimport PropTypes from 'prop-types';\nimport reactCSS from 'reactcss';\nimport merge from 'lodash-es/merge';\n\nimport { ColorWrap, Saturation, Hue } from '../common';\nimport GooglePointerCircle from './GooglePointerCircle';\nimport GooglePointer from './GooglePointer';\nimport GoogleFields from './GoogleFields';\n\nexport var Google = function Google(_ref) {\n var width = _ref.width,\n onChange = _ref.onChange,\n rgb = _ref.rgb,\n hsl = _ref.hsl,\n hsv = _ref.hsv,\n hex = _ref.hex,\n header = _ref.header,\n _ref$styles = _ref.styles,\n passedStyles = _ref$styles === undefined ? {} : _ref$styles,\n _ref$className = _ref.className,\n className = _ref$className === undefined ? '' : _ref$className;\n\n var styles = reactCSS(merge({\n 'default': {\n picker: {\n width: width,\n background: '#fff',\n border: '1px solid #dfe1e5',\n boxSizing: 'initial',\n display: 'flex',\n flexWrap: 'wrap',\n borderRadius: '8px 8px 0px 0px'\n },\n head: {\n height: '57px',\n width: '100%',\n paddingTop: '16px',\n paddingBottom: '16px',\n paddingLeft: '16px',\n fontSize: '20px',\n boxSizing: 'border-box',\n fontFamily: 'Roboto-Regular,HelveticaNeue,Arial,sans-serif'\n },\n saturation: {\n width: '70%',\n padding: '0px',\n position: 'relative',\n overflow: 'hidden'\n },\n swatch: {\n width: '30%',\n height: '228px',\n padding: '0px',\n background: 'rgba(' + rgb.r + ', ' + rgb.g + ', ' + rgb.b + ', 1)',\n position: 'relative',\n overflow: 'hidden'\n },\n body: {\n margin: 'auto',\n width: '95%'\n },\n controls: {\n display: 'flex',\n boxSizing: 'border-box',\n height: '52px',\n paddingTop: '22px'\n },\n color: {\n width: '32px'\n },\n hue: {\n height: '8px',\n position: 'relative',\n margin: '0px 16px 0px 16px',\n width: '100%'\n },\n Hue: {\n radius: '2px'\n }\n }\n }, passedStyles));\n return React.createElement(\n 'div',\n { style: styles.picker, className: 'google-picker ' + className },\n React.createElement(\n 'div',\n { style: styles.head },\n header\n ),\n React.createElement('div', { style: styles.swatch }),\n React.createElement(\n 'div',\n { style: styles.saturation },\n React.createElement(Saturation, {\n hsl: hsl,\n hsv: hsv,\n pointer: GooglePointerCircle,\n onChange: onChange\n })\n ),\n React.createElement(\n 'div',\n { style: styles.body },\n React.createElement(\n 'div',\n { style: styles.controls, className: 'flexbox-fix' },\n React.createElement(\n 'div',\n { style: styles.hue },\n React.createElement(Hue, {\n style: styles.Hue,\n hsl: hsl,\n radius: '4px',\n pointer: GooglePointer,\n onChange: onChange\n })\n )\n ),\n React.createElement(GoogleFields, {\n rgb: rgb,\n hsl: hsl,\n hex: hex,\n hsv: hsv,\n onChange: onChange\n })\n )\n );\n};\n\nGoogle.propTypes = {\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n styles: PropTypes.object,\n header: PropTypes.string\n\n};\n\nGoogle.defaultProps = {\n width: 652,\n styles: {},\n header: 'Color picker'\n};\n\nexport default ColorWrap(Google);","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.autoprefix = undefined;\n\nvar _forOwn2 = require('lodash/forOwn');\n\nvar _forOwn3 = _interopRequireDefault(_forOwn2);\n\nvar _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar transforms = {\n borderRadius: function borderRadius(value) {\n return {\n msBorderRadius: value,\n MozBorderRadius: value,\n OBorderRadius: value,\n WebkitBorderRadius: value,\n borderRadius: value\n };\n },\n boxShadow: function boxShadow(value) {\n return {\n msBoxShadow: value,\n MozBoxShadow: value,\n OBoxShadow: value,\n WebkitBoxShadow: value,\n boxShadow: value\n };\n },\n userSelect: function userSelect(value) {\n return {\n WebkitTouchCallout: value,\n KhtmlUserSelect: value,\n MozUserSelect: value,\n msUserSelect: value,\n WebkitUserSelect: value,\n userSelect: value\n };\n },\n\n flex: function flex(value) {\n return {\n WebkitBoxFlex: value,\n MozBoxFlex: value,\n WebkitFlex: value,\n msFlex: value,\n flex: value\n };\n },\n flexBasis: function flexBasis(value) {\n return {\n WebkitFlexBasis: value,\n flexBasis: value\n };\n },\n justifyContent: function justifyContent(value) {\n return {\n WebkitJustifyContent: value,\n justifyContent: value\n };\n },\n\n transition: function transition(value) {\n return {\n msTransition: value,\n MozTransition: value,\n OTransition: value,\n WebkitTransition: value,\n transition: value\n };\n },\n\n transform: function transform(value) {\n return {\n msTransform: value,\n MozTransform: value,\n OTransform: value,\n WebkitTransform: value,\n transform: value\n };\n },\n absolute: function absolute(value) {\n var direction = value && value.split(' ');\n return {\n position: 'absolute',\n top: direction && direction[0],\n right: direction && direction[1],\n bottom: direction && direction[2],\n left: direction && direction[3]\n };\n },\n extend: function extend(name, otherElementStyles) {\n var otherStyle = otherElementStyles[name];\n if (otherStyle) {\n return otherStyle;\n }\n return {\n 'extend': name\n };\n }\n};\n\nvar autoprefix = exports.autoprefix = function autoprefix(elements) {\n var prefixed = {};\n (0, _forOwn3.default)(elements, function (styles, element) {\n var expanded = {};\n (0, _forOwn3.default)(styles, function (value, key) {\n var transform = transforms[key];\n if (transform) {\n expanded = _extends({}, expanded, transform(value));\n } else {\n expanded[key] = value;\n }\n });\n prefixed[element] = expanded;\n });\n return prefixed;\n};\n\nexports.default = autoprefix;","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.active = undefined;\n\nvar _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nvar _react = require('react');\n\nvar _react2 = _interopRequireDefault(_react);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\nvar active = exports.active = function active(Component) {\n var Span = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'span';\n\n return function (_React$Component) {\n _inherits(Active, _React$Component);\n\n function Active() {\n var _ref;\n\n var _temp, _this, _ret;\n\n _classCallCheck(this, Active);\n\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = Active.__proto__ || Object.getPrototypeOf(Active)).call.apply(_ref, [this].concat(args))), _this), _this.state = { active: false }, _this.handleMouseDown = function () {\n return _this.setState({ active: true });\n }, _this.handleMouseUp = function () {\n return _this.setState({ active: false });\n }, _this.render = function () {\n return _react2.default.createElement(\n Span,\n { onMouseDown: _this.handleMouseDown, onMouseUp: _this.handleMouseUp },\n _react2.default.createElement(Component, _extends({}, _this.props, _this.state))\n );\n }, _temp), _possibleConstructorReturn(_this, _ret);\n }\n\n return Active;\n }(_react2.default.Component);\n};\n\nexports.default = active;","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.hover = undefined;\n\nvar _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nvar _react = require('react');\n\nvar _react2 = _interopRequireDefault(_react);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\nvar hover = exports.hover = function hover(Component) {\n var Span = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'span';\n\n return function (_React$Component) {\n _inherits(Hover, _React$Component);\n\n function Hover() {\n var _ref;\n\n var _temp, _this, _ret;\n\n _classCallCheck(this, Hover);\n\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = Hover.__proto__ || Object.getPrototypeOf(Hover)).call.apply(_ref, [this].concat(args))), _this), _this.state = { hover: false }, _this.handleMouseOver = function () {\n return _this.setState({ hover: true });\n }, _this.handleMouseOut = function () {\n return _this.setState({ hover: false });\n }, _this.render = function () {\n return _react2.default.createElement(\n Span,\n { onMouseOver: _this.handleMouseOver, onMouseOut: _this.handleMouseOut },\n _react2.default.createElement(Component, _extends({}, _this.props, _this.state))\n );\n }, _temp), _possibleConstructorReturn(_this, _ret);\n }\n\n return Hover;\n }(_react2.default.Component);\n};\n\nexports.default = hover;","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.flattenNames = undefined;\n\nvar _isString2 = require('lodash/isString');\n\nvar _isString3 = _interopRequireDefault(_isString2);\n\nvar _forOwn2 = require('lodash/forOwn');\n\nvar _forOwn3 = _interopRequireDefault(_forOwn2);\n\nvar _isPlainObject2 = require('lodash/isPlainObject');\n\nvar _isPlainObject3 = _interopRequireDefault(_isPlainObject2);\n\nvar _map2 = require('lodash/map');\n\nvar _map3 = _interopRequireDefault(_map2);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar flattenNames = exports.flattenNames = function flattenNames() {\n var things = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n\n var names = [];\n\n (0, _map3.default)(things, function (thing) {\n if (Array.isArray(thing)) {\n flattenNames(thing).map(function (name) {\n return names.push(name);\n });\n } else if ((0, _isPlainObject3.default)(thing)) {\n (0, _forOwn3.default)(thing, function (value, key) {\n value === true && names.push(key);\n names.push(key + '-' + value);\n });\n } else if ((0, _isString3.default)(thing)) {\n names.push(thing);\n }\n });\n\n return names;\n};\n\nexports.default = flattenNames;","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.ReactCSS = exports.loop = exports.handleActive = exports.handleHover = exports.hover = undefined;\n\nvar _flattenNames = require('./flattenNames');\n\nvar _flattenNames2 = _interopRequireDefault(_flattenNames);\n\nvar _mergeClasses = require('./mergeClasses');\n\nvar _mergeClasses2 = _interopRequireDefault(_mergeClasses);\n\nvar _autoprefix = require('./autoprefix');\n\nvar _autoprefix2 = _interopRequireDefault(_autoprefix);\n\nvar _hover2 = require('./components/hover');\n\nvar _hover3 = _interopRequireDefault(_hover2);\n\nvar _active = require('./components/active');\n\nvar _active2 = _interopRequireDefault(_active);\n\nvar _loop2 = require('./loop');\n\nvar _loop3 = _interopRequireDefault(_loop2);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nexports.hover = _hover3.default;\nexports.handleHover = _hover3.default;\nexports.handleActive = _active2.default;\nexports.loop = _loop3.default;\nvar ReactCSS = exports.ReactCSS = function ReactCSS(classes) {\n for (var _len = arguments.length, activations = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n activations[_key - 1] = arguments[_key];\n }\n\n var activeNames = (0, _flattenNames2.default)(activations);\n var merged = (0, _mergeClasses2.default)(classes, activeNames);\n return (0, _autoprefix2.default)(merged);\n};\n\nexports.default = ReactCSS;","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nvar loopable = function loopable(i, length) {\n var props = {};\n var setProp = function setProp(name) {\n var value = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;\n\n props[name] = value;\n };\n\n i === 0 && setProp('first-child');\n i === length - 1 && setProp('last-child');\n (i === 0 || i % 2 === 0) && setProp('even');\n Math.abs(i % 2) === 1 && setProp('odd');\n setProp('nth-child', i);\n\n return props;\n};\n\nexports.default = loopable;","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.mergeClasses = undefined;\n\nvar _forOwn2 = require('lodash/forOwn');\n\nvar _forOwn3 = _interopRequireDefault(_forOwn2);\n\nvar _cloneDeep2 = require('lodash/cloneDeep');\n\nvar _cloneDeep3 = _interopRequireDefault(_cloneDeep2);\n\nvar _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar mergeClasses = exports.mergeClasses = function mergeClasses(classes) {\n var activeNames = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];\n\n var styles = classes.default && (0, _cloneDeep3.default)(classes.default) || {};\n activeNames.map(function (name) {\n var toMerge = classes[name];\n if (toMerge) {\n (0, _forOwn3.default)(toMerge, function (value, key) {\n if (!styles[key]) {\n styles[key] = {};\n }\n\n styles[key] = _extends({}, styles[key], toMerge[key]);\n });\n }\n\n return name;\n });\n return styles;\n};\n\nexports.default = mergeClasses;"],"names":["_extends","target","i","source","key","_react","_react2","_interopRequireDefault","obj","_objectWithoutProperties","keys","DEFAULT_SIZE","exports","_ref","_ref$fill","fill","_ref$width","width","_ref$height","height","_ref$style","style","props","getNative","root","DataView","module","hashClear","hashDelete","hashGet","hashHas","hashSet","Hash","entries","index","length","entry","listCacheClear","listCacheDelete","listCacheGet","listCacheHas","listCacheSet","ListCache","Map","mapCacheClear","mapCacheDelete","mapCacheGet","mapCacheHas","mapCacheSet","MapCache","Promise","Set","setCacheAdd","setCacheHas","SetCache","values","stackClear","stackDelete","stackGet","stackHas","stackSet","Stack","data","Symbol","Uint8Array","WeakMap","arrayEach","array","iteratee","arrayFilter","predicate","resIndex","result","value","baseTimes","isArguments","isArray","isBuffer","isIndex","isTypedArray","objectProto","hasOwnProperty","arrayLikeKeys","inherited","isArr","isArg","isBuff","isType","skipIndexes","arrayMap","arrayPush","offset","arraySome","baseAssignValue","eq","assignValue","object","objValue","assocIndexOf","copyObject","baseAssign","keysIn","baseAssignIn","defineProperty","cloneBuffer","copyArray","copySymbols","copySymbolsIn","getAllKeys","getAllKeysIn","getTag","initCloneArray","initCloneByTag","initCloneObject","isMap","isObject","isSet","CLONE_DEEP_FLAG","CLONE_FLAT_FLAG","CLONE_SYMBOLS_FLAG","argsTag","arrayTag","boolTag","dateTag","errorTag","funcTag","genTag","mapTag","numberTag","objectTag","regexpTag","setTag","stringTag","symbolTag","weakMapTag","arrayBufferTag","dataViewTag","float32Tag","float64Tag","int8Tag","int16Tag","int32Tag","uint8Tag","uint8ClampedTag","uint16Tag","uint32Tag","cloneableTags","baseClone","bitmask","customizer","stack","isDeep","isFlat","isFull","tag","isFunc","stacked","subValue","keysFunc","objectCreate","baseCreate","proto","baseForOwn","createBaseEach","baseEach","createBaseFor","baseFor","castPath","toKey","baseGet","path","baseGetAllKeys","symbolsFunc","getRawTag","objectToString","nullTag","undefinedTag","symToStringTag","baseGetTag","baseHasIn","isObjectLike","baseIsArguments","baseIsEqualDeep","baseIsEqual","other","equalArrays","equalByTag","equalObjects","COMPARE_PARTIAL_FLAG","equalFunc","objIsArr","othIsArr","objTag","othTag","objIsObj","othIsObj","isSameTag","objIsWrapped","othIsWrapped","objUnwrapped","othUnwrapped","baseIsMap","COMPARE_UNORDERED_FLAG","baseIsMatch","matchData","noCustomizer","srcValue","isFunction","isMasked","toSource","reRegExpChar","reIsHostCtor","funcProto","funcToString","reIsNative","baseIsNative","pattern","baseIsSet","isLength","typedArrayTags","baseIsTypedArray","baseMatches","baseMatchesProperty","identity","property","baseIteratee","isPrototype","nativeKeys","baseKeys","nativeKeysIn","baseKeysIn","isProto","isArrayLike","baseMap","collection","getMatchData","matchesStrictComparable","get","hasIn","isKey","isStrictComparable","baseProperty","basePropertyDeep","n","isSymbol","INFINITY","symbolProto","symbolToString","baseToString","baseUnary","func","cacheHas","cache","castFunction","stringToPath","toString","cloneArrayBuffer","arrayBuffer","freeExports","freeModule","moduleExports","Buffer","allocUnsafe","buffer","cloneDataView","dataView","reFlags","cloneRegExp","regexp","symbolValueOf","cloneSymbol","symbol","cloneTypedArray","typedArray","isNew","newValue","getSymbols","getSymbolsIn","coreJsData","eachFunc","fromRight","iterable","e","isPartial","arrLength","othLength","arrStacked","othStacked","seen","arrValue","othValue","compared","othIndex","mapToArray","setToArray","convert","objProps","objLength","othProps","objStacked","skipCtor","objCtor","othCtor","freeGlobal","isKeyable","getMapData","map","getValue","overArg","getPrototype","nativeObjectToString","isOwn","unmasked","stubArray","propertyIsEnumerable","nativeGetSymbols","promiseTag","dataViewCtorString","mapCtorString","promiseCtorString","setCtorString","weakMapCtorString","Ctor","ctorString","hasPath","hasFunc","nativeCreate","HASH_UNDEFINED","MAX_SAFE_INTEGER","reIsUint","type","reIsDeepProp","reIsPlainProp","maskSrcKey","uid","arrayProto","splice","lastIndex","size","memoize","MAX_MEMOIZE_SIZE","memoizeCapped","freeProcess","nodeUtil","types","transform","arg","freeSelf","set","LARGE_ARRAY_SIZE","pairs","rePropName","reEscapeChar","string","match","number","quote","subString","cloneDeep","forOwn","defaultValue","stubFalse","nativeIsBuffer","asyncTag","proxyTag","nodeIsMap","objectCtorString","isPlainObject","nodeIsSet","isString","nodeIsTypedArray","FUNC_ERROR_TEXT","resolver","memoized","args","calculateChange","hsl","direction","initialA","container","containerWidth","containerHeight","x","y","left","top","a","_a","checkboardCache","render","c1","c2","serverCanvas","canvas","ctx","checkboard","Checkboard","white","grey","renderers","borderRadius","boxShadow","children","styles","_createClass","defineProperties","descriptor","Constructor","protoProps","staticProps","_classCallCheck","instance","_possibleConstructorReturn","self","call","_inherits","subClass","superClass","Alpha","_ref2","_temp","_this","_ret","_len","_key","change","_this2","rgb","_defineProperty","DEFAULT_ARROW_OFFSET","UP_KEY_CODE","DOWN_KEY_CODE","VALID_KEY_CODES","isValidKeyCode","keyCode","getNumberValue","idCounter","EditableInput","updatedValue","prevProps","prevState","onChangeValue","input","h","percent","_h","_percent","Hue","_props$direction","assignMergeValue","isArrayLikeObject","safeGet","toPlainObject","baseMergeDeep","srcIndex","mergeFunc","isCommon","isTyped","baseMerge","apply","thisArg","nativeMax","overRest","start","otherArgs","constant","baseSetToString","HOT_COUNT","HOT_SPAN","nativeNow","shortOut","count","lastCalled","stamp","remaining","setToString","baseRest","isIterateeCall","createAssigner","assigner","sources","guard","merge","Raised","zDepth","radius","background","_ref$styles","passedStyles","now","reWhitespace","trimmedEndIndex","reTrimStart","baseTrim","NAN","reIsBadHex","reIsBinary","reIsOctal","freeParseInt","toNumber","isBinary","nativeMin","debounce","wait","options","lastArgs","lastThis","maxWait","timerId","lastCallTime","lastInvokeTime","leading","maxing","trailing","invokeFunc","time","leadingEdge","timerExpired","remainingWait","timeSinceLastCall","timeSinceLastInvoke","timeWaiting","shouldInvoke","trailingEdge","cancel","flush","debounced","isInvoking","throttle","_container$getBoundin","saturation","bright","Saturation","renderWindow","fn","color","black","pointer","circle","forEach","_typeof","trimLeft","trimRight","tinycolor","opts","inputToRGB","RsRGB","GsRGB","BsRGB","R","G","B","boundAlpha","hsv","rgbToHsv","s","v","rgbToHsl","l","allow3Char","rgbToHex","allow4Char","rgbaToHex","bound01","hexNames","secondColor","hex8String","rgbaToArgbHex","secondHex8String","gradientType","format","formatSet","formattedString","hasAlpha","needsAlphaFormat","_lighten","_brighten","_darken","_desaturate","_saturate","_greyscale","_spin","_analogous","_complement","_monochromatic","_splitcomplement","polyad","newColor","convertToPercentage","ok","stringInputToObject","isValidCSSUnit","rgbToRgb","hsvToRgb","hslToRgb","r","g","b","max","min","d","hue2rgb","p","q","t","f","mod","hex","pad2","convertDecimalToHex","color1","color2","amount","clamp01","hue","step","results","slices","part","ret","modification","rgb1","rgb2","rgba","wcag2","readability","wcag2Parms","out","validateWCAG2Parms","baseColor","colorList","bestColor","bestScore","includeFallbackColors","level","names","flip","o","flipped","isOnePointZero","processPercent","isPercentage","val","parseIntFromHex","c","convertHexToDecimal","matchers","CSS_INTEGER","CSS_NUMBER","CSS_UNIT","PERMISSIVE_MATCH3","PERMISSIVE_MATCH4","named","parms","simpleCheckForValidColor","keysToCheck","checked","passed","letter","percentPatt","toState","oldHue","transparent","isValidHex","lh","getContrastingColor","col","yiq","red","isvalidColorString","stringWithoutDegree","ColorWrap","Picker","ColorPicker","event","isValidColor","colors","optionalEvents","nextProps","state","handleFocus","Component","Span","_React$Component","Focus","ENTER","Swatch","_ref$onClick","onClick","onHover","_ref$title","title","focus","_ref$focusStyle","focusStyle","handleClick","handleKeyDown","handleHover","AlphaPointer","AlphaPicker","onChange","_ref$className","className","BlockSwatches","onSwatchHover","Block","triangle","handleChange","hexCode","pink","purple","deepPurple","indigo","blue","lightBlue","cyan","teal","green","lightGreen","lime","yellow","amber","orange","deepOrange","brown","blueGrey","darkText","lightText","darkIcons","lightIcons","CircleSwatch","hover","active","circleSize","circleSpacing","Circle","isUndefined","ChromeFields","fields","icon","UnfoldMoreHorizontalIcon","ChromePointer","ChromePointerCircle","Chrome","disableAlpha","defaultView","CompactColor","CompactFields","Compact","GithubSwatch","hoverSwatch","Github","SliderPointer","HuePicker","HuePointer","Material","PhotoshopPicker","PhotoshopPointerCircle","PhotoshopButton","label","PhotoshopPreviews","currentColor","Photoshop","_props","_props$styles","_props$className","PhotoshopPointer","PhotoshopFields","SketchFields","SketchPresetColors","colorObjOrString","Sketch","presetColors","SliderSwatch","first","last","SliderSwatches","epsilon","Slider","SwatchesColor","CheckIcon","SwatchesGroup","group","Swatches","Twitter","hexcode","GooglePointerCircle","GooglePointer","GoogleFields","_values","_values2","hsvValue","rgbValue","hslValue","Google","header","_forOwn2","_forOwn3","transforms","name","otherElementStyles","otherStyle","autoprefix","elements","prefixed","element","expanded","Active","Hover","_isString2","_isString3","_isPlainObject2","_isPlainObject3","_map2","_map3","flattenNames","things","thing","_flattenNames","_flattenNames2","_mergeClasses","_mergeClasses2","_autoprefix","_autoprefix2","_hover2","_hover3","_active","_active2","_loop2","_loop3","ReactCSS","classes","activations","activeNames","merged","loopable","setProp","_cloneDeep2","_cloneDeep3","mergeClasses","toMerge"],"sourceRoot":""} \ No newline at end of file diff --git a/package.json b/package.json index 6ba6621..c171250 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "publishConfig": { "access": "public" }, - "version": "1.0.10", + "version": "1.0.11", "scripts": { "start": "set PORT=4173 && craco start", "lint": "eslint --fix --ext .js,.jsx src",