!function(){let e=[],t={name:null,trigger:null,element:null},n=null,r=null,i=!1;const s=e=>{o(),c(e),l()},c=e=>{t.name&&document.querySelector(".ci-project-content").classList.remove(`ci-${t.name}-visible`),t.name=e.id.replace("-trigger",""),document.querySelector(".ci-project-content").classList.add(`ci-${t.name}-visible`),t.trigger&&t.trigger.classList.remove("ci-selected-project"),t.trigger=e,t.trigger.classList.add("ci-selected-project"),t.element=document.querySelector(`.ci-project-${t.name}`)},l=()=>{n||(n=setInterval(()=>{const n=e.findIndex(e=>e.name===t.name),r=n===e.length-1?0:n+1;c(e[r].trigger)},1e4))},o=()=>{clearInterval(n),n=null},a=()=>{const e=(e=>{const t=e.getBoundingClientRect();return t.top>=0&&t.left>=0&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)})(r);!n&&e?l():n&&!e&&o()},u=e=>{const t=e.target,r=t.dataset.slug,s=t.innerText;!0!==i&&(i=!0,t.innerText="Installing, please wait...",t.classList.add("ci-inisev-prepare"),clearInterval(n),setTimeout(()=>{t.classList.add("ci-inisev-install");let e=new XMLHttpRequest;e.open("POST",ajaxurl,!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.onload=(()=>{if(l(),200===e.status||e.status<400)try{let n=e.responseText;g(n)&&(n=v(n)),void 0!==n.success&&!0===n.success?(t.classList.remove("ci-inisev-install"),t.innerText="Plugin installed successfully :)",setTimeout(()=>{window.location.href=n.data.url},300)):d(t,s)}catch(e){d(t,s)}else d(t,s)}),e.send("action=inisev_installation&slug="+r)},7e3))},d=(e,t)=>{e.innerText="Installation failed...",setTimeout(()=>{e.classList.remove("ci-inisev-install"),setTimeout(()=>{e.classList.remove("ci-inisev-prepare"),e.innerText=t,i=!1})},2e3)},m=e=>{e&&e.addEventListener("click",u)},g=e=>{try{JSON.parse(e)}catch(t){if("string"==typeof e){let t=p(e).indexOf("}");t=0==t?e.length:-t,e=e.slice(e.indexOf("{"),t);try{JSON.parse(e)}catch(e){return!1}return!0}return!1}return!0},p=e=>"string"==typeof e?""===e?"":p(e.substr(1))+e.charAt(0):e,v=e=>{try{JSON.parse(e)}catch(t){if("string"==typeof e){let t=p(e).indexOf("}");t=0==t?e.length:-t,e=e.slice(e.indexOf("{"),t);try{JSON.parse(e)}catch(e){return!1}return JSON.parse(e)}return!1}return JSON.parse(e)};document.addEventListener("DOMContentLoaded",()=>{(()=>{const t=document.querySelectorAll(".ci-project-list-element"),n=document.querySelectorAll(".ci-project");e=Array.from(t).map((e,t)=>({trigger:e,element:n[t],name:e.id.replace("-trigger","")}))})(),c(document.querySelector("#BackupMigration-trigger")),document.querySelectorAll(".ci-project-list-element").forEach(e=>{e.addEventListener("mouseover",t=>(e=>{e.classList.contains("ci-selected-project")?o():s(e)})(e)),e.addEventListener("mouseout",l)}),r=document.querySelector(".ci-carrinis .ci-carousel"),document.addEventListener("scroll",a),document.querySelectorAll(".ci-carrinis .ci-project").forEach(e=>{e.addEventListener("mouseover",o),e.addEventListener("mouseout",l)}),(()=>{const e=document.getElementsByClassName("ci-inisev-install-plugin");for(let t=0;t
/*! For license information please see main.js.LICENSE.txt */ (()=>{var e={851:(e,t,n)=>{"use strict";var r=n(3951),i=n.n(r),o=n(1412),a=n(907),l=n(2458);i()((function(e){return e.className.indexOf("mc4wp-tooltip")>-1})),n(534),n(4644),n(7171),n(1183),window.mc4wp=window.mc4wp||{},window.mc4wp.helpers=l,window.mc4wp.settings=a,window.mc4wp.tabs=o},4644:()=>{var e=document.getElementById("mailchimp_api_key");e&&e.addEventListener("change",(function(t){var n=document.createElement("p");n.className="help red",n.innerText=window.mc4wp_vars.i18n.invalid_api_key,e.nextElementSibling.innerText===n.innerText&&e.nextElementSibling.parentElement.removeChild(e.nextElementSibling),e.value.match(/^[0-9a-zA-Z*]{32}-[a-z]{2}[0-9]{1,2}$/)||e.parentElement.insertBefore(n,e.nextElementSibling)}))},8342:(e,t,n)=>{var r=window.mc4wp_forms_i18n,i=n(865),o={showType:function(e){var t=e.type;return t=t.charAt(0).toUpperCase()+t.slice(1),i("div",[i("label",r.fieldType),i("span",t)])},label:function(e){return i("div",[i("label",r.fieldLabel),i("input.widefat",{type:"text",value:e.label,onchange:function(t){e.label=t.target.value},placeholder:e.title})])},value:function(e){var t="hidden"===e.type;return i("div",[i("label",[t?r.value:r.initialValue," ",t?"":i("small",{style:"float: right; font-weight: normal;"},r.optional)]),i("input.widefat",{type:"text",value:e.value,onchange:function(t){e.value=t.target.value}}),t?"":i("p.help",r.valueHelp)])},numberMinMax:function(e){return i("div",[i("div.row",[i("div.col.col-3",[i("label",r.min),i("input",{type:"number",onchange:function(t){e.min=t.target.value}})]),i("div.col.col-3",[i("label",r.max),i("input",{type:"number",onchange:function(t){e.max=t.target.value}})])])])},isRequired:function(e){var t,n={type:"checkbox",checked:e.required,onchange:function(t){e.required=t.target.checked}};return e.forceRequired&&(n.required=!0,n.disabled=!0,t=i("p.help",r.forceRequired)),i("div",[i("label.cb-wrap",[i("input",n),r.isFieldRequired]),t])},placeholder:function(e){return i("div",[i("label",[r.placeholder," ",i("small",{style:"float: right; font-weight: normal;"},r.optional)]),i("input.widefat",{type:"text",value:e.placeholder,onchange:function(t){e.placeholder=t.target.value},placeholder:""}),i("p.help",r.placeholderHelp)])},useParagraphs:function(e){return i("div",[i("label.cb-wrap",[i("input",{type:"checkbox",checked:e.wrap,onchange:function(t){e.wrap=t.target.checked}}),r.wrapInParagraphTags])])},choiceType:function(e){var t=[i("option",{value:"select",selected:"select"===e.type&&"selected"},r.dropdown),i("option",{value:"radio",selected:"radio"===e.type&&"selected"},r.radioButtons)];return e.acceptsMultipleValues&&t.push(i("option",{value:"checkbox",selected:"checkbox"===e.type&&"selected"},r.checkboxes)),i("div",[i("label",r.choiceType),i("select",{value:e.type,onchange:function(t){e.type=t.target.value}},t)])},choices:function(e){var t=[];return t.push(i("div",[i("label",r.choices),i("div.limit-height",[i("table",e.choices.map((function(t,n){return i("tr",{"data-id":n},[i("td.cb",i("input",{name:"selected",type:"checkbox"===e.type?"checkbox":"radio",onchange:function(t){e.choices=e.choices.map((function(n){return n.value===t.target.value?n.selected=!n.selected:"checkbox"!==e.type&&(n.selected=!1),n}))},checked:t.selected,value:t.value,title:r.preselect})),i("td.stretch",i("input.widefat",{type:"text",value:t.label,placeholder:t.title,onchange:function(e){t.label=e.target.value}})),i("td",i("span",{title:r.remove,class:"dashicons dashicons-no-alt hover-activated",onclick:function(e){this.choices.splice(e,1)}.bind(e,n)},""))])})))])])),t},linkToTerms:function(e){return i("div",[i("label",r.agreeToTermsLink),i("input.widefat",{type:"text",value:e.link,onchange:function(t){e.link=t.target.value},placeholder:"https://..."})])}};e.exports=o},5425:(e,t,n)=>{var r={},i=n(8342);r.render=function(e){var t=e.type;return"function"==typeof r[t]?r[t](e):["select","radio","checkbox"].indexOf(t)>-1?r.choice(e):r.text(e)},r.text=function(e){return[i.label(e),i.placeholder(e),i.value(e),i.isRequired(e),i.useParagraphs(e)]},r.choice=function(e){var t=[i.label(e),i.choiceType(e),i.choices(e)];return"select"===e.type&&t.push(i.placeholder(e)),t.push(i.useParagraphs(e)),"select"!==e.type&&"radio"!==e.type||t.push(i.isRequired(e)),t},r.hidden=function(e){return e.placeholder="",e.label="",e.wrap=!1,[i.showType(e),i.value(e)]},r.submit=function(e){return e.label="",e.placeholder="",[i.value(e),i.useParagraphs(e)]},r["terms-checkbox"]=function(e){return[i.label(e),i.linkToTerms(e),i.isRequired(e),i.useParagraphs(e)]},r.number=function(e){return[r.text(e),i.numberMinMax(e)]},e.exports=r},5756:(e,t,n)=>{var r=n(347),i=n(865),o=function(e){e.dom.checked&&e.dom.setAttribute("checked","true"),e.dom.value&&e.dom.setAttribute("value",e.dom.value),e.dom.selected&&e.dom.setAttribute("selected","true")},a={select:function(e){var t={name:e.name,required:e.required},n=!1,r=e.choices.map((function(e){return e.selected&&(n=!0),i("option",{value:e.value!==e.label?e.value:void 0,selected:e.selected,oncreate:o},e.label)})),a=e.placeholder;return a.length>0&&r.unshift(i("option",{disabled:!0,value:"",selected:!n,oncreate:o},a)),i("select",t,r)},"terms-checkbox":function(e){var t;return t=e.link.length>0?i("a",{href:e.link,target:"_blank"},e.label):e.label,i("label",[i("input",{name:e.name,type:"checkbox",value:e.value,required:e.required})," ",t])},checkbox:function(e){return e.choices.map((function(t){var n=e.name+("checkbox"===e.type?"[]":""),r=e.required&&"radio"===e.type;return i("label",[i("input",{name:n,type:e.type,value:t.value,checked:t.selected,required:r,oncreate:o})," ",i("span",t.label)])}))}};a.radio=a.checkbox,a.default=function(e){var t={type:e.type};return e.name&&(t.name=e.name),e.min&&(t.min=e.min),e.max&&(t.max=e.max),e.value.length>0&&(t.value=e.value),e.placeholder.length>0&&(t.placeholder=e.placeholder),t.required=e.required,t.oncreate=o,i("input",t)},e.exports=function(e){var t=e.label.length>0&&e.showLabel?i("label",{},e.label):"",n="function"==typeof a[e.type]?a[e.type](e):a.default(e),o=e.wrap?i("p",[t,n]):[t,n],l=document.createElement("div");return i.render(l,o),r.prettyPrint(l.innerHTML)+"\n"}},5726:(e,t,n)=>{var r,i=n(865),o=n(7462),a=n(146),l=window.mc4wp_forms_i18n,s=n(5756),c=n(6883),u=n(5425);function d(e){(r=null!==e?a.get(e):null)&&"hidden"===r.type&&r.choices.length>0&&(r.value=r.choices.map((function(e){return e.label})).join("|")),i.redraw()}function f(){var e=s(r);o.insert(e),d(null)}o.on("blur",i.redraw);var h=document.getElementById("mc4wp-field-wizard");h&&i.mount(h,{view:function(){var e=a.getAll(),t=i("div.available-fields.small-margin",[i("h4",l.chooseField),[l.listFields,l.interestCategories,l.formFields].map((function(t){var n=e.filter((function(e){return e.category===t}));return n.length?i("div.tiny-margin",[i("strong",t),n.map((function(e){var t="button";e.forceRequired&&(t+=" is-required");var n=e.inFormContent;return null!==n&&(t+=" "+(n?"in-form":"not-in-form")),i("button",{className:t,type:"button",onclick:function(e){return d(e.target.value)},value:e.name},e.title)}))]):""}))]),n=null;return r&&(n=i(c,{onClose:function(){return d(null)}},i("div.field-wizard",[i("h3",[r.title,r.forceRequired?i("span.red","*"):"",r.name.length?i("code",r.name):""]),r.help.length?i("p",i.trust(r.help)):"",u.render(r),i("p",[i("button",{class:"button-primary",type:"button",onkeydown:function(e){13===e.keyCode&&f()},onclick:f},l.addToForm)])]))),[t,n]}})},3024:(e,t,n)=>{var r=n(865),i=n(146),o=window.mc4wp.settings,a=window.mc4wp_vars.ajaxurl,l=window.mc4wp_forms_i18n,s=window.mc4wp_vars.mailchimp,c=window.mc4wp_vars.countries,u=[];function d(e,t,n){var r=i.register(e,t);n||u.push(r)}function f(e){var t={phone:"tel",dropdown:"select",checkboxes:"checkbox",birthday:"text"};return void 0!==t[e]?t[e]:e}function h(e){var t=l.listFields,n=f(e.type),r={name:e.tag,title:e.name,required:e.required,forceRequired:e.required,type:n,choices:e.options.choices,acceptsMultipleValues:!1};return"address"!==r.type?d(t,r,!1):(d(t,{name:r.name+"[addr1]",type:"text",mailchimpType:"address",title:l.streetAddress},!1),d(t,{name:r.name+"[city]",type:"text",mailchimpType:"address",title:l.city},!1),d(t,{name:r.name+"[state]",type:"text",mailchimpType:"address",title:l.state},!1),d(t,{name:r.name+"[zip]",type:"text",mailchimpType:"address",title:l.zip},!1),d(t,{name:r.name+"[country]",type:"select",mailchimpType:"address",title:l.country,choices:c},!1)),!0}function p(e){var t=f(e.type),n={title:e.title,name:"INTERESTS["+e.id+"]",type:t,choices:e.interests,acceptsMultipleValues:"checkbox"===t};d(l.interestCategories,n,!1)}function m(e){e.merge_fields=e.merge_fields.sort((function(e,t){return"EMAIL"===e.tag||e.public&&!t.public?-1:!e.public&&t.public?1:0})),e.merge_fields.forEach(h),e.interest_categories.forEach(p),r.redraw()}function g(e){var t=a+"?action=mc4wp_get_list_details&ids="+e.map((function(e){return e.id})).join(",");r.request({url:t,method:"GET"}).then((function(e){u.forEach(i.deregister),r.redraw(),e.forEach(m)}))}o.on("selectedLists.change",g),g(o.getSelectedLists()),function(e){var t;for(var n in d(l.listFields,{name:"EMAIL",title:l.emailAddress,required:!0,forceRequired:!0,type:"email"},!0),d(l.formFields,{name:"",value:l.subscribe,type:"submit",title:l.submitButton},!0),t={},e)t[e[n].id]=e[n].name;d(l.formFields,{name:"_mc4wp_lists",type:"checkbox",title:l.listChoice,choices:t,help:l.listChoiceDescription,acceptsMultipleValues:!0},!0),t={subscribe:"Subscribe",unsubscribe:"Unsubscribe"},d(l.formFields,{name:"_mc4wp_action",type:"radio",title:l.formAction,choices:t,value:"subscribe",help:l.formActionDescription},!0),d(l.formFields,{name:"AGREE_TO_TERMS",value:1,type:"terms-checkbox",label:l.agreeToTerms,title:l.agreeToTermsShort,showLabel:!1,required:!0},!0)}(s.lists)},146:e=>{var t={},n={};function r(e){return{name:e.name,title:e.title||e.name,type:e.type,mailchimpType:e.mailchimpType||null,label:e.label||e.title||"",showLabel:"boolean"!=typeof e.showLabel||e.showLabel,value:e.value||"",placeholder:e.placeholder||"",required:"boolean"==typeof e.required&&e.required,forceRequired:"boolean"==typeof e.forceRequired&&e.forceRequired,wrap:"boolean"!=typeof e.wrap||e.wrap,min:e.min,max:e.max,help:e.help||"",choices:e.choices||[],inFormContent:null,acceptsMultipleValues:e.acceptsMultipleValues,link:e.link||""}}function i(e){return{title:e.title||e.label,selected:e.selected||!1,value:e.value||e.label,label:e.label}}function o(){return Object.values(t)}e.exports={get:function(e){return t[e]},getAll:o,getAllWhere:function(e,t){return o().filter((function(n){return n[e]===t}))},deregister:function(e){delete t[e.name]},register:function(e,o){var a=t[o.name];if(a)return!a.forceRequired&&o.forceRequired&&(a.forceRequired=!0),a;o.choices&&(o.choices=function(e){return"function"==typeof e.map?e.map((function(e){return new i({label:e})})):Object.keys(e).map((function(t){return new i({label:e[t],value:t})}))}(o.choices),o.value&&(o.choices=o.choices.map((function(e){return e.value===o.value&&(e.selected=!0),e}))));var l=new r(o);return l.category=e,t[o.name]=l,n["change"]=n.change||[],n.change.forEach((function(e){return e.apply(null,undefined)})),l},on:function(e,t){n[e]=n[e]||[],n[e].push(t)}}},7462:(e,t,n)=>{var r=n(4631);n(9589),n(6876),n(6629),n(6531),n(4786),n(908),n(7341),n(17),n(4328);var i,o,a={},l=document.createElement("form"),s=!1,c=document.getElementById("mc4wp-form-content"),u=document.getElementById("mc4wp-form-preview"),d=/\{[^{}]+\}/g;function f(){var e=u.contentDocument||u.contentWindow.document;(o=e.querySelector(".mc4wp-form-fields"))&&h()}function h(){if(!o)return f();var e=a.getValue();e=e.replace(d,"").replace(d,""),o.innerHTML=e,o.dispatchEvent(new Event("mc4wp-refresh"))}function p(){return s&&(l.innerHTML=a.getValue().toLowerCase(),s=!1),l}a.getValue=function(){return i?i.getValue():c.value},a.query=function(e){return p().querySelectorAll(e.toLowerCase())},a.containsField=function(e){return null!==p().elements.namedItem(e.toLowerCase())},a.insert=function(e){i?(i.replaceSelection(e),i.focus()):c.value+=e},a.on=function(e,t){return i?(e="input"===e?"changes":e,i.on(e,t)):c.addEventListener(e,t)},a.refresh=function(){i&&i.refresh()},c&&(window.addEventListener("load",(function(){r.signal(i,"change")})),c.addEventListener("change",(function(){s=!0,h()})),l.innerHTML=c.value.toLowerCase(),r&&(i=r.fromTextArea(c,{selectionPointer:!0,mode:"htmlmixed",htmlMode:!0,autoCloseTags:!0,autoRefresh:!0,styleActiveLine:!0,matchBrackets:!0,matchTags:{bothTags:!0}}),window.dispatchEvent&&i.on("change",(function(){if("function"==typeof Event){var e=new Event("change",{bubbles:!0});c.dispatchEvent(e)}})))),u&&(u.addEventListener("load",f),f.call()),e.exports=a},2906:(e,t,n)=>{var r=n(865),i=n(2458),o=n(7462),a=n(146),l=/\[(\w+)\]/g,s=/\[\]$/,c=document.getElementById("required-fields");function u(){var e,t;a.getAll().forEach((function(e){if(!(e.name.length<=0)){var t=e.name;if("checkbox"===e.type&&(t+="[]"),e.inFormContent=o.containsField(t),"address"===e.mailchimpType){void 0===e.originalRequiredValue&&(e.originalRequiredValue=e.forceRequired);var n=e.name.replace(l,"");o.query('[name^="'+n+'"]').length>0?e.forceRequired=!0:e.forceRequired=e.originalRequiredValue}}})),e=a.getAllWhere("forceRequired",!0).map((function(e){return e.name.toUpperCase().replace(l,".$1")})),t=o.query("[required]"),[].forEach.call(t,(function(t){var n=t.name;if(n&&!(n.length<0)&&"_"!==n[0]){var r=(n=(n=n.replace(l,".$1")).replace(s,"")).indexOf(".");r=r>0?r:n.length,n=n.substr(0,r).toUpperCase()+n.substr(r),-1===e.indexOf(n)&&e.push(n)}})),c.value=e.join(","),r.redraw()}o.on("change",i.debounce(u,600)),a.on("change",i.debounce(u,600))},2458:e=>{e.exports={debounce:function(e,t,n){var r;return function(){var i=this,o=arguments,a=n&&!r;clearTimeout(r),r=setTimeout((function(){r=null,n||e.apply(i,o)}),t),a&&e.apply(i,o)}}}},534:(e,t,n)=>{var r=window.mc4wp_vars,i=window.mc4wp_vars.i18n,o=window.mc4wp_vars.ajaxurl,a=n(865),l={working:!1,done:!1,success:!1};function s(e){e&&e.preventDefault(),l.working=!0,l.done=!1,a.request({method:"POST",url:o+"?action=mc4wp_renew_mailchimp_lists",timeout:6e5}).then((function(e){l.success=!0,e&&window.setTimeout((function(){window.location.reload()}),3e3)})).catch((function(e){l.success=!1})).finally((function(e){l.working=!1,l.done=!0,a.redraw()}))}var c=document.getElementById("mc4wp-list-fetcher");c&&(r.mailchimp.api_connected&&0===r.mailchimp.lists.length&&s(),a.mount(c,{view:function(){return a("form",{method:"POST",onsubmit:s.bind(this)},[a("p",[a("input",{type:"submit",value:l.working?i.fetching_mailchimp_lists:i.renew_mailchimp_lists,className:"button",disabled:!!l.working}),a.trust("   "),l.working?[a("span.mc4wp-loader","Loading..."),a.trust("   ")]:"",l.done?[l.success?a("em.help.green",i.fetching_mailchimp_lists_done):a("em.help.red",i.fetching_mailchimp_lists_error)]:""])])}}))},7171:(e,t,n)=>{var r=window.mc4wp_vars.ajaxurl,i=n(865);Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var o=document.getElementById("mc4wp-mailchimp-lists-overview");o&&o.addEventListener("click",(function(e){e.target.matches(".mc4wp-mailchimp-list")&&function(e){e.preventDefault();var t=e.target,n=t.parentElement.parentElement.nextElementSibling,o=t.getAttribute("data-list-id"),a=n.querySelector("div");"none"===n.style.display?(i.request({method:"GET",url:r+"?action=mc4wp_get_list_details&ids="+o}).then((function(e){var t;i.render(a,(t=e.shift(),[i("h3","Merge fields"),i("table.widefat.striped",[i("thead",[i("tr",[i("th","Name"),i("th","Tag"),i("th","Type")])]),i("tbody",t.merge_fields.map((function(e){return i("tr",[i("td",[e.name,e.required&&i("span.red","*")]),i("td",[i("code",e.tag)]),i("td",[e.type," ",e.options&&e.options.date_format?"("+e.options.date_format+")":"",e.options&&e.options.choices?"("+e.options.choices.join(", ")+")":""])])})))]),t.interest_categories.length>0&&[i("h3","Interest Categories"),i("table.striped.widefat",[i("thead",[i("tr",[i("th","Name"),i("th","Type"),i("th","Interests")])]),i("tbody",t.interest_categories.map((function(e){return i("tr",[i("td",[i("strong",e.title),i("br"),i("br"),"ID: ",i("code",e.id)]),i("td",e.type),i("td",[i("div.row",{style:"margin-bottom: 4px;"},[i("div.col.col-3",[i("strong",{style:"display: block; border-bottom: 1px solid #eee;"},"Name")]),i("div.col.col-3",[i("strong",{style:"display: block; border-bottom: 1px solid #eee;"},"ID")])]),Object.keys(e.interests).map((function(t){return i("div.row.tiny-margin",[i("div.col.col-3",e.interests[t]),i("div.col.col-3",[i("code",{title:"Interest ID"},t)]),i("br.clearfix.clear.cf")])}))])])})))])]]))})),n.style.display=""):n.style.display="none"}(e)}))},9661:(e,t,n)=>{var r=n(7462),i=n(146),o=n(907),a={};function l(e,t){a[e]=t,c()}function s(e){delete a[e],c()}function c(){var e="";for(var t in a)e+='

'+a[t]+"

";var n=document.querySelector(".mc4wp-notices");if(!n){(n=document.createElement("div")).className="mc4wp-notices";var r=document.querySelector("h1, h2");r.parentNode.insertBefore(n,r.nextSibling)}n.innerHTML=e}var u=function(){r.getValue().toLowerCase().indexOf('name="groupings')>-1?l("deprecated_groupings","Your form contains deprecated GROUPINGS fields.

Please remove these fields from your form and then re-add them through the available field buttons to make sure your data is getting through to Mailchimp correctly."):s("deprecated_groupings")},d=function(){var e=i.getAllWhere("forceRequired",!0).filter((function(e){return!r.containsField(e.name.toUpperCase())})),t="Heads up! Your form is missing list fields that are required in Mailchimp. Either add these fields to your form or mark them as optional in Mailchimp.";t+='
",e.length>0?l("required_fields_missing",t):s("required_fields_missing")};u(),r.on("focus",u),r.on("blur",u),d(),r.on("blur",d),r.on("focus",d),document.body.addEventListener("change",(function(){o.getSelectedLists().length>0?s("no_lists_selected"):l("no_lists_selected",'Heads up! You have not yet selected a Mailchimp list to subscribe people to. Please select at least one list from the settings tab.')}))},6883:(e,t,n)=>{var r=n(865),i=window.mc4wp_forms_i18n;e.exports=function(e){var t,n=e.attrs.onClose;function o(){n.apply(null)}function a(e){27===e.keyCode&&o(),13===e.keyCode&&e.preventDefault()}function l(){var e=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,n=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight,r=(e-t.clientWidth-40)/2,i=(n-t.clientHeight-40)/2;t.style.left=(r>0?r:0)+"px",t.style.top=(i>0?i:0)+"px"}return{oncreate:function(){document.addEventListener("keydown",a),window.addEventListener("resize",l)},onremove:function(){document.removeEventListener("keydown",a),window.removeEventListener("resize",l)},view:function(e){return[r("div.mc4wp-overlay-wrap",r("div.mc4wp-overlay",{oncreate:function(e){t=e.dom,l()}},[r("span",{class:"close dashicons dashicons-no",title:i.close,onclick:o}),e.children])),r("div.mc4wp-overlay-background",{title:i.close,onclick:o})]}}}},907:e=>{function t(e){return(t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var n=document.getElementById("mc4wp-admin").querySelectorAll(".mc4wp-list-input"),r=window.mc4wp_vars.mailchimp.lists,i=[],o={};function a(){var e,a,l;return i=[],[].forEach.call(n,(function(e){("boolean"!=typeof e.checked||e.checked)&&"object"===t(r[e.value])&&i.push(r[e.value])})),e=document.querySelectorAll(".lists--only-selected > *"),[].forEach.call(e,(function(e){var t,n=e.getAttribute("data-list-id"),r=("id",t=n,i.filter((function(e){return e.id===t}))).length>0;e.style.display=r?"":"none"})),l=[i],o[a="selectedLists.change"]=o[a]||[],o[a].forEach((function(e){return e.apply(null,l)})),i}[].forEach.call(n,(function(e){e.addEventListener("change",a)})),a(),e.exports={getSelectedLists:function(){return i},on:function(e,t){o[e]=o[e]||[],o[e].push(t)}}},1183:()=>{var e=document.querySelectorAll("[data-showif]");[].forEach.call(e,(function(e){var t=JSON.parse(e.getAttribute("data-showif")),n=document.querySelectorAll('[name="'+t.element+'"]'),r=e.querySelectorAll("input,select,textarea:not([readonly])"),i=void 0===t.hide||t.hide;function o(){if("radio"!==this.type||this.checked){var n="checkbox"===this.type?this.checked:this.value,o=String(n)===String(t.value);i?(e.style.display=o?"":"none",e.style.visibility=o?"":"hidden"):e.style.opacity=o?"":"0.4",[].forEach.call(r,(function(e){e.readOnly=!o}))}}[].forEach.call(n,(function(e){e.addEventListener("change",o),o.call(e)}))}))},1412:(e,t,n)=>{var r=n(6356),i=document.getElementById("mc4wp-admin"),o=i.querySelectorAll(".tab"),a=i.querySelectorAll(".nav-tab"),l=i.querySelector('input[name="_wp_http_referer"]'),s=[];function c(e){for(var t=0;t{function t(e){var t={},n=e.split("&");for(var r in n)if(n.hasOwnProperty(r)){var i=n[r].split("=");t[decodeURIComponent(i[0])]=decodeURIComponent(i[1])}return t}function n(e){var t=[];for(var n in e)t.push(n+"="+encodeURIComponent(e[n]));return t.join("&")}e.exports={parse:t,build:n,setParameter:function(e,r,i){var o=t(e);return o[r]=i,n(o)}}},8521:(e,t,n)=>{var r=n(7462);n(2906),n(5726),n(3024),n(9661),window.mc4wp.forms=window.mc4wp.forms||{},window.mc4wp.forms.editor=r},8693:()=>{var e=window.wp.i18n.__,t=window.wp.blocks.registerBlockType,n=window.wp.components.SelectControl,r=window.mc4wp_forms;t("mailchimp-for-wp/form",{title:e("Mailchimp for WordPress Form"),description:e("Block showing a Mailchimp for WordPress sign-up form"),category:"widgets",attributes:{id:{type:"int"}},icon:React.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",version:"1.1"},React.createElement("path",{opacity:"1",fill:"#a0a5aa",fillOpacity:"1",stroke:"none",d:"M 8.0097656 0.052734375 A 8 8 0 0 0 0.009765625 8.0527344 A 8 8 0 0 0 8.0097656 16.052734 A 8 8 0 0 0 16.009766 8.0527344 A 8 8 0 0 0 8.0097656 0.052734375 z M 9.2597656 4.171875 C 9.3205456 4.171875 9.9296146 5.0233822 10.611328 6.0664062 C 11.293041 7.1094313 12.296018 8.5331666 12.841797 9.2285156 L 13.833984 10.492188 L 13.316406 11.041016 C 13.031321 11.342334 12.708299 11.587891 12.599609 11.587891 C 12.253798 11.587891 11.266634 10.490156 10.349609 9.0859375 C 9.8610009 8.3377415 9.4126385 7.7229 9.3515625 7.71875 C 9.2904825 7.71455 9.2402344 8.3477011 9.2402344 9.1269531 L 9.2402344 10.544922 L 8.5839844 10.982422 C 8.2233854 11.223015 7.8735746 11.418294 7.8066406 11.417969 C 7.7397106 11.417644 7.4861075 10.997223 7.2421875 10.482422 C 6.9982675 9.9676199 6.6560079 9.3946444 6.4824219 9.2089844 L 6.1679688 8.8710938 L 6.0664062 9.34375 C 5.7203313 10.974656 5.6693219 11.090791 5.0917969 11.505859 C 4.5805569 11.873288 4.2347982 12.017623 4.1914062 11.882812 C 4.1839062 11.859632 4.1482681 11.574497 4.1113281 11.25 C 3.9708341 10.015897 3.5347399 8.7602861 2.8105469 7.5019531 C 2.5672129 7.0791451 2.5711235 7.0651693 2.9765625 6.8320312 C 3.2046215 6.7008903 3.5466561 6.4845105 3.7363281 6.3515625 C 4.0587811 6.1255455 4.1076376 6.1466348 4.4941406 6.6679688 C 4.8138896 7.0992628 4.9275606 7.166285 4.9941406 6.96875 C 5.0960956 6.666263 6.181165 5.8574219 6.484375 5.8574219 C 6.600668 5.8574219 6.8857635 6.1981904 7.1171875 6.6152344 C 7.3486105 7.0322784 7.5790294 7.3728809 7.6308594 7.3730469 C 7.7759584 7.3735219 7.9383234 5.8938023 7.8339844 5.5195312 C 7.7605544 5.2561423 7.8865035 5.0831575 8.4453125 4.6796875 C 8.8327545 4.3999485 9.1989846 4.171875 9.2597656 4.171875 z "})),supports:{html:!1},edit:function(t){var i=r.map((function(e){return{label:e.name,value:e.id}}));return void 0===t.attributes.id&&r.length>0&&t.setAttributes({id:r[0].id}),React.createElement("div",{style:{backgroundColor:"#f8f9f9",padding:"14px"}},React.createElement(n,{label:e("Mailchimp for WordPress Sign-up Form"),value:t.attributes.id,options:i,onChange:function(e){t.setAttributes({id:e})}}))},save:function(e){return null}})},5750:(e,t,n)=>{"use strict";var r,i,o,a,l,s,c=n(7678),u=n.n(c),d=window.mc4wp_submitted_form,f=window.mc4wp.forms;function h(e,t){f.trigger(t[0].id+"."+e,t),f.trigger(e,t)}if(d){var p=document.getElementById(d.element_id);r=f.getByElement(p),i=d.event,o=d.errors,a=d.data,l=Date.now(),s=document.body.clientHeight,o&&r.setData(a),window.scrollY<=10&&d.auto_scroll&&u()(r.element),window.addEventListener("load",(function(){h("submitted",[r]),o?h("error",[r,o]):(h("success",[r,a]),h(i,[r,a]),"updated_subscriber"===i&&h("subscribed",[r,a,!0]));var e=Date.now()-l;d.auto_scroll&&e>1e3&&e<2e3&&document.body.clientHeight!==s&&u()(r.element)}))}},7661:(e,t,n)=>{var r=window.mc4wp||{},i=n(8592);function o(e,t){i.trigger(t[0].id+"."+e,t),i.trigger(e,t)}function a(e,t){document.addEventListener(e,(function(e){if(e.target){var n=e.target,r=!1;"string"==typeof n.className&&(r=n.className.indexOf("mc4wp-form")>-1),r||"function"!=typeof n.matches||(r=n.matches(".mc4wp-form *")),r&&t.call(e,e)}}),!0)}if(n(1677),a("submit",(function(e){var t=i.getByElement(e.target);e.defaultPrevented||i.trigger(t.id+".submit",[t,e]),e.defaultPrevented||i.trigger("submit",[t,e])})),a("focus",(function(e){var t=i.getByElement(e.target);t.started||(o("started",[t,e]),t.started=!0)})),a("change",(function(e){o("change",[i.getByElement(e.target),e])})),r.listeners){for(var l=r.listeners,s=0;s{function e(e){for(var t=!!e.getAttribute("data-show-if"),n=t?e.getAttribute("data-show-if").split(":"):e.getAttribute("data-hide-if").split(":"),r=n[0],i=(n.length>1?n[1]:"*").split("|"),o=function(e,t){for(var n=[],r=e.querySelectorAll('input[name="'+t+'"],select[name="'+t+'"],textarea[name="'+t+'"]'),i=0;i-1||i.indexOf("*")>-1&&s.length>0)break}e.style.display=t?a?"":"none":a?"none":"";var c=e.querySelectorAll("input,select,textarea");[].forEach.call(c,(function(e){(a||t)&&e.getAttribute("data-was-required")&&(e.required=!0,e.removeAttribute("data-was-required")),a&&t||!e.required||(e.setAttribute("data-was-required","true"),e.required=!1)}))}function t(){var t=document.querySelectorAll(".mc4wp-form [data-show-if],.mc4wp-form [data-hide-if]");[].forEach.call(t,e)}function n(t){if(t.target&&t.target.form&&!(t.target.form.className.indexOf("mc4wp-form")<0)){var n=t.target.form.querySelectorAll("[data-show-if],[data-hide-if]");[].forEach.call(n,e)}}document.addEventListener("keyup",n,!0),document.addEventListener("change",n,!0),document.addEventListener("mc4wp-refresh",t,!0),window.addEventListener("load",t),t()},2573:(e,t,n)=>{var r=n(7422),i=n(3409),o=function(e,t){this.id=e,this.element=t||document.createElement("form"),this.name=this.element.getAttribute("data-name")||"Form #"+this.id,this.errors=[],this.started=!1};o.prototype.setData=function(e){try{i(this.element,e)}catch(e){console.error(e)}},o.prototype.getData=function(){return r(this.element,{hash:!0,empty:!0})},o.prototype.getSerializedData=function(){return r(this.element,{hash:!1,empty:!0})},o.prototype.setResponse=function(e){this.element.querySelector(".mc4wp-response").innerHTML=e},o.prototype.reset=function(){this.setResponse(""),this.element.querySelector(".mc4wp-form-fields").style.display="",this.element.reset()},e.exports=o},8592:(e,t,n)=>{var r=n(2573),i=[],o={};function a(e,t){o[e]=o[e]||[],o[e].forEach((function(e){return e.apply(null,t)}))}function l(e,t){t=t||parseInt(e.getAttribute("data-id"))||0;var n=new r(t,e);return i.push(n),n}e.exports={get:function(e){e=parseInt(e);for(var t=0;t0?a(e,t):window.setTimeout((function(){a(e,t)}),1)}}},786:()=>{var e=window.mc4wp_vars.ajaxurl,t=window.mc4wp.settings,n=document.getElementById("notice-additional-fields");function r(){var t=[].filter.call(document.querySelectorAll(".mc4wp-list-input"),(function(e){return e.checked})).map((function(e){return e.value})).join(","),r=["EMAIL","FNAME","NAME","LNAME"],i=!1;window.fetch("".concat(e,"?action=mc4wp_get_list_details&ids=").concat(t)).then((function(e){return e.json()})).then((function(e){e.forEach((function(e){e.merge_fields.forEach((function(e){e.required&&r.indexOf(e.tag)<0&&(i=!0)}))}))})).finally((function(){n.style.display=i?"":"none"}))}n&&(r(),t.on("selectedLists.change",r))},7678:e=>{e.exports=function(e){var t,n,r,i,o,a,l,s,c=window.pageXOffset||document.documentElement.scrollLeft,u=(t=e,n=document.body,r=document.documentElement,i=t.getBoundingClientRect(),o=r.clientHeight,a=Math.max(n.scrollHeight,n.offsetHeight,r.clientHeight,r.scrollHeight,r.offsetHeight),l=i.bottom-o/2-i.height/2,s=a-o,Math.min(l+window.pageYOffset,s));window.scrollTo(c,u)}},6315:function(){!function(e){"use strict";var t=void 0!==document.createElement("input").placeholder;if(e.Placeholders={nativeSupport:t,disable:t?L:z,enable:t?L:function(e){_(e,D)}},!t){var n,r=["text","search","url","tel","email","password","number","textarea"],i=[27,33,34,35,36,37,38,39,40,8,46],o=new RegExp("(?:^|\\s)placeholdersjs(?!\\S)"),a="data-placeholder-value",l="data-placeholder-active",s="data-placeholder-type",c="data-placeholder-submit",u="data-placeholder-bound",d="data-placeholder-maxlength",f=document.getElementsByTagName("head")[0],h=document.documentElement,p=e.Placeholders,m=document.getElementsByTagName("input"),g=document.getElementsByTagName("textarea"),v="false"===h.getAttribute("data-placeholder-focus"),y="false"!==h.getAttribute("data-placeholder-live"),b=document.createElement("style");b.type="text/css";var w,x,k=document.createTextNode(".placeholdersjs {color:#ccc;}");b.styleSheet?b.styleSheet.cssText=k.nodeValue:b.appendChild(k),f.insertBefore(b,f.firstChild);for(var C=0,S=m.length+g.length;C=0&&(e.setAttribute("maxLength",i),e.removeAttribute(d));var c=e.getAttribute(s);return c&&(e.type=c),!0}return!1}function D(e){var t=e.getAttribute(a);return!(""!==e.value||!t||(e.setAttribute(l,"true"),e.value=t,e.className+=" placeholdersjs",e.getAttribute(d)||(e.setAttribute(d,e.maxLength),e.removeAttribute("maxLength")),e.getAttribute(s)?e.type="text":"password"===e.type&&O(e,"text")&&e.setAttribute(s,"password"),0))}function I(e){var t=e.form;t&&"string"==typeof t&&((t=document.getElementById(t)).getAttribute(c)||(N(t,"submit",function(e){return function(){z(e)}}(t)),t.setAttribute(c,"true"))),N(e,"focus",function(e){return function(){v&&e.value===e.getAttribute(a)&&"true"===e.getAttribute(l)?E(e,0):P(e)}}(e)),N(e,"blur",function(e){return function(){D(e)}}(e)),v&&(N(e,"keydown",function(e){return function(t){if(n=e.value,"true"===e.getAttribute(l)&&n===e.getAttribute(a)&&A(i,t.keyCode))return t.preventDefault&&t.preventDefault(),!1}}(e)),N(e,"keyup",function(e){return function(){P(e,n),""===e.value&&(e.blur(),E(e,0))}}(e)),N(e,"click",function(e){return function(){e===M()&&e.value===e.getAttribute(a)&&"true"===e.getAttribute(l)&&E(e,0)}}(e))),e.setAttribute(u,"true"),e.setAttribute(a,w),(v||e!==M())&&D(e)}}(this)},7341:(e,t,n)=>{!function(e){e.defineOption("autoCloseTags",!1,(function(a,l,s){if(s!=e.Init&&s&&a.removeKeyMap("autoCloseTags"),l){var c={name:"autoCloseTags"};"object"==typeof l&&!1===l.whenClosing||(c["'/'"]=function(t){return function(t){return t.getOption("disableInput")?e.Pass:r(t,!0)}(t)}),"object"==typeof l&&!1===l.whenOpening||(c["'>'"]=function(r){return function(r){if(r.getOption("disableInput"))return e.Pass;for(var a=r.listSelections(),l=[],s=r.getOption("autoCloseTags"),c=0;cu.ch&&(m=m.slice(0,m.length-d.end+u.ch));var b=m.toLowerCase();if(!m||"string"==d.type&&(d.end!=u.ch||!/[\"\']/.test(d.string.charAt(d.string.length-1))||1==d.string.length)||"tag"==d.type&&p.close||d.string.indexOf("/")==u.ch-d.start-1||v&&i(v,b)>-1||o(r,f.mode.xmlCurrentContext&&f.mode.xmlCurrentContext(h)||[],m,u,!0))return e.Pass;var w="object"==typeof s&&s.emptyTags;if(w&&i(w,m)>-1)l[c]={text:"/>",newPos:e.Pos(u.line,u.ch+2)};else{var x=y&&i(y,b)>-1;l[c]={indent:x,text:">"+(x?"\n\n":"")+"",newPos:x?e.Pos(u.line+1,0):e.Pos(u.line,u.ch+1)}}}var k="object"==typeof s&&s.dontIndentOnAutoClose;for(c=a.length-1;c>=0;c--){var C=l[c];r.replaceRange(C.text,a[c].head,a[c].anchor,"+insert");var S=r.listSelections().slice(0);S[c]={head:C.newPos,anchor:C.newPos},r.setSelections(S),!k&&C.indent&&(r.indentLine(C.newPos.line,null,!0),r.indentLine(C.newPos.line+1,null,!0))}}(r)}),a.addKeyMap(c)}}));var t=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],n=["applet","blockquote","body","button","div","dl","fieldset","form","frameset","h1","h2","h3","h4","h5","h6","head","html","iframe","layer","legend","object","ol","p","select","table","ul"];function r(t,n){for(var r=t.listSelections(),i=[],a=n?"/":""!=t.getLine(u.line).charAt(d.end)&&(p+=">"),i[c]=p}if(t.replaceSelections(i),r=t.listSelections(),!s)for(c=0;c=0&&n[c]==r;c--)++s;for(i=l.to,c=1;c{!function(e){var t=/MSIE \d/.test(navigator.userAgent)&&(null==document.documentMode||document.documentMode<8),n=e.Pos,r={"(":")>",")":"(<","[":"]>","]":"[<","{":"}>","}":"{<","<":">>",">":"<<"};function i(e){return e&&e.bracketRegex||/[(){}[\]]/}function o(e,t,o){var l=e.getLineHandle(t.line),s=t.ch-1,c=o&&o.afterCursor;null==c&&(c=/(^| )cm-fat-cursor($| )/.test(e.getWrapperElement().className));var u=i(o),d=!c&&s>=0&&u.test(l.text.charAt(s))&&r[l.text.charAt(s)]||u.test(l.text.charAt(s+1))&&r[l.text.charAt(++s)];if(!d)return null;var f=">"==d.charAt(1)?1:-1;if(o&&o.strict&&f>0!=(s==t.ch))return null;var h=e.getTokenTypeAt(n(t.line,s+1)),p=a(e,n(t.line,s+(f>0?1:0)),f,h,o);return null==p?null:{from:n(t.line,s),to:p&&p.pos,match:p&&p.ch==d.charAt(0),forward:f>0}}function a(e,t,o,a,l){for(var s=l&&l.maxScanLineLength||1e4,c=l&&l.maxScanLines||1e3,u=[],d=i(l),f=o>0?Math.min(t.line+c,e.lastLine()+1):Math.max(e.firstLine()-1,t.line-c),h=t.line;h!=f;h+=o){var p=e.getLine(h);if(p){var m=o>0?0:p.length-1,g=o>0?p.length:-1;if(!(p.length>s))for(h==t.line&&(m=t.ch-(o<0?1:0));m!=g;m+=o){var v=p.charAt(m);if(d.test(v)&&(void 0===a||(e.getTokenTypeAt(n(h,m+1))||"")==(a||""))){var y=r[v];if(y&&">"==y.charAt(1)==o>0)u.push(v);else{if(!u.length)return{pos:n(h,m),ch:v};u.pop()}}}}}return h-o!=(o>0?e.lastLine():e.firstLine())&&null}function l(e,r,i){for(var a=e.state.matchBrackets.maxHighlightLineLength||1e3,l=i&&i.highlightNonMatching,s=[],c=e.listSelections(),u=0;u{!function(e){"use strict";function t(e){e.state.tagHit&&e.state.tagHit.clear(),e.state.tagOther&&e.state.tagOther.clear(),e.state.tagHit=e.state.tagOther=null}function n(n){n.state.failedTagMatch=!1,n.operation((function(){if(t(n),!n.somethingSelected()){var r=n.getCursor(),i=n.getViewport();i.from=Math.min(i.from,r.line),i.to=Math.max(r.line+1,i.to);var o=e.findMatchingTag(n,r,i);if(o){if(n.state.matchBothTags){var a="open"==o.at?o.open:o.close;a&&(n.state.tagHit=n.markText(a.from,a.to,{className:"CodeMirror-matchingtag"}))}var l="close"==o.at?o.open:o.close;l?n.state.tagOther=n.markText(l.from,l.to,{className:"CodeMirror-matchingtag"}):n.state.failedTagMatch=!0}}}))}function r(e){e.state.failedTagMatch&&n(e)}e.defineOption("matchTags",!1,(function(i,o,a){a&&a!=e.Init&&(i.off("cursorActivity",n),i.off("viewportChange",r),t(i)),o&&(i.state.matchBothTags="object"==typeof o&&o.bothTags,i.on("cursorActivity",n),i.on("viewportChange",r),n(i))})),e.commands.toMatchingTag=function(t){var n=e.findMatchingTag(t,t.getCursor());if(n){var r="close"==n.at?n.open:n.close;r&&t.extendSelection(r.to,r.from)}}}(n(4631),n(4786))},4786:(e,t,n)=>{!function(e){"use strict";var t=e.Pos;function n(e,t){return e.line-t.line||e.ch-t.ch}var r="A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",i=new RegExp("<(/?)(["+r+"]["+r+"-:.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*)","g");function o(e,t,n,r){this.line=t,this.ch=n,this.cm=e,this.text=e.getLine(t),this.min=r?Math.max(r.from,e.firstLine()):e.firstLine(),this.max=r?Math.min(r.to-1,e.lastLine()):e.lastLine()}function a(e,n){var r=e.cm.getTokenTypeAt(t(e.line,n));return r&&/\btag\b/.test(r)}function l(e){if(!(e.line>=e.max))return e.ch=0,e.text=e.cm.getLine(++e.line),!0}function s(e){if(!(e.line<=e.min))return e.text=e.cm.getLine(--e.line),e.ch=e.text.length,!0}function c(e){for(;;){var t=e.text.indexOf(">",e.ch);if(-1==t){if(l(e))continue;return}if(a(e,t+1)){var n=e.text.lastIndexOf("/",t),r=n>-1&&!/\S/.test(e.text.slice(n+1,t));return e.ch=t+1,r?"selfClose":"regular"}e.ch=t+1}}function u(e){for(;;){var t=e.ch?e.text.lastIndexOf("<",e.ch-1):-1;if(-1==t){if(s(e))continue;return}if(a(e,t+1)){i.lastIndex=t,e.ch=t;var n=i.exec(e.text);if(n&&n.index==t)return n}else e.ch=t}}function d(e){for(;;){i.lastIndex=e.ch;var t=i.exec(e.text);if(!t){if(l(e))continue;return}if(a(e,t.index+1))return e.ch=t.index+t[0].length,t;e.ch=t.index+1}}function f(e){for(;;){var t=e.ch?e.text.lastIndexOf(">",e.ch-1):-1;if(-1==t){if(s(e))continue;return}if(a(e,t+1)){var n=e.text.lastIndexOf("/",t),r=n>-1&&!/\S/.test(e.text.slice(n+1,t));return e.ch=t+1,r?"selfClose":"regular"}e.ch=t}}function h(e,n){for(var r=[];;){var i,o=d(e),a=e.line,l=e.ch-(o?o[0].length:0);if(!o||!(i=c(e)))return;if("selfClose"!=i)if(o[1]){for(var s=r.length-1;s>=0;--s)if(r[s]==o[2]){r.length=s;break}if(s<0&&(!n||n==o[2]))return{tag:o[2],from:t(a,l),to:t(e.line,e.ch)}}else r.push(o[2])}}function p(e,n){for(var r=[];;){var i=f(e);if(!i)return;if("selfClose"!=i){var o=e.line,a=e.ch,l=u(e);if(!l)return;if(l[1])r.push(l[2]);else{for(var s=r.length-1;s>=0;--s)if(r[s]==l[2]){r.length=s;break}if(s<0&&(!n||n==l[2]))return{tag:l[2],from:t(e.line,e.ch),to:t(o,a)}}}else u(e)}}e.registerHelper("fold","xml",(function(e,r){for(var i=new o(e,r.line,0);;){var a=d(i);if(!a||i.line!=r.line)return;var l=c(i);if(!l)return;if(!a[1]&&"selfClose"!=l){var s=t(i.line,i.ch),u=h(i,a[2]);return u&&n(u.from,s)>0?{from:s,to:u.from}:null}}})),e.findMatchingTag=function(e,r,i){var a=new o(e,r.line,r.ch,i);if(-1!=a.text.indexOf(">")||-1!=a.text.indexOf("<")){var l=c(a),s=l&&t(a.line,a.ch),d=l&&u(a);if(l&&d&&!(n(a,r)>0)){var f={from:t(a.line,a.ch),to:s,tag:d[2]};return"selfClose"==l?{open:f,close:null,at:"open"}:d[1]?{open:p(a,d[2]),close:f,at:"close"}:{open:f,close:h(a=new o(e,s.line,s.ch,i),d[2]),at:"open"}}}},e.findEnclosingTag=function(e,t,n,r){for(var i=new o(e,t.line,t.ch,n);;){var a=p(i,r);if(!a)break;var l=h(new o(e,t.line,t.ch,n),a.tag);if(l)return{open:a,close:l}}},e.scanForClosingTag=function(e,t,n,r){return h(new o(e,t.line,t.ch,r?{from:0,to:r}:null),n)}}(n(4631))},17:(e,t,n)=>{!function(e){"use strict";var t="CodeMirror-activeline",n="CodeMirror-activeline-background",r="CodeMirror-activeline-gutter";function i(e){for(var i=0;i2),g=/Android/.test(e),v=m||g||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(e),y=m||/Mac/.test(t),b=/\bCrOS\b/.test(e),w=/win/i.test(t),x=d&&e.match(/Version\/(\d*\.\d*)/);x&&(x=Number(x[1])),x&&x>=15&&(d=!1,s=!0);var k=y&&(c||d&&(null==x||x<12.11)),C=n||a&&l>=9;function S(e){return new RegExp("(^|\\s)"+e+"(?:$|\\s)\\s*")}var T,L=function(e,t){var n=e.className,r=S(t).exec(n);if(r){var i=n.slice(r.index+r[0].length);e.className=n.slice(0,r.index)+(i?r[1]+i:"")}};function M(e){for(var t=e.childNodes.length;t>0;--t)e.removeChild(e.firstChild);return e}function A(e,t){return M(e).appendChild(t)}function N(e,t,n,r){var i=document.createElement(e);if(n&&(i.className=n),r&&(i.style.cssText=r),"string"==typeof t)i.appendChild(document.createTextNode(t));else if(t)for(var o=0;o=t)return a+(t-o);a+=l-o,a+=n-a%n,o=l+1}}m?D=function(e){e.selectionStart=0,e.selectionEnd=e.value.length}:a&&(D=function(e){try{e.select()}catch(e){}});var H=function(){this.id=null,this.f=null,this.time=0,this.handler=I(this.onTimeout,this)};function R(e,t){for(var n=0;n=t)return r+Math.min(a,t-i);if(i+=o-r,r=o+1,(i+=n-i%n)>=t)return r}}var V=[""];function G(e){for(;V.length<=e;)V.push($(V)+" ");return V[e]}function $(e){return e[e.length-1]}function Y(e,t){for(var n=[],r=0;r"€"&&(e.toUpperCase()!=e.toLowerCase()||J.test(e))}function ee(e,t){return t?!!(t.source.indexOf("\\w")>-1&&Q(e))||t.test(e):Q(e)}function te(e){for(var t in e)if(e.hasOwnProperty(t)&&e[t])return!1;return!0}var ne=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function re(e){return e.charCodeAt(0)>=768&&ne.test(e)}function ie(e,t,n){for(;(n<0?t>0:tn?-1:1;;){if(t==n)return t;var i=(t+n)/2,o=r<0?Math.ceil(i):Math.floor(i);if(o==t)return e(o)?t:n;e(o)?n=o:t=o+r}}var ae=null;function le(e,t,n){var r;ae=null;for(var i=0;it)return i;o.to==t&&(o.from!=o.to&&"before"==n?r=i:ae=i),o.from==t&&(o.from!=o.to&&"before"!=n?r=i:ae=i)}return null!=r?r:ae}var se=function(){var e=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,t=/[stwN]/,n=/[LRr]/,r=/[Lb1n]/,i=/[1n]/;function o(e,t,n){this.level=e,this.from=t,this.to=n}return function(a,l){var s,c="ltr"==l?"L":"R";if(0==a.length||"ltr"==l&&!e.test(a))return!1;for(var u=a.length,d=[],f=0;f-1&&(r[t]=i.slice(0,o).concat(i.slice(o+1)))}}}function pe(e,t){var n=fe(e,t);if(n.length)for(var r=Array.prototype.slice.call(arguments,2),i=0;i0}function ye(e){e.prototype.on=function(e,t){de(this,e,t)},e.prototype.off=function(e,t){he(this,e,t)}}function be(e){e.preventDefault?e.preventDefault():e.returnValue=!1}function we(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}function xe(e){return null!=e.defaultPrevented?e.defaultPrevented:0==e.returnValue}function ke(e){be(e),we(e)}function Ce(e){return e.target||e.srcElement}function Se(e){var t=e.which;return null==t&&(1&e.button?t=1:2&e.button?t=3:4&e.button&&(t=2)),y&&e.ctrlKey&&1==t&&(t=3),t}var Te,Le,Me=function(){if(a&&l<9)return!1;var e=N("div");return"draggable"in e||"dragDrop"in e}();function Ae(e){if(null==Te){var t=N("span","​");A(e,N("span",[t,document.createTextNode("x")])),0!=e.firstChild.offsetHeight&&(Te=t.offsetWidth<=1&&t.offsetHeight>2&&!(a&&l<8))}var n=Te?N("span","​"):N("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px");return n.setAttribute("cm-text",""),n}function Ne(e){if(null!=Le)return Le;var t=A(e,document.createTextNode("AخA")),n=T(t,0,1).getBoundingClientRect(),r=T(t,1,2).getBoundingClientRect();return M(e),!(!n||n.left==n.right)&&(Le=r.right-n.right<3)}var Ee,Oe=3!="\n\nb".split(/\n/).length?function(e){for(var t=0,n=[],r=e.length;t<=r;){var i=e.indexOf("\n",t);-1==i&&(i=e.length);var o=e.slice(t,"\r"==e.charAt(i-1)?i-1:i),a=o.indexOf("\r");-1!=a?(n.push(o.slice(0,a)),t+=a+1):(n.push(o),t=i+1)}return n}:function(e){return e.split(/\r\n?|\n/)},_e=window.getSelection?function(e){try{return e.selectionStart!=e.selectionEnd}catch(e){return!1}}:function(e){var t;try{t=e.ownerDocument.selection.createRange()}catch(e){}return!(!t||t.parentElement()!=e)&&0!=t.compareEndPoints("StartToEnd",t)},ze="oncopy"in(Ee=N("div"))||(Ee.setAttribute("oncopy","return;"),"function"==typeof Ee.oncopy),Pe=null;var De={},Ie={};function We(e,t){arguments.length>2&&(t.dependencies=Array.prototype.slice.call(arguments,2)),De[e]=t}function Fe(e){if("string"==typeof e&&Ie.hasOwnProperty(e))e=Ie[e];else if(e&&"string"==typeof e.name&&Ie.hasOwnProperty(e.name)){var t=Ie[e.name];"string"==typeof t&&(t={name:t}),(e=Z(t,e)).name=t.name}else{if("string"==typeof e&&/^[\w\-]+\/[\w\-]+\+xml$/.test(e))return Fe("application/xml");if("string"==typeof e&&/^[\w\-]+\/[\w\-]+\+json$/.test(e))return Fe("application/json")}return"string"==typeof e?{name:e}:e||{name:"null"}}function He(e,t){t=Fe(t);var n=De[t.name];if(!n)return He(e,"text/plain");var r=n(e,t);if(Re.hasOwnProperty(t.name)){var i=Re[t.name];for(var o in i)i.hasOwnProperty(o)&&(r.hasOwnProperty(o)&&(r["_"+o]=r[o]),r[o]=i[o])}if(r.name=t.name,t.helperType&&(r.helperType=t.helperType),t.modeProps)for(var a in t.modeProps)r[a]=t.modeProps[a];return r}var Re={};function je(e,t){W(t,Re.hasOwnProperty(e)?Re[e]:Re[e]={})}function Be(e,t){if(!0===t)return t;if(e.copyState)return e.copyState(t);var n={};for(var r in t){var i=t[r];i instanceof Array&&(i=i.concat([])),n[r]=i}return n}function qe(e,t){for(var n;e.innerMode&&(n=e.innerMode(t))&&n.mode!=e;)t=n.state,e=n.mode;return n||{mode:e,state:t}}function Ue(e,t,n){return!e.startState||e.startState(t,n)}var Ke=function(e,t,n){this.pos=this.start=0,this.string=e,this.tabSize=t||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=n};function Ve(e,t){if((t-=e.first)<0||t>=e.size)throw new Error("There is no line "+(t+e.first)+" in the document.");for(var n=e;!n.lines;)for(var r=0;;++r){var i=n.children[r],o=i.chunkSize();if(t=e.first&&tn?et(n,Ve(e,n).text.length):function(e,t){var n=e.ch;return null==n||n>t?et(e.line,t):n<0?et(e.line,0):e}(t,Ve(e,t.line).text.length)}function st(e,t){for(var n=[],r=0;r=this.string.length},Ke.prototype.sol=function(){return this.pos==this.lineStart},Ke.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},Ke.prototype.next=function(){if(this.post},Ke.prototype.eatSpace=function(){for(var e=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>e},Ke.prototype.skipToEnd=function(){this.pos=this.string.length},Ke.prototype.skipTo=function(e){var t=this.string.indexOf(e,this.pos);if(t>-1)return this.pos=t,!0},Ke.prototype.backUp=function(e){this.pos-=e},Ke.prototype.column=function(){return this.lastColumnPos0?null:(r&&!1!==t&&(this.pos+=r[0].length),r)}var i=function(e){return n?e.toLowerCase():e};if(i(this.string.substr(this.pos,e.length))==i(e))return!1!==t&&(this.pos+=e.length),!0},Ke.prototype.current=function(){return this.string.slice(this.start,this.pos)},Ke.prototype.hideFirstChars=function(e,t){this.lineStart+=e;try{return t()}finally{this.lineStart-=e}},Ke.prototype.lookAhead=function(e){var t=this.lineOracle;return t&&t.lookAhead(e)},Ke.prototype.baseToken=function(){var e=this.lineOracle;return e&&e.baseToken(this.pos)};var ct=function(e,t){this.state=e,this.lookAhead=t},ut=function(e,t,n,r){this.state=t,this.doc=e,this.line=n,this.maxLookAhead=r||0,this.baseTokens=null,this.baseTokenPos=1};function dt(e,t,n,r){var i=[e.state.modeGen],o={};wt(e,t.text,e.doc.mode,n,(function(e,t){return i.push(e,t)}),o,r);for(var a=n.state,l=function(r){n.baseTokens=i;var l=e.state.overlays[r],s=1,c=0;n.state=!0,wt(e,t.text,l.mode,n,(function(e,t){for(var n=s;ce&&i.splice(s,1,e,i[s+1],r),s+=2,c=Math.min(e,r)}if(t)if(l.opaque)i.splice(n,s-n,e,"overlay "+t),s=n+2;else for(;ne.options.maxHighlightLength&&Be(e.doc.mode,r.state),o=dt(e,t,r);i&&(r.state=i),t.stateAfter=r.save(!i),t.styles=o.styles,o.classes?t.styleClasses=o.classes:t.styleClasses&&(t.styleClasses=null),n===e.doc.highlightFrontier&&(e.doc.modeFrontier=Math.max(e.doc.modeFrontier,++e.doc.highlightFrontier))}return t.styles}function ht(e,t,n){var r=e.doc,i=e.display;if(!r.mode.startState)return new ut(r,!0,t);var o=function(e,t,n){for(var r,i,o=e.doc,a=n?-1:t-(e.doc.mode.innerMode?1e3:100),l=t;l>a;--l){if(l<=o.first)return o.first;var s=Ve(o,l-1),c=s.stateAfter;if(c&&(!n||l+(c instanceof ct?c.lookAhead:0)<=o.modeFrontier))return l;var u=F(s.text,null,e.options.tabSize);(null==i||r>u)&&(i=l-1,r=u)}return i}(e,t,n),a=o>r.first&&Ve(r,o-1).stateAfter,l=a?ut.fromSaved(r,a,o):new ut(r,Ue(r.mode),o);return r.iter(o,t,(function(n){pt(e,n.text,l);var r=l.line;n.stateAfter=r==t-1||r%5==0||r>=i.viewFrom&&rt.start)return o}throw new Error("Mode "+e.name+" failed to advance stream.")}ut.prototype.lookAhead=function(e){var t=this.doc.getLine(this.line+e);return null!=t&&e>this.maxLookAhead&&(this.maxLookAhead=e),t},ut.prototype.baseToken=function(e){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=e;)this.baseTokenPos+=2;var t=this.baseTokens[this.baseTokenPos+1];return{type:t&&t.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-e}},ut.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},ut.fromSaved=function(e,t,n){return t instanceof ct?new ut(e,Be(e.mode,t.state),n,t.lookAhead):new ut(e,Be(e.mode,t),n)},ut.prototype.save=function(e){var t=!1!==e?Be(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new ct(t,this.maxLookAhead):t};var vt=function(e,t,n){this.start=e.start,this.end=e.pos,this.string=e.current(),this.type=t||null,this.state=n};function yt(e,t,n,r){var i,o,a=e.doc,l=a.mode,s=Ve(a,(t=lt(a,t)).line),c=ht(e,t.line,n),u=new Ke(s.text,e.options.tabSize,c);for(r&&(o=[]);(r||u.pose.options.maxHighlightLength?(l=!1,a&&pt(e,t,r,d.pos),d.pos=t.length,s=null):s=bt(gt(n,d,r.state,f),o),f){var h=f[0].name;h&&(s="m-"+(s?h+" "+s:h))}if(!l||u!=s){for(;c=t:o.to>t);(r||(r=[])).push(new Ct(a,o.from,l?null:o.to))}}return r}(n,i,a),s=function(e,t,n){var r;if(e)for(var i=0;i=t:o.to>t)||o.from==t&&"bookmark"==a.type&&(!n||o.marker.insertLeft)){var l=null==o.from||(a.inclusiveLeft?o.from<=t:o.from0&&l)for(var b=0;bt)&&(!n||_t(n,o.marker)<0)&&(n=o.marker)}return n}function Wt(e,t,n,r,i){var o=Ve(e,t),a=kt&&o.markedSpans;if(a)for(var l=0;l=0&&d<=0||u<=0&&d>=0)&&(u<=0&&(s.marker.inclusiveRight&&i.inclusiveLeft?tt(c.to,n)>=0:tt(c.to,n)>0)||u>=0&&(s.marker.inclusiveRight&&i.inclusiveLeft?tt(c.from,r)<=0:tt(c.from,r)<0)))return!0}}}function Ft(e){for(var t;t=Pt(e);)e=t.find(-1,!0).line;return e}function Ht(e,t){var n=Ve(e,t),r=Ft(n);return n==r?t:Xe(r)}function Rt(e,t){if(t>e.lastLine())return t;var n,r=Ve(e,t);if(!jt(e,r))return t;for(;n=Dt(r);)r=n.find(1,!0).line;return Xe(r)+1}function jt(e,t){var n=kt&&t.markedSpans;if(n)for(var r=void 0,i=0;it.maxLineLength&&(t.maxLineLength=n,t.maxLine=e)}))}var Vt=function(e,t,n){this.text=e,Nt(this,t),this.height=n?n(this):1};function Gt(e){e.parent=null,At(e)}Vt.prototype.lineNo=function(){return Xe(this)},ye(Vt);var $t={},Yt={};function Xt(e,t){if(!e||/^\s*$/.test(e))return null;var n=t.addModeClass?Yt:$t;return n[e]||(n[e]=e.replace(/\S+/g,"cm-$&"))}function Zt(e,t){var n=E("span",null,null,s?"padding-right: .1px":null),r={pre:E("pre",[n],"CodeMirror-line"),content:n,col:0,pos:0,cm:e,trailingSpace:!1,splitSpaces:e.getOption("lineWrapping")};t.measure={};for(var i=0;i<=(t.rest?t.rest.length:0);i++){var o=i?t.rest[i-1]:t.line,a=void 0;r.pos=0,r.addToken=Qt,Ne(e.display.measure)&&(a=ce(o,e.doc.direction))&&(r.addToken=en(r.addToken,a)),r.map=[],nn(o,r,ft(e,o,t!=e.display.externalMeasured&&Xe(o))),o.styleClasses&&(o.styleClasses.bgClass&&(r.bgClass=P(o.styleClasses.bgClass,r.bgClass||"")),o.styleClasses.textClass&&(r.textClass=P(o.styleClasses.textClass,r.textClass||""))),0==r.map.length&&r.map.push(0,0,r.content.appendChild(Ae(e.display.measure))),0==i?(t.measure.map=r.map,t.measure.cache={}):((t.measure.maps||(t.measure.maps=[])).push(r.map),(t.measure.caches||(t.measure.caches=[])).push({}))}if(s){var l=r.content.lastChild;(/\bcm-tab\b/.test(l.className)||l.querySelector&&l.querySelector(".cm-tab"))&&(r.content.className="cm-tab-wrap-hack")}return pe(e,"renderLine",e,t.line,r.pre),r.pre.className&&(r.textClass=P(r.pre.className,r.textClass||"")),r}function Jt(e){var t=N("span","•","cm-invalidchar");return t.title="\\u"+e.charCodeAt(0).toString(16),t.setAttribute("aria-label",t.title),t}function Qt(e,t,n,r,i,o,s){if(t){var c,u=e.splitSpaces?function(e,t){if(e.length>1&&!/ /.test(e))return e;for(var n=t,r="",i=0;ic&&d.from<=c);f++);if(d.to>=u)return e(n,r,i,o,a,l,s);e(n,r.slice(0,d.to-c),i,o,null,l,s),o=null,r=r.slice(d.to-c),c=d.to}}}function tn(e,t,n,r){var i=!r&&n.widgetNode;i&&e.map.push(e.pos,e.pos+t,i),!r&&e.cm.display.input.needsContentAttribute&&(i||(i=e.content.appendChild(document.createElement("span"))),i.setAttribute("cm-marker",n.id)),i&&(e.cm.display.input.setUneditable(i),e.content.appendChild(i)),e.pos+=t,e.trailingSpace=!1}function nn(e,t,n){var r=e.markedSpans,i=e.text,o=0;if(r)for(var a,l,s,c,u,d,f,h=i.length,p=0,m=1,g="",v=0;;){if(v==p){s=c=u=l="",f=null,d=null,v=1/0;for(var y=[],b=void 0,w=0;wp||k.collapsed&&x.to==p&&x.from==p)){if(null!=x.to&&x.to!=p&&v>x.to&&(v=x.to,c=""),k.className&&(s+=" "+k.className),k.css&&(l=(l?l+";":"")+k.css),k.startStyle&&x.from==p&&(u+=" "+k.startStyle),k.endStyle&&x.to==v&&(b||(b=[])).push(k.endStyle,x.to),k.title&&((f||(f={})).title=k.title),k.attributes)for(var C in k.attributes)(f||(f={}))[C]=k.attributes[C];k.collapsed&&(!d||_t(d.marker,k)<0)&&(d=x)}else x.from>p&&v>x.from&&(v=x.from)}if(b)for(var S=0;S=h)break;for(var L=Math.min(h,v);;){if(g){var M=p+g.length;if(!d){var A=M>L?g.slice(0,L-p):g;t.addToken(t,A,a?a+s:s,u,p+A.length==v?c:"",l,f)}if(M>=L){g=g.slice(L-p),p=L;break}p=M,u=""}g=i.slice(o,o=n[m++]),a=Xt(n[m++],t.cm.options)}}else for(var N=1;Nn)return{map:e.measure.maps[i],cache:e.measure.caches[i],before:!0}}function En(e,t,n,r){return zn(e,_n(e,t),n,r)}function On(e,t){if(t>=e.display.viewFrom&&t=n.lineN&&t2&&o.push((s.bottom+c.top)/2-n.top)}}o.push(n.bottom-n.top)}}(e,t.view,t.rect),t.hasHeights=!0),(o=function(e,t,n,r){var i,o=In(t.map,n,r),s=o.node,c=o.start,u=o.end,d=o.collapse;if(3==s.nodeType){for(var f=0;f<4;f++){for(;c&&re(t.line.text.charAt(o.coverStart+c));)--c;for(;o.coverStart+u1}(e))return t;var n=screen.logicalXDPI/screen.deviceXDPI,r=screen.logicalYDPI/screen.deviceYDPI;return{left:t.left*n,right:t.right*n,top:t.top*r,bottom:t.bottom*r}}(e.display.measure,i))}else{var h;c>0&&(d=r="right"),i=e.options.lineWrapping&&(h=s.getClientRects()).length>1?h["right"==r?h.length-1:0]:s.getBoundingClientRect()}if(a&&l<9&&!c&&(!i||!i.left&&!i.right)){var p=s.parentNode.getClientRects()[0];i=p?{left:p.left,right:p.left+ir(e.display),top:p.top,bottom:p.bottom}:Dn}for(var m=i.top-t.rect.top,g=i.bottom-t.rect.top,v=(m+g)/2,y=t.view.measure.heights,b=0;bt)&&(i=(o=s-l)-1,t>=s&&(a="right")),null!=i){if(r=e[c+2],l==s&&n==(r.insertLeft?"left":"right")&&(a=n),"left"==n&&0==i)for(;c&&e[c-2]==e[c-3]&&e[c-1].insertLeft;)r=e[2+(c-=3)],a="left";if("right"==n&&i==s-l)for(;c=0&&(n=e[i]).left==n.right;i--);return n}function Fn(e){if(e.measure&&(e.measure.cache={},e.measure.heights=null,e.rest))for(var t=0;t=r.text.length?(s=r.text.length,c="before"):s<=0&&(s=0,c="after"),!l)return a("before"==c?s-1:s,"before"==c);function u(e,t,n){return a(n?e-1:e,1==l[t].level!=n)}var d=le(l,s,c),f=ae,h=u(s,d,"before"==c);return null!=f&&(h.other=u(s,f,"before"!=c)),h}function $n(e,t){var n=0;t=lt(e.doc,t),e.options.lineWrapping||(n=ir(e.display)*t.ch);var r=Ve(e.doc,t.line),i=qt(r)+Cn(e.display);return{left:n,right:n,top:i,bottom:i+r.height}}function Yn(e,t,n,r,i){var o=et(e,t,n);return o.xRel=i,r&&(o.outside=r),o}function Xn(e,t,n){var r=e.doc;if((n+=e.display.viewOffset)<0)return Yn(r.first,0,null,-1,-1);var i=Ze(r,n),o=r.first+r.size-1;if(i>o)return Yn(r.first+r.size-1,Ve(r,o).text.length,null,1,1);t<0&&(t=0);for(var a=Ve(r,i);;){var l=er(e,a,i,t,n),s=It(a,l.ch+(l.xRel>0||l.outside>0?1:0));if(!s)return l;var c=s.find(1);if(c.line==i)return c;a=Ve(r,i=c.line)}}function Zn(e,t,n,r){r-=qn(t);var i=t.text.length,o=oe((function(t){return zn(e,n,t-1).bottom<=r}),i,0);return{begin:o,end:i=oe((function(t){return zn(e,n,t).top>r}),o,i)}}function Jn(e,t,n,r){return n||(n=_n(e,t)),Zn(e,t,n,Un(e,t,zn(e,n,r),"line").top)}function Qn(e,t,n,r){return!(e.bottom<=n)&&(e.top>n||(r?e.left:e.right)>t)}function er(e,t,n,r,i){i-=qt(t);var o=_n(e,t),a=qn(t),l=0,s=t.text.length,c=!0,u=ce(t,e.doc.direction);if(u){var d=(e.options.lineWrapping?nr:tr)(e,t,n,o,u,r,i);l=(c=1!=d.level)?d.from:d.to-1,s=c?d.to:d.from-1}var f,h,p=null,m=null,g=oe((function(t){var n=zn(e,o,t);return n.top+=a,n.bottom+=a,!!Qn(n,r,i,!1)&&(n.top<=i&&n.left<=r&&(p=t,m=n),!0)}),l,s),v=!1;if(m){var y=r-m.left=w.bottom?1:0}return Yn(n,g=ie(t.text,g,1),h,v,r-f)}function tr(e,t,n,r,i,o,a){var l=oe((function(l){var s=i[l],c=1!=s.level;return Qn(Gn(e,et(n,c?s.to:s.from,c?"before":"after"),"line",t,r),o,a,!0)}),0,i.length-1),s=i[l];if(l>0){var c=1!=s.level,u=Gn(e,et(n,c?s.from:s.to,c?"after":"before"),"line",t,r);Qn(u,o,a,!0)&&u.top>a&&(s=i[l-1])}return s}function nr(e,t,n,r,i,o,a){var l=Zn(e,t,r,a),s=l.begin,c=l.end;/\s/.test(t.text.charAt(c-1))&&c--;for(var u=null,d=null,f=0;f=c||h.to<=s)){var p=zn(e,r,1!=h.level?Math.min(c,h.to)-1:Math.max(s,h.from)).right,m=pm)&&(u=h,d=m)}}return u||(u=i[i.length-1]),u.fromc&&(u={from:u.from,to:c,level:u.level}),u}function rr(e){if(null!=e.cachedTextHeight)return e.cachedTextHeight;if(null==Pn){Pn=N("pre",null,"CodeMirror-line-like");for(var t=0;t<49;++t)Pn.appendChild(document.createTextNode("x")),Pn.appendChild(N("br"));Pn.appendChild(document.createTextNode("x"))}A(e.measure,Pn);var n=Pn.offsetHeight/50;return n>3&&(e.cachedTextHeight=n),M(e.measure),n||1}function ir(e){if(null!=e.cachedCharWidth)return e.cachedCharWidth;var t=N("span","xxxxxxxxxx"),n=N("pre",[t],"CodeMirror-line-like");A(e.measure,n);var r=t.getBoundingClientRect(),i=(r.right-r.left)/10;return i>2&&(e.cachedCharWidth=i),i||10}function or(e){for(var t=e.display,n={},r={},i=t.gutters.clientLeft,o=t.gutters.firstChild,a=0;o;o=o.nextSibling,++a){var l=e.display.gutterSpecs[a].className;n[l]=o.offsetLeft+o.clientLeft+i,r[l]=o.clientWidth}return{fixedPos:ar(t),gutterTotalWidth:t.gutters.offsetWidth,gutterLeft:n,gutterWidth:r,wrapperWidth:t.wrapper.clientWidth}}function ar(e){return e.scroller.getBoundingClientRect().left-e.sizer.getBoundingClientRect().left}function lr(e){var t=rr(e.display),n=e.options.lineWrapping,r=n&&Math.max(5,e.display.scroller.clientWidth/ir(e.display)-3);return function(i){if(jt(e.doc,i))return 0;var o=0;if(i.widgets)for(var a=0;a0&&(s=Ve(e.doc,c.line).text).length==c.ch){var u=F(s,s.length,e.options.tabSize)-s.length;c=et(c.line,Math.max(0,Math.round((o-Tn(e.display).left)/ir(e.display))-u))}return c}function ur(e,t){if(t>=e.display.viewTo)return null;if((t-=e.display.viewFrom)<0)return null;for(var n=e.display.view,r=0;rt)&&(i.updateLineNumbers=t),e.curOp.viewChanged=!0,t>=i.viewTo)kt&&Ht(e.doc,t)i.viewFrom?hr(e):(i.viewFrom+=r,i.viewTo+=r);else if(t<=i.viewFrom&&n>=i.viewTo)hr(e);else if(t<=i.viewFrom){var o=pr(e,n,n+r,1);o?(i.view=i.view.slice(o.index),i.viewFrom=o.lineN,i.viewTo+=r):hr(e)}else if(n>=i.viewTo){var a=pr(e,t,t,-1);a?(i.view=i.view.slice(0,a.index),i.viewTo=a.lineN):hr(e)}else{var l=pr(e,t,t,-1),s=pr(e,n,n+r,1);l&&s?(i.view=i.view.slice(0,l.index).concat(on(e,l.lineN,s.lineN)).concat(i.view.slice(s.index)),i.viewTo+=r):hr(e)}var c=i.externalMeasured;c&&(n=i.lineN&&t=r.viewTo)){var o=r.view[ur(e,t)];if(null!=o.node){var a=o.changes||(o.changes=[]);-1==R(a,n)&&a.push(n)}}}function hr(e){e.display.viewFrom=e.display.viewTo=e.doc.first,e.display.view=[],e.display.viewOffset=0}function pr(e,t,n,r){var i,o=ur(e,t),a=e.display.view;if(!kt||n==e.doc.first+e.doc.size)return{index:o,lineN:n};for(var l=e.display.viewFrom,s=0;s0){if(o==a.length-1)return null;i=l+a[o].size-t,o++}else i=l-t;t+=i,n+=i}for(;Ht(e.doc,n)!=n;){if(o==(r<0?0:a.length-1))return null;n+=r*a[o-(r<0?1:0)].size,o+=r}return{index:o,lineN:n}}function mr(e){for(var t=e.display.view,n=0,r=0;r=e.display.viewTo||l.to().linet||t==n&&a.to==t)&&(r(Math.max(a.from,t),Math.min(a.to,n),1==a.level?"rtl":"ltr",o),i=!0)}i||r(t,n,"ltr")}(m,n||0,null==r?f:r,(function(e,t,i,d){var g="ltr"==i,v=h(e,g?"left":"right"),y=h(t-1,g?"right":"left"),b=null==n&&0==e,w=null==r&&t==f,x=0==d,k=!m||d==m.length-1;if(y.top-v.top<=3){var C=(c?w:b)&&k,S=(c?b:w)&&x?l:(g?v:y).left,T=C?s:(g?y:v).right;u(S,v.top,T-S,v.bottom)}else{var L,M,A,N;g?(L=c&&b&&x?l:v.left,M=c?s:p(e,i,"before"),A=c?l:p(t,i,"after"),N=c&&w&&k?s:y.right):(L=c?p(e,i,"before"):l,M=!c&&b&&x?s:v.right,A=!c&&w&&k?l:y.left,N=c?p(t,i,"after"):s),u(L,v.top,M-L,v.bottom),v.bottom0?t.blinker=setInterval((function(){e.hasFocus()||Tr(e),t.cursorDiv.style.visibility=(n=!n)?"":"hidden"}),e.options.cursorBlinkRate):e.options.cursorBlinkRate<0&&(t.cursorDiv.style.visibility="hidden")}}function kr(e){e.hasFocus()||(e.display.input.focus(),e.state.focused||Sr(e))}function Cr(e){e.state.delayingBlurEvent=!0,setTimeout((function(){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1,e.state.focused&&Tr(e))}),100)}function Sr(e,t){e.state.delayingBlurEvent&&!e.state.draggingText&&(e.state.delayingBlurEvent=!1),"nocursor"!=e.options.readOnly&&(e.state.focused||(pe(e,"focus",e,t),e.state.focused=!0,z(e.display.wrapper,"CodeMirror-focused"),e.curOp||e.display.selForContextMenu==e.doc.sel||(e.display.input.reset(),s&&setTimeout((function(){return e.display.input.reset(!0)}),20)),e.display.input.receivedFocus()),xr(e))}function Tr(e,t){e.state.delayingBlurEvent||(e.state.focused&&(pe(e,"blur",e,t),e.state.focused=!1,L(e.display.wrapper,"CodeMirror-focused")),clearInterval(e.display.blinker),setTimeout((function(){e.state.focused||(e.display.shift=!1)}),150))}function Lr(e){for(var t=e.display,n=t.lineDiv.offsetTop,r=0;r.005||f<-.005)&&(Ye(i.line,s),Mr(i.line),i.rest))for(var h=0;he.display.sizerWidth){var p=Math.ceil(c/ir(e.display));p>e.display.maxLineLength&&(e.display.maxLineLength=p,e.display.maxLine=i.line,e.display.maxLineChanged=!0)}}}}function Mr(e){if(e.widgets)for(var t=0;t=a&&(o=Ze(t,qt(Ve(t,s))-e.wrapper.clientHeight),a=s)}return{from:o,to:Math.max(a,o+1)}}function Nr(e,t){var n=e.display,r=rr(e.display);t.top<0&&(t.top=0);var i=e.curOp&&null!=e.curOp.scrollTop?e.curOp.scrollTop:n.scroller.scrollTop,o=An(e),a={};t.bottom-t.top>o&&(t.bottom=t.top+o);var l=e.doc.height+Sn(n),s=t.topl-r;if(t.topi+o){var u=Math.min(t.top,(c?l:t.bottom)-o);u!=i&&(a.scrollTop=u)}var d=e.options.fixedGutter?0:n.gutters.offsetWidth,f=e.curOp&&null!=e.curOp.scrollLeft?e.curOp.scrollLeft:n.scroller.scrollLeft-d,h=Mn(e)-n.gutters.offsetWidth,p=t.right-t.left>h;return p&&(t.right=t.left+h),t.left<10?a.scrollLeft=0:t.lefth+f-3&&(a.scrollLeft=t.right+(p?0:10)-h),a}function Er(e,t){null!=t&&(zr(e),e.curOp.scrollTop=(null==e.curOp.scrollTop?e.doc.scrollTop:e.curOp.scrollTop)+t)}function Or(e){zr(e);var t=e.getCursor();e.curOp.scrollToPos={from:t,to:t,margin:e.options.cursorScrollMargin}}function _r(e,t,n){null==t&&null==n||zr(e),null!=t&&(e.curOp.scrollLeft=t),null!=n&&(e.curOp.scrollTop=n)}function zr(e){var t=e.curOp.scrollToPos;t&&(e.curOp.scrollToPos=null,Pr(e,$n(e,t.from),$n(e,t.to),t.margin))}function Pr(e,t,n,r){var i=Nr(e,{left:Math.min(t.left,n.left),top:Math.min(t.top,n.top)-r,right:Math.max(t.right,n.right),bottom:Math.max(t.bottom,n.bottom)+r});_r(e,i.scrollLeft,i.scrollTop)}function Dr(e,t){Math.abs(e.doc.scrollTop-t)<2||(n||si(e,{top:t}),Ir(e,t,!0),n&&si(e),ri(e,100))}function Ir(e,t,n){t=Math.max(0,Math.min(e.display.scroller.scrollHeight-e.display.scroller.clientHeight,t)),(e.display.scroller.scrollTop!=t||n)&&(e.doc.scrollTop=t,e.display.scrollbars.setScrollTop(t),e.display.scroller.scrollTop!=t&&(e.display.scroller.scrollTop=t))}function Wr(e,t,n,r){t=Math.max(0,Math.min(t,e.display.scroller.scrollWidth-e.display.scroller.clientWidth)),(n?t==e.doc.scrollLeft:Math.abs(e.doc.scrollLeft-t)<2)&&!r||(e.doc.scrollLeft=t,di(e),e.display.scroller.scrollLeft!=t&&(e.display.scroller.scrollLeft=t),e.display.scrollbars.setScrollLeft(t))}function Fr(e){var t=e.display,n=t.gutters.offsetWidth,r=Math.round(e.doc.height+Sn(e.display));return{clientHeight:t.scroller.clientHeight,viewHeight:t.wrapper.clientHeight,scrollWidth:t.scroller.scrollWidth,clientWidth:t.scroller.clientWidth,viewWidth:t.wrapper.clientWidth,barLeft:e.options.fixedGutter?n:0,docHeight:r,scrollHeight:r+Ln(e)+t.barHeight,nativeBarWidth:t.nativeBarWidth,gutterWidth:n}}var Hr=function(e,t,n){this.cm=n;var r=this.vert=N("div",[N("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),i=this.horiz=N("div",[N("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");r.tabIndex=i.tabIndex=-1,e(r),e(i),de(r,"scroll",(function(){r.clientHeight&&t(r.scrollTop,"vertical")})),de(i,"scroll",(function(){i.clientWidth&&t(i.scrollLeft,"horizontal")})),this.checkedZeroWidth=!1,a&&l<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};Hr.prototype.update=function(e){var t=e.scrollWidth>e.clientWidth+1,n=e.scrollHeight>e.clientHeight+1,r=e.nativeBarWidth;if(n){this.vert.style.display="block",this.vert.style.bottom=t?r+"px":"0";var i=e.viewHeight-(t?r:0);this.vert.firstChild.style.height=Math.max(0,e.scrollHeight-e.clientHeight+i)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(t){this.horiz.style.display="block",this.horiz.style.right=n?r+"px":"0",this.horiz.style.left=e.barLeft+"px";var o=e.viewWidth-e.barLeft-(n?r:0);this.horiz.firstChild.style.width=Math.max(0,e.scrollWidth-e.clientWidth+o)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&e.clientHeight>0&&(0==r&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:n?r:0,bottom:t?r:0}},Hr.prototype.setScrollLeft=function(e){this.horiz.scrollLeft!=e&&(this.horiz.scrollLeft=e),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},Hr.prototype.setScrollTop=function(e){this.vert.scrollTop!=e&&(this.vert.scrollTop=e),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},Hr.prototype.zeroWidthHack=function(){var e=y&&!h?"12px":"18px";this.horiz.style.height=this.vert.style.width=e,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new H,this.disableVert=new H},Hr.prototype.enableZeroWidthBar=function(e,t,n){e.style.pointerEvents="auto",t.set(1e3,(function r(){var i=e.getBoundingClientRect();("vert"==n?document.elementFromPoint(i.right-1,(i.top+i.bottom)/2):document.elementFromPoint((i.right+i.left)/2,i.bottom-1))!=e?e.style.pointerEvents="none":t.set(1e3,r)}))},Hr.prototype.clear=function(){var e=this.horiz.parentNode;e.removeChild(this.horiz),e.removeChild(this.vert)};var Rr=function(){};function jr(e,t){t||(t=Fr(e));var n=e.display.barWidth,r=e.display.barHeight;Br(e,t);for(var i=0;i<4&&n!=e.display.barWidth||r!=e.display.barHeight;i++)n!=e.display.barWidth&&e.options.lineWrapping&&Lr(e),Br(e,Fr(e)),n=e.display.barWidth,r=e.display.barHeight}function Br(e,t){var n=e.display,r=n.scrollbars.update(t);n.sizer.style.paddingRight=(n.barWidth=r.right)+"px",n.sizer.style.paddingBottom=(n.barHeight=r.bottom)+"px",n.heightForcer.style.borderBottom=r.bottom+"px solid transparent",r.right&&r.bottom?(n.scrollbarFiller.style.display="block",n.scrollbarFiller.style.height=r.bottom+"px",n.scrollbarFiller.style.width=r.right+"px"):n.scrollbarFiller.style.display="",r.bottom&&e.options.coverGutterNextToScrollbar&&e.options.fixedGutter?(n.gutterFiller.style.display="block",n.gutterFiller.style.height=r.bottom+"px",n.gutterFiller.style.width=t.gutterWidth+"px"):n.gutterFiller.style.display=""}Rr.prototype.update=function(){return{bottom:0,right:0}},Rr.prototype.setScrollLeft=function(){},Rr.prototype.setScrollTop=function(){},Rr.prototype.clear=function(){};var qr={native:Hr,null:Rr};function Ur(e){e.display.scrollbars&&(e.display.scrollbars.clear(),e.display.scrollbars.addClass&&L(e.display.wrapper,e.display.scrollbars.addClass)),e.display.scrollbars=new qr[e.options.scrollbarStyle]((function(t){e.display.wrapper.insertBefore(t,e.display.scrollbarFiller),de(t,"mousedown",(function(){e.state.focused&&setTimeout((function(){return e.display.input.focus()}),0)})),t.setAttribute("cm-not-content","true")}),(function(t,n){"horizontal"==n?Wr(e,t):Dr(e,t)}),e),e.display.scrollbars.addClass&&z(e.display.wrapper,e.display.scrollbars.addClass)}var Kr=0;function Vr(e){var t;e.curOp={cm:e,viewChanged:!1,startHeight:e.doc.height,forceUpdate:!1,updateInput:0,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Kr},t=e.curOp,an?an.ops.push(t):t.ownsGroup=an={ops:[t],delayedCallbacks:[]}}function Gr(e){var t=e.curOp;t&&function(e,t){var n=e.ownsGroup;if(n)try{!function(e){var t=e.delayedCallbacks,n=0;do{for(;n=n.viewTo)||n.maxLineChanged&&t.options.lineWrapping,e.update=e.mustUpdate&&new oi(t,e.mustUpdate&&{top:e.scrollTop,ensure:e.scrollToPos},e.forceUpdate)}function Yr(e){e.updatedDisplay=e.mustUpdate&&ai(e.cm,e.update)}function Xr(e){var t=e.cm,n=t.display;e.updatedDisplay&&Lr(t),e.barMeasure=Fr(t),n.maxLineChanged&&!t.options.lineWrapping&&(e.adjustWidthTo=En(t,n.maxLine,n.maxLine.text.length).left+3,t.display.sizerWidth=e.adjustWidthTo,e.barMeasure.scrollWidth=Math.max(n.scroller.clientWidth,n.sizer.offsetLeft+e.adjustWidthTo+Ln(t)+t.display.barWidth),e.maxScrollLeft=Math.max(0,n.sizer.offsetLeft+e.adjustWidthTo-Mn(t))),(e.updatedDisplay||e.selectionChanged)&&(e.preparedSelection=n.input.prepareSelection())}function Zr(e){var t=e.cm;null!=e.adjustWidthTo&&(t.display.sizer.style.minWidth=e.adjustWidthTo+"px",e.maxScrollLeft(window.innerHeight||document.documentElement.clientHeight)&&(i=!1),null!=i&&!p){var o=N("div","​",null,"position: absolute;\n top: "+(t.top-n.viewOffset-Cn(e.display))+"px;\n height: "+(t.bottom-t.top+Ln(e)+n.barHeight)+"px;\n left: "+t.left+"px; width: "+Math.max(2,t.right-t.left)+"px;");e.display.lineSpace.appendChild(o),o.scrollIntoView(i),e.display.lineSpace.removeChild(o)}}}(t,function(e,t,n,r){var i;null==r&&(r=0),e.options.lineWrapping||t!=n||(n="before"==(t=t.ch?et(t.line,"before"==t.sticky?t.ch-1:t.ch,"after"):t).sticky?et(t.line,t.ch+1,"before"):t);for(var o=0;o<5;o++){var a=!1,l=Gn(e,t),s=n&&n!=t?Gn(e,n):l,c=Nr(e,i={left:Math.min(l.left,s.left),top:Math.min(l.top,s.top)-r,right:Math.max(l.left,s.left),bottom:Math.max(l.bottom,s.bottom)+r}),u=e.doc.scrollTop,d=e.doc.scrollLeft;if(null!=c.scrollTop&&(Dr(e,c.scrollTop),Math.abs(e.doc.scrollTop-u)>1&&(a=!0)),null!=c.scrollLeft&&(Wr(e,c.scrollLeft),Math.abs(e.doc.scrollLeft-d)>1&&(a=!0)),!a)break}return i}(t,lt(r,e.scrollToPos.from),lt(r,e.scrollToPos.to),e.scrollToPos.margin));var i=e.maybeHiddenMarkers,o=e.maybeUnhiddenMarkers;if(i)for(var a=0;a=e.display.viewTo)){var n=+new Date+e.options.workTime,r=ht(e,t.highlightFrontier),i=[];t.iter(r.line,Math.min(t.first+t.size,e.display.viewTo+500),(function(o){if(r.line>=e.display.viewFrom){var a=o.styles,l=o.text.length>e.options.maxHighlightLength?Be(t.mode,r.state):null,s=dt(e,o,r,!0);l&&(r.state=l),o.styles=s.styles;var c=o.styleClasses,u=s.classes;u?o.styleClasses=u:c&&(o.styleClasses=null);for(var d=!a||a.length!=o.styles.length||c!=u&&(!c||!u||c.bgClass!=u.bgClass||c.textClass!=u.textClass),f=0;!d&&fn)return ri(e,e.options.workDelay),!0})),t.highlightFrontier=r.line,t.modeFrontier=Math.max(t.modeFrontier,r.line),i.length&&Qr(e,(function(){for(var t=0;t=n.viewFrom&&t.visible.to<=n.viewTo&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo)&&n.renderedView==n.view&&0==mr(e))return!1;fi(e)&&(hr(e),t.dims=or(e));var i=r.first+r.size,o=Math.max(t.visible.from-e.options.viewportMargin,r.first),a=Math.min(i,t.visible.to+e.options.viewportMargin);n.viewFroma&&n.viewTo-a<20&&(a=Math.min(i,n.viewTo)),kt&&(o=Ht(e.doc,o),a=Rt(e.doc,a));var l=o!=n.viewFrom||a!=n.viewTo||n.lastWrapHeight!=t.wrapperHeight||n.lastWrapWidth!=t.wrapperWidth;(function(e,t,n){var r=e.display;0==r.view.length||t>=r.viewTo||n<=r.viewFrom?(r.view=on(e,t,n),r.viewFrom=t):(r.viewFrom>t?r.view=on(e,t,r.viewFrom).concat(r.view):r.viewFromn&&(r.view=r.view.slice(0,ur(e,n)))),r.viewTo=n})(e,o,a),n.viewOffset=qt(Ve(e.doc,n.viewFrom)),e.display.mover.style.top=n.viewOffset+"px";var c=mr(e);if(!l&&0==c&&!t.force&&n.renderedView==n.view&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo))return!1;var u=function(e){if(e.hasFocus())return null;var t=_();if(!t||!O(e.display.lineDiv,t))return null;var n={activeElt:t};if(window.getSelection){var r=window.getSelection();r.anchorNode&&r.extend&&O(e.display.lineDiv,r.anchorNode)&&(n.anchorNode=r.anchorNode,n.anchorOffset=r.anchorOffset,n.focusNode=r.focusNode,n.focusOffset=r.focusOffset)}return n}(e);return c>4&&(n.lineDiv.style.display="none"),function(e,t,n){var r=e.display,i=e.options.lineNumbers,o=r.lineDiv,a=o.firstChild;function l(t){var n=t.nextSibling;return s&&y&&e.display.currentWheelTarget==t?t.style.display="none":t.parentNode.removeChild(t),n}for(var c=r.view,u=r.viewFrom,d=0;d-1&&(h=!1),un(e,f,u,n)),h&&(M(f.lineNumber),f.lineNumber.appendChild(document.createTextNode(Qe(e.options,u)))),a=f.node.nextSibling}else{var p=vn(e,f,u,n);o.insertBefore(p,a)}u+=f.size}for(;a;)a=l(a)}(e,n.updateLineNumbers,t.dims),c>4&&(n.lineDiv.style.display=""),n.renderedView=n.view,function(e){if(e&&e.activeElt&&e.activeElt!=_()&&(e.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(e.activeElt.nodeName)&&e.anchorNode&&O(document.body,e.anchorNode)&&O(document.body,e.focusNode))){var t=window.getSelection(),n=document.createRange();n.setEnd(e.anchorNode,e.anchorOffset),n.collapse(!1),t.removeAllRanges(),t.addRange(n),t.extend(e.focusNode,e.focusOffset)}}(u),M(n.cursorDiv),M(n.selectionDiv),n.gutters.style.height=n.sizer.style.minHeight=0,l&&(n.lastWrapHeight=t.wrapperHeight,n.lastWrapWidth=t.wrapperWidth,ri(e,400)),n.updateLineNumbers=null,!0}function li(e,t){for(var n=t.viewport,r=!0;;r=!1){if(r&&e.options.lineWrapping&&t.oldDisplayWidth!=Mn(e))r&&(t.visible=Ar(e.display,e.doc,n));else if(n&&null!=n.top&&(n={top:Math.min(e.doc.height+Sn(e.display)-An(e),n.top)}),t.visible=Ar(e.display,e.doc,n),t.visible.from>=e.display.viewFrom&&t.visible.to<=e.display.viewTo)break;if(!ai(e,t))break;Lr(e);var i=Fr(e);gr(e),jr(e,i),ui(e,i),t.force=!1}t.signal(e,"update",e),e.display.viewFrom==e.display.reportedViewFrom&&e.display.viewTo==e.display.reportedViewTo||(t.signal(e,"viewportChange",e,e.display.viewFrom,e.display.viewTo),e.display.reportedViewFrom=e.display.viewFrom,e.display.reportedViewTo=e.display.viewTo)}function si(e,t){var n=new oi(e,t);if(ai(e,n)){Lr(e),li(e,n);var r=Fr(e);gr(e),jr(e,r),ui(e,r),n.finish()}}function ci(e){var t=e.gutters.offsetWidth;e.sizer.style.marginLeft=t+"px",sn(e,"gutterChanged",e)}function ui(e,t){e.display.sizer.style.minHeight=t.docHeight+"px",e.display.heightForcer.style.top=t.docHeight+"px",e.display.gutters.style.height=t.docHeight+e.display.barHeight+Ln(e)+"px"}function di(e){var t=e.display,n=t.view;if(t.alignWidgets||t.gutters.firstChild&&e.options.fixedGutter){for(var r=ar(t)-t.scroller.scrollLeft+e.doc.scrollLeft,i=t.gutters.offsetWidth,o=r+"px",a=0;al.clientWidth,u=l.scrollHeight>l.clientHeight;if(i&&c||o&&u){if(o&&y&&s)e:for(var f=t.target,h=a.view;f!=l;f=f.parentNode)for(var p=0;p=0&&tt(e,r.to())<=0)return n}return-1};var Ci=function(e,t){this.anchor=e,this.head=t};function Si(e,t,n){var r=e&&e.options.selectionsMayTouch,i=t[n];t.sort((function(e,t){return tt(e.from(),t.from())})),n=R(t,i);for(var o=1;o0:s>=0){var c=ot(l.from(),a.from()),u=it(l.to(),a.to()),d=l.empty()?a.from()==a.head:l.from()==l.head;o<=n&&--n,t.splice(--o,2,new Ci(d?u:c,d?c:u))}}return new ki(t,n)}function Ti(e,t){return new ki([new Ci(e,t||e)],0)}function Li(e){return e.text?et(e.from.line+e.text.length-1,$(e.text).length+(1==e.text.length?e.from.ch:0)):e.to}function Mi(e,t){if(tt(e,t.from)<0)return e;if(tt(e,t.to)<=0)return Li(t);var n=e.line+t.text.length-(t.to.line-t.from.line)-1,r=e.ch;return e.line==t.to.line&&(r+=Li(t).ch-t.to.ch),et(n,r)}function Ai(e,t){for(var n=[],r=0;r1&&e.remove(l.line+1,p-1),e.insert(l.line+1,v)}sn(e,"change",e,t)}function Pi(e,t,n){!function e(r,i,o){if(r.linked)for(var a=0;al-(e.cm?e.cm.options.historyEventDelay:500)||"*"==t.origin.charAt(0)))&&(o=function(e,t){return t?(Hi(e.done),$(e.done)):e.done.length&&!$(e.done).ranges?$(e.done):e.done.length>1&&!e.done[e.done.length-2].ranges?(e.done.pop(),$(e.done)):void 0}(i,i.lastOp==r)))a=$(o.changes),0==tt(t.from,t.to)&&0==tt(t.from,a.to)?a.to=Li(t):o.changes.push(Fi(e,t));else{var s=$(i.done);for(s&&s.ranges||Bi(e.sel,i.done),o={changes:[Fi(e,t)],generation:i.generation},i.done.push(o);i.done.length>i.undoDepth;)i.done.shift(),i.done[0].ranges||i.done.shift()}i.done.push(n),i.generation=++i.maxGeneration,i.lastModTime=i.lastSelTime=l,i.lastOp=i.lastSelOp=r,i.lastOrigin=i.lastSelOrigin=t.origin,a||pe(e,"historyAdded")}function ji(e,t,n,r){var i=e.history,o=r&&r.origin;n==i.lastSelOp||o&&i.lastSelOrigin==o&&(i.lastModTime==i.lastSelTime&&i.lastOrigin==o||function(e,t,n,r){var i=t.charAt(0);return"*"==i||"+"==i&&n.ranges.length==r.ranges.length&&n.somethingSelected()==r.somethingSelected()&&new Date-e.history.lastSelTime<=(e.cm?e.cm.options.historyEventDelay:500)}(e,o,$(i.done),t))?i.done[i.done.length-1]=t:Bi(t,i.done),i.lastSelTime=+new Date,i.lastSelOrigin=o,i.lastSelOp=n,r&&!1!==r.clearRedo&&Hi(i.undone)}function Bi(e,t){var n=$(t);n&&n.ranges&&n.equals(e)||t.push(e)}function qi(e,t,n,r){var i=t["spans_"+e.id],o=0;e.iter(Math.max(e.first,n),Math.min(e.first+e.size,r),(function(n){n.markedSpans&&((i||(i=t["spans_"+e.id]={}))[o]=n.markedSpans),++o}))}function Ui(e){if(!e)return null;for(var t,n=0;n-1&&($(l)[d]=c[d],delete c[d])}}}return r}function Gi(e,t,n,r){if(r){var i=e.anchor;if(n){var o=tt(t,i)<0;o!=tt(n,i)<0?(i=t,t=n):o!=tt(t,n)<0&&(t=n)}return new Ci(i,t)}return new Ci(n||t,t)}function $i(e,t,n,r,i){null==i&&(i=e.cm&&(e.cm.display.shift||e.extend)),Qi(e,new ki([Gi(e.sel.primary(),t,n,i)],0),r)}function Yi(e,t,n){for(var r=[],i=e.cm&&(e.cm.display.shift||e.extend),o=0;o=t.ch:l.to>t.ch))){if(i&&(pe(s,"beforeCursorEnter"),s.explicitlyCleared)){if(o.markedSpans){--a;continue}break}if(!s.atomic)continue;if(n){var d=s.find(r<0?1:-1),f=void 0;if((r<0?u:c)&&(d=ao(e,d,-r,d&&d.line==t.line?o:null)),d&&d.line==t.line&&(f=tt(d,n))&&(r<0?f<0:f>0))return io(e,d,t,r,i)}var h=s.find(r<0?-1:1);return(r<0?c:u)&&(h=ao(e,h,r,h.line==t.line?o:null)),h?io(e,h,t,r,i):null}}return t}function oo(e,t,n,r,i){var o=r||1;return io(e,t,n,o,i)||!i&&io(e,t,n,o,!0)||io(e,t,n,-o,i)||!i&&io(e,t,n,-o,!0)||(e.cantEdit=!0,et(e.first,0))}function ao(e,t,n,r){return n<0&&0==t.ch?t.line>e.first?lt(e,et(t.line-1)):null:n>0&&t.ch==(r||Ve(e,t.line)).text.length?t.line0)){var u=[s,1],d=tt(c.from,l.from),f=tt(c.to,l.to);(d<0||!a.inclusiveLeft&&!d)&&u.push({from:c.from,to:l.from}),(f>0||!a.inclusiveRight&&!f)&&u.push({from:l.to,to:c.to}),i.splice.apply(i,u),s+=u.length-3}}return i}(e,t.from,t.to);if(r)for(var i=r.length-1;i>=0;--i)uo(e,{from:r[i].from,to:r[i].to,text:i?[""]:t.text,origin:t.origin});else uo(e,t)}}function uo(e,t){if(1!=t.text.length||""!=t.text[0]||0!=tt(t.from,t.to)){var n=Ai(e,t);Ri(e,t,n,e.cm?e.cm.curOp.id:NaN),po(e,t,n,Lt(e,t));var r=[];Pi(e,(function(e,n){n||-1!=R(r,e.history)||(yo(e.history,t),r.push(e.history)),po(e,t,null,Lt(e,t))}))}}function fo(e,t,n){var r=e.cm&&e.cm.state.suppressEdits;if(!r||n){for(var i,o=e.history,a=e.sel,l="undo"==t?o.done:o.undone,s="undo"==t?o.undone:o.done,c=0;c=0;--h){var p=f(h);if(p)return p.v}}}}function ho(e,t){if(0!=t&&(e.first+=t,e.sel=new ki(Y(e.sel.ranges,(function(e){return new Ci(et(e.anchor.line+t,e.anchor.ch),et(e.head.line+t,e.head.ch))})),e.sel.primIndex),e.cm)){dr(e.cm,e.first,e.first-t,t);for(var n=e.cm.display,r=n.viewFrom;re.lastLine())){if(t.from.lineo&&(t={from:t.from,to:et(o,Ve(e,o).text.length),text:[t.text[0]],origin:t.origin}),t.removed=Ge(e,t.from,t.to),n||(n=Ai(e,t)),e.cm?function(e,t,n){var r=e.doc,i=e.display,o=t.from,a=t.to,l=!1,s=o.line;e.options.lineWrapping||(s=Xe(Ft(Ve(r,o.line))),r.iter(s,a.line+1,(function(e){if(e==i.maxLine)return l=!0,!0}))),r.sel.contains(t.from,t.to)>-1&&ge(e),zi(r,t,n,lr(e)),e.options.lineWrapping||(r.iter(s,o.line+t.text.length,(function(e){var t=Ut(e);t>i.maxLineLength&&(i.maxLine=e,i.maxLineLength=t,i.maxLineChanged=!0,l=!1)})),l&&(e.curOp.updateMaxLine=!0)),function(e,t){if(e.modeFrontier=Math.min(e.modeFrontier,t),!(e.highlightFrontiern;r--){var i=Ve(e,r).stateAfter;if(i&&(!(i instanceof ct)||r+i.lookAhead1||!(this.children[0]instanceof wo))){var l=[];this.collapse(l),this.children=[new wo(l)],this.children[0].parent=this}},collapse:function(e){for(var t=0;t50){for(var a=i.lines.length%25+25,l=a;l10);e.parent.maybeSpill()}},iterN:function(e,t,n){for(var r=0;r0||0==a&&!1!==o.clearWhenEmpty)return o;if(o.replacedWith&&(o.collapsed=!0,o.widgetNode=E("span",[o.replacedWith],"CodeMirror-widget"),r.handleMouseEvents||o.widgetNode.setAttribute("cm-ignore-events","true"),r.insertLeft&&(o.widgetNode.insertLeft=!0)),o.collapsed){if(Wt(e,t.line,t,n,o)||t.line!=n.line&&Wt(e,n.line,t,n,o))throw new Error("Inserting collapsed marker partially overlapping an existing one");kt=!0}o.addToHistory&&Ri(e,{from:t,to:n,origin:"markText"},e.sel,NaN);var l,s=t.line,c=e.cm;if(e.iter(s,n.line+1,(function(e){c&&o.collapsed&&!c.options.lineWrapping&&Ft(e)==c.display.maxLine&&(l=!0),o.collapsed&&s!=t.line&&Ye(e,0),function(e,t){e.markedSpans=e.markedSpans?e.markedSpans.concat([t]):[t],t.marker.attachLine(e)}(e,new Ct(o,s==t.line?t.ch:null,s==n.line?n.ch:null)),++s})),o.collapsed&&e.iter(t.line,n.line+1,(function(t){jt(e,t)&&Ye(t,0)})),o.clearOnEnter&&de(o,"beforeCursorEnter",(function(){return o.clear()})),o.readOnly&&(xt=!0,(e.history.done.length||e.history.undone.length)&&e.clearHistory()),o.collapsed&&(o.id=++So,o.atomic=!0),c){if(l&&(c.curOp.updateMaxLine=!0),o.collapsed)dr(c,t.line,n.line+1);else if(o.className||o.startStyle||o.endStyle||o.css||o.attributes||o.title)for(var u=t.line;u<=n.line;u++)fr(c,u,"text");o.atomic&&no(c.doc),sn(c,"markerAdded",c,o)}return o}To.prototype.clear=function(){if(!this.explicitlyCleared){var e=this.doc.cm,t=e&&!e.curOp;if(t&&Vr(e),ve(this,"clear")){var n=this.find();n&&sn(this,"clear",n.from,n.to)}for(var r=null,i=null,o=0;oe.display.maxLineLength&&(e.display.maxLine=c,e.display.maxLineLength=u,e.display.maxLineChanged=!0)}null!=r&&e&&this.collapsed&&dr(e,r,i+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,e&&no(e.doc)),e&&sn(e,"markerCleared",e,this,r,i),t&&Gr(e),this.parent&&this.parent.clear()}},To.prototype.find=function(e,t){var n,r;null==e&&"bookmark"==this.type&&(e=1);for(var i=0;i=0;s--)co(this,r[s]);l?Ji(this,l):this.cm&&Or(this.cm)})),undo:ni((function(){fo(this,"undo")})),redo:ni((function(){fo(this,"redo")})),undoSelection:ni((function(){fo(this,"undo",!0)})),redoSelection:ni((function(){fo(this,"redo",!0)})),setExtending:function(e){this.extend=e},getExtending:function(){return this.extend},historySize:function(){for(var e=this.history,t=0,n=0,r=0;r=e.ch)&&t.push(i.marker.parent||i.marker)}return t},findMarks:function(e,t,n){e=lt(this,e),t=lt(this,t);var r=[],i=e.line;return this.iter(e.line,t.line+1,(function(o){var a=o.markedSpans;if(a)for(var l=0;l=s.to||null==s.from&&i!=e.line||null!=s.from&&i==t.line&&s.from>=t.ch||n&&!n(s.marker)||r.push(s.marker.parent||s.marker)}++i})),r},getAllMarks:function(){var e=[];return this.iter((function(t){var n=t.markedSpans;if(n)for(var r=0;re)return t=e,!0;e-=o,++n})),lt(this,et(n,t))},indexFromPos:function(e){var t=(e=lt(this,e)).ch;if(e.linet&&(t=e.from),null!=e.to&&e.to-1)return t.state.draggingText(e),void setTimeout((function(){return t.display.input.focus()}),20);try{var d=e.dataTransfer.getData("Text");if(d){var f;if(t.state.draggingText&&!t.state.draggingText.copy&&(f=t.listSelections()),eo(t.doc,Ti(n,n)),f)for(var h=0;h=0;t--)mo(e.doc,"",r[t].from,r[t].to,"+delete");Or(e)}))}function Jo(e,t,n){var r=ie(e.text,t+n,n);return r<0||r>e.text.length?null:r}function Qo(e,t,n){var r=Jo(e,t.ch,n);return null==r?null:new et(t.line,r,n<0?"after":"before")}function ea(e,t,n,r,i){if(e){"rtl"==t.doc.direction&&(i=-i);var o=ce(n,t.doc.direction);if(o){var a,l=i<0?$(o):o[0],s=i<0==(1==l.level)?"after":"before";if(l.level>0||"rtl"==t.doc.direction){var c=_n(t,n);a=i<0?n.text.length-1:0;var u=zn(t,c,a).top;a=oe((function(e){return zn(t,c,e).top==u}),i<0==(1==l.level)?l.from:l.to-1,a),"before"==s&&(a=Jo(n,a,1))}else a=i<0?l.to:l.from;return new et(r,a,s)}}return new et(r,i<0?n.text.length:0,i<0?"before":"after")}qo.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},qo.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},qo.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},qo.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},qo.default=y?qo.macDefault:qo.pcDefault;var ta={selectAll:lo,singleSelection:function(e){return e.setSelection(e.getCursor("anchor"),e.getCursor("head"),B)},killLine:function(e){return Zo(e,(function(t){if(t.empty()){var n=Ve(e.doc,t.head.line).text.length;return t.head.ch==n&&t.head.line0)i=new et(i.line,i.ch+1),e.replaceRange(o.charAt(i.ch-1)+o.charAt(i.ch-2),et(i.line,i.ch-2),i,"+transpose");else if(i.line>e.doc.first){var a=Ve(e.doc,i.line-1).text;a&&(i=new et(i.line,1),e.replaceRange(o.charAt(0)+e.doc.lineSeparator()+a.charAt(a.length-1),et(i.line-1,a.length-1),i,"+transpose"))}n.push(new Ci(i,i))}e.setSelections(n)}))},newlineAndIndent:function(e){return Qr(e,(function(){for(var t=e.listSelections(),n=t.length-1;n>=0;n--)e.replaceRange(e.doc.lineSeparator(),t[n].anchor,t[n].head,"+input");t=e.listSelections();for(var r=0;r-1&&(tt((i=c.ranges[i]).from(),t)<0||t.xRel>0)&&(tt(i.to(),t)>0||t.xRel<0)?function(e,t,n,r){var i=e.display,o=!1,c=ei(e,(function(t){s&&(i.scroller.draggable=!1),e.state.draggingText=!1,e.state.delayingBlurEvent&&(e.hasFocus()?e.state.delayingBlurEvent=!1:Cr(e)),he(i.wrapper.ownerDocument,"mouseup",c),he(i.wrapper.ownerDocument,"mousemove",u),he(i.scroller,"dragstart",d),he(i.scroller,"drop",c),o||(be(t),r.addNew||$i(e.doc,n,null,null,r.extend),s&&!f||a&&9==l?setTimeout((function(){i.wrapper.ownerDocument.body.focus({preventScroll:!0}),i.input.focus()}),20):i.input.focus())})),u=function(e){o=o||Math.abs(t.clientX-e.clientX)+Math.abs(t.clientY-e.clientY)>=10},d=function(){return o=!0};s&&(i.scroller.draggable=!0),e.state.draggingText=c,c.copy=!r.moveOnDrag,de(i.wrapper.ownerDocument,"mouseup",c),de(i.wrapper.ownerDocument,"mousemove",u),de(i.scroller,"dragstart",d),de(i.scroller,"drop",c),e.state.delayingBlurEvent=!0,setTimeout((function(){return i.input.focus()}),20),i.scroller.dragDrop&&i.scroller.dragDrop()}(e,r,t,o):function(e,t,n,r){a&&Cr(e);var i=e.display,o=e.doc;be(t);var l,s,c=o.sel,u=c.ranges;if(r.addNew&&!r.extend?(s=o.sel.contains(n),l=s>-1?u[s]:new Ci(n,n)):(l=o.sel.primary(),s=o.sel.primIndex),"rectangle"==r.unit)r.addNew||(l=new Ci(n,n)),n=cr(e,t,!0,!0),s=-1;else{var d=va(e,n,r.unit);l=r.extend?Gi(l,d.anchor,d.head,r.extend):d}r.addNew?-1==s?(s=u.length,Qi(o,Si(e,u.concat([l]),s),{scroll:!1,origin:"*mouse"})):u.length>1&&u[s].empty()&&"char"==r.unit&&!r.extend?(Qi(o,Si(e,u.slice(0,s).concat(u.slice(s+1)),0),{scroll:!1,origin:"*mouse"}),c=o.sel):Xi(o,s,l,q):(s=0,Qi(o,new ki([l],0),q),c=o.sel);var f=n;function h(t){if(0!=tt(f,t))if(f=t,"rectangle"==r.unit){for(var i=[],a=e.options.tabSize,u=F(Ve(o,n.line).text,n.ch,a),d=F(Ve(o,t.line).text,t.ch,a),h=Math.min(u,d),p=Math.max(u,d),m=Math.min(n.line,t.line),g=Math.min(e.lastLine(),Math.max(n.line,t.line));m<=g;m++){var v=Ve(o,m).text,y=K(v,h,a);h==p?i.push(new Ci(et(m,y),et(m,y))):v.length>y&&i.push(new Ci(et(m,y),et(m,K(v,p,a))))}i.length||i.push(new Ci(n,n)),Qi(o,Si(e,c.ranges.slice(0,s).concat(i),s),{origin:"*mouse",scroll:!1}),e.scrollIntoView(t)}else{var b,w=l,x=va(e,t,r.unit),k=w.anchor;tt(x.anchor,k)>0?(b=x.head,k=ot(w.from(),x.anchor)):(b=x.anchor,k=it(w.to(),x.head));var C=c.ranges.slice(0);C[s]=function(e,t){var n=t.anchor,r=t.head,i=Ve(e.doc,n.line);if(0==tt(n,r)&&n.sticky==r.sticky)return t;var o=ce(i);if(!o)return t;var a=le(o,n.ch,n.sticky),l=o[a];if(l.from!=n.ch&&l.to!=n.ch)return t;var s,c=a+(l.from==n.ch==(1!=l.level)?0:1);if(0==c||c==o.length)return t;if(r.line!=n.line)s=(r.line-n.line)*("ltr"==e.doc.direction?1:-1)>0;else{var u=le(o,r.ch,r.sticky),d=u-a||(r.ch-n.ch)*(1==l.level?-1:1);s=u==c-1||u==c?d<0:d>0}var f=o[c+(s?-1:0)],h=s==(1==f.level),p=h?f.from:f.to,m=h?"after":"before";return n.ch==p&&n.sticky==m?t:new Ci(new et(n.line,p,m),r)}(e,new Ci(lt(o,k),b)),Qi(o,Si(e,C,s),q)}}var p=i.wrapper.getBoundingClientRect(),m=0;function g(t){var n=++m,a=cr(e,t,!0,"rectangle"==r.unit);if(a)if(0!=tt(a,f)){e.curOp.focus=_(),h(a);var l=Ar(i,o);(a.line>=l.to||a.linep.bottom?20:0;s&&setTimeout(ei(e,(function(){m==n&&(i.scroller.scrollTop+=s,g(t))})),50)}}function v(t){e.state.selectingText=!1,m=1/0,t&&(be(t),i.input.focus()),he(i.wrapper.ownerDocument,"mousemove",y),he(i.wrapper.ownerDocument,"mouseup",b),o.history.lastSelOrigin=null}var y=ei(e,(function(e){0!==e.buttons&&Se(e)?g(e):v(e)})),b=ei(e,v);e.state.selectingText=b,de(i.wrapper.ownerDocument,"mousemove",y),de(i.wrapper.ownerDocument,"mouseup",b)}(e,r,t,o)}(t,r,o,e):Ce(e)==n.scroller&&be(e):2==i?(r&&$i(t.doc,r),setTimeout((function(){return n.input.focus()}),20)):3==i&&(C?t.display.input.onContextMenu(e):Cr(t)))}}function va(e,t,n){if("char"==n)return new Ci(t,t);if("word"==n)return e.findWordAt(t);if("line"==n)return new Ci(et(t.line,0),lt(e.doc,et(t.line+1,0)));var r=n(e,t);return new Ci(r.from,r.to)}function ya(e,t,n,r){var i,o;if(t.touches)i=t.touches[0].clientX,o=t.touches[0].clientY;else try{i=t.clientX,o=t.clientY}catch(e){return!1}if(i>=Math.floor(e.display.gutters.getBoundingClientRect().right))return!1;r&&be(t);var a=e.display,l=a.lineDiv.getBoundingClientRect();if(o>l.bottom||!ve(e,n))return xe(t);o-=l.top-a.viewOffset;for(var s=0;s=i)return pe(e,n,e,Ze(e.doc,o),e.display.gutterSpecs[s].className,t),xe(t)}}function ba(e,t){return ya(e,t,"gutterClick",!0)}function wa(e,t){kn(e.display,t)||function(e,t){return!!ve(e,"gutterContextMenu")&&ya(e,t,"gutterContextMenu",!1)}(e,t)||me(e,t,"contextmenu")||C||e.display.input.onContextMenu(t)}function xa(e){e.display.wrapper.className=e.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+e.options.theme.replace(/(^|\s)\s*/g," cm-s-"),Rn(e)}ma.prototype.compare=function(e,t,n){return this.time+400>e&&0==tt(t,this.pos)&&n==this.button};var ka={toString:function(){return"CodeMirror.Init"}},Ca={},Sa={};function Ta(e,t,n){if(!t!=!(n&&n!=ka)){var r=e.display.dragFunctions,i=t?de:he;i(e.display.scroller,"dragstart",r.start),i(e.display.scroller,"dragenter",r.enter),i(e.display.scroller,"dragover",r.over),i(e.display.scroller,"dragleave",r.leave),i(e.display.scroller,"drop",r.drop)}}function La(e){e.options.lineWrapping?(z(e.display.wrapper,"CodeMirror-wrap"),e.display.sizer.style.minWidth="",e.display.sizerWidth=null):(L(e.display.wrapper,"CodeMirror-wrap"),Kt(e)),sr(e),dr(e),Rn(e),setTimeout((function(){return jr(e)}),100)}function Ma(e,t){var n=this;if(!(this instanceof Ma))return new Ma(e,t);this.options=t=t?W(t):{},W(Ca,t,!1);var r=t.value;"string"==typeof r?r=new Oo(r,t.mode,null,t.lineSeparator,t.direction):t.mode&&(r.modeOption=t.mode),this.doc=r;var i=new Ma.inputStyles[t.inputStyle](this),o=this.display=new gi(e,r,i,t);for(var c in o.wrapper.CodeMirror=this,xa(this),t.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),Ur(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:-1,cutIncoming:-1,selectingText:!1,draggingText:!1,highlight:new H,keySeq:null,specialChars:null},t.autofocus&&!v&&o.input.focus(),a&&l<11&&setTimeout((function(){return n.display.input.reset(!0)}),20),function(e){var t=e.display;de(t.scroller,"mousedown",ei(e,ga)),de(t.scroller,"dblclick",a&&l<11?ei(e,(function(t){if(!me(e,t)){var n=cr(e,t);if(n&&!ba(e,t)&&!kn(e.display,t)){be(t);var r=e.findWordAt(n);$i(e.doc,r.anchor,r.head)}}})):function(t){return me(e,t)||be(t)}),de(t.scroller,"contextmenu",(function(t){return wa(e,t)})),de(t.input.getField(),"contextmenu",(function(n){t.scroller.contains(n.target)||wa(e,n)}));var n,r={end:0};function i(){t.activeTouch&&(n=setTimeout((function(){return t.activeTouch=null}),1e3),(r=t.activeTouch).end=+new Date)}function o(e){if(1!=e.touches.length)return!1;var t=e.touches[0];return t.radiusX<=1&&t.radiusY<=1}function s(e,t){if(null==t.left)return!0;var n=t.left-e.left,r=t.top-e.top;return n*n+r*r>400}de(t.scroller,"touchstart",(function(i){if(!me(e,i)&&!o(i)&&!ba(e,i)){t.input.ensurePolled(),clearTimeout(n);var a=+new Date;t.activeTouch={start:a,moved:!1,prev:a-r.end<=300?r:null},1==i.touches.length&&(t.activeTouch.left=i.touches[0].pageX,t.activeTouch.top=i.touches[0].pageY)}})),de(t.scroller,"touchmove",(function(){t.activeTouch&&(t.activeTouch.moved=!0)})),de(t.scroller,"touchend",(function(n){var r=t.activeTouch;if(r&&!kn(t,n)&&null!=r.left&&!r.moved&&new Date-r.start<300){var o,a=e.coordsChar(t.activeTouch,"page");o=!r.prev||s(r,r.prev)?new Ci(a,a):!r.prev.prev||s(r,r.prev.prev)?e.findWordAt(a):new Ci(et(a.line,0),lt(e.doc,et(a.line+1,0))),e.setSelection(o.anchor,o.head),e.focus(),be(n)}i()})),de(t.scroller,"touchcancel",i),de(t.scroller,"scroll",(function(){t.scroller.clientHeight&&(Dr(e,t.scroller.scrollTop),Wr(e,t.scroller.scrollLeft,!0),pe(e,"scroll",e))})),de(t.scroller,"mousewheel",(function(t){return xi(e,t)})),de(t.scroller,"DOMMouseScroll",(function(t){return xi(e,t)})),de(t.wrapper,"scroll",(function(){return t.wrapper.scrollTop=t.wrapper.scrollLeft=0})),t.dragFunctions={enter:function(t){me(e,t)||ke(t)},over:function(t){me(e,t)||(function(e,t){var n=cr(e,t);if(n){var r=document.createDocumentFragment();yr(e,n,r),e.display.dragCursor||(e.display.dragCursor=N("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),e.display.lineSpace.insertBefore(e.display.dragCursor,e.display.cursorDiv)),A(e.display.dragCursor,r)}}(e,t),ke(t))},start:function(t){return function(e,t){if(a&&(!e.state.draggingText||+new Date-_o<100))ke(t);else if(!me(e,t)&&!kn(e.display,t)&&(t.dataTransfer.setData("Text",e.getSelection()),t.dataTransfer.effectAllowed="copyMove",t.dataTransfer.setDragImage&&!f)){var n=N("img",null,null,"position: fixed; left: 0; top: 0;");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",d&&(n.width=n.height=1,e.display.wrapper.appendChild(n),n._top=n.offsetTop),t.dataTransfer.setDragImage(n,0,0),d&&n.parentNode.removeChild(n)}}(e,t)},drop:ei(e,zo),leave:function(t){me(e,t)||Po(e)}};var c=t.input.getField();de(c,"keyup",(function(t){return da.call(e,t)})),de(c,"keydown",ei(e,ua)),de(c,"keypress",ei(e,fa)),de(c,"focus",(function(t){return Sr(e,t)})),de(c,"blur",(function(t){return Tr(e,t)}))}(this),Wo(),Vr(this),this.curOp.forceUpdate=!0,Di(this,r),t.autofocus&&!v||this.hasFocus()?setTimeout((function(){n.hasFocus()&&!n.state.focused&&Sr(n)}),20):Tr(this),Sa)Sa.hasOwnProperty(c)&&Sa[c](this,t[c],ka);fi(this),t.finishInit&&t.finishInit(this);for(var u=0;u150)){if(!r)return;n="prev"}}else c=0,n="not";"prev"==n?c=t>o.first?F(Ve(o,t-1).text,null,a):0:"add"==n?c=s+e.options.indentUnit:"subtract"==n?c=s-e.options.indentUnit:"number"==typeof n&&(c=s+n),c=Math.max(0,c);var d="",f=0;if(e.options.indentWithTabs)for(var h=Math.floor(c/a);h;--h)f+=a,d+="\t";if(fa,s=Oe(t),c=null;if(l&&r.ranges.length>1)if(Ea&&Ea.text.join("\n")==t){if(r.ranges.length%Ea.text.length==0){c=[];for(var u=0;u=0;f--){var h=r.ranges[f],p=h.from(),m=h.to();h.empty()&&(n&&n>0?p=et(p.line,p.ch-n):e.state.overwrite&&!l?m=et(m.line,Math.min(Ve(o,m.line).text.length,m.ch+$(s).length)):l&&Ea&&Ea.lineWise&&Ea.text.join("\n")==s.join("\n")&&(p=m=et(p.line,0)));var g={from:p,to:m,text:c?c[f%c.length]:s,origin:i||(l?"paste":e.state.cutIncoming>a?"cut":"+input")};co(e.doc,g),sn(e,"inputRead",e,g)}t&&!l&&Pa(e,t),Or(e),e.curOp.updateInput<2&&(e.curOp.updateInput=d),e.curOp.typing=!0,e.state.pasteIncoming=e.state.cutIncoming=-1}function za(e,t){var n=e.clipboardData&&e.clipboardData.getData("Text");if(n)return e.preventDefault(),t.isReadOnly()||t.options.disableInput||Qr(t,(function(){return _a(t,n,0,null,"paste")})),!0}function Pa(e,t){if(e.options.electricChars&&e.options.smartIndent)for(var n=e.doc.sel,r=n.ranges.length-1;r>=0;r--){var i=n.ranges[r];if(!(i.head.ch>100||r&&n.ranges[r-1].head.line==i.head.line)){var o=e.getModeAt(i.head),a=!1;if(o.electricChars){for(var l=0;l-1){a=Na(e,i.head.line,"smart");break}}else o.electricInput&&o.electricInput.test(Ve(e.doc,i.head.line).text.slice(0,i.head.ch))&&(a=Na(e,i.head.line,"smart"));a&&sn(e,"electricInput",e,i.head.line)}}}function Da(e){for(var t=[],n=[],r=0;r0?0:-1));if(isNaN(u))a=null;else{var d=n>0?u>=55296&&u<56320:u>=56320&&u<57343;a=new et(t.line,Math.max(0,Math.min(l.text.length,t.ch+n*(d?2:1))),-n)}}else a=i?function(e,t,n,r){var i=ce(t,e.doc.direction);if(!i)return Qo(t,n,r);n.ch>=t.text.length?(n.ch=t.text.length,n.sticky="before"):n.ch<=0&&(n.ch=0,n.sticky="after");var o=le(i,n.ch,n.sticky),a=i[o];if("ltr"==e.doc.direction&&a.level%2==0&&(r>0?a.to>n.ch:a.from=a.from&&f>=u.begin)){var h=d?"before":"after";return new et(n.line,f,h)}}var p=function(e,t,r){for(var o=function(e,t){return t?new et(n.line,s(e,1),"before"):new et(n.line,e,"after")};e>=0&&e0==(1!=a.level),c=l?r.begin:s(r.end,-1);if(a.from<=c&&c0?u.end:s(u.begin,-1);return null==g||r>0&&g==t.text.length||!(m=p(r>0?0:i.length-1,r,c(g)))?null:m}(e.cm,l,t,n):Qo(l,t,n);if(null==a){if(o||((c=t.line+s)=e.first+e.size||(t=new et(c,t.ch,t.sticky),!(l=Ve(e,c)))))return!1;t=ea(i,e.cm,l,t.line,s)}else t=a;return!0}if("char"==r||"codepoint"==r)c();else if("column"==r)c(!0);else if("word"==r||"group"==r)for(var u=null,d="group"==r,f=e.cm&&e.cm.getHelper(t,"wordChars"),h=!0;!(n<0)||c(!h);h=!1){var p=l.text.charAt(t.ch)||"\n",m=ee(p,f)?"w":d&&"\n"==p?"n":!d||/\s/.test(p)?null:"p";if(!d||h||m||(m="s"),u&&u!=m){n<0&&(n=1,c(),t.sticky="after");break}if(m&&(u=m),n>0&&!c(!h))break}var g=oo(e,t,o,a,!0);return nt(o,g)&&(g.hitSide=!0),g}function Ha(e,t,n,r){var i,o,a=e.doc,l=t.left;if("page"==r){var s=Math.min(e.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),c=Math.max(s-.5*rr(e.display),3);i=(n>0?t.bottom:t.top)+n*c}else"line"==r&&(i=n>0?t.bottom+3:t.top-3);for(;(o=Xn(e,l,i)).outside;){if(n<0?i<=0:i>=a.height){o.hitSide=!0;break}i+=5*n}return o}var Ra=function(e){this.cm=e,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new H,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};function ja(e,t){var n=On(e,t.line);if(!n||n.hidden)return null;var r=Ve(e.doc,t.line),i=Nn(n,r,t.line),o=ce(r,e.doc.direction),a="left";o&&(a=le(o,t.ch)%2?"right":"left");var l=In(i.map,t.ch,a);return l.offset="right"==l.collapse?l.end:l.start,l}function Ba(e,t){return t&&(e.bad=!0),e}function qa(e,t,n){var r;if(t==e.display.lineDiv){if(!(r=e.display.lineDiv.childNodes[n]))return Ba(e.clipPos(et(e.display.viewTo-1)),!0);t=null,n=0}else for(r=t;;r=r.parentNode){if(!r||r==e.display.lineDiv)return null;if(r.parentNode&&r.parentNode==e.display.lineDiv)break}for(var i=0;i=t.display.viewTo||o.line=t.display.viewFrom&&ja(t,i)||{node:s[0].measure.map[2],offset:0},u=o.liner.firstLine()&&(a=et(a.line-1,Ve(r.doc,a.line-1).length)),l.ch==Ve(r.doc,l.line).text.length&&l.linei.viewTo-1)return!1;a.line==i.viewFrom||0==(e=ur(r,a.line))?(t=Xe(i.view[0].line),n=i.view[0].node):(t=Xe(i.view[e].line),n=i.view[e-1].node.nextSibling);var s,c,u=ur(r,l.line);if(u==i.view.length-1?(s=i.viewTo-1,c=i.lineDiv.lastChild):(s=Xe(i.view[u+1].line)-1,c=i.view[u+1].node.previousSibling),!n)return!1;for(var d=r.doc.splitLines(function(e,t,n,r,i){var o="",a=!1,l=e.doc.lineSeparator(),s=!1;function c(){a&&(o+=l,s&&(o+=l),a=s=!1)}function u(e){e&&(c(),o+=e)}function d(t){if(1==t.nodeType){var n=t.getAttribute("cm-text");if(n)return void u(n);var o,f=t.getAttribute("cm-marker");if(f){var h=e.findMarks(et(r,0),et(i+1,0),(g=+f,function(e){return e.id==g}));return void(h.length&&(o=h[0].find(0))&&u(Ge(e.doc,o.from,o.to).join(l)))}if("false"==t.getAttribute("contenteditable"))return;var p=/^(pre|div|p|li|table|br)$/i.test(t.nodeName);if(!/^br$/i.test(t.nodeName)&&0==t.textContent.length)return;p&&c();for(var m=0;m1&&f.length>1;)if($(d)==$(f))d.pop(),f.pop(),s--;else{if(d[0]!=f[0])break;d.shift(),f.shift(),t++}for(var h=0,p=0,m=d[0],g=f[0],v=Math.min(m.length,g.length);ha.ch&&y.charCodeAt(y.length-p-1)==b.charCodeAt(b.length-p-1);)h--,p++;d[d.length-1]=y.slice(0,y.length-p).replace(/^\u200b+/,""),d[0]=d[0].slice(h).replace(/\u200b+$/,"");var x=et(t,h),k=et(s,f.length?$(f).length-p:0);return d.length>1||d[0]||tt(x,k)?(mo(r.doc,d,x,k,"+input"),!0):void 0},Ra.prototype.ensurePolled=function(){this.forceCompositionEnd()},Ra.prototype.reset=function(){this.forceCompositionEnd()},Ra.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Ra.prototype.readFromDOMSoon=function(){var e=this;null==this.readDOMTimeout&&(this.readDOMTimeout=setTimeout((function(){if(e.readDOMTimeout=null,e.composing){if(!e.composing.done)return;e.composing=null}e.updateFromDOM()}),80))},Ra.prototype.updateFromDOM=function(){var e=this;!this.cm.isReadOnly()&&this.pollContent()||Qr(this.cm,(function(){return dr(e.cm)}))},Ra.prototype.setUneditable=function(e){e.contentEditable="false"},Ra.prototype.onKeyPress=function(e){0==e.charCode||this.composing||(e.preventDefault(),this.cm.isReadOnly()||ei(this.cm,_a)(this.cm,String.fromCharCode(null==e.charCode?e.keyCode:e.charCode),0))},Ra.prototype.readOnlyChanged=function(e){this.div.contentEditable=String("nocursor"!=e)},Ra.prototype.onContextMenu=function(){},Ra.prototype.resetPosition=function(){},Ra.prototype.needsContentAttribute=!0;var Ka=function(e){this.cm=e,this.prevInput="",this.pollingFast=!1,this.polling=new H,this.hasSelection=!1,this.composing=null};Ka.prototype.init=function(e){var t=this,n=this,r=this.cm;this.createField(e);var i=this.textarea;function o(e){if(!me(r,e)){if(r.somethingSelected())Oa({lineWise:!1,text:r.getSelections()});else{if(!r.options.lineWiseCopyCut)return;var t=Da(r);Oa({lineWise:!0,text:t.text}),"cut"==e.type?r.setSelections(t.ranges,null,B):(n.prevInput="",i.value=t.text.join("\n"),D(i))}"cut"==e.type&&(r.state.cutIncoming=+new Date)}}e.wrapper.insertBefore(this.wrapper,e.wrapper.firstChild),m&&(i.style.width="0px"),de(i,"input",(function(){a&&l>=9&&t.hasSelection&&(t.hasSelection=null),n.poll()})),de(i,"paste",(function(e){me(r,e)||za(e,r)||(r.state.pasteIncoming=+new Date,n.fastPoll())})),de(i,"cut",o),de(i,"copy",o),de(e.scroller,"paste",(function(t){if(!kn(e,t)&&!me(r,t)){if(!i.dispatchEvent)return r.state.pasteIncoming=+new Date,void n.focus();var o=new Event("paste");o.clipboardData=t.clipboardData,i.dispatchEvent(o)}})),de(e.lineSpace,"selectstart",(function(t){kn(e,t)||be(t)})),de(i,"compositionstart",(function(){var e=r.getCursor("from");n.composing&&n.composing.range.clear(),n.composing={start:e,range:r.markText(e,r.getCursor("to"),{className:"CodeMirror-composing"})}})),de(i,"compositionend",(function(){n.composing&&(n.poll(),n.composing.range.clear(),n.composing=null)}))},Ka.prototype.createField=function(e){this.wrapper=Wa(),this.textarea=this.wrapper.firstChild},Ka.prototype.screenReaderLabelChanged=function(e){e?this.textarea.setAttribute("aria-label",e):this.textarea.removeAttribute("aria-label")},Ka.prototype.prepareSelection=function(){var e=this.cm,t=e.display,n=e.doc,r=vr(e);if(e.options.moveInputWithCursor){var i=Gn(e,n.sel.primary().head,"div"),o=t.wrapper.getBoundingClientRect(),a=t.lineDiv.getBoundingClientRect();r.teTop=Math.max(0,Math.min(t.wrapper.clientHeight-10,i.top+a.top-o.top)),r.teLeft=Math.max(0,Math.min(t.wrapper.clientWidth-10,i.left+a.left-o.left))}return r},Ka.prototype.showSelection=function(e){var t=this.cm.display;A(t.cursorDiv,e.cursors),A(t.selectionDiv,e.selection),null!=e.teTop&&(this.wrapper.style.top=e.teTop+"px",this.wrapper.style.left=e.teLeft+"px")},Ka.prototype.reset=function(e){if(!this.contextMenuPending&&!this.composing){var t=this.cm;if(t.somethingSelected()){this.prevInput="";var n=t.getSelection();this.textarea.value=n,t.state.focused&&D(this.textarea),a&&l>=9&&(this.hasSelection=n)}else e||(this.prevInput=this.textarea.value="",a&&l>=9&&(this.hasSelection=null))}},Ka.prototype.getField=function(){return this.textarea},Ka.prototype.supportsTouch=function(){return!1},Ka.prototype.focus=function(){if("nocursor"!=this.cm.options.readOnly&&(!v||_()!=this.textarea))try{this.textarea.focus()}catch(e){}},Ka.prototype.blur=function(){this.textarea.blur()},Ka.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Ka.prototype.receivedFocus=function(){this.slowPoll()},Ka.prototype.slowPoll=function(){var e=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,(function(){e.poll(),e.cm.state.focused&&e.slowPoll()}))},Ka.prototype.fastPoll=function(){var e=!1,t=this;t.pollingFast=!0,t.polling.set(20,(function n(){t.poll()||e?(t.pollingFast=!1,t.slowPoll()):(e=!0,t.polling.set(60,n))}))},Ka.prototype.poll=function(){var e=this,t=this.cm,n=this.textarea,r=this.prevInput;if(this.contextMenuPending||!t.state.focused||_e(n)&&!r&&!this.composing||t.isReadOnly()||t.options.disableInput||t.state.keySeq)return!1;var i=n.value;if(i==r&&!t.somethingSelected())return!1;if(a&&l>=9&&this.hasSelection===i||y&&/[\uf700-\uf7ff]/.test(i))return t.display.input.reset(),!1;if(t.doc.sel==t.display.selForContextMenu){var o=i.charCodeAt(0);if(8203!=o||r||(r="​"),8666==o)return this.reset(),this.cm.execCommand("undo")}for(var s=0,c=Math.min(r.length,i.length);s1e3||i.indexOf("\n")>-1?n.value=e.prevInput="":e.prevInput=i,e.composing&&(e.composing.range.clear(),e.composing.range=t.markText(e.composing.start,t.getCursor("to"),{className:"CodeMirror-composing"}))})),!0},Ka.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Ka.prototype.onKeyPress=function(){a&&l>=9&&(this.hasSelection=null),this.fastPoll()},Ka.prototype.onContextMenu=function(e){var t=this,n=t.cm,r=n.display,i=t.textarea;t.contextMenuPending&&t.contextMenuPending();var o=cr(n,e),c=r.scroller.scrollTop;if(o&&!d){n.options.resetSelectionOnContextMenu&&-1==n.doc.sel.contains(o)&&ei(n,Qi)(n.doc,Ti(o),B);var u,f=i.style.cssText,h=t.wrapper.style.cssText,p=t.wrapper.offsetParent.getBoundingClientRect();if(t.wrapper.style.cssText="position: static",i.style.cssText="position: absolute; width: 30px; height: 30px;\n top: "+(e.clientY-p.top-5)+"px; left: "+(e.clientX-p.left-5)+"px;\n z-index: 1000; background: "+(a?"rgba(255, 255, 255, .05)":"transparent")+";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);",s&&(u=window.scrollY),r.input.focus(),s&&window.scrollTo(null,u),r.input.reset(),n.somethingSelected()||(i.value=t.prevInput=" "),t.contextMenuPending=v,r.selForContextMenu=n.doc.sel,clearTimeout(r.detectingSelectAll),a&&l>=9&&g(),C){ke(e);var m=function(){he(window,"mouseup",m),setTimeout(v,20)};de(window,"mouseup",m)}else setTimeout(v,50)}function g(){if(null!=i.selectionStart){var e=n.somethingSelected(),o="​"+(e?i.value:"");i.value="⇚",i.value=o,t.prevInput=e?"":"​",i.selectionStart=1,i.selectionEnd=o.length,r.selForContextMenu=n.doc.sel}}function v(){if(t.contextMenuPending==v&&(t.contextMenuPending=!1,t.wrapper.style.cssText=h,i.style.cssText=f,a&&l<9&&r.scrollbars.setScrollTop(r.scroller.scrollTop=c),null!=i.selectionStart)){(!a||a&&l<9)&&g();var e=0,o=function(){r.selForContextMenu==n.doc.sel&&0==i.selectionStart&&i.selectionEnd>0&&"​"==t.prevInput?ei(n,lo)(n):e++<10?r.detectingSelectAll=setTimeout(o,500):(r.selForContextMenu=null,r.input.reset())};r.detectingSelectAll=setTimeout(o,200)}}},Ka.prototype.readOnlyChanged=function(e){e||this.reset(),this.textarea.disabled="nocursor"==e,this.textarea.readOnly=!!e},Ka.prototype.setUneditable=function(){},Ka.prototype.needsContentAttribute=!1,function(e){var t=e.optionHandlers;function n(n,r,i,o){e.defaults[n]=r,i&&(t[n]=o?function(e,t,n){n!=ka&&i(e,t,n)}:i)}e.defineOption=n,e.Init=ka,n("value","",(function(e,t){return e.setValue(t)}),!0),n("mode",null,(function(e,t){e.doc.modeOption=t,Ei(e)}),!0),n("indentUnit",2,Ei,!0),n("indentWithTabs",!1),n("smartIndent",!0),n("tabSize",4,(function(e){Oi(e),Rn(e),dr(e)}),!0),n("lineSeparator",null,(function(e,t){if(e.doc.lineSep=t,t){var n=[],r=e.doc.first;e.doc.iter((function(e){for(var i=0;;){var o=e.text.indexOf(t,i);if(-1==o)break;i=o+t.length,n.push(et(r,o))}r++}));for(var i=n.length-1;i>=0;i--)mo(e.doc,t,n[i],et(n[i].line,n[i].ch+t.length))}})),n("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b\u200e\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,(function(e,t,n){e.state.specialChars=new RegExp(t.source+(t.test("\t")?"":"|\t"),"g"),n!=ka&&e.refresh()})),n("specialCharPlaceholder",Jt,(function(e){return e.refresh()}),!0),n("electricChars",!0),n("inputStyle",v?"contenteditable":"textarea",(function(){throw new Error("inputStyle can not (yet) be changed in a running editor")}),!0),n("spellcheck",!1,(function(e,t){return e.getInputField().spellcheck=t}),!0),n("autocorrect",!1,(function(e,t){return e.getInputField().autocorrect=t}),!0),n("autocapitalize",!1,(function(e,t){return e.getInputField().autocapitalize=t}),!0),n("rtlMoveVisually",!w),n("wholeLineUpdateBefore",!0),n("theme","default",(function(e){xa(e),mi(e)}),!0),n("keyMap","default",(function(e,t,n){var r=Xo(t),i=n!=ka&&Xo(n);i&&i.detach&&i.detach(e,r),r.attach&&r.attach(e,i||null)})),n("extraKeys",null),n("configureMouse",null),n("lineWrapping",!1,La,!0),n("gutters",[],(function(e,t){e.display.gutterSpecs=hi(t,e.options.lineNumbers),mi(e)}),!0),n("fixedGutter",!0,(function(e,t){e.display.gutters.style.left=t?ar(e.display)+"px":"0",e.refresh()}),!0),n("coverGutterNextToScrollbar",!1,(function(e){return jr(e)}),!0),n("scrollbarStyle","native",(function(e){Ur(e),jr(e),e.display.scrollbars.setScrollTop(e.doc.scrollTop),e.display.scrollbars.setScrollLeft(e.doc.scrollLeft)}),!0),n("lineNumbers",!1,(function(e,t){e.display.gutterSpecs=hi(e.options.gutters,t),mi(e)}),!0),n("firstLineNumber",1,mi,!0),n("lineNumberFormatter",(function(e){return e}),mi,!0),n("showCursorWhenSelecting",!1,gr,!0),n("resetSelectionOnContextMenu",!0),n("lineWiseCopyCut",!0),n("pasteLinesPerSelection",!0),n("selectionsMayTouch",!1),n("readOnly",!1,(function(e,t){"nocursor"==t&&(Tr(e),e.display.input.blur()),e.display.input.readOnlyChanged(t)})),n("screenReaderLabel",null,(function(e,t){t=""===t?null:t,e.display.input.screenReaderLabelChanged(t)})),n("disableInput",!1,(function(e,t){t||e.display.input.reset()}),!0),n("dragDrop",!0,Ta),n("allowDropFileTypes",null),n("cursorBlinkRate",530),n("cursorScrollMargin",0),n("cursorHeight",1,gr,!0),n("singleCursorHeightPerLine",!0,gr,!0),n("workTime",100),n("workDelay",100),n("flattenSpans",!0,Oi,!0),n("addModeClass",!1,Oi,!0),n("pollInterval",100),n("undoDepth",200,(function(e,t){return e.doc.history.undoDepth=t})),n("historyEventDelay",1250),n("viewportMargin",10,(function(e){return e.refresh()}),!0),n("maxHighlightLength",1e4,Oi,!0),n("moveInputWithCursor",!0,(function(e,t){t||e.display.input.resetPosition()})),n("tabindex",null,(function(e,t){return e.display.input.getField().tabIndex=t||""})),n("autofocus",null),n("direction","ltr",(function(e,t){return e.doc.setDirection(t)}),!0),n("phrases",null)}(Ma),function(e){var t=e.optionHandlers,n=e.helpers={};e.prototype={constructor:e,focus:function(){window.focus(),this.display.input.focus()},setOption:function(e,n){var r=this.options,i=r[e];r[e]==n&&"mode"!=e||(r[e]=n,t.hasOwnProperty(e)&&ei(this,t[e])(this,n,i),pe(this,"optionChange",this,e))},getOption:function(e){return this.options[e]},getDoc:function(){return this.doc},addKeyMap:function(e,t){this.state.keyMaps[t?"push":"unshift"](Xo(e))},removeKeyMap:function(e){for(var t=this.state.keyMaps,n=0;nn&&(Na(this,i.head.line,e,!0),n=i.head.line,r==this.doc.sel.primIndex&&Or(this));else{var o=i.from(),a=i.to(),l=Math.max(n,o.line);n=Math.min(this.lastLine(),a.line-(a.ch?0:1))+1;for(var s=l;s0&&Xi(this.doc,r,new Ci(o,c[r].to()),B)}}})),getTokenAt:function(e,t){return yt(this,e,t)},getLineTokens:function(e,t){return yt(this,et(e),t,!0)},getTokenTypeAt:function(e){e=lt(this.doc,e);var t,n=ft(this,Ve(this.doc,e.line)),r=0,i=(n.length-1)/2,o=e.ch;if(0==o)t=n[2];else for(;;){var a=r+i>>1;if((a?n[2*a-1]:0)>=o)i=a;else{if(!(n[2*a+1]o&&(e=o,i=!0),r=Ve(this.doc,e)}else r=e;return Un(this,r,{top:0,left:0},t||"page",n||i).top+(i?this.doc.height-qt(r):0)},defaultTextHeight:function(){return rr(this.display)},defaultCharWidth:function(){return ir(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(e,t,n,r,i){var o,a,l,s=this.display,c=(e=Gn(this,lt(this.doc,e))).bottom,u=e.left;if(t.style.position="absolute",t.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(t),s.sizer.appendChild(t),"over"==r)c=e.top;else if("above"==r||"near"==r){var d=Math.max(s.wrapper.clientHeight,this.doc.height),f=Math.max(s.sizer.clientWidth,s.lineSpace.clientWidth);("above"==r||e.bottom+t.offsetHeight>d)&&e.top>t.offsetHeight?c=e.top-t.offsetHeight:e.bottom+t.offsetHeight<=d&&(c=e.bottom),u+t.offsetWidth>f&&(u=f-t.offsetWidth)}t.style.top=c+"px",t.style.left=t.style.right="","right"==i?(u=s.sizer.clientWidth-t.offsetWidth,t.style.right="0px"):("left"==i?u=0:"middle"==i&&(u=(s.sizer.clientWidth-t.offsetWidth)/2),t.style.left=u+"px"),n&&(o=this,a={left:u,top:c,right:u+t.offsetWidth,bottom:c+t.offsetHeight},null!=(l=Nr(o,a)).scrollTop&&Dr(o,l.scrollTop),null!=l.scrollLeft&&Wr(o,l.scrollLeft))},triggerOnKeyDown:ti(ua),triggerOnKeyPress:ti(fa),triggerOnKeyUp:da,triggerOnMouseDown:ti(ga),execCommand:function(e){if(ta.hasOwnProperty(e))return ta[e].call(null,this)},triggerElectric:ti((function(e){Pa(this,e)})),findPosH:function(e,t,n,r){var i=1;t<0&&(i=-1,t=-t);for(var o=lt(this.doc,e),a=0;a0&&a(t.charAt(n-1));)--n;for(;r.5||this.options.lineWrapping)&&sr(this),pe(this,"refresh",this)})),swapDoc:ti((function(e){var t=this.doc;return t.cm=null,this.state.selectingText&&this.state.selectingText(),Di(this,e),Rn(this),this.display.input.reset(),_r(this,e.scrollLeft,e.scrollTop),this.curOp.forceScroll=!0,sn(this,"swapDoc",this,t),t})),phrase:function(e){var t=this.options.phrases;return t&&Object.prototype.hasOwnProperty.call(t,e)?t[e]:e},getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},ye(e),e.registerHelper=function(t,r,i){n.hasOwnProperty(t)||(n[t]=e[t]={_global:[]}),n[t][r]=i},e.registerGlobalHelper=function(t,r,i,o){e.registerHelper(t,r,o),n[t]._global.push({pred:i,val:o})}}(Ma);var Va="iter insert remove copy getEditor constructor".split(" ");for(var Ga in Oo.prototype)Oo.prototype.hasOwnProperty(Ga)&&R(Va,Ga)<0&&(Ma.prototype[Ga]=function(e){return function(){return e.apply(this.doc,arguments)}}(Oo.prototype[Ga]));return ye(Oo),Ma.inputStyles={textarea:Ka,contenteditable:Ra},Ma.defineMode=function(e){Ma.defaults.mode||"null"==e||(Ma.defaults.mode=e),We.apply(this,arguments)},Ma.defineMIME=function(e,t){Ie[e]=t},Ma.defineMode("null",(function(){return{token:function(e){return e.skipToEnd()}}})),Ma.defineMIME("text/plain","null"),Ma.defineExtension=function(e,t){Ma.prototype[e]=t},Ma.defineDocExtension=function(e,t){Oo.prototype[e]=t},Ma.fromTextArea=function(e,t){if((t=t?W(t):{}).value=e.value,!t.tabindex&&e.tabIndex&&(t.tabindex=e.tabIndex),!t.placeholder&&e.placeholder&&(t.placeholder=e.placeholder),null==t.autofocus){var n=_();t.autofocus=n==e||null!=e.getAttribute("autofocus")&&n==document.body}function r(){e.value=l.getValue()}var i;if(e.form&&(de(e.form,"submit",r),!t.leaveSubmitMethodAlone)){var o=e.form;i=o.submit;try{var a=o.submit=function(){r(),o.submit=i,o.submit(),o.submit=a}}catch(e){}}t.finishInit=function(n){n.save=r,n.getTextArea=function(){return e},n.toTextArea=function(){n.toTextArea=isNaN,r(),e.parentNode.removeChild(n.getWrapperElement()),e.style.display="",e.form&&(he(e.form,"submit",r),t.leaveSubmitMethodAlone||"function"!=typeof e.form.submit||(e.form.submit=i))}},e.style.display="none";var l=Ma((function(t){return e.parentNode.insertBefore(t,e.nextSibling)}),t);return l},function(e){e.off=he,e.on=de,e.wheelEventPixels=wi,e.Doc=Oo,e.splitLines=Oe,e.countColumn=F,e.findColumn=K,e.isWordChar=Q,e.Pass=j,e.signal=pe,e.Line=Vt,e.changeEnd=Li,e.scrollbarModel=qr,e.Pos=et,e.cmpPos=tt,e.modes=De,e.mimeModes=Ie,e.resolveMode=Fe,e.getMode=He,e.modeExtensions=Re,e.extendMode=je,e.copyState=Be,e.startState=Ue,e.innerMode=qe,e.commands=ta,e.keyMap=qo,e.keyName=Yo,e.isModifierKey=Go,e.lookupKey=Vo,e.normalizeKeyMap=Ko,e.StringStream=Ke,e.SharedTextMarker=Mo,e.TextMarker=To,e.LineWidget=ko,e.e_preventDefault=be,e.e_stopPropagation=we,e.e_stop=ke,e.addClass=z,e.contains=O,e.rmClass=L,e.keyNames=Ho}(Ma),Ma.version="5.61.0",Ma}()},6629:(e,t,n)=>{!function(e){"use strict";function t(e){for(var t={},n=0;n*\/]/.test(n)?k(null,"select-op"):"."==n&&e.match(/^-?[_a-z][_a-z0-9-]*/i)?k("qualifier","qualifier"):/[:;{}\[\]\(\)]/.test(n)?k(null,n):e.match(/^[\w-.]+(?=\()/)?(/^(url(-prefix)?|domain|regexp)$/i.test(e.current())&&(t.tokenize=T),k("variable callee","variable")):/[\w\\\-]/.test(n)?(e.eatWhile(/[\w\\\-]/),k("property","word")):k(null,null):/[\d.]/.test(e.peek())?(e.eatWhile(/[\w.%]/),k("number","unit")):e.match(/^-[\w\\\-]*/)?(e.eatWhile(/[\w\\\-]/),e.match(/^\s*:/,!1)?k("variable-2","variable-definition"):k("variable-2","variable")):e.match(/^\w+-/)?k("meta","meta"):void 0}function S(e){return function(t,n){for(var r,i=!1;null!=(r=t.next());){if(r==e&&!i){")"==e&&t.backUp(1);break}i=!i&&"\\"==r}return(r==e||!i&&")"!=e)&&(n.tokenize=null),k("string","string")}}function T(e,t){return e.next(),e.match(/^\s*[\"\')]/,!1)?t.tokenize=null:t.tokenize=S(")"),k(null,"(")}function L(e,t,n){this.type=e,this.indent=t,this.prev=n}function M(e,t,n,r){return e.context=new L(n,t.indentation()+(!1===r?0:a),e.context),n}function A(e){return e.context.prev&&(e.context=e.context.prev),e.context.type}function N(e,t,n){return _[n.context.type](e,t,n)}function E(e,t,n,r){for(var i=r||1;i>0;i--)n.context=n.context.prev;return N(e,t,n)}function O(e){var t=e.current().toLowerCase();o=v.hasOwnProperty(t)?"atom":g.hasOwnProperty(t)?"keyword":"variable"}var _={top:function(e,t,n){if("{"==e)return M(n,t,"block");if("}"==e&&n.context.prev)return A(n);if(w&&/@component/i.test(e))return M(n,t,"atComponentBlock");if(/^@(-moz-)?document$/i.test(e))return M(n,t,"documentTypes");if(/^@(media|supports|(-moz-)?document|import)$/i.test(e))return M(n,t,"atBlock");if(/^@(font-face|counter-style)/i.test(e))return n.stateArg=e,"restricted_atBlock_before";if(/^@(-(moz|ms|o|webkit)-)?keyframes$/i.test(e))return"keyframes";if(e&&"@"==e.charAt(0))return M(n,t,"at");if("hash"==e)o="builtin";else if("word"==e)o="tag";else{if("variable-definition"==e)return"maybeprop";if("interpolation"==e)return M(n,t,"interpolation");if(":"==e)return"pseudo";if(y&&"("==e)return M(n,t,"parens")}return n.context.type},block:function(e,t,n){if("word"==e){var r=t.current().toLowerCase();return f.hasOwnProperty(r)?(o="property","maybeprop"):h.hasOwnProperty(r)?(o=x?"string-2":"property","maybeprop"):y?(o=t.match(/^\s*:(?:\s|$)/,!1)?"property":"tag","block"):(o+=" error","maybeprop")}return"meta"==e?"block":y||"hash"!=e&&"qualifier"!=e?_.top(e,t,n):(o="error","block")},maybeprop:function(e,t,n){return":"==e?M(n,t,"prop"):N(e,t,n)},prop:function(e,t,n){if(";"==e)return A(n);if("{"==e&&y)return M(n,t,"propBlock");if("}"==e||"{"==e)return E(e,t,n);if("("==e)return M(n,t,"parens");if("hash"!=e||/^#([0-9a-fA-f]{3,4}|[0-9a-fA-f]{6}|[0-9a-fA-f]{8})$/.test(t.current())){if("word"==e)O(t);else if("interpolation"==e)return M(n,t,"interpolation")}else o+=" error";return"prop"},propBlock:function(e,t,n){return"}"==e?A(n):"word"==e?(o="property","maybeprop"):n.context.type},parens:function(e,t,n){return"{"==e||"}"==e?E(e,t,n):")"==e?A(n):"("==e?M(n,t,"parens"):"interpolation"==e?M(n,t,"interpolation"):("word"==e&&O(t),"parens")},pseudo:function(e,t,n){return"meta"==e?"pseudo":"word"==e?(o="variable-3",n.context.type):N(e,t,n)},documentTypes:function(e,t,n){return"word"==e&&s.hasOwnProperty(t.current())?(o="tag",n.context.type):_.atBlock(e,t,n)},atBlock:function(e,t,n){if("("==e)return M(n,t,"atBlock_parens");if("}"==e||";"==e)return E(e,t,n);if("{"==e)return A(n)&&M(n,t,y?"block":"top");if("interpolation"==e)return M(n,t,"interpolation");if("word"==e){var r=t.current().toLowerCase();o="only"==r||"not"==r||"and"==r||"or"==r?"keyword":c.hasOwnProperty(r)?"attribute":u.hasOwnProperty(r)?"property":d.hasOwnProperty(r)?"keyword":f.hasOwnProperty(r)?"property":h.hasOwnProperty(r)?x?"string-2":"property":v.hasOwnProperty(r)?"atom":g.hasOwnProperty(r)?"keyword":"error"}return n.context.type},atComponentBlock:function(e,t,n){return"}"==e?E(e,t,n):"{"==e?A(n)&&M(n,t,y?"block":"top",!1):("word"==e&&(o="error"),n.context.type)},atBlock_parens:function(e,t,n){return")"==e?A(n):"{"==e||"}"==e?E(e,t,n,2):_.atBlock(e,t,n)},restricted_atBlock_before:function(e,t,n){return"{"==e?M(n,t,"restricted_atBlock"):"word"==e&&"@counter-style"==n.stateArg?(o="variable","restricted_atBlock_before"):N(e,t,n)},restricted_atBlock:function(e,t,n){return"}"==e?(n.stateArg=null,A(n)):"word"==e?(o="@font-face"==n.stateArg&&!p.hasOwnProperty(t.current().toLowerCase())||"@counter-style"==n.stateArg&&!m.hasOwnProperty(t.current().toLowerCase())?"error":"property","maybeprop"):"restricted_atBlock"},keyframes:function(e,t,n){return"word"==e?(o="variable","keyframes"):"{"==e?M(n,t,"top"):N(e,t,n)},at:function(e,t,n){return";"==e?A(n):"{"==e||"}"==e?E(e,t,n):("word"==e?o="tag":"hash"==e&&(o="builtin"),"at")},interpolation:function(e,t,n){return"}"==e?A(n):"{"==e||";"==e?E(e,t,n):("word"==e?o="variable":"variable"!=e&&"("!=e&&")"!=e&&(o="error"),"interpolation")}};return{startState:function(e){return{tokenize:null,state:r?"block":"top",stateArg:null,context:new L(r?"block":"top",e||0,null)}},token:function(e,t){if(!t.tokenize&&e.eatSpace())return null;var n=(t.tokenize||C)(e,t);return n&&"object"==typeof n&&(i=n[1],n=n[0]),o=n,"comment"!=i&&(t.state=_[t.state](i,e,t)),o},indent:function(e,t){var n=e.context,r=t&&t.charAt(0),i=n.indent;return"prop"!=n.type||"}"!=r&&")"!=r||(n=n.prev),n.prev&&("}"!=r||"block"!=n.type&&"top"!=n.type&&"interpolation"!=n.type&&"restricted_atBlock"!=n.type?(")"!=r||"parens"!=n.type&&"atBlock_parens"!=n.type)&&("{"!=r||"at"!=n.type&&"atBlock"!=n.type)||(i=Math.max(0,n.indent-a)):i=(n=n.prev).indent),i},electricChars:"}",blockCommentStart:"/*",blockCommentEnd:"*/",blockCommentContinue:" * ",lineComment:b,fold:"brace"}}));var n=["domain","regexp","url","url-prefix"],r=t(n),i=["all","aural","braille","handheld","print","projection","screen","tty","tv","embossed"],o=t(i),a=["width","min-width","max-width","height","min-height","max-height","device-width","min-device-width","max-device-width","device-height","min-device-height","max-device-height","aspect-ratio","min-aspect-ratio","max-aspect-ratio","device-aspect-ratio","min-device-aspect-ratio","max-device-aspect-ratio","color","min-color","max-color","color-index","min-color-index","max-color-index","monochrome","min-monochrome","max-monochrome","resolution","min-resolution","max-resolution","scan","grid","orientation","device-pixel-ratio","min-device-pixel-ratio","max-device-pixel-ratio","pointer","any-pointer","hover","any-hover","prefers-color-scheme"],l=t(a),s=["landscape","portrait","none","coarse","fine","on-demand","hover","interlace","progressive","dark","light"],c=t(s),u=["align-content","align-items","align-self","alignment-adjust","alignment-baseline","all","anchor-point","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","appearance","azimuth","backdrop-filter","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-position-x","background-position-y","background-repeat","background-size","baseline-shift","binding","bleed","block-size","bookmark-label","bookmark-level","bookmark-state","bookmark-target","border","border-bottom","border-bottom-color","border-bottom-left-radius","border-bottom-right-radius","border-bottom-style","border-bottom-width","border-collapse","border-color","border-image","border-image-outset","border-image-repeat","border-image-slice","border-image-source","border-image-width","border-left","border-left-color","border-left-style","border-left-width","border-radius","border-right","border-right-color","border-right-style","border-right-width","border-spacing","border-style","border-top","border-top-color","border-top-left-radius","border-top-right-radius","border-top-style","border-top-width","border-width","bottom","box-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","color","color-profile","column-count","column-fill","column-gap","column-rule","column-rule-color","column-rule-style","column-rule-width","column-span","column-width","columns","contain","content","counter-increment","counter-reset","crop","cue","cue-after","cue-before","cursor","direction","display","dominant-baseline","drop-initial-after-adjust","drop-initial-after-align","drop-initial-before-adjust","drop-initial-before-align","drop-initial-size","drop-initial-value","elevation","empty-cells","fit","fit-position","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","float-offset","flow-from","flow-into","font","font-family","font-feature-settings","font-kerning","font-language-override","font-optical-sizing","font-size","font-size-adjust","font-stretch","font-style","font-synthesis","font-variant","font-variant-alternates","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-variation-settings","font-weight","gap","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-gap","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-gap","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","inline-box-align","inset","inset-block","inset-block-end","inset-block-start","inset-inline","inset-inline-end","inset-inline-start","isolation","justify-content","justify-items","justify-self","left","letter-spacing","line-break","line-height","line-height-step","line-stacking","line-stacking-ruby","line-stacking-shift","line-stacking-strategy","list-style","list-style-image","list-style-position","list-style-type","margin","margin-bottom","margin-left","margin-right","margin-top","marks","marquee-direction","marquee-loop","marquee-play-count","marquee-speed","marquee-style","mask-clip","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mix-blend-mode","move-to","nav-down","nav-index","nav-left","nav-right","nav-up","object-fit","object-position","offset","offset-anchor","offset-distance","offset-path","offset-position","offset-rotate","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-style","overflow-wrap","overflow-x","overflow-y","padding","padding-bottom","padding-left","padding-right","padding-top","page","page-break-after","page-break-before","page-break-inside","page-policy","pause","pause-after","pause-before","perspective","perspective-origin","pitch","pitch-range","place-content","place-items","place-self","play-during","position","presentation-level","punctuation-trim","quotes","region-break-after","region-break-before","region-break-inside","region-fragment","rendering-intent","resize","rest","rest-after","rest-before","richness","right","rotate","rotation","rotation-point","row-gap","ruby-align","ruby-overhang","ruby-position","ruby-span","scale","scroll-behavior","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","scroll-snap-align","scroll-snap-type","shape-image-threshold","shape-inside","shape-margin","shape-outside","size","speak","speak-as","speak-header","speak-numeral","speak-punctuation","speech-rate","stress","string-set","tab-size","table-layout","target","target-name","target-new","target-position","text-align","text-align-last","text-combine-upright","text-decoration","text-decoration-color","text-decoration-line","text-decoration-skip","text-decoration-skip-ink","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-height","text-indent","text-justify","text-orientation","text-outline","text-overflow","text-rendering","text-shadow","text-size-adjust","text-space-collapse","text-transform","text-underline-position","text-wrap","top","touch-action","transform","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","translate","unicode-bidi","user-select","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","writing-mode","z-index","clip-path","clip-rule","mask","enable-background","filter","flood-color","flood-opacity","lighting-color","stop-color","stop-opacity","pointer-events","color-interpolation","color-interpolation-filters","color-rendering","fill","fill-opacity","fill-rule","image-rendering","marker","marker-end","marker-mid","marker-start","paint-order","shape-rendering","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-rendering","baseline-shift","dominant-baseline","glyph-orientation-horizontal","glyph-orientation-vertical","text-anchor","writing-mode"],d=t(u),f=["border-block","border-block-color","border-block-end","border-block-end-color","border-block-end-style","border-block-end-width","border-block-start","border-block-start-color","border-block-start-style","border-block-start-width","border-block-style","border-block-width","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-end-style","border-inline-end-width","border-inline-start","border-inline-start-color","border-inline-start-style","border-inline-start-width","border-inline-style","border-inline-width","margin-block","margin-block-end","margin-block-start","margin-inline","margin-inline-end","margin-inline-start","padding-block","padding-block-end","padding-block-start","padding-inline","padding-inline-end","padding-inline-start","scroll-snap-stop","scrollbar-3d-light-color","scrollbar-arrow-color","scrollbar-base-color","scrollbar-dark-shadow-color","scrollbar-face-color","scrollbar-highlight-color","scrollbar-shadow-color","scrollbar-track-color","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","shape-inside","zoom"],h=t(f),p=t(["font-display","font-family","src","unicode-range","font-variant","font-feature-settings","font-stretch","font-weight","font-style"]),m=t(["additive-symbols","fallback","negative","pad","prefix","range","speak-as","suffix","symbols","system"]),g=["aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","rebeccapurple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"],v=t(g),y=["above","absolute","activeborder","additive","activecaption","afar","after-white-space","ahead","alias","all","all-scroll","alphabetic","alternate","always","amharic","amharic-abegede","antialiased","appworkspace","arabic-indic","armenian","asterisks","attr","auto","auto-flow","avoid","avoid-column","avoid-page","avoid-region","axis-pan","background","backwards","baseline","below","bidi-override","binary","bengali","blink","block","block-axis","bold","bolder","border","border-box","both","bottom","break","break-all","break-word","bullets","button","button-bevel","buttonface","buttonhighlight","buttonshadow","buttontext","calc","cambodian","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-decimal","cjk-earthly-branch","cjk-heavenly-stem","cjk-ideographic","clear","clip","close-quote","col-resize","collapse","color","color-burn","color-dodge","column","column-reverse","compact","condensed","contain","content","contents","content-box","context-menu","continuous","copy","counter","counters","cover","crop","cross","crosshair","currentcolor","cursive","cyclic","darken","dashed","decimal","decimal-leading-zero","default","default-button","dense","destination-atop","destination-in","destination-out","destination-over","devanagari","difference","disc","discard","disclosure-closed","disclosure-open","document","dot-dash","dot-dot-dash","dotted","double","down","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipse","ellipsis","embed","end","ethiopic","ethiopic-abegede","ethiopic-abegede-am-et","ethiopic-abegede-gez","ethiopic-abegede-ti-er","ethiopic-abegede-ti-et","ethiopic-halehame-aa-er","ethiopic-halehame-aa-et","ethiopic-halehame-am-et","ethiopic-halehame-gez","ethiopic-halehame-om-et","ethiopic-halehame-sid-et","ethiopic-halehame-so-et","ethiopic-halehame-ti-er","ethiopic-halehame-ti-et","ethiopic-halehame-tig","ethiopic-numeric","ew-resize","exclusion","expanded","extends","extra-condensed","extra-expanded","fantasy","fast","fill","fill-box","fixed","flat","flex","flex-end","flex-start","footnotes","forwards","from","geometricPrecision","georgian","graytext","grid","groove","gujarati","gurmukhi","hand","hangul","hangul-consonant","hard-light","hebrew","help","hidden","hide","higher","highlight","highlighttext","hiragana","hiragana-iroha","horizontal","hsl","hsla","hue","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-flex","inline-grid","inline-table","inset","inside","intrinsic","invert","italic","japanese-formal","japanese-informal","justify","kannada","katakana","katakana-iroha","keep-all","khmer","korean-hangul-formal","korean-hanja-formal","korean-hanja-informal","landscape","lao","large","larger","left","level","lighter","lighten","line-through","linear","linear-gradient","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-alpha","lower-armenian","lower-greek","lower-hexadecimal","lower-latin","lower-norwegian","lower-roman","lowercase","ltr","luminosity","malayalam","manipulation","match","matrix","matrix3d","media-controls-background","media-current-time-display","media-fullscreen-button","media-mute-button","media-play-button","media-return-to-realtime-button","media-rewind-button","media-seek-back-button","media-seek-forward-button","media-slider","media-sliderthumb","media-time-remaining-display","media-volume-slider","media-volume-slider-container","media-volume-sliderthumb","medium","menu","menulist","menulist-button","menulist-text","menulist-textfield","menutext","message-box","middle","min-intrinsic","mix","mongolian","monospace","move","multiple","multiple_mask_images","multiply","myanmar","n-resize","narrower","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","numbers","numeric","nw-resize","nwse-resize","oblique","octal","opacity","open-quote","optimizeLegibility","optimizeSpeed","oriya","oromo","outset","outside","outside-shape","overlay","overline","padding","padding-box","painted","page","paused","persian","perspective","pinch-zoom","plus-darker","plus-lighter","pointer","polygon","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radial-gradient","radio","read-only","read-write","read-write-plaintext-only","rectangle","region","relative","repeat","repeating-linear-gradient","repeating-radial-gradient","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","rotate","rotate3d","rotateX","rotateY","rotateZ","round","row","row-resize","row-reverse","rtl","run-in","running","s-resize","sans-serif","saturation","scale","scale3d","scaleX","scaleY","scaleZ","screen","scroll","scrollbar","scroll-position","se-resize","searchfield","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","self-start","self-end","semi-condensed","semi-expanded","separate","serif","show","sidama","simp-chinese-formal","simp-chinese-informal","single","skew","skewX","skewY","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","soft-light","solid","somali","source-atop","source-in","source-out","source-over","space","space-around","space-between","space-evenly","spell-out","square","square-button","start","static","status-bar","stretch","stroke","stroke-box","sub","subpixel-antialiased","svg_masks","super","sw-resize","symbolic","symbols","system-ui","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","tamil","telugu","text","text-bottom","text-top","textarea","textfield","thai","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","tibetan","tigre","tigrinya-er","tigrinya-er-abegede","tigrinya-et","tigrinya-et-abegede","to","top","trad-chinese-formal","trad-chinese-informal","transform","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","unidirectional-pan","unset","up","upper-alpha","upper-armenian","upper-greek","upper-hexadecimal","upper-latin","upper-norwegian","upper-roman","uppercase","urdu","url","var","vertical","vertical-text","view-box","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","wider","window","windowframe","windowtext","words","wrap","wrap-reverse","x-large","x-small","xor","xx-large","xx-small"],b=t(y),w=n.concat(i).concat(a).concat(s).concat(u).concat(f).concat(g).concat(y);function x(e,t){for(var n,r=!1;null!=(n=e.next());){if(r&&"/"==n){t.tokenize=null;break}r="*"==n}return["comment","comment"]}e.registerHelper("hintWords","css",w),e.defineMIME("text/css",{documentTypes:r,mediaTypes:o,mediaFeatures:l,mediaValueKeywords:c,propertyKeywords:d,nonStandardPropertyKeywords:h,fontProperties:p,counterDescriptors:m,colorKeywords:v,valueKeywords:b,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=x,x(e,t))}},name:"css"}),e.defineMIME("text/x-scss",{mediaTypes:o,mediaFeatures:l,mediaValueKeywords:c,propertyKeywords:d,nonStandardPropertyKeywords:h,colorKeywords:v,valueKeywords:b,fontProperties:p,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=x,x(e,t)):["operator","operator"]},":":function(e){return!!e.match(/^\s*\{/,!1)&&[null,null]},$:function(e){return e.match(/^[\w-]+/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"]},"#":function(e){return!!e.eat("{")&&[null,"interpolation"]}},name:"css",helperType:"scss"}),e.defineMIME("text/x-less",{mediaTypes:o,mediaFeatures:l,mediaValueKeywords:c,propertyKeywords:d,nonStandardPropertyKeywords:h,colorKeywords:v,valueKeywords:b,fontProperties:p,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=x,x(e,t)):["operator","operator"]},"@":function(e){return e.eat("{")?[null,"interpolation"]:!e.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/i,!1)&&(e.eatWhile(/[\w\\\-]/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"])},"&":function(){return["atom","atom"]}},name:"css",helperType:"less"}),e.defineMIME("text/x-gss",{documentTypes:r,mediaTypes:o,mediaFeatures:l,propertyKeywords:d,nonStandardPropertyKeywords:h,fontProperties:p,counterDescriptors:m,colorKeywords:v,valueKeywords:b,supportsAtComponent:!0,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=x,x(e,t))}},name:"css",helperType:"gss"})}(n(4631))},6531:(e,t,n)=>{!function(e){"use strict";var t={script:[["lang",/(javascript|babel)/i,"javascript"],["type",/^(?:text|application)\/(?:x-)?(?:java|ecma)script$|^module$|^$/i,"javascript"],["type",/./,"text/plain"],[null,null,"javascript"]],style:[["lang",/^css$/i,"css"],["type",/^(text\/)?(x-)?(stylesheet|css)$/i,"css"],["type",/./,"text/plain"],[null,null,"css"]]};var n={};function r(e,t){var r=e.match(function(e){return n[e]||(n[e]=new RegExp("\\s+"+e+"\\s*=\\s*('|\")?([^'\"]+)('|\")?\\s*"))}(t));return r?/^\s*(.*?)\s*$/.exec(r[2])[1]:""}function i(e,t){return new RegExp((t?"^":"")+"","i")}function o(e,t){for(var n in e)for(var r=t[n]||(t[n]=[]),i=e[n],o=i.length-1;o>=0;o--)r.unshift(i[o])}e.defineMode("htmlmixed",(function(n,a){var l=e.getMode(n,{name:"xml",htmlMode:!0,multilineTagIndentFactor:a.multilineTagIndentFactor,multilineTagIndentPastTag:a.multilineTagIndentPastTag,allowMissingTagName:a.allowMissingTagName}),s={},c=a&&a.tags,u=a&&a.scriptTypes;if(o(t,s),c&&o(c,s),u)for(var d=u.length-1;d>=0;d--)s.script.unshift(["type",u[d].matches,u[d].mode]);function f(t,o){var a,c=l.token(t,o.htmlState),u=/\btag\b/.test(c);if(u&&!/[<>\s\/]/.test(t.current())&&(a=o.htmlState.tagName&&o.htmlState.tagName.toLowerCase())&&s.hasOwnProperty(a))o.inTag=a+" ";else if(o.inTag&&u&&/>$/.test(t.current())){var d=/^([\S]+) (.*)/.exec(o.inTag);o.inTag=null;var h=">"==t.current()&&function(e,t){for(var n=0;n-1?e.backUp(r.length-i):r.match(/<\/?$/)&&(e.backUp(r.length),e.match(t,!1)||e.match(r)),n}(e,g,t.localMode.token(e,t.localState))},o.localMode=p,o.localState=e.startState(p,l.indent(o.htmlState,"",""))}else o.inTag&&(o.inTag+=t.current(),t.eol()&&(o.inTag+=" "));return c}return{startState:function(){return{token:f,inTag:null,localMode:null,localState:null,htmlState:e.startState(l)}},copyState:function(t){var n;return t.localState&&(n=e.copyState(t.localMode,t.localState)),{token:t.token,inTag:t.inTag,localMode:t.localMode,localState:n,htmlState:e.copyState(l,t.htmlState)}},token:function(e,t){return t.token(e,t)},indent:function(t,n,r){return!t.localMode||/^\s*<\//.test(n)?l.indent(t.htmlState,n,r):t.localMode.indent?t.localMode.indent(t.localState,n,r):e.Pass},innerMode:function(e){return{state:e.localState||e.htmlState,mode:e.localMode||l}}}}),"xml","javascript","css"),e.defineMIME("text/html","htmlmixed")}(n(4631),n(9589),n(6876),n(6629))},6876:(e,t,n)=>{!function(e){"use strict";e.defineMode("javascript",(function(t,n){var r,i,o=t.indentUnit,a=n.statementIndent,l=n.jsonld,s=n.json||l,c=!1!==n.trackScope,u=n.typescript,d=n.wordCharacters||/[\w$\xa1-\uffff]/,f=function(){function e(e){return{type:e,style:"keyword"}}var t=e("keyword a"),n=e("keyword b"),r=e("keyword c"),i=e("keyword d"),o=e("operator"),a={type:"atom",style:"atom"};return{if:e("if"),while:t,with:t,else:n,do:n,try:n,finally:n,return:i,break:i,continue:i,new:e("new"),delete:r,void:r,throw:r,debugger:e("debugger"),var:e("var"),const:e("var"),let:e("var"),function:e("function"),catch:e("catch"),for:e("for"),switch:e("switch"),case:e("case"),default:e("default"),in:o,typeof:o,instanceof:o,true:a,false:a,null:a,undefined:a,NaN:a,Infinity:a,this:e("this"),class:e("class"),super:e("atom"),yield:r,export:e("export"),import:e("import"),extends:r,await:r}}(),h=/[+\-*&%=<>!?|~^@]/,p=/^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/;function m(e,t,n){return r=e,i=n,t}function g(e,t){var n,r=e.next();if('"'==r||"'"==r)return t.tokenize=(n=r,function(e,t){var r,i=!1;if(l&&"@"==e.peek()&&e.match(p))return t.tokenize=g,m("jsonld-keyword","meta");for(;null!=(r=e.next())&&(r!=n||i);)i=!i&&"\\"==r;return i||(t.tokenize=g),m("string","string")}),t.tokenize(e,t);if("."==r&&e.match(/^\d[\d_]*(?:[eE][+\-]?[\d_]+)?/))return m("number","number");if("."==r&&e.match(".."))return m("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(r))return m(r);if("="==r&&e.eat(">"))return m("=>","operator");if("0"==r&&e.match(/^(?:x[\dA-Fa-f_]+|o[0-7_]+|b[01_]+)n?/))return m("number","number");if(/\d/.test(r))return e.match(/^[\d_]*(?:n|(?:\.[\d_]*)?(?:[eE][+\-]?[\d_]+)?)?/),m("number","number");if("/"==r)return e.eat("*")?(t.tokenize=v,v(e,t)):e.eat("/")?(e.skipToEnd(),m("comment","comment")):Xe(e,t,1)?(function(e){for(var t,n=!1,r=!1;null!=(t=e.next());){if(!n){if("/"==t&&!r)return;"["==t?r=!0:r&&"]"==t&&(r=!1)}n=!n&&"\\"==t}}(e),e.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/),m("regexp","string-2")):(e.eat("="),m("operator","operator",e.current()));if("`"==r)return t.tokenize=y,y(e,t);if("#"==r&&"!"==e.peek())return e.skipToEnd(),m("meta","meta");if("#"==r&&e.eatWhile(d))return m("variable","property");if("<"==r&&e.match("!--")||"-"==r&&e.match("->")&&!/\S/.test(e.string.slice(0,e.start)))return e.skipToEnd(),m("comment","comment");if(h.test(r))return">"==r&&t.lexical&&">"==t.lexical.type||(e.eat("=")?"!"!=r&&"="!=r||e.eat("="):/[<>*+\-|&?]/.test(r)&&(e.eat(r),">"==r&&e.eat(r))),"?"==r&&e.eat(".")?m("."):m("operator","operator",e.current());if(d.test(r)){e.eatWhile(d);var i=e.current();if("."!=t.lastType){if(f.propertyIsEnumerable(i)){var o=f[i];return m(o.type,o.style,i)}if("async"==i&&e.match(/^(\s|\/\*([^*]|\*(?!\/))*?\*\/)*[\[\(\w]/,!1))return m("async","keyword",i)}return m("variable","variable",i)}}function v(e,t){for(var n,r=!1;n=e.next();){if("/"==n&&r){t.tokenize=g;break}r="*"==n}return m("comment","comment")}function y(e,t){for(var n,r=!1;null!=(n=e.next());){if(!r&&("`"==n||"$"==n&&e.eat("{"))){t.tokenize=g;break}r=!r&&"\\"==n}return m("quasi","string-2",e.current())}function b(e,t){t.fatArrowAt&&(t.fatArrowAt=null);var n=e.string.indexOf("=>",e.start);if(!(n<0)){if(u){var r=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start,n));r&&(n=r.index)}for(var i=0,o=!1,a=n-1;a>=0;--a){var l=e.string.charAt(a),s="([{}])".indexOf(l);if(s>=0&&s<3){if(!i){++a;break}if(0==--i){"("==l&&(o=!0);break}}else if(s>=3&&s<6)++i;else if(d.test(l))o=!0;else if(/["'\/`]/.test(l))for(;;--a){if(0==a)return;if(e.string.charAt(a-1)==l&&"\\"!=e.string.charAt(a-2)){a--;break}}else if(o&&!i){++a;break}}o&&!i&&(t.fatArrowAt=a)}}var w={atom:!0,number:!0,variable:!0,string:!0,regexp:!0,this:!0,import:!0,"jsonld-keyword":!0};function x(e,t,n,r,i,o){this.indented=e,this.column=t,this.type=n,this.prev=i,this.info=o,null!=r&&(this.align=r)}function k(e,t){if(!c)return!1;for(var n=e.localVars;n;n=n.next)if(n.name==t)return!0;for(var r=e.context;r;r=r.prev)for(n=r.vars;n;n=n.next)if(n.name==t)return!0}var C={state:null,column:null,marked:null,cc:null};function S(){for(var e=arguments.length-1;e>=0;e--)C.cc.push(arguments[e])}function T(){return S.apply(null,arguments),!0}function L(e,t){for(var n=t;n;n=n.next)if(n.name==e)return!0;return!1}function M(e){var t=C.state;if(C.marked="def",c){if(t.context)if("var"==t.lexical.info&&t.context&&t.context.block){var r=A(e,t.context);if(null!=r)return void(t.context=r)}else if(!L(e,t.localVars))return void(t.localVars=new O(e,t.localVars));n.globalVars&&!L(e,t.globalVars)&&(t.globalVars=new O(e,t.globalVars))}}function A(e,t){if(t){if(t.block){var n=A(e,t.prev);return n?n==t.prev?t:new E(n,t.vars,!0):null}return L(e,t.vars)?t:new E(t.prev,new O(e,t.vars),!1)}return null}function N(e){return"public"==e||"private"==e||"protected"==e||"abstract"==e||"readonly"==e}function E(e,t,n){this.prev=e,this.vars=t,this.block=n}function O(e,t){this.name=e,this.next=t}var _=new O("this",new O("arguments",null));function z(){C.state.context=new E(C.state.context,C.state.localVars,!1),C.state.localVars=_}function P(){C.state.context=new E(C.state.context,C.state.localVars,!0),C.state.localVars=null}function D(){C.state.localVars=C.state.context.vars,C.state.context=C.state.context.prev}function I(e,t){var n=function(){var n=C.state,r=n.indented;if("stat"==n.lexical.type)r=n.lexical.indented;else for(var i=n.lexical;i&&")"==i.type&&i.align;i=i.prev)r=i.indented;n.lexical=new x(r,C.stream.column(),e,null,n.lexical,t)};return n.lex=!0,n}function W(){var e=C.state;e.lexical.prev&&(")"==e.lexical.type&&(e.indented=e.lexical.indented),e.lexical=e.lexical.prev)}function F(e){return function t(n){return n==e?T():";"==e||"}"==n||")"==n||"]"==n?S():T(t)}}function H(e,t){return"var"==e?T(I("vardef",t),xe,F(";"),W):"keyword a"==e?T(I("form"),q,H,W):"keyword b"==e?T(I("form"),H,W):"keyword d"==e?C.stream.match(/^\s*$/,!1)?T():T(I("stat"),K,F(";"),W):"debugger"==e?T(F(";")):"{"==e?T(I("}"),P,le,W,D):";"==e?T():"if"==e?("else"==C.state.lexical.info&&C.state.cc[C.state.cc.length-1]==W&&C.state.cc.pop()(),T(I("form"),q,H,W,Me)):"function"==e?T(Oe):"for"==e?T(I("form"),P,Ae,H,D,W):"class"==e||u&&"interface"==t?(C.marked="keyword",T(I("form","class"==e?e:t),Ie,W)):"variable"==e?u&&"declare"==t?(C.marked="keyword",T(H)):u&&("module"==t||"enum"==t||"type"==t)&&C.stream.match(/^\s*\w/,!1)?(C.marked="keyword","enum"==t?T($e):"type"==t?T(ze,F("operator"),fe,F(";")):T(I("form"),ke,F("{"),I("}"),le,W,W)):u&&"namespace"==t?(C.marked="keyword",T(I("form"),j,H,W)):u&&"abstract"==t?(C.marked="keyword",T(H)):T(I("stat"),ee):"switch"==e?T(I("form"),q,F("{"),I("}","switch"),P,le,W,W,D):"case"==e?T(j,F(":")):"default"==e?T(F(":")):"catch"==e?T(I("form"),z,R,H,W,D):"export"==e?T(I("stat"),Re,W):"import"==e?T(I("stat"),Be,W):"async"==e?T(H):"@"==t?T(j,H):S(I("stat"),j,F(";"),W)}function R(e){if("("==e)return T(Pe,F(")"))}function j(e,t){return U(e,t,!1)}function B(e,t){return U(e,t,!0)}function q(e){return"("!=e?S():T(I(")"),K,F(")"),W)}function U(e,t,n){if(C.state.fatArrowAt==C.stream.start){var r=n?Z:X;if("("==e)return T(z,I(")"),oe(Pe,")"),W,F("=>"),r,D);if("variable"==e)return S(z,ke,F("=>"),r,D)}var i=n?G:V;return w.hasOwnProperty(e)?T(i):"function"==e?T(Oe,i):"class"==e||u&&"interface"==t?(C.marked="keyword",T(I("form"),De,W)):"keyword c"==e||"async"==e?T(n?B:j):"("==e?T(I(")"),K,F(")"),W,i):"operator"==e||"spread"==e?T(n?B:j):"["==e?T(I("]"),Ge,W,i):"{"==e?ae(ne,"}",null,i):"quasi"==e?S($,i):"new"==e?T(function(e){return function(t){return"."==t?T(e?Q:J):"variable"==t&&u?T(ye,e?G:V):S(e?B:j)}}(n)):T()}function K(e){return e.match(/[;\}\)\],]/)?S():S(j)}function V(e,t){return","==e?T(K):G(e,t,!1)}function G(e,t,n){var r=0==n?V:G,i=0==n?j:B;return"=>"==e?T(z,n?Z:X,D):"operator"==e?/\+\+|--/.test(t)||u&&"!"==t?T(r):u&&"<"==t&&C.stream.match(/^([^<>]|<[^<>]*>)*>\s*\(/,!1)?T(I(">"),oe(fe,">"),W,r):"?"==t?T(j,F(":"),i):T(i):"quasi"==e?S($,r):";"!=e?"("==e?ae(B,")","call",r):"."==e?T(te,r):"["==e?T(I("]"),K,F("]"),W,r):u&&"as"==t?(C.marked="keyword",T(fe,r)):"regexp"==e?(C.state.lastType=C.marked="operator",C.stream.backUp(C.stream.pos-C.stream.start-1),T(i)):void 0:void 0}function $(e,t){return"quasi"!=e?S():"${"!=t.slice(t.length-2)?T($):T(j,Y)}function Y(e){if("}"==e)return C.marked="string-2",C.state.tokenize=y,T($)}function X(e){return b(C.stream,C.state),S("{"==e?H:j)}function Z(e){return b(C.stream,C.state),S("{"==e?H:B)}function J(e,t){if("target"==t)return C.marked="keyword",T(V)}function Q(e,t){if("target"==t)return C.marked="keyword",T(G)}function ee(e){return":"==e?T(W,H):S(V,F(";"),W)}function te(e){if("variable"==e)return C.marked="property",T()}function ne(e,t){return"async"==e?(C.marked="property",T(ne)):"variable"==e||"keyword"==C.style?(C.marked="property","get"==t||"set"==t?T(re):(u&&C.state.fatArrowAt==C.stream.start&&(n=C.stream.match(/^\s*:\s*/,!1))&&(C.state.fatArrowAt=C.stream.pos+n[0].length),T(ie))):"number"==e||"string"==e?(C.marked=l?"property":C.style+" property",T(ie)):"jsonld-keyword"==e?T(ie):u&&N(t)?(C.marked="keyword",T(ne)):"["==e?T(j,se,F("]"),ie):"spread"==e?T(B,ie):"*"==t?(C.marked="keyword",T(ne)):":"==e?S(ie):void 0;var n}function re(e){return"variable"!=e?S(ie):(C.marked="property",T(Oe))}function ie(e){return":"==e?T(B):"("==e?S(Oe):void 0}function oe(e,t,n){function r(i,o){if(n?n.indexOf(i)>-1:","==i){var a=C.state.lexical;return"call"==a.info&&(a.pos=(a.pos||0)+1),T((function(n,r){return n==t||r==t?S():S(e)}),r)}return i==t||o==t?T():n&&n.indexOf(";")>-1?S(e):T(F(t))}return function(n,i){return n==t||i==t?T():S(e,r)}}function ae(e,t,n){for(var r=3;r"),fe):void 0}function he(e){if("=>"==e)return T(fe)}function pe(e){return e.match(/[\}\)\]]/)?T():","==e||";"==e?T(pe):S(me,pe)}function me(e,t){return"variable"==e||"keyword"==C.style?(C.marked="property",T(me)):"?"==t||"number"==e||"string"==e?T(me):":"==e?T(fe):"["==e?T(F("variable"),ce,F("]"),me):"("==e?S(_e,me):e.match(/[;\}\)\],]/)?void 0:T()}function ge(e,t){return"variable"==e&&C.stream.match(/^\s*[?:]/,!1)||"?"==t?T(ge):":"==e?T(fe):"spread"==e?T(ge):S(fe)}function ve(e,t){return"<"==t?T(I(">"),oe(fe,">"),W,ve):"|"==t||"."==e||"&"==t?T(fe):"["==e?T(fe,F("]"),ve):"extends"==t||"implements"==t?(C.marked="keyword",T(fe)):"?"==t?T(fe,F(":"),fe):void 0}function ye(e,t){if("<"==t)return T(I(">"),oe(fe,">"),W,ve)}function be(){return S(fe,we)}function we(e,t){if("="==t)return T(fe)}function xe(e,t){return"enum"==t?(C.marked="keyword",T($e)):S(ke,se,Te,Le)}function ke(e,t){return u&&N(t)?(C.marked="keyword",T(ke)):"variable"==e?(M(t),T()):"spread"==e?T(ke):"["==e?ae(Se,"]"):"{"==e?ae(Ce,"}"):void 0}function Ce(e,t){return"variable"!=e||C.stream.match(/^\s*:/,!1)?("variable"==e&&(C.marked="property"),"spread"==e?T(ke):"}"==e?S():"["==e?T(j,F("]"),F(":"),Ce):T(F(":"),ke,Te)):(M(t),T(Te))}function Se(){return S(ke,Te)}function Te(e,t){if("="==t)return T(B)}function Le(e){if(","==e)return T(xe)}function Me(e,t){if("keyword b"==e&&"else"==t)return T(I("form","else"),H,W)}function Ae(e,t){return"await"==t?T(Ae):"("==e?T(I(")"),Ne,W):void 0}function Ne(e){return"var"==e?T(xe,Ee):"variable"==e?T(Ee):S(Ee)}function Ee(e,t){return")"==e?T():";"==e?T(Ee):"in"==t||"of"==t?(C.marked="keyword",T(j,Ee)):S(j,Ee)}function Oe(e,t){return"*"==t?(C.marked="keyword",T(Oe)):"variable"==e?(M(t),T(Oe)):"("==e?T(z,I(")"),oe(Pe,")"),W,ue,H,D):u&&"<"==t?T(I(">"),oe(be,">"),W,Oe):void 0}function _e(e,t){return"*"==t?(C.marked="keyword",T(_e)):"variable"==e?(M(t),T(_e)):"("==e?T(z,I(")"),oe(Pe,")"),W,ue,D):u&&"<"==t?T(I(">"),oe(be,">"),W,_e):void 0}function ze(e,t){return"keyword"==e||"variable"==e?(C.marked="type",T(ze)):"<"==t?T(I(">"),oe(be,">"),W):void 0}function Pe(e,t){return"@"==t&&T(j,Pe),"spread"==e?T(Pe):u&&N(t)?(C.marked="keyword",T(Pe)):u&&"this"==e?T(se,Te):S(ke,se,Te)}function De(e,t){return"variable"==e?Ie(e,t):We(e,t)}function Ie(e,t){if("variable"==e)return M(t),T(We)}function We(e,t){return"<"==t?T(I(">"),oe(be,">"),W,We):"extends"==t||"implements"==t||u&&","==e?("implements"==t&&(C.marked="keyword"),T(u?fe:j,We)):"{"==e?T(I("}"),Fe,W):void 0}function Fe(e,t){return"async"==e||"variable"==e&&("static"==t||"get"==t||"set"==t||u&&N(t))&&C.stream.match(/^\s+[\w$\xa1-\uffff]/,!1)?(C.marked="keyword",T(Fe)):"variable"==e||"keyword"==C.style?(C.marked="property",T(He,Fe)):"number"==e||"string"==e?T(He,Fe):"["==e?T(j,se,F("]"),He,Fe):"*"==t?(C.marked="keyword",T(Fe)):u&&"("==e?S(_e,Fe):";"==e||","==e?T(Fe):"}"==e?T():"@"==t?T(j,Fe):void 0}function He(e,t){if("?"==t)return T(He);if(":"==e)return T(fe,Te);if("="==t)return T(B);var n=C.state.lexical.prev;return S(n&&"interface"==n.info?_e:Oe)}function Re(e,t){return"*"==t?(C.marked="keyword",T(Ve,F(";"))):"default"==t?(C.marked="keyword",T(j,F(";"))):"{"==e?T(oe(je,"}"),Ve,F(";")):S(H)}function je(e,t){return"as"==t?(C.marked="keyword",T(F("variable"))):"variable"==e?S(B,je):void 0}function Be(e){return"string"==e?T():"("==e?S(j):"."==e?S(V):S(qe,Ue,Ve)}function qe(e,t){return"{"==e?ae(qe,"}"):("variable"==e&&M(t),"*"==t&&(C.marked="keyword"),T(Ke))}function Ue(e){if(","==e)return T(qe,Ue)}function Ke(e,t){if("as"==t)return C.marked="keyword",T(qe)}function Ve(e,t){if("from"==t)return C.marked="keyword",T(j)}function Ge(e){return"]"==e?T():S(oe(B,"]"))}function $e(){return S(I("form"),ke,F("{"),I("}"),oe(Ye,"}"),W,W)}function Ye(){return S(ke,Te)}function Xe(e,t,n){return t.tokenize==g&&/^(?:operator|sof|keyword [bcd]|case|new|export|default|spread|[\[{}\(,;:]|=>)$/.test(t.lastType)||"quasi"==t.lastType&&/\{\s*$/.test(e.string.slice(0,e.pos-(n||0)))}return D.lex=!0,W.lex=!0,{startState:function(e){var t={tokenize:g,lastType:"sof",cc:[],lexical:new x((e||0)-o,0,"block",!1),localVars:n.localVars,context:n.localVars&&new E(null,null,!1),indented:e||0};return n.globalVars&&"object"==typeof n.globalVars&&(t.globalVars=n.globalVars),t},token:function(e,t){if(e.sol()&&(t.lexical.hasOwnProperty("align")||(t.lexical.align=!1),t.indented=e.indentation(),b(e,t)),t.tokenize!=v&&e.eatSpace())return null;var n=t.tokenize(e,t);return"comment"==r?n:(t.lastType="operator"!=r||"++"!=i&&"--"!=i?r:"incdec",function(e,t,n,r,i){var o=e.cc;for(C.state=e,C.stream=i,C.marked=null,C.cc=o,C.style=t,e.lexical.hasOwnProperty("align")||(e.lexical.align=!0);;)if((o.length?o.pop():s?j:H)(n,r)){for(;o.length&&o[o.length-1].lex;)o.pop()();return C.marked?C.marked:"variable"==n&&k(e,r)?"variable-2":t}}(t,n,r,i,e))},indent:function(t,r){if(t.tokenize==v||t.tokenize==y)return e.Pass;if(t.tokenize!=g)return 0;var i,l=r&&r.charAt(0),s=t.lexical;if(!/^\s*else\b/.test(r))for(var c=t.cc.length-1;c>=0;--c){var u=t.cc[c];if(u==W)s=s.prev;else if(u!=Me&&u!=D)break}for(;("stat"==s.type||"form"==s.type)&&("}"==l||(i=t.cc[t.cc.length-1])&&(i==V||i==G)&&!/^[,\.=+\-*:?[\(]/.test(r));)s=s.prev;a&&")"==s.type&&"stat"==s.prev.type&&(s=s.prev);var d=s.type,f=l==d;return"vardef"==d?s.indented+("operator"==t.lastType||","==t.lastType?s.info.length+1:0):"form"==d&&"{"==l?s.indented:"form"==d?s.indented+o:"stat"==d?s.indented+(function(e,t){return"operator"==e.lastType||","==e.lastType||h.test(t.charAt(0))||/[,.]/.test(t.charAt(0))}(t,r)?a||o:0):"switch"!=s.info||f||0==n.doubleIndentSwitch?s.align?s.column+(f?0:1):s.indented+(f?0:o):s.indented+(/^(?:case|default)\b/.test(r)?o:2*o)},electricInput:/^\s*(?:case .*?:|default:|\{|\})$/,blockCommentStart:s?null:"/*",blockCommentEnd:s?null:"*/",blockCommentContinue:s?null:" * ",lineComment:s?null:"//",fold:"brace",closeBrackets:"()[]{}''\"\"``",helperType:s?"json":"javascript",jsonldMode:l,jsonMode:s,expressionAllowed:Xe,skipExpression:function(e){var t=e.cc[e.cc.length-1];t!=j&&t!=B||e.cc.pop()}}})),e.registerHelper("wordChars","javascript",/[\w$]/),e.defineMIME("text/javascript","javascript"),e.defineMIME("text/ecmascript","javascript"),e.defineMIME("application/javascript","javascript"),e.defineMIME("application/x-javascript","javascript"),e.defineMIME("application/ecmascript","javascript"),e.defineMIME("application/json",{name:"javascript",json:!0}),e.defineMIME("application/x-json",{name:"javascript",json:!0}),e.defineMIME("application/manifest+json",{name:"javascript",json:!0}),e.defineMIME("application/ld+json",{name:"javascript",jsonld:!0}),e.defineMIME("text/typescript",{name:"javascript",typescript:!0}),e.defineMIME("application/typescript",{name:"javascript",typescript:!0})}(n(4631))},9589:(e,t,n)=>{!function(e){"use strict";var t={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},n={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};e.defineMode("xml",(function(r,i){var o,a,l=r.indentUnit,s={},c=i.htmlMode?t:n;for(var u in c)s[u]=c[u];for(var u in i)s[u]=i[u];function d(e,t){function n(n){return t.tokenize=n,n(e,t)}var r=e.next();return"<"==r?e.eat("!")?e.eat("[")?e.match("CDATA[")?n(h("atom","]]>")):null:e.match("--")?n(h("comment","--\x3e")):e.match("DOCTYPE",!0,!0)?(e.eatWhile(/[\w\._\-]/),n(p(1))):null:e.eat("?")?(e.eatWhile(/[\w\._\-]/),t.tokenize=h("meta","?>"),"meta"):(o=e.eat("/")?"closeTag":"openTag",t.tokenize=f,"tag bracket"):"&"==r?(e.eat("#")?e.eat("x")?e.eatWhile(/[a-fA-F\d]/)&&e.eat(";"):e.eatWhile(/[\d]/)&&e.eat(";"):e.eatWhile(/[\w\.\-:]/)&&e.eat(";"))?"atom":"error":(e.eatWhile(/[^&<]/),null)}function f(e,t){var n,r,i=e.next();if(">"==i||"/"==i&&e.eat(">"))return t.tokenize=d,o=">"==i?"endTag":"selfcloseTag","tag bracket";if("="==i)return o="equals",null;if("<"==i){t.tokenize=d,t.state=y,t.tagName=t.tagStart=null;var a=t.tokenize(e,t);return a?a+" tag error":"tag error"}return/[\'\"]/.test(i)?(t.tokenize=(n=i,(r=function(e,t){for(;!e.eol();)if(e.next()==n){t.tokenize=f;break}return"string"}).isInAttribute=!0,r),t.stringStartCol=e.column(),t.tokenize(e,t)):(e.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function h(e,t){return function(n,r){for(;!n.eol();){if(n.match(t)){r.tokenize=d;break}n.next()}return e}}function p(e){return function(t,n){for(var r;null!=(r=t.next());){if("<"==r)return n.tokenize=p(e+1),n.tokenize(t,n);if(">"==r){if(1==e){n.tokenize=d;break}return n.tokenize=p(e-1),n.tokenize(t,n)}}return"meta"}}function m(e,t,n){this.prev=e.context,this.tagName=t||"",this.indent=e.indented,this.startOfLine=n,(s.doNotIndent.hasOwnProperty(t)||e.context&&e.context.noIndent)&&(this.noIndent=!0)}function g(e){e.context&&(e.context=e.context.prev)}function v(e,t){for(var n;;){if(!e.context)return;if(n=e.context.tagName,!s.contextGrabbers.hasOwnProperty(n)||!s.contextGrabbers[n].hasOwnProperty(t))return;g(e)}}function y(e,t,n){return"openTag"==e?(n.tagStart=t.column(),b):"closeTag"==e?w:y}function b(e,t,n){return"word"==e?(n.tagName=t.current(),a="tag",C):s.allowMissingTagName&&"endTag"==e?(a="tag bracket",C(e,0,n)):(a="error",b)}function w(e,t,n){if("word"==e){var r=t.current();return n.context&&n.context.tagName!=r&&s.implicitlyClosed.hasOwnProperty(n.context.tagName)&&g(n),n.context&&n.context.tagName==r||!1===s.matchClosing?(a="tag",x):(a="tag error",k)}return s.allowMissingTagName&&"endTag"==e?(a="tag bracket",x(e,0,n)):(a="error",k)}function x(e,t,n){return"endTag"!=e?(a="error",x):(g(n),y)}function k(e,t,n){return a="error",x(e,0,n)}function C(e,t,n){if("word"==e)return a="attribute",S;if("endTag"==e||"selfcloseTag"==e){var r=n.tagName,i=n.tagStart;return n.tagName=n.tagStart=null,"selfcloseTag"==e||s.autoSelfClosers.hasOwnProperty(r)?v(n,r):(v(n,r),n.context=new m(n,r,i==n.indented)),y}return a="error",C}function S(e,t,n){return"equals"==e?T:(s.allowMissing||(a="error"),C(e,0,n))}function T(e,t,n){return"string"==e?L:"word"==e&&s.allowUnquoted?(a="string",C):(a="error",C(e,0,n))}function L(e,t,n){return"string"==e?L:C(e,0,n)}return d.isInText=!0,{startState:function(e){var t={tokenize:d,state:y,indented:e||0,tagName:null,tagStart:null,context:null};return null!=e&&(t.baseIndent=e),t},token:function(e,t){if(!t.tagName&&e.sol()&&(t.indented=e.indentation()),e.eatSpace())return null;o=null;var n=t.tokenize(e,t);return(n||o)&&"comment"!=n&&(a=null,t.state=t.state(o||n,e,t),a&&(n="error"==a?n+" error":a)),n},indent:function(t,n,r){var i=t.context;if(t.tokenize.isInAttribute)return t.tagStart==t.indented?t.stringStartCol+1:t.indented+l;if(i&&i.noIndent)return e.Pass;if(t.tokenize!=f&&t.tokenize!=d)return r?r.match(/^(\s*)/)[0].length:0;if(t.tagName)return!1!==s.multilineTagIndentPastTag?t.tagStart+t.tagName.length+2:t.tagStart+l*(s.multilineTagIndentFactor||1);if(s.alignCDATA&&/$/,blockCommentStart:"\x3c!--",blockCommentEnd:"--\x3e",configuration:s.htmlMode?"html":"xml",helperType:s.htmlMode?"html":"xml",skipAttribute:function(e){e.state==T&&(e.state=C)},xmlCurrentTag:function(e){return e.tagName?{name:e.tagName,close:"closeTag"==e.type}:null},xmlCurrentContext:function(e){for(var t=[],n=e.context;n;n=n.prev)t.push(n.tagName);return t.reverse()}}})),e.defineMIME("text/xml","xml"),e.defineMIME("application/xml","xml"),e.mimeModes.hasOwnProperty("text/html")||e.defineMIME("text/html",{name:"xml",htmlMode:!0})}(n(4631))},7422:e=>{var t=/^(?:submit|button|image|reset|file)$/i,n=/^(?:input|select|textarea|keygen)/i,r=/(\[[^\[\]]*\])/g;function i(e,t,n){if(0===t.length)return n;var r=t.shift(),o=r.match(/^\[(.+?)\]$/);if("[]"===r)return e=e||[],Array.isArray(e)?e.push(i(null,t,n)):(e._values=e._values||[],e._values.push(i(null,t,n))),e;if(o){var a=o[1],l=+a;isNaN(l)?(e=e||{})[a]=i(e[a],t,n):(e=e||[])[l]=i(e[l],t,n)}else e[r]=i(e[r],t,n);return e}function o(e,t,n){if(t.match(r))i(e,function(e){var t=[],n=new RegExp(r),i=/^([^\[\]]*)/.exec(e);for(i[1]&&t.push(i[1]);null!==(i=n.exec(e));)t.push(i[1]);return t}(t),n);else{var o=e[t];o?(Array.isArray(o)||(e[t]=[o]),e[t].push(n)):e[t]=n}return e}function a(e,t,n){return n=n.replace(/(\r)?\n/g,"\r\n"),n=(n=encodeURIComponent(n)).replace(/%20/g,"+"),e+(e?"&":"")+encodeURIComponent(t)+"="+n}e.exports=function(e,r){"object"!=typeof r?r={hash:!!r}:void 0===r.hash&&(r.hash=!0);for(var i=r.hash?{}:"",l=r.serializer||(r.hash?o:a),s=e&&e.elements?e.elements:[],c=Object.create(null),u=0;u{e.exports={prettyPrint:function(e,t){var n,r,i,o,a,l;for(r=(t=t||{}).indent_size||4,i=t.indent_char||" ",a=t.brace_style||"collapse",o=0==t.max_char?1/0:t.max_char||70,l=t.unformatted||["a","span","bdo","em","strong","dfn","code","samp","kbd","var","cite","abbr","acronym","q","sub","sup","tt","i","b","big","small","u","s","strike","font","ins","del","pre","address","dt","h1","h2","h3","h4","h5","h6"],(n=new function(){return this.pos=0,this.token="",this.current_mode="CONTENT",this.tags={parent:"parent1",parentcount:1,parent1:""},this.tag_type="",this.token_text=this.last_token=this.last_text=this.token_type="",this.Utils={whitespace:"\n\r\t ".split(""),single_token:"br,input,link,meta,!doctype,basefont,base,area,hr,wbr,param,img,isindex,?xml,embed,?php,?,?=".split(","),extra_liners:"head,body,/html".split(","),in_array:function(e,t){for(var n=0;n=this.input.length)return t.length?t.join(""):["","TK_EOF"];if(e=this.input.charAt(this.pos),this.pos++,this.line_char_count++,this.Utils.in_array(e,this.Utils.whitespace))t.length&&(n=!0),this.line_char_count--;else{if(n){if(this.line_char_count>=this.max_char){t.push("\n");for(var r=0;r","igm");n.lastIndex=this.pos;var r=n.exec(this.input),i=r?r.index:this.input.length;return this.pos=this.input.length)return r.length?r.join(""):["","TK_EOF"];n=this.input.charAt(this.pos),this.pos++,this.line_char_count++,this.Utils.in_array(n,this.Utils.whitespace)?(i=!0,this.line_char_count--):("'"!==n&&'"'!==n||r[1]&&"!"===r[1]||(n+=this.get_unformatted(n),i=!0),"="===n&&(i=!1),r.length&&"="!==r[r.length-1]&&">"!==n&&i&&(this.line_char_count>=this.max_char?(this.print_newline(!1,r),this.line_char_count=0):(r.push(" "),this.line_char_count++),i=!1),"<"===n&&(e=this.pos-1),r.push(n))}while(">"!==n);var o,a=r.join("");o=-1!=a.indexOf(" ")?a.indexOf(" "):a.indexOf(">");var s=a.substring(1,o).toLowerCase();if("/"===a.charAt(a.length-2)||this.Utils.in_array(s,this.Utils.single_token))this.tag_type="SINGLE";else if("script"===s)this.record_tag(s),this.tag_type="SCRIPT";else if("style"===s)this.record_tag(s),this.tag_type="STYLE";else if(this.Utils.in_array(s,l)){var c=this.get_unformatted("",a);r.push(c),e>0&&this.Utils.in_array(this.input.charAt(e-1),this.Utils.whitespace)&&r.splice(0,0,this.input.charAt(e-1)),t=this.pos-1,this.Utils.in_array(this.input.charAt(t+1),this.Utils.whitespace)&&r.push(this.input.charAt(t+1)),this.tag_type="SINGLE"}else"!"===s.charAt(0)?-1!=s.indexOf("[if")?(-1!=a.indexOf("!IE")&&(c=this.get_unformatted("--\x3e",a),r.push(c)),this.tag_type="START"):-1!=s.indexOf("[endif")?(this.tag_type="END",this.unindent()):-1!=s.indexOf("[cdata[")?(c=this.get_unformatted("]]>",a),r.push(c),this.tag_type="SINGLE"):(c=this.get_unformatted("--\x3e",a),r.push(c),this.tag_type="SINGLE"):("/"===s.charAt(0)?(this.retrieve_tag(s.substring(1)),this.tag_type="END"):(this.record_tag(s),this.tag_type="START"),this.Utils.in_array(s,this.Utils.extra_liners)&&this.print_newline(!0,this.output));return r.join("")},this.get_unformatted=function(e,t){if(t&&-1!=t.toLowerCase().indexOf(e))return"";var n="",r="",i=!0;do{if(this.pos>=this.input.length)return r;if(n=this.input.charAt(this.pos),this.pos++,this.Utils.in_array(n,this.Utils.whitespace)){if(!i){this.line_char_count--;continue}if("\n"===n||"\r"===n){r+="\n",this.line_char_count=0;continue}}r+=n,this.line_char_count++,i=!0}while(-1==r.toLowerCase().indexOf(e));return r},this.get_token=function(){var e;if("TK_TAG_SCRIPT"===this.last_token||"TK_TAG_STYLE"===this.last_token){var t=this.last_token.substr(7);return"string"!=typeof(e=this.get_contents_to(t))?e:[e,"TK_"+t]}return"CONTENT"===this.current_mode?"string"!=typeof(e=this.get_content())?e:[e,"TK_CONTENT"]:"TAG"===this.current_mode?"string"!=typeof(e=this.get_tag())?e:[e,"TK_TAG_"+this.tag_type]:void 0},this.get_full_indent=function(e){return(e=this.indent_level+e||0)<1?"":Array(e+1).join(this.indent_string)},this.printer=function(e,t,n,r,i){this.input=e||"",this.output=[],this.indent_character=t,this.indent_string="",this.indent_size=n,this.brace_style=i,this.indent_level=0,this.max_char=r,this.line_char_count=0;for(var o=0;o0&&this.indent_level--}},this}).printer(e,i,r,o,a);;){var s=n.get_token();if(n.token_text=s[0],n.token_type=s[1],"TK_EOF"===n.token_type)break;switch(n.token_type){case"TK_TAG_START":n.print_newline(!1,n.output),n.print_token(n.token_text),n.indent(),n.current_mode="CONTENT";break;case"TK_TAG_STYLE":case"TK_TAG_SCRIPT":n.print_newline(!1,n.output),n.print_token(n.token_text),n.current_mode="CONTENT";break;case"TK_TAG_END":if("TK_CONTENT"===n.last_token&&""===n.last_text){var c=n.token_text.match(/\w+/)[0],u=n.output[n.output.length-1].match(/<\s*(\w+)/);null!==u&&u[1]===c||n.print_newline(!0,n.output)}n.print_token(n.token_text),n.current_mode="CONTENT";break;case"TK_TAG_SINGLE":var d=n.token_text.match(/^\s*<([a-z]+)/i);d&&n.Utils.in_array(d[1],l)||n.print_newline(!1,n.output),n.print_token(n.token_text),n.current_mode="CONTENT";break;case"TK_CONTENT":""!==n.token_text&&n.print_token(n.token_text),n.current_mode="TAG";break;case"TK_STYLE":case"TK_SCRIPT":if(""!==n.token_text){n.output.push("\n");var f=n.token_text;if("TK_SCRIPT"==n.token_type)var h="function"==typeof js_beautify&&js_beautify;else"TK_STYLE"==n.token_type&&(h="function"==typeof css_beautify&&css_beautify);if("keep"==t.indent_scripts)var p=0;else p="separate"==t.indent_scripts?-n.indent_level:1;var m=n.get_full_indent(p);if(h)f=h(f.replace(/^\s*/,m),t);else{var g=f.match(/^\s*/)[0].match(/[^\n\r]*$/)[0].split(n.indent_string).length-1,v=n.get_full_indent(p-g);f=f.replace(/^\s*/,m).replace(/\r\n|\r|\n/g,"\n"+v).replace(/\s*$/,"")}f&&(n.print_token(f),n.print_newline(!0,n.output))}n.current_mode="TAG"}n.last_token=n.token_type,n.last_text=n.token_text}return n.output.join("")}}},8018:(e,t,n)=>{"use strict";var r=n(8178);e.exports=function(e,t,n){var i=[],o=!1,a=!1;function l(){if(o)throw new Error("Nested m.redraw.sync() call");o=!0;for(var t=0;t=0&&(i.splice(o,2),e(t,[],s)),null!=n&&(i.push(t,n),e(t,r(n),s))},redraw:s}}},3223:(e,t,n)=>{"use strict";var r=n(8178),i=n(373),o=n(5164),a=n(249),l=n(8561),s=n(7562),c=n(1127),u={};e.exports=function(e,t){var n;function d(t,r,i){if(t=a(t,r),null!=n){n();var o=i?i.state:null,l=i?i.title:null;i&&i.replace?e.history.replaceState(o,l,y.prefix+t):e.history.pushState(o,l,y.prefix+t)}else e.location.href=y.prefix+t}var f,h,p,m,g=u,v=y.SKIP={};function y(i,a,b){if(null==i)throw new Error("Ensure the DOM element that was passed to `m.route` is not undefined");var w,x=0,k=Object.keys(b).map((function(e){if("/"!==e[0])throw new SyntaxError("Routes must start with a `/`");if(/:([^\/\.-]+)(\.{3})?:/.test(e))throw new SyntaxError("Route parameter names must be separated with either `/`, `.`, or `-`");return{route:e,component:b[e],check:s(e)}})),C="function"==typeof setImmediate?setImmediate:setTimeout,S=o.resolve(),T=!1;if(n=null,null!=a){var L=l(a);if(!k.some((function(e){return e.check(L)})))throw new ReferenceError("Default route doesn't match any known routes")}function M(){T=!1;var n=e.location.hash;"#"!==y.prefix[0]&&(n=e.location.search+n,"?"!==y.prefix[0]&&"/"!==(n=e.location.pathname+n)[0]&&(n="/"+n));var r=n.concat().replace(/(?:%[a-f89][a-f0-9])+/gim,decodeURIComponent).slice(y.prefix.length),i=l(r);function o(){if(r===a)throw new Error("Could not resolve default route "+a);d(a,null,{replace:!0})}c(i.params,e.history.state),function e(n){for(;n{"use strict";var r=n(373);r.trust=n(4742),r.fragment=n(9621),e.exports=r},865:(e,t,n)=>{"use strict";var r=n(1262),i=n(9074),o=n(9165),a=function(){return r.apply(this,arguments)};a.m=r,a.trust=r.trust,a.fragment=r.fragment,a.mount=o.mount,a.route=n(843),a.render=n(5358),a.redraw=o.redraw,a.request=i.request,a.jsonp=i.jsonp,a.parseQueryString=n(9874),a.buildQueryString=n(478),a.parsePathname=n(8561),a.buildPathname=n(249),a.vnode=n(8178),a.PromisePolyfill=n(2803),e.exports=a},9165:(e,t,n)=>{"use strict";var r=n(5358);e.exports=n(8018)(r,requestAnimationFrame,console)},1127:e=>{"use strict";e.exports=Object.assign||function(e,t){t&&Object.keys(t).forEach((function(n){e[n]=t[n]}))}},249:(e,t,n)=>{"use strict";var r=n(478),i=n(1127);e.exports=function(e,t){if(/:([^\/\.-]+)(\.{3})?:/.test(e))throw new SyntaxError("Template parameter names *must* be separated");if(null==t)return e;var n=e.indexOf("?"),o=e.indexOf("#"),a=o<0?e.length:o,l=n<0?a:n,s=e.slice(0,l),c={};i(c,t);var u=s.replace(/:([^\/\.-]+)(\.{3})?/g,(function(e,n,r){return delete c[n],null==t[n]?e:r?t[n]:encodeURIComponent(String(t[n]))})),d=u.indexOf("?"),f=u.indexOf("#"),h=f<0?u.length:f,p=d<0?h:d,m=u.slice(0,p);n>=0&&(m+=e.slice(n,a)),d>=0&&(m+=(n<0?"?":"&")+u.slice(d,h));var g=r(c);return g&&(m+=(n<0&&d<0?"?":"&")+g),o>=0&&(m+=e.slice(o)),f>=0&&(m+=(o<0?"":"&")+u.slice(f)),m}},7562:(e,t,n)=>{"use strict";var r=n(8561);e.exports=function(e){var t=r(e),n=Object.keys(t.params),i=[],o=new RegExp("^"+t.path.replace(/:([^\/.-]+)(\.{3}|\.(?!\.)|-)?|[\\^$*+.()|\[\]{}]/g,(function(e,t,n){return null==t?"\\"+e:(i.push({k:t,r:"..."===n}),"..."===n?"(.*)":"."===n?"([^/]+)\\.":"([^/]+)"+(n||""))}))+"$");return function(e){for(var r=0;r{"use strict";var r=n(9874);e.exports=function(e){var t=e.indexOf("?"),n=e.indexOf("#"),i=n<0?e.length:n,o=t<0?i:t,a=e.slice(0,o).replace(/\/{2,}/g,"/");return a?("/"!==a[0]&&(a="/"+a),a.length>1&&"/"===a[a.length-1]&&(a=a.slice(0,-1))):a="/",{path:a,params:t<0?{}:r(e.slice(t+1,i))}}},2803:e=>{"use strict";var t=function(e){if(!(this instanceof t))throw new Error("Promise must be called with `new`");if("function"!=typeof e)throw new TypeError("executor must be a function");var n=this,r=[],i=[],o=c(r,!0),a=c(i,!1),l=n._instance={resolvers:r,rejectors:i},s="function"==typeof setImmediate?setImmediate:setTimeout;function c(e,t){return function o(c){var d;try{if(!t||null==c||"object"!=typeof c&&"function"!=typeof c||"function"!=typeof(d=c.then))s((function(){t||0!==e.length||console.error("Possible unhandled promise rejection:",c);for(var n=0;n0||e(n)}}var r=n(a);try{e(n(o),r)}catch(e){r(e)}}u(e)};t.prototype.then=function(e,n){var r,i,o=this._instance;function a(e,t,n,a){t.push((function(t){if("function"!=typeof e)n(t);else try{r(e(t))}catch(e){i&&i(e)}})),"function"==typeof o.retry&&a===o.state&&o.retry()}var l=new t((function(e,t){r=e,i=t}));return a(e,o.resolvers,r,!0),a(n,o.rejectors,i,!1),l},t.prototype.catch=function(e){return this.then(null,e)},t.prototype.finally=function(e){return this.then((function(n){return t.resolve(e()).then((function(){return n}))}),(function(n){return t.resolve(e()).then((function(){return t.reject(n)}))}))},t.resolve=function(e){return e instanceof t?e:new t((function(t){t(e)}))},t.reject=function(e){return new t((function(t,n){n(e)}))},t.all=function(e){return new t((function(t,n){var r=e.length,i=0,o=[];if(0===e.length)t([]);else for(var a=0;a{"use strict";var r=n(2803);"undefined"!=typeof window?(void 0===window.Promise?window.Promise=r:window.Promise.prototype.finally||(window.Promise.prototype.finally=r.prototype.finally),e.exports=window.Promise):void 0!==n.g?(void 0===n.g.Promise?n.g.Promise=r:n.g.Promise.prototype.finally||(n.g.Promise.prototype.finally=r.prototype.finally),e.exports=n.g.Promise):e.exports=r},478:e=>{"use strict";e.exports=function(e){if("[object Object]"!==Object.prototype.toString.call(e))return"";var t=[];for(var n in e)r(n,e[n]);return t.join("&");function r(e,n){if(Array.isArray(n))for(var i=0;i{"use strict";e.exports=function(e){if(""===e||null==e)return{};"?"===e.charAt(0)&&(e=e.slice(1));for(var t=e.split("&"),n={},r={},i=0;i-1&&s.pop();for(var u=0;u{"use strict";e.exports=n(5452)(window)},9621:(e,t,n)=>{"use strict";var r=n(8178),i=n(1359);e.exports=function(){var e=i.apply(0,arguments);return e.tag="[",e.children=r.normalizeChildren(e.children),e}},373:(e,t,n)=>{"use strict";var r=n(8178),i=n(1359),o=/(?:(^|#|\.)([^#\.\[\]]+))|(\[(.+?)(?:\s*=\s*("|'|)((?:\\["'\]]|.)*?)\5)?\])/g,a={},l={}.hasOwnProperty;function s(e){for(var t in e)if(l.call(e,t))return!1;return!0}function c(e){for(var t,n="div",r=[],i={};t=o.exec(e);){var l=t[1],s=t[2];if(""===l&&""!==s)n=s;else if("#"===l)i.id=s;else if("."===l)r.push(s);else if("["===t[3][0]){var c=t[6];c&&(c=c.replace(/\\(["'])/g,"$1").replace(/\\\\/g,"\\")),"class"===t[4]?r.push(c):i[t[4]]=""===c?c:c||!0}}return r.length>0&&(i.className=r.join(" ")),a[e]={tag:n,attrs:i}}function u(e,t){var n=t.attrs,i=r.normalizeChildren(t.children),o=l.call(n,"class"),a=o?n.class:n.className;if(t.tag=e.tag,t.attrs=null,t.children=void 0,!s(e.attrs)&&!s(n)){var c={};for(var u in n)l.call(n,u)&&(c[u]=n[u]);n=c}for(var u in e.attrs)l.call(e.attrs,u)&&"className"!==u&&!l.call(n,u)&&(n[u]=e.attrs[u]);for(var u in null==a&&null==e.attrs.className||(n.className=null!=a?null!=e.attrs.className?String(e.attrs.className)+" "+String(a):a:null!=e.attrs.className?e.attrs.className:null),o&&(n.class=null),n)if(l.call(n,u)&&"key"!==u){t.attrs=n;break}return Array.isArray(i)&&1===i.length&&null!=i[0]&&"#"===i[0].tag?t.text=i[0].children:t.children=i,t}e.exports=function(e){if(null==e||"string"!=typeof e&&"function"!=typeof e&&"function"!=typeof e.view)throw Error("The selector must be either a string or a component.");var t=i.apply(1,arguments);return"string"==typeof e&&(t.children=r.normalizeChildren(t.children),"["!==e)?u(a[e]||c(e),t):(t.tag=e,t)}},1359:(e,t,n)=>{"use strict";var r=n(8178);e.exports=function(){var e,t=arguments[this],n=this+1;if(null==t?t={}:("object"!=typeof t||null!=t.tag||Array.isArray(t))&&(t={},n=this),arguments.length===n+1)e=arguments[n],Array.isArray(e)||(e=[e]);else for(e=[];n{"use strict";var r=n(8178);e.exports=function(e){var t,n=e&&e.document,i={svg:"http://www.w3.org/2000/svg",math:"http://www.w3.org/1998/Math/MathML"};function o(e){return e.attrs&&e.attrs.xmlns||i[e.tag]}function a(e,t){if(e.state!==t)throw new Error("`vnode.state` must not be modified")}function l(e){var t=e.state;try{return this.apply(t,arguments)}finally{a(e,t)}}function s(){try{return n.activeElement}catch(e){return null}}function c(e,t,n,r,i,o,a){for(var l=n;l'+t.children+"",a=a.firstChild):a.innerHTML=t.children,t.dom=a.firstChild,t.domSize=a.childNodes.length,t.instance=[];for(var l,s=n.createDocumentFragment();l=a.firstChild;)t.instance.push(l),s.appendChild(l);w(e,s,i)}function h(e,t,n,r,i,o){if(t!==n&&(null!=t||null!=n))if(null==t||0===t.length)c(e,n,0,n.length,r,i,o);else if(null==n||0===n.length)k(e,t,0,t.length);else{var a=null!=t[0]&&null!=t[0].key,l=null!=n[0]&&null!=n[0].key,s=0,d=0;if(!a)for(;d=d&&T>=s&&(b=t[S],w=n[T],b.key===w.key);)b!==w&&p(e,b,w,r,i,o),null!=w.dom&&(i=w.dom),S--,T--;for(;S>=d&&T>=s&&(f=t[d],h=n[s],f.key===h.key);)d++,s++,f!==h&&p(e,f,h,r,v(t,d,i),o);for(;S>=d&&T>=s&&s!==T&&f.key===w.key&&b.key===h.key;)y(e,b,x=v(t,d,i)),b!==h&&p(e,b,h,r,x,o),++s<=--T&&y(e,f,i),f!==w&&p(e,f,w,r,i,o),null!=w.dom&&(i=w.dom),d++,b=t[--S],w=n[T],f=t[d],h=n[s];for(;S>=d&&T>=s&&b.key===w.key;)b!==w&&p(e,b,w,r,i,o),null!=w.dom&&(i=w.dom),T--,b=t[--S],w=n[T];if(s>T)k(e,t,d,S+1);else if(d>S)c(e,n,s,T+1,r,i,o);else{var L,M,A=i,N=T-s+1,E=new Array(N),O=0,_=0,z=2147483647,P=0;for(_=0;_=s;_--){null==L&&(L=m(t,d,S+1));var D=L[(w=n[_]).key];null!=D&&(z=D>>1)+(r>>>1)+(n&r&1);e[t[l]]0&&(g[i]=t[n-1]),t[n]=i)}}for(r=t[(n=t.length)-1];n-- >0;)t[n]=r,r=g[r];return g.length=0,t}(E)).length-1,_=T;_>=s;_--)h=n[_],-1===E[_-s]?u(e,h,r,o,i):M[O]===_-s?O--:y(e,h,i),null!=h.dom&&(i=n[_].dom);else for(_=T;_>=s;_--)h=n[_],-1===E[_-s]&&u(e,h,r,o,i),null!=h.dom&&(i=n[_].dom)}}else{var I=t.lengthI&&k(e,t,s,t.length),n.length>I&&c(e,n,s,n.length,r,i,o)}}}function p(e,t,n,i,a,s){var c=t.tag;if(c===n.tag){if(n.state=t.state,n.events=t.events,function(e,t){do{var n;if(null!=e.attrs&&"function"==typeof e.attrs.onbeforeupdate&&void 0!==(n=l.call(e.attrs.onbeforeupdate,e,t))&&!n)break;if("string"!=typeof e.tag&&"function"==typeof e.state.onbeforeupdate&&void 0!==(n=l.call(e.state.onbeforeupdate,e,t))&&!n)break;return!1}while(0);return e.dom=t.dom,e.domSize=t.domSize,e.instance=t.instance,e.attrs=t.attrs,e.children=t.children,e.text=t.text,!0}(n,t))return;if("string"==typeof c)switch(null!=n.attrs&&F(n.attrs,n,i),c){case"#":!function(e,t){e.children.toString()!==t.children.toString()&&(e.dom.nodeValue=t.children),t.dom=e.dom}(t,n);break;case"<":!function(e,t,n,r,i){t.children!==n.children?(S(e,t),f(e,n,r,i)):(n.dom=t.dom,n.domSize=t.domSize,n.instance=t.instance)}(e,t,n,s,a);break;case"[":!function(e,t,n,r,i,o){h(e,t.children,n.children,r,i,o);var a=0,l=n.children;if(n.dom=null,null!=l){for(var s=0;s-1||null!=e.attrs&&e.attrs.is||"href"!==t&&"list"!==t&&"form"!==t&&"width"!==t&&"height"!==t)&&t in e.dom}var O=/[A-Z]/g;function _(e){return"-"+e.toLowerCase()}function z(e){return"-"===e[0]&&"-"===e[1]?e:"cssFloat"===e?"float":e.replace(O,_)}function P(e,t,n){if(t===n);else if(null==n)e.style.cssText="";else if("object"!=typeof n)e.style.cssText=n;else if(null==t||"object"!=typeof t)for(var r in e.style.cssText="",n)null!=(i=n[r])&&e.style.setProperty(z(r),String(i));else{for(var r in n){var i;null!=(i=n[r])&&(i=String(i))!==String(t[r])&&e.style.setProperty(z(r),i)}for(var r in t)null!=t[r]&&null==n[r]&&e.style.removeProperty(z(r))}}function D(){this._=t}function I(e,t,n){if(null!=e.events){if(e.events[t]===n)return;null==n||"function"!=typeof n&&"object"!=typeof n?(null!=e.events[t]&&e.dom.removeEventListener(t.slice(2),e.events,!1),e.events[t]=void 0):(null==e.events[t]&&e.dom.addEventListener(t.slice(2),e.events,!1),e.events[t]=n)}else null==n||"function"!=typeof n&&"object"!=typeof n||(e.events=new D,e.dom.addEventListener(t.slice(2),e.events,!1),e.events[t]=n)}function W(e,t,n){"function"==typeof e.oninit&&l.call(e.oninit,t),"function"==typeof e.oncreate&&n.push(l.bind(e.oncreate,t))}function F(e,t,n){"function"==typeof e.onupdate&&n.push(l.bind(e.onupdate,t))}return D.prototype=Object.create(null),D.prototype.handleEvent=function(e){var t,n=this["on"+e.type];"function"==typeof n?t=n.call(e.currentTarget,e):"function"==typeof n.handleEvent&&n.handleEvent(e),this._&&!1!==e.redraw&&(0,this._)(),!1===t&&(e.preventDefault(),e.stopPropagation())},function(e,n,i){if(!e)throw new TypeError("Ensure the DOM element being passed to m.route/m.mount/m.render is not undefined.");var o=[],a=s(),l=e.namespaceURI;null==e.vnodes&&(e.textContent=""),n=r.normalizeChildren(Array.isArray(n)?n:[n]);var c=t;try{t="function"==typeof i?i:void 0,h(e,e.vnodes,n,o,null,"http://www.w3.org/1999/xhtml"===l?void 0:l)}finally{t=c}e.vnodes=n,null!=a&&s()!==a&&"function"==typeof a.focus&&a.focus();for(var u=0;u{"use strict";var r=n(8178);e.exports=function(e){return null==e&&(e=""),r("<",void 0,void 0,e,void 0,void 0)}},8178:e=>{"use strict";function t(e,t,n,r,i,o){return{tag:e,key:t,attrs:n,children:r,text:i,dom:o,domSize:void 0,state:void 0,events:void 0,instance:void 0}}t.normalize=function(e){return Array.isArray(e)?t("[",void 0,void 0,t.normalizeChildren(e),void 0,void 0):null==e||"boolean"==typeof e?null:"object"==typeof e?e:t("#",void 0,void 0,String(e),void 0,void 0)},t.normalizeChildren=function(e){var n=[];if(e.length){for(var r=null!=e[0]&&null!=e[0].key,i=1;i{"use strict";var r=n(5164),i=n(9165);e.exports=n(2775)(window,r,i.redraw)},2775:(e,t,n)=>{"use strict";var r=n(249);e.exports=function(e,t,n){var i=0;function o(e){return new t(e)}function a(e){return function(i,a){"string"!=typeof i?(a=i,i=i.url):null==a&&(a={});var l=new t((function(t,n){e(r(i,a.params),a,(function(e){if("function"==typeof a.type)if(Array.isArray(e))for(var n=0;n=200&&e.target.status<300||304===e.target.status||/^file:\/\//i.test(t),l=e.target.response;if("json"===u?e.target.responseType||"function"==typeof n.extract||(l=JSON.parse(e.target.responseText)):u&&"text"!==u||null==l&&(l=e.target.responseText),"function"==typeof n.extract?(l=n.extract(e.target,n),a=!0):"function"==typeof n.deserialize&&(l=n.deserialize(l)),a)r(l);else{try{o=e.target.responseText}catch(e){o=l}var s=new Error(o);s.code=e.target.status,s.response=l,i(s)}}catch(e){i(e)}},"function"==typeof n.config&&(d=n.config(d,n,t)||d)!==h&&(o=d.abort,d.abort=function(){f=!0,o.call(this)}),null==s?d.send():"function"==typeof n.serialize?d.send(n.serialize(s)):s instanceof e.FormData?d.send(s):d.send(JSON.stringify(s))})),jsonp:a((function(t,n,r,o){var a=n.callbackName||"_mithril_"+Math.round(1e16*Math.random())+"_"+i++,l=e.document.createElement("script");e[a]=function(t){delete e[a],l.parentNode.removeChild(l),r(t)},l.onerror=function(){delete e[a],l.parentNode.removeChild(l),o(new Error("JSONP request failed"))},l.src=t+(t.indexOf("?")<0?"?":"&")+encodeURIComponent(n.callbackKey||"callback")+"="+encodeURIComponent(a),e.document.documentElement.appendChild(l)}))}}},843:(e,t,n)=>{"use strict";var r=n(9165);e.exports=n(3223)(window,r)},3409:e=>{e.exports&&(e.exports=function e(t,n,r){for(var i in n)if(n.hasOwnProperty(i)){var o=i,a=n[i];if(void 0===a&&(a=""),null===a&&(a=""),void 0!==r&&(o=r+"["+i+"]"),a.constructor===Array)o+="[]";else if("object"==typeof a){e(t,a,o);continue}var l=t.elements.namedItem(o);if(l)switch(l.type||l[0].type){default:l.value=a;break;case"radio":case"checkbox":for(var s=a.constructor===Array?a:[a],c=0;c-1;break;case"select-multiple":s=a.constructor===Array?a:[a];for(var u=0;u-1;break;case"select":case"select-one":l.value=a.toString()||a;break;case"date":l.value=new Date(a).toISOString().split("T")[0]}}})},3951:e=>{function t(e){document.addEventListener("mouseover",(function(n){var r=n.target,i=e(r);i||(i=(r=r.parentElement)&&e(r)),i&&t.show(r,i,!0)}))}t.show=function(e,n,r){var i="data-tlite";n=n||{},(e.tooltip||function(e,n){var o,a,l;function s(){t.hide(e,!0)}function c(){o||(o=function(e,t,n){var r=document.createElement("span"),i=n.grav||e.getAttribute("data-tlite")||"n";r.innerHTML=t,e.appendChild(r);var o=i[0]||"",a=i[1]||"";function l(){r.className="tlite tlite-"+o+a;var t=e.offsetTop,n=e.offsetLeft;r.offsetParent===e&&(t=n=0);var i=e.offsetWidth,l=e.offsetHeight,s=r.offsetHeight,c=r.offsetWidth,u=n+i/2;r.style.top=("s"===o?t-s-10:"n"===o?t+l+10:t+l/2-s/2)+"px",r.style.left=("w"===a?n:"e"===a?n+i-c:"w"===o?n+i+10:"e"===o?n-c-10:u-c/2)+"px"}l();var s=r.getBoundingClientRect();return"s"===o&&s.top<0?(o="n",l()):"n"===o&&s.bottom>window.innerHeight?(o="s",l()):"e"===o&&s.left<0?(o="w",l()):"w"===o&&s.right>window.innerWidth&&(o="e",l()),r.className+=" tlite-visible",r}(e,l,n))}return e.addEventListener("mousedown",s),e.addEventListener("mouseleave",s),e.tooltip={show:function(){l=e.title||e.getAttribute(i)||l,e.title="",e.setAttribute(i,""),l&&!a&&(a=setTimeout(c,r?150:1))},hide:function(e){if(r===e){a=clearTimeout(a);var t=o&&o.parentNode;t&&t.removeChild(o),o=void 0}}}}(e,n)).show()},t.hide=function(e,t){e.tooltip&&e.tooltip.hide(t)},e.exports&&(e.exports=t)}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var o=t[r]={exports:{}};return e[r].call(o.exports,o,o.exports,n),o.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n(851),n(786),n(7661),n(5750),n(8521),n(8693),n(6315)})();/** * editor.js * Version : 2.0.0 * Author : inc2734 * Created : September 23, 2014 * Modified : July 11, 2018 * License : GPLv2 or later * License URI: http://www.gnu.org/licenses/gpl-2.0.html */ jQuery( function( $ ) { $( '.smart-cf-meta-box' ).each( function( i, e ) { var wrapper = $( e ); var btn_add_repeat_group = wrapper.find( '.btn-add-repeat-group' ); var btn_remove_repeat_group = wrapper.find( '.btn-remove-repeat-group' ); var table_class = '.smart-cf-meta-box-table'; var cnt = wrapper.find( table_class ).length; /** * グループ追加���タン */ btn_add_repeat_group.click( function( e ) { cnt ++; var parent = $( this ).parents( '.smart-cf-meta-box-repeat-tables' ); add_repeat_group( $( this ) ); } ); /** * グループ削除ボタン */ btn_remove_repeat_group.click( function() { var table = $( this ).parents( table_class ); table.fadeOut( 'fast', function() { $( this ).remove(); } ); var tables = $( this ).parents( '.smart-cf-meta-box-repeat-tables' ); if ( tables.find( table_class ).length === 2 ) { cnt ++; add_repeat_group( $( this ) ); } } ); function add_repeat_group( button ) { var tables = button.parents( '.smart-cf-meta-box-repeat-tables' ); var table = tables.find( table_class ).first(); var clone = table.clone( true, true ).hide(); clone.find( 'input, select, textarea' ).each( function( i, e ) { var name = $( this ).attr( 'name' ); if ( name ) { $( this ).attr( 'name', name.replace( /^(smart-custom-fields\[.+?\])\[\]/, '$1[' + cnt + ']' ) ); $( this ).removeAttr( 'disabled' ); } } ); clone.find( '.smart-cf-datetime_picker' ).addClass( 'add' ); button.parent().after( clone.fadeIn( 'fast' ) ); button.trigger( 'smart-cf-after-add-group', { button: button, clone: clone} ); } /** * 画像アップローダー */ wrapper.find( '.btn-add-image' ).click( function( e ) { e.preventDefault(); var custom_uploader_image; var upload_button = $( this ); if ( custom_uploader_image ) { custom_uploader_image.open(); return; } wp.media.view.Modal.prototype.on( 'ready', function(){ $( 'select.attachment-filters' ) .find( '[value="uploaded"]' ) .attr( 'selected', true ) .parent() .trigger( 'change' ); } ); custom_uploader_image = wp.media( { button : { text: smart_cf_uploader.image_uploader_title }, states: [ new wp.media.controller.Library({ title : smart_cf_uploader.image_uploader_title, library : wp.media.query( { type: 'image' } ), multiple : false, filterable: 'uploaded' }) ] } ); custom_uploader_image.on( 'select', function() { var images = custom_uploader_image.state().get( 'selection' ); images.each( function( file ){ var sizes = file.get('sizes'); var image_area = upload_button.parent().find( '.smart-cf-upload-image' ); var sizename = image_area.data('size'); var img = sizes[ sizename ] || sizes.full; var alt_attr = file.get('title'); image_area.find( 'img' ).remove(); image_area.prepend( '' + alt_attr + '' ); image_area.removeClass( 'hide' ); upload_button.parent().find( 'input[type="hidden"]' ).val( file.toJSON().id ); } ); } ); custom_uploader_image.open(); } ); /** * 画像削除ボタン */ wrapper.find( '.smart-cf-upload-image' ).hover( function() { $( this ).find( '.btn-remove-image' ).fadeIn( 'fast', function() { $( this ).removeClass( 'hide' ); } ); }, function() { $( this ).find( '.btn-remove-image' ).fadeOut( 'fast', function() { $( this ).addClass( 'hide' ); } ); } ); wrapper.find( '.btn-remove-image' ).click( function() { $( this ).parent().find( 'img' ).remove(); $( this ).parent().siblings( 'input[type="hidden"]' ).val( '' ); $( this ).parent().addClass( 'hide' ); } ); /** * ファイルアップローダー */ wrapper.find( '.btn-add-file' ).click( function( e ) { e.preventDefault(); var custom_uploader_file; var upload_button = $( this ); if ( custom_uploader_file ) { custom_uploader_file.open(); return; } custom_uploader_file = wp.media( { title : smart_cf_uploader.file_uploader_title, button: { text: smart_cf_uploader.file_uploader_title }, multiple: false } ); custom_uploader_file.on( 'select', function() { var images = custom_uploader_file.state().get( 'selection' ); images.each( function( file ){ var image_area = upload_button.parent().find( '.smart-cf-upload-file' ); var alt_attr = file.get('title'); image_area.find( 'a' ).remove(); image_area.prepend( '' + alt_attr + '' + file.toJSON().filename + '' ); image_area.removeClass( 'hide' ); upload_button.parent().find( 'input[type="hidden"]' ).val( file.toJSON().id ); } ); } ); custom_uploader_file.open(); } ); /** * ファイル削除ボタン */ wrapper.find( '.smart-cf-upload-file' ).hover( function() { $( this ).find( '.btn-remove-file' ).fadeIn( 'fast', function() { $( this ).removeClass( 'hide' ); } ); }, function() { $( this ).find( '.btn-remove-file' ).fadeOut( 'fast', function() { $( this ).addClass( 'hide' ); } ); } ); wrapper.find( '.btn-remove-file' ).click( function() { $( this ).parent().find( 'img' ).remove(); $( this ).parent().siblings( 'input[type="hidden"]' ).val( '' ); $( this ).parent().addClass( 'hide' ); } ); /** * sortable */ wrapper.find( '.smart-cf-meta-box-repeat-tables' ).sortable( { handle: '.smart-cf-icon-handle', items : '> .smart-cf-meta-box-table:not( :first-child )', start : function( e, ui ) { $( this ).trigger( 'smart-cf-repeat-table-sortable-start', ui.item ); }, stop : function( e, ui ) { $( this ).trigger( 'smart-cf-repeat-table-sortable-stop', ui.item ); }, } ); } ); } ); Page not found – International Woodwind