diff --git a/components/wifi-manager/webapp/dist/dist/js/index.d10a43.bundle.d.ts b/components/wifi-manager/webapp/dist/dist/js/index.4135c4.bundle.d.ts similarity index 100% rename from components/wifi-manager/webapp/dist/dist/js/index.d10a43.bundle.d.ts rename to components/wifi-manager/webapp/dist/dist/js/index.4135c4.bundle.d.ts diff --git a/components/wifi-manager/webapp/dist/dist/js/node_vendors.d10a43.bundle.d.ts b/components/wifi-manager/webapp/dist/dist/js/node_vendors.4135c4.bundle.d.ts similarity index 100% rename from components/wifi-manager/webapp/dist/dist/js/node_vendors.d10a43.bundle.d.ts rename to components/wifi-manager/webapp/dist/dist/js/node_vendors.4135c4.bundle.d.ts diff --git a/components/wifi-manager/webapp/dist/index.html b/components/wifi-manager/webapp/dist/index.html index fbd4fe4d4..6c1301e39 100644 --- a/components/wifi-manager/webapp/dist/index.html +++ b/components/wifi-manager/webapp/dist/index.html @@ -1 +1 @@ -
Software Updates
VersionDate/TimePlatformBranchBit Depth
Local Firmware Upload
KeyValue
WiFi Status
Logs
TimestampMessage
Tasks
#Task NameCPUStateMin StackBase PriorityCur Priority
Credits

squeezelite-esp32
© 2020, philippe44, sle118, daduke
This software is released under the MIT License.

This app would not be possible without the following libraries:

  • squeezelite, © 2012-2019, Adrian Smith and Ralph Irving. Licensed under the GPL License.
  • esp32-wifi-manager, © 2017-2019, Tony Pottier. Licensed under the MIT License.
  • SpinKit, © 2015, Tobias Ahlin. Licensed under the MIT License.
  • jQuery, The jQuery Foundation. Licensed under the MIT License.
  • cJSON, © 2009-2017, Dave Gamble and cJSON contributors. Licensed under the MIT License.
  • esp32-rotary-encoder, © 2011-2019, David Antliff and Ben Buxton. Licensed under the GPL License.
  • tarablessd1306, © 2017-2018, Tara Keeling. Licensed under the MIT license.
  • CSpot, © 2020 feelfreelinux & alufers. Licensed under the GPL License
Extras/Overrides
\ No newline at end of file +
Software Updates
VersionDate/TimePlatformBranchBit Depth
Local Firmware Upload
KeyValue
WiFi Status
Logs
TimestampMessage
Tasks
#Task NameCPUStateMin StackBase PriorityCur Priority
Credits

squeezelite-esp32
© 2020, philippe44, sle118, daduke
This software is released under the MIT License.

This app would not be possible without the following libraries:

  • squeezelite, © 2012-2019, Adrian Smith and Ralph Irving. Licensed under the GPL License.
  • esp32-wifi-manager, © 2017-2019, Tony Pottier. Licensed under the MIT License.
  • SpinKit, © 2015, Tobias Ahlin. Licensed under the MIT License.
  • jQuery, The jQuery Foundation. Licensed under the MIT License.
  • cJSON, © 2009-2017, Dave Gamble and cJSON contributors. Licensed under the MIT License.
  • esp32-rotary-encoder, © 2011-2019, David Antliff and Ben Buxton. Licensed under the GPL License.
  • tarablessd1306, © 2017-2018, Tara Keeling. Licensed under the MIT license.
  • CSpot, © 2020 feelfreelinux & alufers. Licensed under the GPL License
Extras/Overrides
\ No newline at end of file diff --git a/components/wifi-manager/webapp/dist/index.html.gz b/components/wifi-manager/webapp/dist/index.html.gz index f4cc2d1be..b3c461d54 100644 Binary files a/components/wifi-manager/webapp/dist/index.html.gz and b/components/wifi-manager/webapp/dist/index.html.gz differ diff --git a/components/wifi-manager/webapp/dist/js/index.4135c4.bundle.js b/components/wifi-manager/webapp/dist/js/index.1d06b9.bundle.js similarity index 58% rename from components/wifi-manager/webapp/dist/js/index.4135c4.bundle.js rename to components/wifi-manager/webapp/dist/js/index.1d06b9.bundle.js index f2969beeb..a8befcafe 100644 --- a/components/wifi-manager/webapp/dist/js/index.4135c4.bundle.js +++ b/components/wifi-manager/webapp/dist/js/index.1d06b9.bundle.js @@ -1,2 +1,2 @@ -(()=>{"use strict";var t,e={322:(t,e,n)=>{n.r(e);var a=n(531),s=n(152),o=n(687),i=n.n(o),c=n(955),r=n(755);function l(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(!t)return;if("string"==typeof t)return u(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);"Object"===n&&t.constructor&&(n=t.constructor.name);if("Map"===n||"Set"===n)return Array.from(t);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return u(t,e)}(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var a=0,s=function(){};return{s,n:function(){return a>=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function(t){throw t},f:s}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,c=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return i=t.done,t},e:function(t){c=!0,o=t},f:function(){try{i||null==n.return||n.return()}finally{if(c)throw o}}}}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,a=new Array(e);n")}}),Object.assign(Date.prototype,{toLocalShort:function(){return this.toLocaleString(void 0,{dateStyle:"short",timeStyle:"short"})}});var v=1,g=17,b=2,S=18,_=4,y=20,w=8,T=24,E={bt_playing:{label:"",icon:"media_bluetooth_on"},bt_disconnected:{label:"",icon:"media_bluetooth_off"},bt_neutral:{label:"",icon:"bluetooth"},bt_connecting:{label:"",icon:"bluetooth_searching"},bt_connected:{label:"",icon:"bluetooth_connected"},bt_disabled:{label:"",icon:"bluetooth_disabled"},play_arrow:{label:"",icon:"play_circle_filled"},pause:{label:"",icon:"pause_circle"},stop:{label:"",icon:"stop_circle"},"":{label:"",icon:""}},A=[{icon:"battery_0_bar",label:"▪",ranges:[{f:5.8,t:6.8},{f:8.8,t:10.2}]},{icon:"battery_2_bar",label:"▪▪",ranges:[{f:6.8,t:7.4},{f:10.2,t:11.1}]},{icon:"battery_3_bar",label:"▪▪▪",ranges:[{f:7.4,t:7.5},{f:11.1,t:11.25}]},{icon:"battery_4_bar",label:"▪▪▪▪",ranges:[{f:7.5,t:7.8},{f:11.25,t:11.7}]}],O=[{desc:"Idle",sub:["bt_neutral"]},{desc:"Discovering",sub:["bt_connecting"]},{desc:"Discovered",sub:["bt_connecting"]},{desc:"Unconnected",sub:["bt_disconnected"]},{desc:"Connecting",sub:["bt_connecting"]},{desc:"Connected",sub:["bt_connected","play_arrow","bt_playing","pause","stop"]},{desc:"Disconnecting",sub:["bt_disconnected"]}],k={MESSAGING_INFO:"badge-success",MESSAGING_WARNING:"badge-warning",MESSAGING_ERROR:"badge-danger"},N={OK:0,FAIL:1,DISC:2,LOST:3,RESTORE:4,ETH:5},x={0:"eRunning",1:"eReady",2:"eBlocked",3:"eSuspended",4:"eDeleted"},R={NONE:0,REBOOT_TO_RECOVERY:2,SET_FWURL:5,FLASHING:6,DONE:7,UPLOADING:8,ERROR:9,UPLOADCOMPLETE:10,_state:-1,olderRecovery:!1,statusText:"",flashURL:"",flashFileName:"",statusPercent:0,Completed:!1,recovery:!1,prevRecovery:!1,updateModal:new bootstrap.Modal(document.getElementById("otadiv"),{}),reset:function(){return this.olderRecovery=!1,this.statusText="",this.statusPercent=-1,this.flashURL="",this.flashFileName=void 0,this.UpdateProgress(),r("#rTable tr.release").removeClass("table-success table-warning"),r(".flact").prop("disabled",!1),r("#flashfilename").value=null,r("#fw-url-input").value=null,this.isStateError()||(r("span#flash-status").html(""),r("#fwProgressLabel").parent().removeClass("bg-danger")),this._state=this.NONE,this},isStateUploadComplete:function(){return this._state==this.UPLOADCOMPLETE},isStateError:function(){return this._state==this.ERROR},isStateNone:function(){return this._state==this.NONE},isStateRebootRecovery:function(){return this._state==this.REBOOT_TO_RECOVERY},isStateSetUrl:function(){return this._state==this.SET_FWURL},isStateFlashing:function(){return this._state==this.FLASHING},isStateDone:function(){return this._state==this.DONE},isStateUploading:function(){return this._state==this.UPLOADING},init:function(){return this._state=this.NONE,this},SetStateError:function(){return this._state=this.ERROR,r("#fwProgressLabel").parent().addClass("bg-danger"),this},SetStateNone:function(){return this._state=this.NONE,this},SetStateRebootRecovery:function(){return this._state=this.REBOOT_TO_RECOVERY,this.SetStatusText("Starting recovery mode."),r.ajax({url:"/recovery.json",context:this,dataType:"text",method:"POST",cache:!1,contentType:"application/json; charset=utf-8",data:JSON.stringify({timestamp:Date.now()}),error:function(t,e,n){var a;this.setOTAError("Unexpected error while trying to restart to recovery. (status=".concat(null!==(a=t.status)&&void 0!==a?a:"",", error=").concat(null!=n?n:""," ) "))},complete:function(t){this.SetStatusText("Waiting for system to boot.")}}),this},SetStateSetUrl:function(){return this._state=this.SET_FWURL,this.statusText="Sending firmware download location.",G({fwurl:{value:this.flashURL,type:33}}),this},SetStateFlashing:function(){return this._state=this.FLASHING,this},SetStateDone:function(){return this._state=this.DONE,this.reset(),this},SetStateUploading:function(){return this._state=this.UPLOADING,this.SetStatusText("Sending file to device.")},SetStateUploadComplete:function(){return this._state=this.UPLOADCOMPLETE,this},isFlashExecuting:function(){return!0==(this._state!=this.UPLOADING&&(""!==this.statusText||this.statusPercent>=0))},toString:function(){var t=this;return Object.keys(this).find((function(e){return t[e]===t._state}))},setOTATargets:function(){this.flashURL="",this.flashFileName="",this.flashURL=r("#fw-url-input").val();var t=r("#flashfilename")[0].files;return t.length>0&&(this.flashFileName=t[0]),0==this.flashFileName.length&&0==this.flashURL.length&&this.setOTAError("Invalid url or file. Cannot start OTA"),this},setOTAError:function(t){return this.SetStateError().SetStatusPercent(0).SetStatusText(t).reset(),this},ShowDialog:function(){return this.isStateNone()||(this.updateModal.show(),r(".flact").prop("disabled",!0)),this},SetStatusPercent:function(t){var e=this.statusPercent!=t;return this.statusPercent=t,e&&(this.isStateUploading()||this.isStateFlashing()||this.SetStateFlashing(),100==t&&(this.isStateFlashing()?this.SetStateDone():this.isStateUploading()&&(this.statusPercent=0,this.SetStateFlashing())),this.UpdateProgress().ShowDialog()),this},SetStatusText:function(t){var e=this.statusText!=t;return this.statusText=t,e&&(r("span#flash-status").html(this.statusText),this.ShowDialog()),this},UpdateProgress:function(){return r(".progress-bar").css("width",this.statusPercent+"%").attr("aria-valuenow",this.statusPercent).text(this.statusPercent+"%"),r(".progress-bar").html((this.isStateDone()?100:this.statusPercent)+"%"),this},StartOTA:function(){return this.logEvent(this.StartOTA.name),r("#fwProgressLabel").parent().removeClass("bg-danger"),this.setOTATargets(),this.isStateError()||(J?this.SetStateFlashing().TargetReadyStartOTA():this.SetStateRebootRecovery()),this},UploadLocalFile:function(){this.SetStateUploading();var t=new XMLHttpRequest;t.context=this;var e=this.HandleUploadProgressEvent.bind(this),n=this.setOTAError.bind(this);t.upload.addEventListener("progress",e,!1),t.onreadystatechange=function(){4===t.readyState&&(0!==t.status&&404!==t.status||n("Upload Failed. Recovery version might not support uploading. Please use web update instead."))},t.open("POST","/flash.json",!0),t.send(this.flashFileName)},TargetReadyStartOTA:function(){return J&&this.prevRecovery&&!this.isStateRebootRecovery()&&!this.isStateFlashing()?this:(this.logEvent(this.TargetReadyStartOTA.name),J?(this.prevRecovery=!0,void(""!==this.flashFileName?this.UploadLocalFile():""!=this.flashURL?this.SetStateSetUrl():this.setOTAError("Invalid URL or file name while trying to start the OTa process"))):(console.error("Event TargetReadyStartOTA fired in the wrong mode "),this))},HandleUploadProgressEvent:function(t){this.logEvent(this.HandleUploadProgressEvent.name),this.SetStateUploading().SetStatusPercent(Math.round(t.loaded/t.total*100)).SetStatusText("Uploading file to device")},EventTargetStatus:function(t){var e,n;this.isStateNone()||this.logEvent(this.EventTargetStatus.name),null!==(e=t.ota_pct)&&void 0!==e&&e&&(this.olderRecovery=!0,this.SetStatusPercent(t.ota_pct)),""!=(null!==(n=t.ota_dsc)&&void 0!==n?n:"")&&(this.olderRecovery=!0,this.SetStatusText(t.ota_dsc)),null!=t.recovery&&(this.recovery=1===t.recovery),this.isStateRebootRecovery()&&this.recovery&&this.TargetReadyStartOTA()},EventOTAMessageClass:function(t){this.logEvent(this.EventOTAMessageClass.name);var e=JSON.parse(t);this.SetStatusPercent(e.ota_pct).SetStatusText(e.ota_dsc)},logEvent:function(t){console.log("".concat(t,", flash state ").concat(this.toString(),", recovery: ").concat(this.recovery,", ota pct: ").concat(this.statusPercent,", ota desc: ").concat(this.statusText))}};window.hideSurrounding=function(t){r(t).parent().parent().hide()};var C=!1,I=2500;function G(t){var e={timestamp:Date.now(),config:t};r.ajax({url:"/config.json",dataType:"text",method:"POST",cache:!1,contentType:"application/json; charset=utf-8",data:JSON.stringify(e),error:U})}function M(){return ot.hasOwnProperty("ip")&&"0.0.0.0"!=ot.ip&&""!=ot.ip}function j(t){return M()?t.icon:t.label}function P(t){r("#o_type").children("span").css({display:"none"});var e=!1;"bt"===t?(e="bt"!==K&&""!==K,K="bt"):"spdif"===t?(e="spdif"!==K&&""!==K,K="spdif"):(e="i2s"!==K&&""!==K,K="i2s"),r("#"+K).prop("checked",!0),r("#o_"+K).css({display:"inline"}),e&&Object.keys(B[K]).forEach((function(t){r("#cmd_opt_".concat(t)).val(B[K][t])}))}function U(t,e,n){console.log(t.status),console.log(n),""!==n&&kt(n,"MESSAGING_ERROR")}function L(t,e,n){var a=arguments.length>3&&void 0!==arguments[3]&&arguments[3],s="table-success";"MESSAGING_WARNING"===e?s="table-warning":"MESSAGING_ERROR"===e&&(s="table-danger"),r("#toast_"+t).removeClass("table-success").removeClass("table-warning").removeClass("table-danger").addClass(s).addClass("show");var o=n.substring(0,n.length-1).encodeHTML().replace(/\n/g,"
");o=(r("#msg_"+t).html().length>0&&a?r("#msg_"+t).html()+"
":"")+o,r("#msg_"+t).html(o)}window.hFlash=function(){r("#flashfilename").value=null,R.StartOTA()},window.handleReboot=function(t){"reboot_ota"==t?(r("#reboot_ota_nav").removeClass("active").prop("disabled",!0),ut(500,"","reboot_ota")):(r("#reboot_nav").removeClass("active"),ut(500,"",t))};var F,D="https://api.github.com/repos/sle118/squeezelite-esp32/releases",J=!1,W=!1,H="",B={i2s:{b:"500:2000",C:"30",W:"",Z:"96000",o:"I2S"},spdif:{b:"500:2000",C:"30",W:"",Z:"48000",o:"SPDIF"},bt:{b:"500:2000",C:"30",W:"",Z:"44100",o:"BT"}},q={codecs:["flac","pcm","mp3","ogg","aac","wma","alac","dsd","mad","mpg"]},Y=0,z="MESSAGING_INFO",V={},Z=null,K="",Q="",X="Squeezelite-ESP32",$="",tt=X,et="",nt=X,at="",st="#cfg-audio-bt_source-sink_name",ot={},it={},ct="",rt={CONN:0,MAN:1,STS:2};function lt(t){var e={};r("input.nvs").each((function(n,a){if(t)e[a.id]=a.value;else{var s=parseInt(a.attributes.nvs_type.value,10);""!==a.id&&(e[a.id]={},e[a.id].value=s===v||s===g||s===b||s===S||s===_||s===y||s===w||s===T?parseInt(a.value):a.value,e[a.id].type=s)}}));var n=r("#nvs-new-key").val(),a=r("#nvs-new-value").val();return""!==n&&(t?e[n]=a:(e[n]={},e[n].value=a,e[n].type=33)),e}function ut(t,e){var n="/"+(arguments.length>2&&void 0!==arguments[2]?arguments[2]:"reboot")+".json";r("tbody#tasks").empty(),r("#tasks_sect").css("visibility","collapse"),h.resolve({cmdname:e,url:n}).delay(t).then((function(t){t.cmdname.length>0?L(t.cmdname,"MESSAGING_WARNING","System is rebooting.\n",!0):kt("System is rebooting.\n","MESSAGING_WARNING"),console.log("now triggering reboot"),r("button[onclick*='handleReboot']").addClass("rebooting"),r.ajax({url:t.url,dataType:"text",method:"POST",cache:!1,contentType:"application/json; charset=utf-8",data:JSON.stringify({timestamp:Date.now()}),error:U,complete:function(){console.log("reboot call completed"),h.resolve(t).delay(6e3).then((function(t){t.cmdname.length>0&&function(t){r("#toast_"+t).removeClass("table-success").removeClass("table-warning").removeClass("table-danger").addClass("table-success").removeClass("show"),r("#msg_"+t).html("")}(t.cmdname),At(),Ot()}))}})}))}function dt(t){return r(".upf").filter((function(){return r(this).text().toUpperCase()===t.toUpperCase()})).length>0&&(r("#splf").val(t).trigger("input"),!0)}function ht(t,e){var n="cmd_opt_".concat(t),a="".concat(n,"-error"),s=r("#".concat(a)),o=r("#".concat(n));return s&&0!=s.length||(o.after('
')),s=r("#".concat(a))),0==e.length?(s.hide(),o.removeClass("is-invalid"),o.addClass("is-valid"),s.text("")):(s.show(),s.text(e),o.removeClass("is-valid"),o.addClass("is-invalid")),s}function pt(t){return t>=-55?{label:"****",icon:"signal_wifi_statusbar_4_bar"}:t>=-60?{label:"***",icon:"network_wifi_3_bar"}:t>=-65?{label:"**",icon:"network_wifi_2_bar"}:t>=-70?{label:"*",icon:"network_wifi_1_bar"}:{label:".",icon:"signal_wifi_statusbar_null"}}function ft(){var t;(null===(t=ot)||void 0===t?void 0:t.urc)!==N.ETH&&(r.ajaxSetup({timeout:3e3}),r.getJSON("/scan.json",(0,a.Z)(i().mark((function t(){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,xt(2e3);case 2:r.getJSON("/ap.json",(function(t){t.length>0&&(t.sort((function(t,e){var n=t.rssi,a=e.rssi;return na?-1:0})),vt(t))}));case 3:case"end":return t.stop()}}),t)})))))}function mt(t,e,n){var a=pt(e),s={label:0==n?"🔓":"🔒",icon:0==n?"no_encryption":"lock"};return''.concat(t,'\n ').concat(j(a),'\n \t\n ').concat(j(s),"\n ")}function vt(t){var e,n="";if(r("#wifiTable tr td:first-of-type").text(""),r("#wifiTable tr").removeClass("table-success table-warning"),t&&(t.forEach((function(t){n+=mt(t.ssid,t.rssi,t.auth)})),r("#wifiTable").html(n)),0==r(".manual_add").length&&(r("#wifiTable").append(mt("Manual add",0,0)),r("#wifiTable tr:last").addClass("table-light text-dark").addClass("manual_add")),!ot.ssid||ot.urc!==N.OK&&ot.urc!==N.RESTORE)(null===(e=ot)||void 0===e?void 0:e.urc)!==N.ETH&&r("span#foot-if").html("");else{var a,s='#wifiTable td:contains("'.concat(ot.ssid,'")');if(0==r(s).filter((function(){return r(this).text()===ot.ssid})).length)r("#wifiTable").prepend("".concat(mt(ot.ssid,null!==(a=ot.rssi)&&void 0!==a?a:0,0)));r(s).filter((function(){return r(this).text()===ot.ssid})).siblings().first().html("✓").parent().addClass(ot.urc===N.OK?"table-success":"table-warning"),r("span#foot-if").html("SSID: ".concat(ot.ssid,", IP: ").concat(ot.ip,"")),r("#wifiStsIcon").html(pt(ot.rssi))}}function gt(t){console.debug(this.toLocaleString()+"\t"+t.nme+"\t"+t.cpu+"\t"+x[t.st]+"\t"+t.minstk+"\t"+t.bprio+"\t"+t.cprio+"\t"+t.num),r("tbody#tasks").append(''+t.num+""+t.nme+""+t.cpu+""+x[t.st]+""+t.minstk+""+t.bprio+""+t.cprio+"")}function bt(t){return r("".concat(st," option:contains('").concat(t,"')"))}function St(){r.ajaxSetup({timeout:I}),r.getJSON("/messages.json",function(){var t=(0,a.Z)(i().mark((function t(e){var n,a,s,o,c,u,d,h,p,f;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:n=l(e),t.prev=1,s=i().mark((function t(){var e,n;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=a.value,n=e.current_time-e.sent_time,(o=new Date).setTime(o.getTime()-n),t.t0=e.class,t.next="MESSAGING_CLASS_OTA"===t.t0?7:"MESSAGING_CLASS_STATS"===t.t0?9:"MESSAGING_CLASS_SYSTEM"===t.t0?14:"MESSAGING_CLASS_CFGCMD"===t.t0?16:"MESSAGING_CLASS_BT"===t.t0?19:23;break;case 7:return R.EventOTAMessageClass(e.message),t.abrupt("break",24);case 9:return c=JSON.parse(e.message),console.debug(o.toLocalShort()+" - Number of running tasks: "+c.ntasks),console.debug(o.toLocalShort()+"\tname\tcpu\tstate\tminstk\tbprio\tcprio\tnum"),c.tasks?("collapse"===r("#tasks_sect").css("visibility")&&r("#tasks_sect").css("visibility","visible"),r("tbody#tasks").html(""),c.tasks.sort((function(t,e){return e.cpu-t.cpu})).forEach(gt,o)):"visible"===r("#tasks_sect").css("visibility")&&(r("tbody#tasks").empty(),r("#tasks_sect").css("visibility","collapse")),t.abrupt("break",24);case 14:return Nt(e,o),t.abrupt("break",24);case 16:return L((u=e.message.split(/([^\n]*)\n([\s\S]*)/g))[1],e.type,u[2],!0),t.abrupt("break",24);case 19:if(r("#cfg-audio-bt_source-sink_name").is("input")){for(d=r("#cfg-audio-bt_source-sink_name")[0].attributes,h="",p=0;p "))}return JSON.parse(e.message).forEach((function(t){bt(t.name).length>0||(r("#cfg-audio-bt_source-sink_name").append("")),Nt({type:e.type,message:"BT Audio device found: ".concat(t.name," RSSI: ").concat(t.rssi," ")},o)),bt(t.name).attr("data-bs-description","".concat(t.name," (").concat(t.rssi,"dB)")).attr("rssi",t.rssi).attr("value",t.name).text("".concat(t.name," [").concat(t.rssi,"dB]")).trigger("change")})),r(st).append(r("".concat(st," option")).remove().sort((function(t,e){return console.log("".concat(parseInt(r(t).attr("rssi"))," < ").concat(parseInt(r(e).attr("rssi"))," ? ")),parseInt(r(t).attr("rssi"))".concat(ot.ip,""))):(r(".if_wifi").show(),vt())),_t(t)}function Tt(){r.ajaxSetup({timeout:2e3}),r.getJSON("/status.json",(function(t){var e;if(function(t){var e;1===(null!==(e=t.recovery)&&void 0!==e?e:0)?(J=!0,r(".recovery_element").show(),r(".ota_element").hide(),r("#boot-button").html("Reboot"),r("#boot-form").attr("action","/reboot_ota.json")):(!J&&W&&(W=!1,setTimeout(St,I)),J=!1,r(".recovery_element").hide(),r(".ota_element").show(),r("#boot-button").html("Recovery"),r("#boot-form").attr("action","/recovery.json"))}(t),f(),wt(t),function(t){var e="",n="";if(void 0!==t.bt_status&&void 0!==t.bt_sub_status){var a=O[t.bt_status].sub[t.bt_sub_status];a?(e=E[a],n=O[t.bt_status].desc):(e=E.bt_connected,n="Output status")}r("#o_type").attr("title",n),r("#o_bt").html(M()?e.label:e.text)}(t),R.EventTargetStatus(t),t.depth&&(16==t.depth?r("#cmd_opt_R").show():r("#cmd_opt_R").hide()),t.project_name&&""!==t.project_name&&(tt=t.project_name),t.platform_name&&""!==t.platform_name&&(nt=t.platform_name),""===et&&(et=tt),""===et&&(et="Squeezelite-ESP32"),t.version&&""!==t.version?(X=t.version,r("#navtitle").html("".concat(et).concat(J?"
[recovery]":"")),r("span#foot-fw").html("fw: ".concat(X,", mode: ").concat(J?"Recovery":tt,""))):r("span#flash-status").html(""),t.Voltage){var n=function(t){for(var e=0,n=A;e
'.concat(e.help.encodeHTML().replace(/\n/g,"
"),'
'),e.argtable&&e.argtable.forEach((function(n){var a=n.datatype||"",s=e.name+"-"+n.longopts,i=Et(t,e.name,n.longopts),c="hasvalue="+n.hasvalue+" ";c+='longopts="'+n.longopts+'" ',c+='shortopts="'+n.shortopts+'" ',c+="checkbox="+n.checkbox+" ",c+='cmdname="'+e.name+'" ',c+='id="'+s+'" name="'+s+'" ',n.longopts&&n.longopts.startsWith("_")&&(c+="readonly ");var r=n.mincount>0?"is-invalid":"";"hidden"===n.glossary&&(c+=' style="visibility: hidden;"'),n.checkbox?o+='
"):n.remark?o+='
"):(o+='
"),a.includes("|")?(r=a.startsWith("+")?" multiple ":"",a=a.replace("<","").replace("=","").replace(">",""),o+=""):o+='")),n.remark||(o+='Previous value: '.concat(n.checkbox?i?"Checked":"Unchecked":i||"","")),o+="
"})),o+='
\n '),o+=a?'\n'):''),o+="
",a?r(s).append(o):r("#commands-list").append(o)}})),r(".sclk").off("click").on("click",(function(){runCommand(this,!1)})),r(".cclk").off("click").on("click",(function(){runCommand(this,!0)})),t.commands.forEach((function(e){r("[cmdname="+e.name+"]:input").val(""),r("[cmdname="+e.name+"]:checkbox").prop("checked",!1),e.argtable&&e.argtable.forEach((function(n){var a="#"+e.name+"-"+n.longopts,s=Et(t,e.name,n.longopts);n.checkbox?r(a)[0].checked=s:n.remark||(void 0!==s&&r(a).val(s).trigger("change"),0===r(a)[0].value.length&&(n.datatype||"").includes("|")&&(r(a)[0].value="--")),n.mincount&&n.mincount>0&&(r(a).removeClass("is-invalid"),r(a).addClass("is-valid"))}))})),0!=r("#cfg-hw-preset-model_config").length&&(C||(C=!0,r("#cfg-hw-preset-model_config").html(""),r.getJSON("https://gist.githubusercontent.com/sle118/dae585e157b733a639c12dc70f0910c5/raw/",{_:(new Date).getTime()},(function(t){r.each(t,(function(t,e){r("#cfg-hw-preset-model_config").append("")),""!==at&&at==e.name&&r("#cfg-hw-preset-model_config").val(at)})),""!==at&&"#prev_preset".show().val(at)})).fail((function(t,e,n){var a=e+", "+n;console.log("Request Failed: "+a)}))))})).fail((function(t,e,n){404==t.status?r(".orec").hide():U(t,0,n),r("#commands-list").empty()}))}function Ot(){r.ajaxSetup({timeout:7e3}),r.getJSON("/config.json",(function(t){r("#nvsTable tr").remove();var e=t.config?t.config:t;V=e,H="",Object.keys(e).sort().forEach((function(t){var n=e[t].value;"autoexec"===t||("host_name"===t?(n=n.replaceAll('"',""),r("input#dhcp-name1").val(n),r("input#dhcp-name2").val(n),0==r("#cmd_opt_n").length&&r("#cmd_opt_n").val(n),document.title=n,Q=n):"rel_api"===t?D=n:"enable_airplay"===t?r("#s_airplay").css({display:m(n)?"inline":"none"}):"enable_cspot"===t?r("#s_cspot").css({display:m(n)?"inline":"none"}):"preset_name"==t?at=n:"board_model"==t&&(et=n)),r("tbody#nvsTable").append(""+t+""),r("input#"+t).val(e[t].value)})),H.length>0&&r("#cfg-audio-bt_source-sink_name").val(H),r("tbody#nvsTable").append(""),t.gpio?(r("#pins").show(),r("tbody#gpiotable tr").remove(),t.gpio.forEach((function(t){r("tbody#gpiotable").append("'+t.group+""+t.name+""+t.gpio+""+(t.fixed?"Fixed":"Configuration")+"")}))):r("#pins").hide()})).fail((function(t,e,n){U(t,0,n)}))}function kt(t,e){Nt({message:t,type:e},new Date)}function Nt(t,e){var n="table-success";"MESSAGING_WARNING"===t.type?(n="table-warning","MESSAGING_INFO"===z&&(z="MESSAGING_WARNING")):"MESSAGING_ERROR"===t.type&&("MESSAGING_INFO"!==z&&"MESSAGING_WARNING"!==z||(z="MESSAGING_ERROR"),n="table-danger"),++Y>0&&(r("#msgcnt").removeClass("badge-success"),r("#msgcnt").removeClass("badge-warning"),r("#msgcnt").removeClass("badge-danger"),r("#msgcnt").addClass(k[z]),r("#msgcnt").text(Y)),r("#syslogTable").append(""+e.toLocalShort()+""+t.message.encodeHTML()+"")}function xt(t){return new h((function(e){return setTimeout(e,t)}))}h.prototype.delay=function(t){return this.then((function(e){return new h((function(n){setTimeout((function(){n(e)}),t)}))}),(function(e){return new h((function(n,a){setTimeout((function(){a(e)}),t)}))}))},window.saveAutoexec1=function(t){L("cfg-audio-tmpl","MESSAGING_INFO","Saving.\n",!1);var e="".concat("squeezelite "," -o ").concat(K," ");r(".sqcmd").each((function(){var t=p(r(this)),n=t.opt,a=t.val;if(n&&n.length>0&&"boolean"==typeof a||a.length>0){var s=":"===n?n:" -".concat(n," ");a="boolean"==typeof a?"":a,e+="".concat(s," ").concat(a)}}));var n=r("#cmd_opt_R input[name=resample]:checked");n.length>0&&""!==n.attr("suffix")&&(e+=n.attr("suffix"),r("#resample_i").is(":checked")&&"true"==n.attr("aint")&&(e+=r("#resample_i").attr("suffix"))),"bt"===K&&L("cfg-audio-tmpl","MESSAGING_INFO","Remember to configure the Bluetooth audio device name.\n",!0),e+=function(t){for(var e=" ",n=0,a=Object.entries(t);n8&&(r(this).val().startsWith("http://")||r(this).val().startsWith("https://"))?r("#start-flash").show():r("#start-flash").hide()})),r(".upSrch").on("input",(function(){var t=this.value;r("#rTable tr").removeClass(this.id+"_hide"),t.length>0&&r("#rTable td:nth-child(".concat(r(this).parent().index()+1,")")).filter((function(){return!r(this).text().toUpperCase().includes(t.toUpperCase())})).parent().addClass(this.id+"_hide"),r('[class*="_hide"]').hide(),r("#rTable tr").not('[class*="_hide"]').show()})),setTimeout(ft,1500),r("#options input").on("input",(function(){var t=p(this),e=t.opt,n=t.val;if("c"===e||"e"===e){"cmd_opt_".concat(e,"_codec-error");var a=n.split(",").map((function(t){return t.trim()})).filter((function(t){return!q.codecs.includes(t)}));ht(e,a.length>0?"Invalid codec(s) ".concat(a.join(", ")):"")}if("m"===e){ht(e,/^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$/.test(n)?"":"Invalid MAC address")}if("r"===e){ht(e,/^(\d+\.?\d*|\.\d+)-(\d+\.?\d*|\.\d+)$|^(\d+\.?\d*)$|^(\d+\.?\d*,)+\d+\.?\d*$/.test(n)?"":"Invalid rate(s) ".concat(n,". Acceptable format: |-|,,"))}})),r("#WifiConnectDialog")[0].addEventListener("shown.bs.modal",(function(t){r("*[class*='connecting']").hide(),null!=t&&t.relatedTarget&&(it.Action=rt.CONN,r(t.relatedTarget).children("td:eq(1)").text()==ot.ssid?it.Action=rt.STS:r(t.relatedTarget).is(":last-child")?(it.Action=rt.MAN,it.ssid="",r("#manual_ssid").val(it.ssid)):(it.ssid=r(t.relatedTarget).children("td:eq(1)").text(),r("#manual_ssid").val(it.ssid))),it.Action!==rt.STS?(r(".connecting-init").show(),r("#manual_ssid").trigger("focus")):_t()})),r("#WifiConnectDialog")[0].addEventListener("hidden.bs.modal",(function(){r("#WifiConnectDialog input").val("")})),r("#uCnfrm")[0].addEventListener("shown.bs.modal",(function(){r("#selectedFWURL").text(r("#fw-url-input").val())})),r("input#show-commands")[0].checked=1===Z,r('a[href^="#tab-commands"]').hide(),r("#load-nvs").on("click",(function(){r("#nvsfilename").trigger("click")})),r("#nvsfilename").on("change",(function(){if("function"!=typeof window.FileReader)throw"The file API isn't supported on this browser.";if(!this.files)throw"This browser does not support the `files` property of the file input.";if(this.files[0]){var t=this.files[0],e=new FileReader;e.onload=function(t){var e={};try{e=JSON.parse(t.target.result)}catch(t){alert("Parsing failed!\r\n "+t)}r("input.nvs").each((function(t,n){r(this).parent().removeClass("bg-warning").removeClass("bg-success"),e[n.id]&&(e[n.id]!==n.value?(console.log("Changed "+n.id+" "+n.value+"==>"+e[n.id]),r(this).parent().addClass("bg-warning"),r(this).val(e[n.id])):r(this).parent().addClass("bg-success"))})),r("input.nvs").children(".bg-warning")&&alert("Highlighted values were changed. Press Commit to change on the device")},e.readAsText(t),this.value=null}})),r("#clear-syslog").on("click",(function(){Y=0,z="MESSAGING_INFO",r("#msgcnt").text(""),r("#syslogTable").html("")})),r("#ok-credits").on("click",(function(){r("#credits").slideUp("fast",(function(){})),r("#app").slideDown("fast",(function(){}))})),r("#acredits").on("click",(function(t){t.preventDefault(),r("#app").slideUp("fast",(function(){})),r("#credits").slideDown("fast",(function(){}))})),r("input#show-commands").on("click",(function(){this.checked=this.checked?1:0,this.checked?(r('a[href^="#tab-commands"]').show(),Z=1):(Z=0,r('a[href^="#tab-commands"]').hide())})),r("#disable-squeezelite").on("click",(function(){if(this.checked){var t=r("#cmd_opt_s").val();r("#cmd_opt_s").data("originalValue",t),r("#cmd_opt_s").val("-disable")}else{var e=r("#cmd_opt_s").data("originalValue");r("#cmd_opt_s").val(e||"")}})),r("input#show-nvs").on("click",(function(){this.checked=this.checked?1:0,c.Z.set("show-nvs",this.checked?"Y":"N"),f()})),r("#btn_reboot_recovery").on("click",(function(){handleReboot("recovery")})),r("#btn_reboot").on("click",(function(){handleReboot("reboot")})),r("#btn_flash").on("click",(function(){hFlash()})),r("#save-autoexec1").on("click",(function(){saveAutoexec1(!1)})),r("#commit-autoexec1").on("click",(function(){saveAutoexec1(!0)})),r("#btn_disconnect").on("click",(function(){ot={},vt(),r.ajax({url:"/connect.json",dataType:"text",method:"DELETE",cache:!1,contentType:"application/json; charset=utf-8",data:JSON.stringify({timestamp:Date.now()})})})),r("#btnJoin").on("click",(function(){handleConnect()})),r("#reboot_nav").on("click",(function(){handleReboot("reboot")})),r("#reboot_ota_nav").on("click",(function(){handleReboot("reboot_ota")})),r("#save-as-nvs").on("click",(function(){var t=lt(!0),e=document.createElement("a");e.href=URL.createObjectURL(new Blob([JSON.stringify(t,null,2)],{type:"text/plain"})),e.setAttribute("download","nvs_config_"+Q+"_"+Date.now()+"json"),document.body.appendChild(e),e.click(),document.body.removeChild(e)})),r("#save-nvs").on("click",(function(){G(lt(!1))})),r("#fwUpload").on("click",(function(){0===document.getElementById("flashfilename").files.length?alert("No file selected!"):(r("#fw-url-input").value=null,R.StartOTA())})),r("[name=output-tmpl]").on("click",(function(){P(this.id)})),r("#chkUpdates").on("click",(function(){r("#rTable").html(""),r.getJSON(D,(function(t){var e=[];t.forEach((function(t){var n=t.name.split("#")[3];e.includes(n)||e.push(n)}));var n="";e.forEach((function(t){n+='"})),r("#fwbranch").append(n),t.forEach((function(t){var e="";t.assets.forEach((function(t){t.name.match(/\.bin$/)&&(e=t.browser_download_url)}));var n=t.name.split("#"),a=n[0],s=n[2],o=n[3],i=a.substr(a.lastIndexOf("-")+1);i="32"==i||"16"==i?i:"";var c=t.body;c=(c=(c=c.replace(/'/gi,'"')).replace(/[\s\S]+(### Revision Log[\s\S]+)### ESP-IDF Version Used[\s\S]+/,"$1")).replace(/- \(.+?\) /g,"- ").encodeHTML(),r("#rTable").append("\n ").concat(a,"").concat(new Date(t.created_at).toLocalShort(),"\n ").concat(s,"").concat(o,"").concat(i,""))})),r("#searchfw").css("display","inline"),dt(nt)||dt(tt),r("#rTable tr.release").on("click",(function(){var t=this.attributes.fwurl.value;F&&(t=t.replace(/.*\/download\//,F+"/plugins/SqueezeESP32/firmware/")),r("#fw-url-input").val(t),r("#start-flash").show(),r("#rTable tr.release").removeClass("table-success table-warning"),r(this).addClass("table-success table-warning")}))})).fail((function(){alert("failed to fetch release history!")}))})),r("#fwcheck").on("click",(function(){r("#releaseTable").html(""),r("#fwbranch").empty(),r.getJSON(D,(function(t){var e,n=0,a=[];t.forEach((function(t){var e=t.name.split("#")[3];a.includes(e)||a.push(e)})),a.forEach((function(t){e+='"})),r("#fwbranch").append(e),t.forEach((function(t){var e="";t.assets.forEach((function(t){t.name.match(/\.bin$/)&&(e=t.browser_download_url)}));var a=t.name.split("#"),s=a[0],o=a[1],i=a[2],c=a[3],l=t.body;l=(l=(l=l.replace(/'/gi,'"')).replace(/[\s\S]+(### Revision Log[\s\S]+)### ESP-IDF Version Used[\s\S]+/,"$1")).replace(/- \(.+?\) /g,"- ");var u=n++>6?" hide":"";r("#releaseTable").append(""+s+""+new Date(t.created_at).toLocalShort()+""+i+""+o+""+c+"")})),n>7&&(r("#releaseTable").append(""),r("#showallbutton").on("click",(function(){r("tr.hide").removeClass("hide"),r("tr#showall").addClass("hide")}))),r("#searchfw").css("display","inline")})).fail((function(){alert("failed to fetch release history!")}))})),r("#updateAP").on("click",(function(){ft(),console.log("refresh AP")})),Ot(),At(),St(),Tt()})),window.setURL=function(t){var e=t.dataset.url;r('[data-bs-url^="http"]').addClass("btn-success").removeClass("btn-danger"),r('[data-bs-url="'+e+'"]').addClass("btn-danger").removeClass("btn-success"),F&&(e=e.replace(/.*\/download\//,F+"/plugins/SqueezeESP32/firmware/")),r("#fwurl").val(e)},window.runCommand=function(t,e){var n=t.attributes.cmdname.value;L(t.attributes.cmdname.value,"MESSAGING_INFO","Executing.",!1);var a=document.getElementById("flds-"+n),o=null==a?void 0:a.querySelectorAll("select,input");if("cfg-hw-preset"===n)return function(t,e){var n=JSON.parse(t[0].value),a=t[0].attributes.cmdname.value;console.log("selected model: ".concat(n.name));for(var o={timestamp:Date.now(),config:{model_config:{value:n.name,type:33}}},i=0,c=Object.entries(n.config);i{n.r(e)},607:(t,e,n)=>{n(138),n(393),n(861),n(322)},861:t=>{t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAAb1BMVEXIycuswsKMjI4rqqZyc3RQlpQ6jIEmJifW2dq5ursppJ8Om4zC0NAFdGYmmpb///8Hg3O4x8cHkoEggX0jko5Ks6/P0dM5r6ocoZb3+PgiiYVevrp/y8bg4uOS09FtxMDs7+7M6um529qoysik2tiNn72gAAAAF3RSTlP94Fr/Wf39BP26/////////////////kibhL0AAAGjSURBVDjLbZMJkoMgEEWtmETEJWpkiSC45P5nnF4wk7HmW2jLfzYIdFYUxbXUYp5nIbTOUFoLAR2ivIKZFQXYuu6TahSHmdAlAqWub0/QNI1jSxrHacKeWw9EdtH1xHbbyiRgCJn67JqVAr9nO2fJnBDMoUuYEvsfmxnJBM66Zj8/iYmaAPKlOvRNJAC/fz8OefINEAngAbYPEMiHTJCCAZrACciVMpCCgDEBKwsAowymMO3IAP3Btqa5vYJx0ZlcOSUZaE/AWznvnTHOyfZ/wMUQvAIg/wb27QNEH94BgGj+APsZiF8AXAhQQEMwkIYYLW7xvsENoyUoF0I0ysf0F2O743kDQNXzXM8+j8Eb6byzDEz7gtpsO1PgrXG5Nd6btNTP+YXarKTny1uQ9JiAN6vbqT9au+BzMQjAWtlq6BiYttdjiVVVqfXxWFWFkk6Cz0DTdYOFPmpHAAK/YQCJoTppQJ8A3TAxVAAhR439Bg5tKe7NgSDEje3mDsf+ovuGCUbYZb/BwoHS6ykHMYfo/U6lx8Xb/+qo3U/x/lf+VP9c/j9c3zy20WEMxgAAAABJRU5ErkJggg=="}},n={};function a(t){var s=n[t];if(void 0!==s)return s.exports;var o=n[t]={id:t,loaded:!1,exports:{}};return e[t].call(o.exports,o,o.exports,a),o.loaded=!0,o.exports}a.m=e,t=[],a.O=(e,n,s,o)=>{if(!n){var i=1/0;for(u=0;u=o)&&Object.keys(a.O).every((t=>a.O[t](n[r])))?n.splice(r--,1):(c=!1,o0&&t[u-1][2]>o;u--)t[u]=t[u-1];t[u]=[n,s,o]},a.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return a.d(e,{a:e}),e},a.d=(t,e)=>{for(var n in e)a.o(e,n)&&!a.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},a.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),a.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),a.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},a.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),(()=>{var t={826:0};a.O.j=e=>0===t[e];var e=(e,n)=>{var s,o,[i,c,r]=n,l=0;if(i.some((e=>0!==t[e]))){for(s in c)a.o(c,s)&&(a.m[s]=c[s]);if(r)var u=r(a)}for(e&&e(n);la(607)));s=a.O(s)})(); -//# sourceMappingURL=index.4135c4.bundle.js.map \ No newline at end of file +(()=>{"use strict";var t,e={322:(t,e,n)=>{n.r(e);var a=n(531),s=n(152),o=n(687),i=n.n(o),c=n(955),r=n(755);function l(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(!t)return;if("string"==typeof t)return u(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);"Object"===n&&t.constructor&&(n=t.constructor.name);if("Map"===n||"Set"===n)return Array.from(t);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return u(t,e)}(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var a=0,s=function(){};return{s,n:function(){return a>=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function(t){throw t},f:s}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,c=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return i=t.done,t},e:function(t){c=!0,o=t},f:function(){try{i||null==n.return||n.return()}finally{if(c)throw o}}}}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,a=new Array(e);n")}}),Object.assign(Date.prototype,{toLocalShort:function(){return this.toLocaleString(void 0,{dateStyle:"short",timeStyle:"short"})}});var v=1,g=17,b=2,S=18,_=4,y=20,w=8,T=24,E={bt_playing:{label:"",icon:"media_bluetooth_on"},bt_disconnected:{label:"",icon:"media_bluetooth_off"},bt_neutral:{label:"",icon:"bluetooth"},bt_connecting:{label:"",icon:"bluetooth_searching"},bt_connected:{label:"",icon:"bluetooth_connected"},bt_disabled:{label:"",icon:"bluetooth_disabled"},play_arrow:{label:"",icon:"play_circle_filled"},pause:{label:"",icon:"pause_circle"},stop:{label:"",icon:"stop_circle"},"":{label:"",icon:""}},A=[{icon:"battery_0_bar",label:"▪",ranges:[{f:5.8,t:6.8},{f:8.8,t:10.2}]},{icon:"battery_2_bar",label:"▪▪",ranges:[{f:6.8,t:7.4},{f:10.2,t:11.1}]},{icon:"battery_3_bar",label:"▪▪▪",ranges:[{f:7.4,t:7.5},{f:11.1,t:11.25}]},{icon:"battery_4_bar",label:"▪▪▪▪",ranges:[{f:7.5,t:7.8},{f:11.25,t:11.7}]}],O=[{desc:"Idle",sub:["bt_neutral"]},{desc:"Discovering",sub:["bt_connecting"]},{desc:"Discovered",sub:["bt_connecting"]},{desc:"Unconnected",sub:["bt_disconnected"]},{desc:"Connecting",sub:["bt_connecting"]},{desc:"Connected",sub:["bt_connected","play_arrow","bt_playing","pause","stop"]},{desc:"Disconnecting",sub:["bt_disconnected"]}],k={MESSAGING_INFO:"badge-success",MESSAGING_WARNING:"badge-warning",MESSAGING_ERROR:"badge-danger"},N={OK:0,FAIL:1,DISC:2,LOST:3,RESTORE:4,ETH:5},x={0:"eRunning",1:"eReady",2:"eBlocked",3:"eSuspended",4:"eDeleted"},R={NONE:0,REBOOT_TO_RECOVERY:2,SET_FWURL:5,FLASHING:6,DONE:7,UPLOADING:8,ERROR:9,UPLOADCOMPLETE:10,_state:-1,olderRecovery:!1,statusText:"",flashURL:"",flashFileName:"",statusPercent:0,Completed:!1,recovery:!1,prevRecovery:!1,updateModal:new bootstrap.Modal(document.getElementById("otadiv"),{}),reset:function(){return this.olderRecovery=!1,this.statusText="",this.statusPercent=-1,this.flashURL="",this.flashFileName=void 0,this.UpdateProgress(),r("#rTable tr.release").removeClass("table-success table-warning"),r(".flact").prop("disabled",!1),r("#flashfilename").value=null,r("#fw-url-input").value=null,this.isStateError()||(r("span#flash-status").html(""),r("#fwProgressLabel").parent().removeClass("bg-danger")),this._state=this.NONE,this},isStateUploadComplete:function(){return this._state==this.UPLOADCOMPLETE},isStateError:function(){return this._state==this.ERROR},isStateNone:function(){return this._state==this.NONE},isStateRebootRecovery:function(){return this._state==this.REBOOT_TO_RECOVERY},isStateSetUrl:function(){return this._state==this.SET_FWURL},isStateFlashing:function(){return this._state==this.FLASHING},isStateDone:function(){return this._state==this.DONE},isStateUploading:function(){return this._state==this.UPLOADING},init:function(){return this._state=this.NONE,this},SetStateError:function(){return this._state=this.ERROR,r("#fwProgressLabel").parent().addClass("bg-danger"),this},SetStateNone:function(){return this._state=this.NONE,this},SetStateRebootRecovery:function(){return this._state=this.REBOOT_TO_RECOVERY,this.SetStatusText("Starting recovery mode."),r.ajax({url:"/recovery.json",context:this,dataType:"text",method:"POST",cache:!1,contentType:"application/json; charset=utf-8",data:JSON.stringify({timestamp:Date.now()}),error:function(t,e,n){var a;this.setOTAError("Unexpected error while trying to restart to recovery. (status=".concat(null!==(a=t.status)&&void 0!==a?a:"",", error=").concat(null!=n?n:""," ) "))},complete:function(t){this.SetStatusText("Waiting for system to boot.")}}),this},SetStateSetUrl:function(){return this._state=this.SET_FWURL,this.statusText="Sending firmware download location.",G({fwurl:{value:this.flashURL,type:33}}),this},SetStateFlashing:function(){return this._state=this.FLASHING,this},SetStateDone:function(){return this._state=this.DONE,this.reset(),this},SetStateUploading:function(){return this._state=this.UPLOADING,this.SetStatusText("Sending file to device.")},SetStateUploadComplete:function(){return this._state=this.UPLOADCOMPLETE,this},isFlashExecuting:function(){return!0==(this._state!=this.UPLOADING&&(""!==this.statusText||this.statusPercent>=0))},toString:function(){var t=this;return Object.keys(this).find((function(e){return t[e]===t._state}))},setOTATargets:function(){this.flashURL="",this.flashFileName="",this.flashURL=r("#fw-url-input").val();var t=r("#flashfilename")[0].files;return t.length>0&&(this.flashFileName=t[0]),0==this.flashFileName.length&&0==this.flashURL.length&&this.setOTAError("Invalid url or file. Cannot start OTA"),this},setOTAError:function(t){return this.SetStateError().SetStatusPercent(0).SetStatusText(t).reset(),this},ShowDialog:function(){return this.isStateNone()||(this.updateModal.show(),r(".flact").prop("disabled",!0)),this},SetStatusPercent:function(t){var e=this.statusPercent!=t;return this.statusPercent=t,e&&(this.isStateUploading()||this.isStateFlashing()||this.SetStateFlashing(),100==t&&(this.isStateFlashing()?this.SetStateDone():this.isStateUploading()&&(this.statusPercent=0,this.SetStateFlashing())),this.UpdateProgress().ShowDialog()),this},SetStatusText:function(t){var e=this.statusText!=t;return this.statusText=t,e&&(r("span#flash-status").html(this.statusText),this.ShowDialog()),this},UpdateProgress:function(){return r(".progress-bar").css("width",this.statusPercent+"%").attr("aria-valuenow",this.statusPercent).text(this.statusPercent+"%"),r(".progress-bar").html((this.isStateDone()?100:this.statusPercent)+"%"),this},StartOTA:function(){return this.logEvent(this.StartOTA.name),r("#fwProgressLabel").parent().removeClass("bg-danger"),this.setOTATargets(),this.isStateError()||(J?this.SetStateFlashing().TargetReadyStartOTA():this.SetStateRebootRecovery()),this},UploadLocalFile:function(){this.SetStateUploading();var t=new XMLHttpRequest;t.context=this;var e=this.HandleUploadProgressEvent.bind(this),n=this.setOTAError.bind(this);t.upload.addEventListener("progress",e,!1),t.onreadystatechange=function(){4===t.readyState&&(0!==t.status&&404!==t.status||n("Upload Failed. Recovery version might not support uploading. Please use web update instead."))},t.open("POST","/flash.json",!0),t.send(this.flashFileName)},TargetReadyStartOTA:function(){return J&&this.prevRecovery&&!this.isStateRebootRecovery()&&!this.isStateFlashing()?this:(this.logEvent(this.TargetReadyStartOTA.name),J?(this.prevRecovery=!0,void(""!==this.flashFileName?this.UploadLocalFile():""!=this.flashURL?this.SetStateSetUrl():this.setOTAError("Invalid URL or file name while trying to start the OTa process"))):(console.error("Event TargetReadyStartOTA fired in the wrong mode "),this))},HandleUploadProgressEvent:function(t){this.logEvent(this.HandleUploadProgressEvent.name),this.SetStateUploading().SetStatusPercent(Math.round(t.loaded/t.total*100)).SetStatusText("Uploading file to device")},EventTargetStatus:function(t){var e,n;this.isStateNone()||this.logEvent(this.EventTargetStatus.name),null!==(e=t.ota_pct)&&void 0!==e&&e&&(this.olderRecovery=!0,this.SetStatusPercent(t.ota_pct)),""!=(null!==(n=t.ota_dsc)&&void 0!==n?n:"")&&(this.olderRecovery=!0,this.SetStatusText(t.ota_dsc)),null!=t.recovery&&(this.recovery=1===t.recovery),this.isStateRebootRecovery()&&this.recovery&&this.TargetReadyStartOTA()},EventOTAMessageClass:function(t){this.logEvent(this.EventOTAMessageClass.name);var e=JSON.parse(t);this.SetStatusPercent(e.ota_pct).SetStatusText(e.ota_dsc)},logEvent:function(t){console.log("".concat(t,", flash state ").concat(this.toString(),", recovery: ").concat(this.recovery,", ota pct: ").concat(this.statusPercent,", ota desc: ").concat(this.statusText))}};window.hideSurrounding=function(t){r(t).parent().parent().hide()};var C=!1,I=2500;function G(t){var e={timestamp:Date.now(),config:t};r.ajax({url:"/config.json",dataType:"text",method:"POST",cache:!1,contentType:"application/json; charset=utf-8",data:JSON.stringify(e),error:U})}function M(){return ot.hasOwnProperty("ip")&&"0.0.0.0"!=ot.ip&&""!=ot.ip}function j(t){return M()?t.icon:t.label}function P(t){r("#o_type").children("span").css({display:"none"});var e=!1;"bt"===t?(e="bt"!==K&&""!==K,K="bt"):"spdif"===t?(e="spdif"!==K&&""!==K,K="spdif"):(e="i2s"!==K&&""!==K,K="i2s"),r("#"+K).prop("checked",!0),r("#o_"+K).css({display:"inline"}),e&&Object.keys(B[K]).forEach((function(t){r("#cmd_opt_".concat(t)).val(B[K][t])}))}function U(t,e,n){console.log(t.status),console.log(n),""!==n&&kt(n,"MESSAGING_ERROR")}function L(t,e,n){var a=arguments.length>3&&void 0!==arguments[3]&&arguments[3],s="table-success";"MESSAGING_WARNING"===e?s="table-warning":"MESSAGING_ERROR"===e&&(s="table-danger"),r("#toast_"+t).removeClass("table-success").removeClass("table-warning").removeClass("table-danger").addClass(s).addClass("show");var o=n.substring(0,n.length-1).encodeHTML().replace(/\n/g,"
");o=(r("#msg_"+t).html().length>0&&a?r("#msg_"+t).html()+"
":"")+o,r("#msg_"+t).html(o)}window.hFlash=function(){r("#flashfilename").value=null,R.StartOTA()},window.handleReboot=function(t){"reboot_ota"==t?(r("#reboot_ota_nav").removeClass("active").prop("disabled",!0),ut(500,"","reboot_ota")):(r("#reboot_nav").removeClass("active"),ut(500,"",t))};var F,D="https://api.github.com/repos/sle118/squeezelite-esp32/releases",J=!1,W=!1,H="",B={i2s:{b:"500:2000",C:"30",W:"",Z:"96000",o:"I2S"},spdif:{b:"500:2000",C:"30",W:"",Z:"48000",o:"SPDIF"},bt:{b:"500:2000",C:"30",W:"",Z:"44100",o:"BT"}},q={codecs:["flac","pcm","mp3","ogg","aac","wma","alac","dsd","mad","mpg"]},Y=0,z="MESSAGING_INFO",V={},Z=null,K="",Q="",X="Squeezelite-ESP32",$="",tt=X,et="",nt=X,at="",st="#cfg-audio-bt_source-sink_name",ot={},it={},ct="",rt={CONN:0,MAN:1,STS:2};function lt(t){var e={};r("input.nvs").each((function(n,a){if(t)e[a.id]=a.value;else{var s=parseInt(a.attributes.nvs_type.value,10);""!==a.id&&(e[a.id]={},e[a.id].value=s===v||s===g||s===b||s===S||s===_||s===y||s===w||s===T?parseInt(a.value):a.value,e[a.id].type=s)}}));var n=r("#nvs-new-key").val(),a=r("#nvs-new-value").val();return""!==n&&(t?e[n]=a:(e[n]={},e[n].value=a,e[n].type=33)),e}function ut(t,e){var n="/"+(arguments.length>2&&void 0!==arguments[2]?arguments[2]:"reboot")+".json";r("tbody#tasks").empty(),r("#tasks_sect").css("visibility","collapse"),h.resolve({cmdname:e,url:n}).delay(t).then((function(t){t.cmdname.length>0?L(t.cmdname,"MESSAGING_WARNING","System is rebooting.\n",!0):kt("System is rebooting.\n","MESSAGING_WARNING"),console.log("now triggering reboot"),r("button[onclick*='handleReboot']").addClass("rebooting"),r.ajax({url:t.url,dataType:"text",method:"POST",cache:!1,contentType:"application/json; charset=utf-8",data:JSON.stringify({timestamp:Date.now()}),error:U,complete:function(){console.log("reboot call completed"),h.resolve(t).delay(6e3).then((function(t){t.cmdname.length>0&&function(t){r("#toast_"+t).removeClass("table-success").removeClass("table-warning").removeClass("table-danger").addClass("table-success").removeClass("show"),r("#msg_"+t).html("")}(t.cmdname),At(),Ot()}))}})}))}function dt(t){return r(".upf").filter((function(){return r(this).text().toUpperCase()===t.toUpperCase()})).length>0&&(r("#splf").val(t).trigger("input"),!0)}function ht(t,e){var n="cmd_opt_".concat(t),a="".concat(n,"-error"),s=r("#".concat(a)),o=r("#".concat(n));return s&&0!=s.length||(o.after('
')),s=r("#".concat(a))),0==e.length?(s.hide(),o.removeClass("is-invalid"),o.addClass("is-valid"),s.text("")):(s.show(),s.text(e),o.removeClass("is-valid"),o.addClass("is-invalid")),s}function pt(t){return t>=-55?{label:"****",icon:"signal_wifi_statusbar_4_bar"}:t>=-60?{label:"***",icon:"network_wifi_3_bar"}:t>=-65?{label:"**",icon:"network_wifi_2_bar"}:t>=-70?{label:"*",icon:"network_wifi_1_bar"}:{label:".",icon:"signal_wifi_statusbar_null"}}function ft(){var t;(null===(t=ot)||void 0===t?void 0:t.urc)!==N.ETH&&(r.ajaxSetup({timeout:3e3}),r.getJSON("/scan.json",(0,a.Z)(i().mark((function t(){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,xt(2e3);case 2:r.getJSON("/ap.json",(function(t){t.length>0&&(t.sort((function(t,e){var n=t.rssi,a=e.rssi;return na?-1:0})),vt(t))}));case 3:case"end":return t.stop()}}),t)})))))}function mt(t,e,n){var a=pt(e),s={label:0==n?"🔓":"🔒",icon:0==n?"no_encryption":"lock"};return''.concat(t,'\n ').concat(j(a),'\n \t\n ').concat(j(s),"\n ")}function vt(t){var e,n="";if(r("#wifiTable tr td:first-of-type").text(""),r("#wifiTable tr").removeClass("table-success table-warning"),t&&(t.forEach((function(t){n+=mt(t.ssid,t.rssi,t.auth)})),r("#wifiTable").html(n)),0==r(".manual_add").length&&(r("#wifiTable").append(mt("Manual add",0,0)),r("#wifiTable tr:last").addClass("table-light text-dark").addClass("manual_add")),!ot.ssid||ot.urc!==N.OK&&ot.urc!==N.RESTORE)(null===(e=ot)||void 0===e?void 0:e.urc)!==N.ETH&&r("span#foot-if").html("");else{var a,s='#wifiTable td:contains("'.concat(ot.ssid,'")');if(0==r(s).filter((function(){return r(this).text()===ot.ssid})).length)r("#wifiTable").prepend("".concat(mt(ot.ssid,null!==(a=ot.rssi)&&void 0!==a?a:0,0)));r(s).filter((function(){return r(this).text()===ot.ssid})).siblings().first().html("✓").parent().addClass(ot.urc===N.OK?"table-success":"table-warning"),r("span#foot-if").html("SSID: ".concat(ot.ssid,", IP: ").concat(ot.ip,"")),r("#wifiStsIcon").html(pt(ot.rssi))}}function gt(t){console.debug(this.toLocaleString()+"\t"+t.nme+"\t"+t.cpu+"\t"+x[t.st]+"\t"+t.minstk+"\t"+t.bprio+"\t"+t.cprio+"\t"+t.num),r("tbody#tasks").append(''+t.num+""+t.nme+""+t.cpu+""+x[t.st]+""+t.minstk+""+t.bprio+""+t.cprio+"")}function bt(t){return r("".concat(st," option:contains('").concat(t,"')"))}function St(){r.ajaxSetup({timeout:I}),r.getJSON("/messages.json",function(){var t=(0,a.Z)(i().mark((function t(e){var n,a,s,o,c,u,d,h,p,f;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:n=l(e),t.prev=1,s=i().mark((function t(){var e,n;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=a.value,n=e.current_time-e.sent_time,(o=new Date).setTime(o.getTime()-n),t.t0=e.class,t.next="MESSAGING_CLASS_OTA"===t.t0?7:"MESSAGING_CLASS_STATS"===t.t0?9:"MESSAGING_CLASS_SYSTEM"===t.t0?14:"MESSAGING_CLASS_CFGCMD"===t.t0?16:"MESSAGING_CLASS_BT"===t.t0?19:23;break;case 7:return R.EventOTAMessageClass(e.message),t.abrupt("break",24);case 9:return c=JSON.parse(e.message),console.debug(o.toLocalShort()+" - Number of running tasks: "+c.ntasks),console.debug(o.toLocalShort()+"\tname\tcpu\tstate\tminstk\tbprio\tcprio\tnum"),c.tasks?("collapse"===r("#tasks_sect").css("visibility")&&r("#tasks_sect").css("visibility","visible"),r("tbody#tasks").html(""),c.tasks.sort((function(t,e){return e.cpu-t.cpu})).forEach(gt,o)):"visible"===r("#tasks_sect").css("visibility")&&(r("tbody#tasks").empty(),r("#tasks_sect").css("visibility","collapse")),t.abrupt("break",24);case 14:return Nt(e,o),t.abrupt("break",24);case 16:return L((u=e.message.split(/([^\n]*)\n([\s\S]*)/g))[1],e.type,u[2],!0),t.abrupt("break",24);case 19:if(r("#cfg-audio-bt_source-sink_name").is("input")){for(d=r("#cfg-audio-bt_source-sink_name")[0].attributes,h="",p=0;p "))}return JSON.parse(e.message).forEach((function(t){bt(t.name).length>0||(r("#cfg-audio-bt_source-sink_name").append("")),Nt({type:e.type,message:"BT Audio device found: ".concat(t.name," RSSI: ").concat(t.rssi," ")},o)),bt(t.name).attr("data-bs-description","".concat(t.name," (").concat(t.rssi,"dB)")).attr("rssi",t.rssi).attr("value",t.name).text("".concat(t.name," [").concat(t.rssi,"dB]")).trigger("change")})),r(st).append(r("".concat(st," option")).remove().sort((function(t,e){return console.log("".concat(parseInt(r(t).attr("rssi"))," < ").concat(parseInt(r(e).attr("rssi"))," ? ")),parseInt(r(t).attr("rssi"))".concat(ot.ip,"
"))):(r(".if_wifi").show(),vt())),_t(t)}function Tt(){r.ajaxSetup({timeout:2e3}),r.getJSON("/status.json",(function(t){var e;if(function(t){var e;1===(null!==(e=t.recovery)&&void 0!==e?e:0)?(J=!0,r(".recovery_element").show(),r(".ota_element").hide(),r("#boot-button").html("Reboot"),r("#boot-form").attr("action","/reboot_ota.json")):(!J&&W&&(W=!1,setTimeout(St,I)),J=!1,r(".recovery_element").hide(),r(".ota_element").show(),r("#boot-button").html("Recovery"),r("#boot-form").attr("action","/recovery.json"))}(t),f(),wt(t),function(t){var e="",n="";if(void 0!==t.bt_status&&void 0!==t.bt_sub_status){var a=O[t.bt_status].sub[t.bt_sub_status];a?(e=E[a],n=O[t.bt_status].desc):(e=E.bt_connected,n="Output status")}r("#o_type").attr("title",n),r("#o_bt").html(M()?e.label:e.text)}(t),R.EventTargetStatus(t),t.depth&&(16==t.depth?r("#cmd_opt_R").show():r("#cmd_opt_R").hide()),t.project_name&&""!==t.project_name&&(tt=t.project_name),t.platform_name&&""!==t.platform_name&&(nt=t.platform_name),""===et&&(et=tt),""===et&&(et="Squeezelite-ESP32"),t.version&&""!==t.version?(X=t.version,r("#navtitle").html("".concat(et).concat(J?"
[recovery]":"")),r("span#foot-fw").html("fw: ".concat(X,", mode: ").concat(J?"Recovery":tt,""))):r("span#flash-status").html(""),t.Voltage){var n=function(t){for(var e=0,n=A;e
'.concat(e.help.encodeHTML().replace(/\n/g,"
"),'
'),e.argtable&&e.argtable.forEach((function(n){var a=n.datatype||"",s=e.name+"-"+n.longopts,i=Et(t,e.name,n.longopts),c="hasvalue="+n.hasvalue+" ";c+='longopts="'+n.longopts+'" ',c+='shortopts="'+n.shortopts+'" ',c+="checkbox="+n.checkbox+" ",c+='cmdname="'+e.name+'" ',c+='id="'+s+'" name="'+s+'" ',n.longopts&&n.longopts.startsWith("_")&&(c+="readonly ");var r=n.mincount>0?"is-invalid":"";"hidden"===n.glossary&&(c+=' style="visibility: hidden;"'),n.checkbox?o+='
"):n.remark?o+='
"):(o+='
"),a.includes("|")?(r=a.startsWith("+")?" multiple ":"",a=a.replace("<","").replace("=","").replace(">",""),o+=""):o+='")),n.remark||(o+='Previous value: '.concat(n.checkbox?i?"Checked":"Unchecked":i||"","")),o+="
"})),o+='
\n '),o+=a?'\n'):''),o+="
",a?r(s).append(o):r("#commands-list").append(o)}})),r(".sclk").off("click").on("click",(function(){runCommand(this,!1)})),r(".cclk").off("click").on("click",(function(){runCommand(this,!0)})),t.commands.forEach((function(e){r("[cmdname="+e.name+"]:input").val(""),r("[cmdname="+e.name+"]:checkbox").prop("checked",!1),e.argtable&&e.argtable.forEach((function(n){var a="#"+e.name+"-"+n.longopts,s=Et(t,e.name,n.longopts);n.checkbox?r(a)[0].checked=s:n.remark||(void 0!==s&&(r(a).val(s).trigger("change"),n.mincount&&n.mincount>0&&(r(a).removeClass("is-invalid"),r(a).addClass("is-valid"))),0===r(a)[0].value.length&&(n.datatype||"").includes("|")&&(r(a)[0].value="--"))}))})),0!=r("#cfg-hw-preset-model_config").length&&(C||(C=!0,r("#cfg-hw-preset-model_config").html(""),r.getJSON("https://gist.githubusercontent.com/sle118/dae585e157b733a639c12dc70f0910c5/raw/",{_:(new Date).getTime()},(function(t){r.each(t,(function(t,e){r("#cfg-hw-preset-model_config").append("")),""!==at&&at==e.name&&r("#cfg-hw-preset-model_config").val(at)})),""!==at&&"#prev_preset".show().val(at)})).fail((function(t,e,n){var a=e+", "+n;console.log("Request Failed: "+a)}))))})).fail((function(t,e,n){404==t.status?r(".orec").hide():U(t,0,n),r("#commands-list").empty()}))}function Ot(){r.ajaxSetup({timeout:7e3}),r.getJSON("/config.json",(function(t){r("#nvsTable tr").remove();var e=t.config?t.config:t;V=e,H="",Object.keys(e).sort().forEach((function(t){var n=e[t].value;"autoexec"===t||("host_name"===t?(n=n.replaceAll('"',""),r("input#dhcp-name1").val(n),r("input#dhcp-name2").val(n),0==r("#cmd_opt_n").length&&r("#cmd_opt_n").val(n),document.title=n,Q=n):"rel_api"===t?D=n:"enable_airplay"===t?r("#s_airplay").css({display:m(n)?"inline":"none"}):"enable_cspot"===t?r("#s_cspot").css({display:m(n)?"inline":"none"}):"preset_name"==t?at=n:"board_model"==t&&(et=n)),r("tbody#nvsTable").append(""+t+""),r("input#"+t).val(e[t].value)})),H.length>0&&r("#cfg-audio-bt_source-sink_name").val(H),r("tbody#nvsTable").append(""),t.gpio?(r("#pins").show(),r("tbody#gpiotable tr").remove(),t.gpio.forEach((function(t){r("tbody#gpiotable").append("'+t.group+""+t.name+""+t.gpio+""+(t.fixed?"Fixed":"Configuration")+"")}))):r("#pins").hide()})).fail((function(t,e,n){U(t,0,n)}))}function kt(t,e){Nt({message:t,type:e},new Date)}function Nt(t,e){var n="table-success";"MESSAGING_WARNING"===t.type?(n="table-warning","MESSAGING_INFO"===z&&(z="MESSAGING_WARNING")):"MESSAGING_ERROR"===t.type&&("MESSAGING_INFO"!==z&&"MESSAGING_WARNING"!==z||(z="MESSAGING_ERROR"),n="table-danger"),++Y>0&&(r("#msgcnt").removeClass("badge-success"),r("#msgcnt").removeClass("badge-warning"),r("#msgcnt").removeClass("badge-danger"),r("#msgcnt").addClass(k[z]),r("#msgcnt").text(Y)),r("#syslogTable").append(""+e.toLocalShort()+""+t.message.encodeHTML()+"")}function xt(t){return new h((function(e){return setTimeout(e,t)}))}h.prototype.delay=function(t){return this.then((function(e){return new h((function(n){setTimeout((function(){n(e)}),t)}))}),(function(e){return new h((function(n,a){setTimeout((function(){a(e)}),t)}))}))},window.saveAutoexec1=function(t){L("cfg-audio-tmpl","MESSAGING_INFO","Saving.\n",!1);var e="".concat("squeezelite "," -o ").concat(K," ");r(".sqcmd").each((function(){var t=p(r(this)),n=t.opt,a=t.val;if(n&&n.length>0&&"boolean"==typeof a||a.length>0){var s=":"===n?n:" -".concat(n," ");a="boolean"==typeof a?"":a,e+="".concat(s," ").concat(a)}}));var n=r("#cmd_opt_R input[name=resample]:checked");n.length>0&&""!==n.attr("suffix")&&(e+=n.attr("suffix"),r("#resample_i").is(":checked")&&"true"==n.attr("aint")&&(e+=r("#resample_i").attr("suffix"))),"bt"===K&&L("cfg-audio-tmpl","MESSAGING_INFO","Remember to configure the Bluetooth audio device name.\n",!0),e+=function(t){for(var e=" ",n=0,a=Object.entries(t);n8&&(r(this).val().startsWith("http://")||r(this).val().startsWith("https://"))?r("#start-flash").show():r("#start-flash").hide()})),r(".upSrch").on("input",(function(){var t=this.value;r("#rTable tr").removeClass(this.id+"_hide"),t.length>0&&r("#rTable td:nth-child(".concat(r(this).parent().index()+1,")")).filter((function(){return!r(this).text().toUpperCase().includes(t.toUpperCase())})).parent().addClass(this.id+"_hide"),r('[class*="_hide"]').hide(),r("#rTable tr").not('[class*="_hide"]').show()})),setTimeout(ft,1500),r("#options input").on("input",(function(){var t=p(this),e=t.opt,n=t.val;if("c"===e||"e"===e){"cmd_opt_".concat(e,"_codec-error");var a=n.split(",").map((function(t){return t.trim()})).filter((function(t){return!q.codecs.includes(t)}));ht(e,a.length>0?"Invalid codec(s) ".concat(a.join(", ")):"")}if("m"===e){ht(e,/^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$/.test(n)?"":"Invalid MAC address")}if("r"===e){ht(e,/^(\d+\.?\d*|\.\d+)-(\d+\.?\d*|\.\d+)$|^(\d+\.?\d*)$|^(\d+\.?\d*,)+\d+\.?\d*$/.test(n)?"":"Invalid rate(s) ".concat(n,". Acceptable format: |-|,,"))}})),r("#WifiConnectDialog")[0].addEventListener("shown.bs.modal",(function(t){r("*[class*='connecting']").hide(),null!=t&&t.relatedTarget&&(it.Action=rt.CONN,r(t.relatedTarget).children("td:eq(1)").text()==ot.ssid?it.Action=rt.STS:r(t.relatedTarget).is(":last-child")?(it.Action=rt.MAN,it.ssid="",r("#manual_ssid").val(it.ssid)):(it.ssid=r(t.relatedTarget).children("td:eq(1)").text(),r("#manual_ssid").val(it.ssid))),it.Action!==rt.STS?(r(".connecting-init").show(),r("#manual_ssid").trigger("focus")):_t()})),r("#WifiConnectDialog")[0].addEventListener("hidden.bs.modal",(function(){r("#WifiConnectDialog input").val("")})),r("#uCnfrm")[0].addEventListener("shown.bs.modal",(function(){r("#selectedFWURL").text(r("#fw-url-input").val())})),r("input#show-commands")[0].checked=1===Z,r('a[href^="#tab-commands"]').hide(),r("#load-nvs").on("click",(function(){r("#nvsfilename").trigger("click")})),r("#nvsfilename").on("change",(function(){if("function"!=typeof window.FileReader)throw"The file API isn't supported on this browser.";if(!this.files)throw"This browser does not support the `files` property of the file input.";if(this.files[0]){var t=this.files[0],e=new FileReader;e.onload=function(t){var e={};try{e=JSON.parse(t.target.result)}catch(t){alert("Parsing failed!\r\n "+t)}r("input.nvs").each((function(t,n){r(this).parent().removeClass("bg-warning").removeClass("bg-success"),e[n.id]&&(e[n.id]!==n.value?(console.log("Changed "+n.id+" "+n.value+"==>"+e[n.id]),r(this).parent().addClass("bg-warning"),r(this).val(e[n.id])):r(this).parent().addClass("bg-success"))})),r("input.nvs").children(".bg-warning")&&alert("Highlighted values were changed. Press Commit to change on the device")},e.readAsText(t),this.value=null}})),r("#clear-syslog").on("click",(function(){Y=0,z="MESSAGING_INFO",r("#msgcnt").text(""),r("#syslogTable").html("")})),r("#ok-credits").on("click",(function(){r("#credits").slideUp("fast",(function(){})),r("#app").slideDown("fast",(function(){}))})),r("#acredits").on("click",(function(t){t.preventDefault(),r("#app").slideUp("fast",(function(){})),r("#credits").slideDown("fast",(function(){}))})),r("input#show-commands").on("click",(function(){this.checked=this.checked?1:0,this.checked?(r('a[href^="#tab-commands"]').show(),Z=1):(Z=0,r('a[href^="#tab-commands"]').hide())})),r("#disable-squeezelite").on("click",(function(){if(this.checked){var t=r("#cmd_opt_s").val();r("#cmd_opt_s").data("originalValue",t),r("#cmd_opt_s").val("-disable")}else{var e=r("#cmd_opt_s").data("originalValue");r("#cmd_opt_s").val(e||"")}})),r("input#show-nvs").on("click",(function(){this.checked=this.checked?1:0,c.Z.set("show-nvs",this.checked?"Y":"N"),f()})),r("#btn_reboot_recovery").on("click",(function(){handleReboot("recovery")})),r("#btn_reboot").on("click",(function(){handleReboot("reboot")})),r("#btn_flash").on("click",(function(){hFlash()})),r("#save-autoexec1").on("click",(function(){saveAutoexec1(!1)})),r("#commit-autoexec1").on("click",(function(){saveAutoexec1(!0)})),r("#btn_disconnect").on("click",(function(){ot={},vt(),r.ajax({url:"/connect.json",dataType:"text",method:"DELETE",cache:!1,contentType:"application/json; charset=utf-8",data:JSON.stringify({timestamp:Date.now()})})})),r("#btnJoin").on("click",(function(){handleConnect()})),r("#reboot_nav").on("click",(function(){handleReboot("reboot")})),r("#reboot_ota_nav").on("click",(function(){handleReboot("reboot_ota")})),r("#save-as-nvs").on("click",(function(){var t=lt(!0),e=document.createElement("a");e.href=URL.createObjectURL(new Blob([JSON.stringify(t,null,2)],{type:"text/plain"})),e.setAttribute("download","nvs_config_"+Q+"_"+Date.now()+"json"),document.body.appendChild(e),e.click(),document.body.removeChild(e)})),r("#save-nvs").on("click",(function(){G(lt(!1))})),r("#fwUpload").on("click",(function(){0===document.getElementById("flashfilename").files.length?alert("No file selected!"):(r("#fw-url-input").value=null,R.StartOTA())})),r("[name=output-tmpl]").on("click",(function(){P(this.id)})),r("#chkUpdates").on("click",(function(){r("#rTable").html(""),r.getJSON(D,(function(t){var e=[];t.forEach((function(t){var n=t.name.split("#")[3];e.includes(n)||e.push(n)}));var n="";e.forEach((function(t){n+='"})),r("#fwbranch").append(n),t.forEach((function(t){var e="";t.assets.forEach((function(t){t.name.match(/\.bin$/)&&(e=t.browser_download_url)}));var n=t.name.split("#"),a=n[0],s=n[2],o=n[3],i=a.substr(a.lastIndexOf("-")+1);i="32"==i||"16"==i?i:"";var c=t.body;c=(c=(c=c.replace(/'/gi,'"')).replace(/[\s\S]+(### Revision Log[\s\S]+)### ESP-IDF Version Used[\s\S]+/,"$1")).replace(/- \(.+?\) /g,"- ").encodeHTML(),r("#rTable").append("\n ").concat(a,"").concat(new Date(t.created_at).toLocalShort(),"\n ").concat(s,"").concat(o,"").concat(i,""))})),r("#searchfw").css("display","inline"),dt(nt)||dt(tt),r("#rTable tr.release").on("click",(function(){var t=this.attributes.fwurl.value;F&&(t=t.replace(/.*\/download\//,F+"/plugins/SqueezeESP32/firmware/")),r("#fw-url-input").val(t),r("#start-flash").show(),r("#rTable tr.release").removeClass("table-success table-warning"),r(this).addClass("table-success table-warning")}))})).fail((function(){alert("failed to fetch release history!")}))})),r("#fwcheck").on("click",(function(){r("#releaseTable").html(""),r("#fwbranch").empty(),r.getJSON(D,(function(t){var e,n=0,a=[];t.forEach((function(t){var e=t.name.split("#")[3];a.includes(e)||a.push(e)})),a.forEach((function(t){e+='"})),r("#fwbranch").append(e),t.forEach((function(t){var e="";t.assets.forEach((function(t){t.name.match(/\.bin$/)&&(e=t.browser_download_url)}));var a=t.name.split("#"),s=a[0],o=a[1],i=a[2],c=a[3],l=t.body;l=(l=(l=l.replace(/'/gi,'"')).replace(/[\s\S]+(### Revision Log[\s\S]+)### ESP-IDF Version Used[\s\S]+/,"$1")).replace(/- \(.+?\) /g,"- ");var u=n++>6?" hide":"";r("#releaseTable").append(""+s+""+new Date(t.created_at).toLocalShort()+""+i+""+o+""+c+"")})),n>7&&(r("#releaseTable").append(""),r("#showallbutton").on("click",(function(){r("tr.hide").removeClass("hide"),r("tr#showall").addClass("hide")}))),r("#searchfw").css("display","inline")})).fail((function(){alert("failed to fetch release history!")}))})),r("#updateAP").on("click",(function(){ft(),console.log("refresh AP")})),Ot(),At(),St(),Tt()})),window.setURL=function(t){var e=t.dataset.url;r('[data-bs-url^="http"]').addClass("btn-success").removeClass("btn-danger"),r('[data-bs-url="'+e+'"]').addClass("btn-danger").removeClass("btn-success"),F&&(e=e.replace(/.*\/download\//,F+"/plugins/SqueezeESP32/firmware/")),r("#fwurl").val(e)},window.runCommand=function(t,e){var n=t.attributes.cmdname.value;L(t.attributes.cmdname.value,"MESSAGING_INFO","Executing.",!1);var a=document.getElementById("flds-"+n),o=null==a?void 0:a.querySelectorAll("select,input");if("cfg-hw-preset"===n)return function(t,e){var n=JSON.parse(t[0].value),a=t[0].attributes.cmdname.value;console.log("selected model: ".concat(n.name));for(var o={timestamp:Date.now(),config:{model_config:{value:n.name,type:33}}},i=0,c=Object.entries(n.config);i{n.r(e)},607:(t,e,n)=>{n(138),n(393),n(861),n(322)},861:t=>{t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAAb1BMVEXIycuswsKMjI4rqqZyc3RQlpQ6jIEmJifW2dq5ursppJ8Om4zC0NAFdGYmmpb///8Hg3O4x8cHkoEggX0jko5Ks6/P0dM5r6ocoZb3+PgiiYVevrp/y8bg4uOS09FtxMDs7+7M6um529qoysik2tiNn72gAAAAF3RSTlP94Fr/Wf39BP26/////////////////kibhL0AAAGjSURBVDjLbZMJkoMgEEWtmETEJWpkiSC45P5nnF4wk7HmW2jLfzYIdFYUxbXUYp5nIbTOUFoLAR2ivIKZFQXYuu6TahSHmdAlAqWub0/QNI1jSxrHacKeWw9EdtH1xHbbyiRgCJn67JqVAr9nO2fJnBDMoUuYEvsfmxnJBM66Zj8/iYmaAPKlOvRNJAC/fz8OefINEAngAbYPEMiHTJCCAZrACciVMpCCgDEBKwsAowymMO3IAP3Btqa5vYJx0ZlcOSUZaE/AWznvnTHOyfZ/wMUQvAIg/wb27QNEH94BgGj+APsZiF8AXAhQQEMwkIYYLW7xvsENoyUoF0I0ysf0F2O743kDQNXzXM8+j8Eb6byzDEz7gtpsO1PgrXG5Nd6btNTP+YXarKTny1uQ9JiAN6vbqT9au+BzMQjAWtlq6BiYttdjiVVVqfXxWFWFkk6Cz0DTdYOFPmpHAAK/YQCJoTppQJ8A3TAxVAAhR439Bg5tKe7NgSDEje3mDsf+ovuGCUbYZb/BwoHS6ykHMYfo/U6lx8Xb/+qo3U/x/lf+VP9c/j9c3zy20WEMxgAAAABJRU5ErkJggg=="}},n={};function a(t){var s=n[t];if(void 0!==s)return s.exports;var o=n[t]={id:t,loaded:!1,exports:{}};return e[t].call(o.exports,o,o.exports,a),o.loaded=!0,o.exports}a.m=e,t=[],a.O=(e,n,s,o)=>{if(!n){var i=1/0;for(u=0;u=o)&&Object.keys(a.O).every((t=>a.O[t](n[r])))?n.splice(r--,1):(c=!1,o0&&t[u-1][2]>o;u--)t[u]=t[u-1];t[u]=[n,s,o]},a.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return a.d(e,{a:e}),e},a.d=(t,e)=>{for(var n in e)a.o(e,n)&&!a.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},a.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),a.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),a.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},a.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),(()=>{var t={826:0};a.O.j=e=>0===t[e];var e=(e,n)=>{var s,o,[i,c,r]=n,l=0;if(i.some((e=>0!==t[e]))){for(s in c)a.o(c,s)&&(a.m[s]=c[s]);if(r)var u=r(a)}for(e&&e(n);la(607)));s=a.O(s)})(); +//# sourceMappingURL=index.1d06b9.bundle.js.map \ No newline at end of file diff --git a/components/wifi-manager/webapp/dist/js/index.4135c4.bundle.js.gz b/components/wifi-manager/webapp/dist/js/index.1d06b9.bundle.js.gz similarity index 59% rename from components/wifi-manager/webapp/dist/js/index.4135c4.bundle.js.gz rename to components/wifi-manager/webapp/dist/js/index.1d06b9.bundle.js.gz index 853756c20..a53e7cffd 100644 Binary files a/components/wifi-manager/webapp/dist/js/index.4135c4.bundle.js.gz and b/components/wifi-manager/webapp/dist/js/index.1d06b9.bundle.js.gz differ diff --git a/components/wifi-manager/webapp/dist/js/index.1d06b9.bundle.js.map b/components/wifi-manager/webapp/dist/js/index.1d06b9.bundle.js.map new file mode 100644 index 000000000..45a91a4ce --- /dev/null +++ b/components/wifi-manager/webapp/dist/js/index.1d06b9.bundle.js.map @@ -0,0 +1 @@ +{"version":3,"file":"./js/index.1d06b9.bundle.js","mappings":"uBAAIA,E,omCCAJ,IAAIC,EAAKC,EAAQ,KACbC,EAAUD,EAAAA,KAAAA,QA6Bd,SAASE,EAAyBC,GAChC,IAAIC,EAAKC,EAAGC,EAAIC,EAoBhB,MAjBqB,iBAATJ,EAEVC,EAAOI,EAAE,IAADC,OADRJ,EAAKF,KAGLE,EAAKG,EAAEL,GAAKO,KAAK,MACjBN,EAAOI,EAAEL,IAEc,aAAtBC,EAAKM,KAAK,SACXH,EAAMC,EAAEL,GAAKQ,QAAQN,EAAGO,QAAQ,WAAY,IAAI,GAChDN,GAAM,IAGNC,EAAMF,EAAGO,QAAQ,WAAY,IAC7BN,EAAME,EAAEL,GAAKG,MACbA,EAAM,GAAHG,OAAMH,EAAIO,SAAS,KAAO,IAAM,IAAEJ,OAAGH,GAAGG,OAAGH,EAAIO,SAAS,KAAO,IAAM,KAGnE,CAAEN,IAAAA,EA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B,CAACC,EAA4Bzd,KACvD,IAGIwb,EAAU+B,GAHTvB,EAAU0B,EAAaC,GAAW3d,EAGhBuZ,EAAI,EAC3B,GAAGyC,EAAS4B,MAAMllB,GAAgC,IAAxB4kB,EAAgB5kB,KAAa,CACtD,IAAI8iB,KAAYkC,EACZnC,EAAoBpU,EAAEuW,EAAalC,KACrCD,EAAoBO,EAAEN,GAAYkC,EAAYlC,IAGhD,GAAGmC,EAAS,IAAI9H,EAAS8H,EAAQpC,EAClC,CAEA,IADGkC,GAA4BA,EAA2Bzd,GACrDuZ,EAAIyC,EAASja,OAAQwX,IACzBgE,EAAUvB,EAASzC,GAChBgC,EAAoBpU,EAAEmW,EAAiBC,IAAYD,EAAgBC,IACrED,EAAgBC,GAAS,KAE1BD,EAAgBC,GAAW,EAE5B,OAAOhC,EAAoBQ,EAAElG,EAAO,EAGjCgI,EAAqBC,KAAoC,8BAAIA,KAAoC,+BAAK,GAC1GD,EAAmBlY,QAAQ6X,EAAqBta,KAAK,KAAM,IAC3D2a,EAAmBlF,KAAO6E,EAAqBta,KAAK,KAAM2a,EAAmBlF,KAAKzV,KAAK2a,G,KC7CvF,IAAIE,EAAsBxC,EAAoBQ,OAAEpiB,EAAW,CAAC,MAAM,IAAO4hB,EAAoB,OAC7FwC,EAAsBxC,EAAoBQ,EAAEgC,E","sources":["webpack://squeezelite-esp32/webpack/runtime/chunk loaded","webpack://squeezelite-esp32/./src/js/custom.js","webpack://squeezelite-esp32/./src/index.ts","webpack://squeezelite-esp32/webpack/bootstrap","webpack://squeezelite-esp32/webpack/runtime/compat get default export","webpack://squeezelite-esp32/webpack/runtime/define property getters","webpack://squeezelite-esp32/webpack/runtime/global","webpack://squeezelite-esp32/webpack/runtime/hasOwnProperty shorthand","webpack://squeezelite-esp32/webpack/runtime/make namespace object","webpack://squeezelite-esp32/webpack/runtime/node module decorator","webpack://squeezelite-esp32/webpack/runtime/jsonp chunk loading","webpack://squeezelite-esp32/webpack/startup"],"sourcesContent":["var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var he = require('he');\r\nvar Promise = require('es6-promise').Promise;\r\nwindow.bootstrap = require('bootstrap');\r\nimport Cookies from 'js-cookie';\r\n\r\n\r\n\r\nif (!String.prototype.format) {\r\n Object.assign(String.prototype, {\r\n format() {\r\n const args = arguments;\r\n return this.replace(/{(\\d+)}/g, function (match, number) {\r\n return typeof args[number] !== 'undefined' ? args[number] : match;\r\n });\r\n },\r\n });\r\n}\r\nif (!String.prototype.encodeHTML) {\r\n Object.assign(String.prototype, {\r\n encodeHTML() {\r\n return he.encode(this).replace(/\\n/g, '
');\r\n },\r\n });\r\n}\r\nObject.assign(Date.prototype, {\r\n toLocalShort() {\r\n const opt = { dateStyle: 'short', timeStyle: 'short' };\r\n return this.toLocaleString(undefined, opt);\r\n },\r\n});\r\nfunction get_control_option_value(obj) {\r\n let ctrl,id,val,opt;\r\n let radio = false;\r\n let checked = false;\r\n if (typeof (obj) === 'string') {\r\n id = obj;\r\n ctrl = $(`#${id}`);\r\n } else {\r\n id = $(obj).attr('id');\r\n ctrl = $(obj);\r\n }\r\n if(ctrl.attr('type') === 'checkbox'){\r\n opt = $(obj).checked?id.replace('cmd_opt_', ''):'';\r\n val = true;\r\n }\r\n else {\r\n opt = id.replace('cmd_opt_', '');\r\n val = $(obj).val();\r\n val = `${val.includes(\" \") ? '\"' : ''}${val}${val.includes(\" \") ? '\"' : ''}`;\r\n }\r\n\r\n return { opt, val };\r\n}\r\nfunction handleNVSVisible() {\r\n let nvs_previous_checked = isEnabled(Cookies.get(\"show-nvs\"));\r\n $('input#show-nvs')[0].checked = nvs_previous_checked;\r\n if ($('input#show-nvs')[0].checked || recovery) {\r\n $('*[href*=\"-nvs\"]').show();\r\n } else {\r\n $('*[href*=\"-nvs\"]').hide();\r\n }\r\n}\r\nfunction concatenateOptions(options) {\r\n let commandLine = ' ';\r\n for (const [option, value] of Object.entries(options)) {\r\n if (option !== 'n' && option !== 'o') {\r\n commandLine += `-${option} `;\r\n if (value !== true) {\r\n commandLine += `${value} `;\r\n }\r\n }\r\n }\r\n return commandLine;\r\n}\r\n\r\nfunction isEnabled(val) {\r\n return val != undefined && typeof val === 'string' && val.match(\"[Yy1]\");\r\n}\r\n\r\nconst nvsTypes = {\r\n NVS_TYPE_U8: 0x01,\r\n /*! < Type uint8_t */\r\n NVS_TYPE_I8: 0x11,\r\n /*! < Type int8_t */\r\n NVS_TYPE_U16: 0x02,\r\n /*! < Type uint16_t */\r\n NVS_TYPE_I16: 0x12,\r\n /*! < Type int16_t */\r\n NVS_TYPE_U32: 0x04,\r\n /*! < Type uint32_t */\r\n NVS_TYPE_I32: 0x14,\r\n /*! < Type int32_t */\r\n NVS_TYPE_U64: 0x08,\r\n /*! < Type uint64_t */\r\n NVS_TYPE_I64: 0x18,\r\n /*! < Type int64_t */\r\n NVS_TYPE_STR: 0x21,\r\n /*! < Type string */\r\n NVS_TYPE_BLOB: 0x42,\r\n /*! < Type blob */\r\n NVS_TYPE_ANY: 0xff /*! < Must be last */,\r\n};\r\nconst btIcons = {\r\n bt_playing: { 'label': '', 'icon': 'media_bluetooth_on' },\r\n bt_disconnected: { 'label': '', 'icon': 'media_bluetooth_off' },\r\n bt_neutral: { 'label': '', 'icon': 'bluetooth' },\r\n bt_connecting: { 'label': '', 'icon': 'bluetooth_searching' },\r\n bt_connected: { 'label': '', 'icon': 'bluetooth_connected' },\r\n bt_disabled: { 'label': '', 'icon': 'bluetooth_disabled' },\r\n play_arrow: { 'label': '', 'icon': 'play_circle_filled' },\r\n pause: { 'label': '', 'icon': 'pause_circle' },\r\n stop: { 'label': '', 'icon': 'stop_circle' },\r\n '': { 'label': '', 'icon': '' }\r\n};\r\nconst batIcons = [\r\n { icon: \"battery_0_bar\", label: '▪', ranges: [{ f: 5.8, t: 6.8 }, { f: 8.8, t: 10.2 }] },\r\n { icon: \"battery_2_bar\", label: '▪▪', ranges: [{ f: 6.8, t: 7.4 }, { f: 10.2, t: 11.1 }] },\r\n { icon: \"battery_3_bar\", label: '▪▪▪', ranges: [{ f: 7.4, t: 7.5 }, { f: 11.1, t: 11.25 }] },\r\n { icon: \"battery_4_bar\", label: '▪▪▪▪', ranges: [{ f: 7.5, t: 7.8 }, { f: 11.25, t: 11.7 }] }\r\n];\r\nconst btStateIcons = [\r\n { desc: 'Idle', sub: ['bt_neutral'] },\r\n { desc: 'Discovering', sub: ['bt_connecting'] },\r\n { desc: 'Discovered', sub: ['bt_connecting'] },\r\n { desc: 'Unconnected', sub: ['bt_disconnected'] },\r\n { desc: 'Connecting', sub: ['bt_connecting'] },\r\n {\r\n desc: 'Connected',\r\n sub: ['bt_connected', 'play_arrow', 'bt_playing', 'pause', 'stop'],\r\n },\r\n { desc: 'Disconnecting', sub: ['bt_disconnected'] },\r\n];\r\n\r\nconst pillcolors = {\r\n MESSAGING_INFO: 'badge-success',\r\n MESSAGING_WARNING: 'badge-warning',\r\n MESSAGING_ERROR: 'badge-danger',\r\n};\r\nconst connectReturnCode = {\r\n OK: 0,\r\n FAIL: 1,\r\n DISC: 2,\r\n LOST: 3,\r\n RESTORE: 4,\r\n ETH: 5\r\n}\r\nconst taskStates = {\r\n 0: 'eRunning',\r\n /*! < A task is querying the state of itself, so must be running. */\r\n 1: 'eReady',\r\n /*! < The task being queried is in a read or pending ready list. */\r\n 2: 'eBlocked',\r\n /*! < The task being queried is in the Blocked state. */\r\n 3: 'eSuspended',\r\n /*! < The task being queried is in the Suspended state, or is in the Blocked state with an infinite time out. */\r\n 4: 'eDeleted',\r\n};\r\nlet flashState = {\r\n NONE: 0,\r\n REBOOT_TO_RECOVERY: 2,\r\n SET_FWURL: 5,\r\n FLASHING: 6,\r\n DONE: 7,\r\n UPLOADING: 8,\r\n ERROR: 9,\r\n UPLOADCOMPLETE: 10,\r\n _state: -1,\r\n olderRecovery: false,\r\n statusText: '',\r\n flashURL: '',\r\n flashFileName: '',\r\n statusPercent: 0,\r\n Completed: false,\r\n recovery: false,\r\n prevRecovery: false,\r\n updateModal: new bootstrap.Modal(document.getElementById('otadiv'), {}),\r\n reset: function () {\r\n\r\n this.olderRecovery = false;\r\n this.statusText = '';\r\n this.statusPercent = -1;\r\n this.flashURL = '';\r\n this.flashFileName = undefined;\r\n this.UpdateProgress();\r\n $('#rTable tr.release').removeClass('table-success table-warning');\r\n $('.flact').prop('disabled', false);\r\n $('#flashfilename').value = null;\r\n $('#fw-url-input').value = null;\r\n if (!this.isStateError()) {\r\n $('span#flash-status').html('');\r\n $('#fwProgressLabel').parent().removeClass('bg-danger');\r\n }\r\n this._state = this.NONE\r\n return this;\r\n },\r\n isStateUploadComplete: function () {\r\n return this._state == this.UPLOADCOMPLETE;\r\n },\r\n isStateError: function () {\r\n return this._state == this.ERROR;\r\n },\r\n isStateNone: function () {\r\n return this._state == this.NONE;\r\n },\r\n isStateRebootRecovery: function () {\r\n return this._state == this.REBOOT_TO_RECOVERY;\r\n },\r\n isStateSetUrl: function () {\r\n return this._state == this.SET_FWURL;\r\n },\r\n isStateFlashing: function () {\r\n return this._state == this.FLASHING;\r\n },\r\n isStateDone: function () {\r\n return this._state == this.DONE;\r\n },\r\n isStateUploading: function () {\r\n return this._state == this.UPLOADING;\r\n },\r\n init: function () {\r\n this._state = this.NONE;\r\n return this;\r\n },\r\n\r\n SetStateError: function () {\r\n this._state = this.ERROR;\r\n $('#fwProgressLabel').parent().addClass('bg-danger');\r\n return this;\r\n },\r\n SetStateNone: function () {\r\n this._state = this.NONE;\r\n return this;\r\n },\r\n SetStateRebootRecovery: function () {\r\n this._state = this.REBOOT_TO_RECOVERY;\r\n // Reboot system to recovery mode\r\n this.SetStatusText('Starting recovery mode.')\r\n $.ajax({\r\n url: '/recovery.json',\r\n context: this,\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify({\r\n timestamp: Date.now(),\r\n }),\r\n error: function (xhr, _ajaxOptions, thrownError) {\r\n this.setOTAError(`Unexpected error while trying to restart to recovery. (status=${xhr.status ?? ''}, error=${thrownError ?? ''} ) `);\r\n },\r\n complete: function (response) {\r\n this.SetStatusText('Waiting for system to boot.')\r\n },\r\n });\r\n return this;\r\n },\r\n SetStateSetUrl: function () {\r\n this._state = this.SET_FWURL;\r\n this.statusText = 'Sending firmware download location.';\r\n let confData = {\r\n fwurl: {\r\n value: this.flashURL,\r\n type: 33,\r\n }\r\n };\r\n post_config(confData);\r\n return this;\r\n },\r\n SetStateFlashing: function () {\r\n this._state = this.FLASHING;\r\n return this;\r\n },\r\n SetStateDone: function () {\r\n this._state = this.DONE;\r\n this.reset();\r\n return this;\r\n },\r\n SetStateUploading: function () {\r\n this._state = this.UPLOADING;\r\n return this.SetStatusText('Sending file to device.');\r\n },\r\n SetStateUploadComplete: function () {\r\n this._state = this.UPLOADCOMPLETE;\r\n return this;\r\n },\r\n\r\n isFlashExecuting: function () {\r\n return true === (this._state != this.UPLOADING && (this.statusText !== '' || this.statusPercent >= 0));\r\n },\r\n\r\n\r\n\r\n toString: function () {\r\n let keys = Object.keys(this);\r\n return keys.find(x => this[x] === this._state);\r\n },\r\n\r\n setOTATargets: function () {\r\n this.flashURL = '';\r\n this.flashFileName = '';\r\n this.flashURL = $('#fw-url-input').val();\r\n let fileInput = $('#flashfilename')[0].files;\r\n if (fileInput.length > 0) {\r\n this.flashFileName = fileInput[0];\r\n }\r\n if (this.flashFileName.length == 0 && this.flashURL.length == 0) {\r\n this.setOTAError('Invalid url or file. Cannot start OTA');\r\n }\r\n return this;\r\n },\r\n\r\n setOTAError: function (message) {\r\n this.SetStateError().SetStatusPercent(0).SetStatusText(message).reset();\r\n return this;\r\n },\r\n\r\n ShowDialog: function () {\r\n if (!this.isStateNone()) {\r\n this.updateModal.show();\r\n $('.flact').prop('disabled', true);\r\n }\r\n return this;\r\n },\r\n\r\n SetStatusPercent: function (pct) {\r\n var pctChanged = (this.statusPercent != pct);\r\n this.statusPercent = pct;\r\n if (pctChanged) {\r\n if (!this.isStateUploading() && !this.isStateFlashing()) {\r\n this.SetStateFlashing();\r\n }\r\n if (pct == 100) {\r\n if (this.isStateFlashing()) {\r\n this.SetStateDone();\r\n }\r\n else if (this.isStateUploading()) {\r\n this.statusPercent = 0;\r\n this.SetStateFlashing();\r\n }\r\n }\r\n this.UpdateProgress().ShowDialog();\r\n }\r\n return this;\r\n },\r\n SetStatusText: function (txt) {\r\n var changed = (this.statusText != txt);\r\n this.statusText = txt;\r\n if (changed) {\r\n $('span#flash-status').html(this.statusText);\r\n this.ShowDialog();\r\n }\r\n\r\n return this;\r\n },\r\n UpdateProgress: function () {\r\n $('.progress-bar')\r\n .css('width', this.statusPercent + '%')\r\n .attr('aria-valuenow', this.statusPercent)\r\n .text(this.statusPercent + '%')\r\n $('.progress-bar').html((this.isStateDone() ? 100 : this.statusPercent) + '%');\r\n return this;\r\n },\r\n StartOTA: function () {\r\n this.logEvent(this.StartOTA.name);\r\n $('#fwProgressLabel').parent().removeClass('bg-danger');\r\n this.setOTATargets();\r\n if (this.isStateError()) {\r\n return this;\r\n }\r\n if (!recovery) {\r\n this.SetStateRebootRecovery();\r\n }\r\n else {\r\n this.SetStateFlashing().TargetReadyStartOTA();\r\n }\r\n\r\n return this;\r\n },\r\n UploadLocalFile: function () {\r\n this.SetStateUploading();\r\n const xhttp = new XMLHttpRequest();\r\n xhttp.context = this;\r\n var boundHandleUploadProgressEvent = this.HandleUploadProgressEvent.bind(this);\r\n var boundsetOTAError = this.setOTAError.bind(this);\r\n xhttp.upload.addEventListener(\"progress\", boundHandleUploadProgressEvent, false);\r\n xhttp.onreadystatechange = function () {\r\n if (xhttp.readyState === 4) {\r\n if (xhttp.status === 0 || xhttp.status === 404) {\r\n boundsetOTAError(`Upload Failed. Recovery version might not support uploading. Please use web update instead.`);\r\n }\r\n }\r\n };\r\n xhttp.open('POST', '/flash.json', true);\r\n xhttp.send(this.flashFileName);\r\n },\r\n TargetReadyStartOTA: function () {\r\n if (recovery && this.prevRecovery && !this.isStateRebootRecovery() && !this.isStateFlashing()) {\r\n // this should only execute once, while being in a valid state\r\n return this;\r\n }\r\n\r\n this.logEvent(this.TargetReadyStartOTA.name);\r\n if (!recovery) {\r\n console.error('Event TargetReadyStartOTA fired in the wrong mode ');\r\n return this;\r\n }\r\n this.prevRecovery = true;\r\n\r\n if (this.flashFileName !== '') {\r\n this.UploadLocalFile();\r\n }\r\n else if (this.flashURL != '') {\r\n this.SetStateSetUrl();\r\n }\r\n else {\r\n this.setOTAError('Invalid URL or file name while trying to start the OTa process')\r\n }\r\n },\r\n HandleUploadProgressEvent: function (data) {\r\n this.logEvent(this.HandleUploadProgressEvent.name);\r\n this.SetStateUploading().SetStatusPercent(Math.round(data.loaded / data.total * 100)).SetStatusText('Uploading file to device');\r\n },\r\n EventTargetStatus: function (data) {\r\n if (!this.isStateNone()) {\r\n this.logEvent(this.EventTargetStatus.name);\r\n }\r\n if (data.ota_pct ?? -1 >= 0) {\r\n this.olderRecovery = true;\r\n this.SetStatusPercent(data.ota_pct);\r\n }\r\n if ((data.ota_dsc ?? '') != '') {\r\n this.olderRecovery = true;\r\n this.SetStatusText(data.ota_dsc);\r\n }\r\n\r\n if (data.recovery != undefined) {\r\n this.recovery = data.recovery === 1 ? true : false;\r\n }\r\n if (this.isStateRebootRecovery() && this.recovery) {\r\n this.TargetReadyStartOTA();\r\n }\r\n },\r\n EventOTAMessageClass: function (data) {\r\n this.logEvent(this.EventOTAMessageClass.name);\r\n var otaData = JSON.parse(data);\r\n this.SetStatusPercent(otaData.ota_pct).SetStatusText(otaData.ota_dsc);\r\n },\r\n logEvent: function (fun) {\r\n console.log(`${fun}, flash state ${this.toString()}, recovery: ${this.recovery}, ota pct: ${this.statusPercent}, ota desc: ${this.statusText}`);\r\n }\r\n\r\n};\r\nwindow.hideSurrounding = function (obj) {\r\n $(obj).parent().parent().hide();\r\n}\r\n\r\nlet presetsloaded = false;\r\nlet is_i2c_locked = false;\r\nlet statusInterval = 2000;\r\nlet messageInterval = 2500;\r\nfunction post_config(data) {\r\n let confPayload = {\r\n timestamp: Date.now(),\r\n config: data\r\n };\r\n $.ajax({\r\n url: '/config.json',\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify(confPayload),\r\n error: handleExceptionResponse,\r\n });\r\n}\r\n\r\n\r\nwindow.hFlash = function () {\r\n // reset file upload selection if any;\r\n $('#flashfilename').value = null\r\n flashState.StartOTA();\r\n}\r\nwindow.handleReboot = function (link) {\r\n if (link == 'reboot_ota') {\r\n $('#reboot_ota_nav').removeClass('active').prop(\"disabled\", true); delayReboot(500, '', 'reboot_ota');\r\n }\r\n else {\r\n $('#reboot_nav').removeClass('active'); delayReboot(500, '', link);\r\n }\r\n}\r\n\r\nfunction parseSqueezeliteCommandLine(commandLine) {\r\n const options = {};\r\n let output, name;\r\n let otherValues = '';\r\n\r\n const argRegex = /(\"[^\"]+\"|'[^']+'|\\S+)/g;\r\n const args = commandLine.match(argRegex);\r\n\r\n let i = 0;\r\n\r\n while (i < args.length) {\r\n const arg = args[i];\r\n\r\n if (arg.startsWith('-')) {\r\n const option = arg.slice(1);\r\n\r\n if (option === '') {\r\n otherValues += args.slice(i).join(' ');\r\n break;\r\n }\r\n\r\n let value = true;\r\n\r\n if (i + 1 < args.length && !args[i + 1].startsWith('-')) {\r\n value = args[i + 1].replace(/\"/g, '').replace(/'/g, '');\r\n i++;\r\n }\r\n\r\n options[option] = value;\r\n } else {\r\n otherValues += arg + ' ';\r\n }\r\n\r\n i++;\r\n }\r\n\r\n otherValues = otherValues.trim();\r\n output = getOutput(options);\r\n name = getName(options);\r\n let otherOptions={btname:null,n:null};\r\n // assign o and n options to otheroptions if present\r\n if (options.o && output.toUpperCase() === 'BT') {\r\n let temp = parseSqueezeliteCommandLine(options.o);\r\n if(temp.name) {\r\n otherOptions.btname = temp.name;\r\n }\r\n delete options.o;\r\n }\r\n if (options.n) {\r\n otherOptions['n'] = options.n;\r\n delete options.n;\r\n }\r\n return { name, output, options, otherValues,otherOptions }; \r\n}\r\n\r\nfunction getOutput(options) {\r\n let output;\r\n if (options.o){\r\n output = options.o.replace(/\"/g, '').replace(/'/g, '');\r\n /* set output as the first alphanumerical word in the command line */\r\n if (output.indexOf(' ') > 0) {\r\n output = output.substring(0, output.indexOf(' '));\r\n }\r\n }\r\n return output;\r\n}\r\n\r\nfunction getName(options) {\r\n let name;\r\n /* if n option present, assign to name variable */\r\n if (options.n){\r\n name = options.n.replace(/\"/g, '').replace(/'/g, '');\r\n }\r\n return name;\r\n}\r\n\r\n\r\nfunction isConnected() {\r\n return ConnectedTo.hasOwnProperty('ip') && ConnectedTo.ip != '0.0.0.0' && ConnectedTo.ip != '';\r\n}\r\nfunction getIcon(icons) {\r\n return isConnected() ? icons.icon : icons.label;\r\n}\r\nfunction handlebtstate(data) {\r\n let icon = '';\r\n let tt = '';\r\n if (data.bt_status !== undefined && data.bt_sub_status !== undefined) {\r\n const iconindex = btStateIcons[data.bt_status].sub[data.bt_sub_status];\r\n if (iconindex) {\r\n icon = btIcons[iconindex];\r\n tt = btStateIcons[data.bt_status].desc;\r\n } else {\r\n icon = btIcons.bt_connected;\r\n tt = 'Output status';\r\n }\r\n }\r\n\r\n $('#o_type').attr('title', tt);\r\n $('#o_bt').html(isConnected() ? icon.label : icon.text);\r\n}\r\nfunction handleTemplateTypeRadio(outtype) {\r\n $('#o_type').children('span').css({ display: 'none' });\r\n let changed = false;\r\n if (outtype === 'bt') {\r\n changed = output !== 'bt' && output !== '';\r\n output = 'bt';\r\n } else if (outtype === 'spdif') {\r\n changed = output !== 'spdif' && output !== '';\r\n output = 'spdif';\r\n } else {\r\n changed = output !== 'i2s' && output !== '';\r\n output = 'i2s';\r\n }\r\n $('#' + output).prop('checked', true);\r\n $('#o_' + output).css({ display: 'inline' });\r\n if (changed) {\r\n Object.keys(commandDefaults[output]).forEach(function (key) {\r\n $(`#cmd_opt_${key}`).val(commandDefaults[output][key]);\r\n });\r\n }\r\n}\r\n\r\nfunction handleExceptionResponse(xhr, _ajaxOptions, thrownError) {\r\n console.log(xhr.status);\r\n console.log(thrownError);\r\n if (thrownError !== '') {\r\n showLocalMessage(thrownError, 'MESSAGING_ERROR');\r\n }\r\n}\r\nfunction HideCmdMessage(cmdname) {\r\n $('#toast_' + cmdname)\r\n .removeClass('table-success')\r\n .removeClass('table-warning')\r\n .removeClass('table-danger')\r\n .addClass('table-success')\r\n .removeClass('show');\r\n $('#msg_' + cmdname).html('');\r\n}\r\nfunction showCmdMessage(cmdname, msgtype, msgtext, append = false) {\r\n let color = 'table-success';\r\n if (msgtype === 'MESSAGING_WARNING') {\r\n color = 'table-warning';\r\n } else if (msgtype === 'MESSAGING_ERROR') {\r\n color = 'table-danger';\r\n }\r\n $('#toast_' + cmdname)\r\n .removeClass('table-success')\r\n .removeClass('table-warning')\r\n .removeClass('table-danger')\r\n .addClass(color)\r\n .addClass('show');\r\n let escapedtext = msgtext\r\n .substring(0, msgtext.length - 1)\r\n .encodeHTML()\r\n .replace(/\\n/g, '
');\r\n escapedtext =\r\n ($('#msg_' + cmdname).html().length > 0 && append\r\n ? $('#msg_' + cmdname).html() + '
'\r\n : '') + escapedtext;\r\n $('#msg_' + cmdname).html(escapedtext);\r\n}\r\n\r\nlet releaseURL =\r\n 'https://api.github.com/repos/sle118/squeezelite-esp32/releases';\r\n\r\nlet recovery = false;\r\nlet messagesHeld = false;\r\nlet commandBTSinkName = '';\r\nconst commandHeader = 'squeezelite ';\r\nconst commandDefaults = {\r\n i2s: { b: \"500:2000\", C: \"30\", W: \"\", Z: \"96000\", o: \"I2S\" },\r\n spdif: { b: \"500:2000\", C: \"30\", W: \"\", Z: \"48000\", o: \"SPDIF\" },\r\n bt: { b: \"500:2000\", C: \"30\", W: \"\", Z: \"44100\", o: \"BT\" },\r\n};\r\nlet validOptions = {\r\n codecs: ['flac', 'pcm', 'mp3', 'ogg', 'aac', 'wma', 'alac', 'dsd', 'mad', 'mpg']\r\n};\r\n\r\n//let blockFlashButton = false;\r\nlet apList = null;\r\n//let selectedSSID = '';\r\n//let checkStatusInterval = null;\r\nlet messagecount = 0;\r\nlet messageseverity = 'MESSAGING_INFO';\r\nlet SystemConfig = {};\r\nlet LastCommandsState = null;\r\nvar output = '';\r\nlet hostName = '';\r\nlet versionName = 'Squeezelite-ESP32';\r\nlet prevmessage = '';\r\nlet project_name = versionName;\r\nlet depth = 16;\r\nlet board_model = '';\r\nlet platform_name = versionName;\r\nlet preset_name = '';\r\nlet btSinkNamesOptSel = '#cfg-audio-bt_source-sink_name';\r\nlet ConnectedTo = {};\r\nlet ConnectingToSSID = {};\r\nlet lmsBaseUrl;\r\nlet prevLMSIP = '';\r\nconst ConnectingToActions = {\r\n 'CONN': 0, 'MAN': 1, 'STS': 2,\r\n}\r\n\r\nPromise.prototype.delay = function (duration) {\r\n return this.then(\r\n function (value) {\r\n return new Promise(function (resolve) {\r\n setTimeout(function () {\r\n resolve(value);\r\n }, duration);\r\n });\r\n },\r\n function (reason) {\r\n return new Promise(function (_resolve, reject) {\r\n setTimeout(function () {\r\n reject(reason);\r\n }, duration);\r\n });\r\n }\r\n );\r\n};\r\n\r\nfunction getConfigJson(slimMode) {\r\n const config = {};\r\n $('input.nvs').each(function (_index, entry) {\r\n if (!slimMode) {\r\n const nvsType = parseInt(entry.attributes.nvs_type.value, 10);\r\n if (entry.id !== '') {\r\n config[entry.id] = {};\r\n if (\r\n nvsType === nvsTypes.NVS_TYPE_U8 ||\r\n nvsType === nvsTypes.NVS_TYPE_I8 ||\r\n nvsType === nvsTypes.NVS_TYPE_U16 ||\r\n nvsType === nvsTypes.NVS_TYPE_I16 ||\r\n nvsType === nvsTypes.NVS_TYPE_U32 ||\r\n nvsType === nvsTypes.NVS_TYPE_I32 ||\r\n nvsType === nvsTypes.NVS_TYPE_U64 ||\r\n nvsType === nvsTypes.NVS_TYPE_I64\r\n ) {\r\n config[entry.id].value = parseInt(entry.value);\r\n } else {\r\n config[entry.id].value = entry.value;\r\n }\r\n config[entry.id].type = nvsType;\r\n }\r\n } else {\r\n config[entry.id] = entry.value;\r\n }\r\n });\r\n const key = $('#nvs-new-key').val();\r\n const val = $('#nvs-new-value').val();\r\n if (key !== '') {\r\n if (!slimMode) {\r\n config[key] = {};\r\n config[key].value = val;\r\n config[key].type = 33;\r\n } else {\r\n config[key] = val;\r\n }\r\n }\r\n return config;\r\n}\r\n\r\nfunction handleHWPreset(allfields, reboot) {\r\n\r\n const selJson = JSON.parse(allfields[0].value);\r\n var cmd = allfields[0].attributes.cmdname.value;\r\n\r\n console.log(`selected model: ${selJson.name}`);\r\n let confPayload = {\r\n timestamp: Date.now(),\r\n config: { model_config: { value: selJson.name, type: 33 } }\r\n };\r\n for (const [name, value] of Object.entries(selJson.config)) {\r\n const storedval = (typeof value === 'string' || value instanceof String) ? value : JSON.stringify(value);\r\n confPayload.config[name] = {\r\n value: storedval,\r\n type: 33,\r\n }\r\n showCmdMessage(\r\n cmd,\r\n 'MESSAGING_INFO',\r\n `Setting ${name}=${storedval} `,\r\n true\r\n );\r\n }\r\n\r\n showCmdMessage(\r\n cmd,\r\n 'MESSAGING_INFO',\r\n `Committing `,\r\n true\r\n );\r\n $.ajax({\r\n url: '/config.json',\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify(confPayload),\r\n error: function (xhr, _ajaxOptions, thrownError) {\r\n handleExceptionResponse(xhr, _ajaxOptions, thrownError);\r\n showCmdMessage(\r\n cmd,\r\n 'MESSAGING_ERROR',\r\n `Unexpected error ${(thrownError !== '') ? thrownError : 'with return status = ' + xhr.status} `,\r\n true\r\n );\r\n },\r\n success: function (response) {\r\n showCmdMessage(\r\n cmd,\r\n 'MESSAGING_INFO',\r\n `Saving complete `,\r\n true\r\n );\r\n console.log(response);\r\n if (reboot) {\r\n delayReboot(2500, cmd);\r\n }\r\n },\r\n });\r\n}\r\n\r\n\r\n// pull json file from https://gist.githubusercontent.com/sle118/dae585e157b733a639c12dc70f0910c5/raw/b462691f69e2ad31ac95c547af6ec97afb0f53db/squeezelite-esp32-presets.json and\r\nfunction loadPresets() {\r\n if ($(\"#cfg-hw-preset-model_config\").length == 0) return;\r\n if (presetsloaded) return;\r\n presetsloaded = true;\r\n $('#cfg-hw-preset-model_config').html('');\r\n $.getJSON(\r\n 'https://gist.githubusercontent.com/sle118/dae585e157b733a639c12dc70f0910c5/raw/',\r\n { _: new Date().getTime() },\r\n function (data) {\r\n $.each(data, function (key, val) {\r\n $('#cfg-hw-preset-model_config').append(``);\r\n if (preset_name !== '' && preset_name == val.name) {\r\n $('#cfg-hw-preset-model_config').val(preset_name);\r\n }\r\n });\r\n if (preset_name !== '') {\r\n ('#prev_preset').show().val(preset_name);\r\n }\r\n }\r\n\r\n ).fail(function (jqxhr, textStatus, error) {\r\n const err = textStatus + ', ' + error;\r\n console.log('Request Failed: ' + err);\r\n }\r\n );\r\n}\r\n\r\nfunction delayReboot(duration, cmdname, ota = 'reboot') {\r\n const url = '/' + ota + '.json';\r\n $('tbody#tasks').empty();\r\n $('#tasks_sect').css('visibility', 'collapse');\r\n Promise.resolve({ cmdname: cmdname, url: url })\r\n .delay(duration)\r\n .then(function (data) {\r\n if (data.cmdname.length > 0) {\r\n showCmdMessage(\r\n data.cmdname,\r\n 'MESSAGING_WARNING',\r\n 'System is rebooting.\\n',\r\n true\r\n );\r\n } else {\r\n showLocalMessage('System is rebooting.\\n', 'MESSAGING_WARNING');\r\n }\r\n console.log('now triggering reboot');\r\n $(\"button[onclick*='handleReboot']\").addClass('rebooting');\r\n $.ajax({\r\n url: data.url,\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify({\r\n timestamp: Date.now(),\r\n }),\r\n error: handleExceptionResponse,\r\n complete: function () {\r\n console.log('reboot call completed');\r\n Promise.resolve(data)\r\n .delay(6000)\r\n .then(function (rdata) {\r\n if (rdata.cmdname.length > 0) {\r\n HideCmdMessage(rdata.cmdname);\r\n }\r\n getCommands();\r\n getConfig();\r\n });\r\n },\r\n });\r\n });\r\n}\r\n// eslint-disable-next-line no-unused-vars\r\nwindow.saveAutoexec1 = function (apply) {\r\n showCmdMessage('cfg-audio-tmpl', 'MESSAGING_INFO', 'Saving.\\n', false);\r\n let commandLine = `${commandHeader} -o ${output} `;\r\n $('.sqcmd').each(function () {\r\n let { opt, val } = get_control_option_value($(this));\r\n if ((opt && opt.length>0 ) && typeof(val) == 'boolean' || val.length > 0) {\r\n const optStr=opt===':'?opt:(` -${opt} `);\r\n val = typeof(val) == 'boolean'?'':val;\r\n commandLine += `${optStr} ${val}`;\r\n }\r\n });\r\n const resample=$('#cmd_opt_R input[name=resample]:checked');\r\n if (resample.length>0 && resample.attr('suffix')!=='') {\r\n commandLine += resample.attr('suffix');\r\n // now check resample_i option and if checked, add suffix to command line\r\n if ($('#resample_i').is(\":checked\") && resample.attr('aint') =='true') {\r\n commandLine += $('#resample_i').attr('suffix');\r\n }\r\n}\r\n\r\n \r\n if (output === 'bt') {\r\n showCmdMessage(\r\n 'cfg-audio-tmpl',\r\n 'MESSAGING_INFO',\r\n 'Remember to configure the Bluetooth audio device name.\\n',\r\n true\r\n );\r\n }\r\n commandLine += concatenateOptions(options);\r\n const data = {\r\n timestamp: Date.now(),\r\n };\r\n data.config = {\r\n autoexec1: { value: commandLine, type: 33 },\r\n // autoexec: {\r\n // value: $('#disable-squeezelite').prop('checked') ? '0' : '1',\r\n // type: 33,\r\n // },\r\n };\r\n\r\n $.ajax({\r\n url: '/config.json',\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify(data),\r\n error: handleExceptionResponse,\r\n complete: function (response) {\r\n if (\r\n response.responseText &&\r\n JSON.parse(response.responseText).result === 'OK'\r\n ) {\r\n showCmdMessage('cfg-audio-tmpl', 'MESSAGING_INFO', 'Done.\\n', true);\r\n if (apply) {\r\n delayReboot(1500, 'cfg-audio-tmpl');\r\n }\r\n } else if (JSON.parse(response.responseText).result) {\r\n showCmdMessage(\r\n 'cfg-audio-tmpl',\r\n 'MESSAGING_WARNING',\r\n JSON.parse(response.responseText).Result + '\\n',\r\n true\r\n );\r\n } else {\r\n showCmdMessage(\r\n 'cfg-audio-tmpl',\r\n 'MESSAGING_ERROR',\r\n response.statusText + '\\n'\r\n );\r\n }\r\n console.log(response.responseText);\r\n },\r\n });\r\n console.log('sent data:', JSON.stringify(data));\r\n}\r\nwindow.handleDisconnect = function () {\r\n $.ajax({\r\n url: '/connect.json',\r\n dataType: 'text',\r\n method: 'DELETE',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify({\r\n timestamp: Date.now(),\r\n }),\r\n });\r\n}\r\nfunction setPlatformFilter(val) {\r\n if ($('.upf').filter(function () { return $(this).text().toUpperCase() === val.toUpperCase() }).length > 0) {\r\n $('#splf').val(val).trigger('input');\r\n return true;\r\n }\r\n return false;\r\n}\r\nwindow.handleConnect = function () {\r\n ConnectingToSSID.ssid = $('#manual_ssid').val();\r\n ConnectingToSSID.pwd = $('#manual_pwd').val();\r\n ConnectingToSSID.dhcpname = $('#dhcp-name2').val();\r\n $(\"*[class*='connecting']\").hide();\r\n $('#ssid-wait').text(ConnectingToSSID.ssid);\r\n $('.connecting').show();\r\n $.ajax({\r\n url: '/connect.json',\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify({\r\n timestamp: Date.now(),\r\n ssid: ConnectingToSSID.ssid,\r\n pwd: ConnectingToSSID.pwd\r\n }),\r\n error: handleExceptionResponse,\r\n });\r\n\r\n // now we can re-set the intervals regardless of result\r\n\r\n}\r\nfunction renderError(opt,error){\r\n const fieldname = `cmd_opt_${opt}`;\r\n let errorFieldName=`${fieldname}-error`;\r\n let errorField=$(`#${errorFieldName}`);\r\n let field=$(`#${fieldname}`);\r\n \r\n if (!errorField || errorField.length ==0) {\r\n field.after(`
`);\r\n errorField=$(`#${errorFieldName}`);\r\n }\r\n if(error.length ==0){\r\n errorField.hide();\r\n field.removeClass('is-invalid');\r\n field.addClass('is-valid');\r\n errorField.text('');\r\n }\r\n else { \r\n errorField.show();\r\n errorField.text(error);\r\n field.removeClass('is-valid');\r\n field.addClass('is-invalid');\r\n }\r\n return errorField;\r\n}\r\n$(document).ready(function () {\r\n $('.material-icons').each(function (_index, entry) {\r\n entry.attributes['icon'] = entry.textContent;\r\n });\r\n setIcons(true);\r\n handleNVSVisible();\r\n flashState.init();\r\n $('#fw-url-input').on('input', function () {\r\n if ($(this).val().length > 8 && ($(this).val().startsWith('http://') || $(this).val().startsWith('https://'))) {\r\n $('#start-flash').show();\r\n }\r\n else {\r\n $('#start-flash').hide();\r\n }\r\n });\r\n $('.upSrch').on('input', function () {\r\n const val = this.value;\r\n $(\"#rTable tr\").removeClass(this.id + '_hide');\r\n if (val.length > 0) {\r\n $(`#rTable td:nth-child(${$(this).parent().index() + 1})`).filter(function () {\r\n return !$(this).text().toUpperCase().includes(val.toUpperCase());\r\n }).parent().addClass(this.id + '_hide');\r\n }\r\n $('[class*=\"_hide\"]').hide();\r\n $('#rTable tr').not('[class*=\"_hide\"]').show()\r\n\r\n });\r\n setTimeout(refreshAP, 1500);\r\n /* add validation for cmd_opt_c, which accepts a comma separated list. \r\n getting known codecs from validOptions.codecs array\r\n use bootstrap classes to highlight the error with an overlay message */\r\n $('#options input').on('input', function () {\r\n const { opt, val } = get_control_option_value(this);\r\n if (opt === 'c' || opt === 'e') {\r\n const fieldname = `cmd_opt_${opt}_codec-error`;\r\n \r\n const values = val.split(',').map(function (item) {\r\n return item.trim();\r\n });\r\n /* get a list of invalid codecs */\r\n const invalid = values.filter(function (item) {\r\n return !validOptions.codecs.includes(item);\r\n });\r\n renderError(opt,invalid.length > 0 ? `Invalid codec(s) ${invalid.join(', ')}` : '');\r\n }\r\n /* add validation for cmd_opt_m, which accepts a mac_address */\r\n if (opt === 'm') {\r\n const mac_regex = /^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$/;\r\n renderError(opt,mac_regex.test(val) ? '' : 'Invalid MAC address');\r\n }\r\n if (opt === 'r') {\r\n const rateRegex = /^(\\d+\\.?\\d*|\\.\\d+)-(\\d+\\.?\\d*|\\.\\d+)$|^(\\d+\\.?\\d*)$|^(\\d+\\.?\\d*,)+\\d+\\.?\\d*$/;\r\n renderError(opt,rateRegex.test(val)?'':`Invalid rate(s) ${val}. Acceptable format: |-|,,`);\r\n }\r\n\r\n\r\n\r\n }\r\n\r\n\r\n );\r\n\r\n\r\n\r\n\r\n\r\n $('#WifiConnectDialog')[0].addEventListener('shown.bs.modal', function (event) {\r\n $(\"*[class*='connecting']\").hide();\r\n\r\n if (event?.relatedTarget) {\r\n ConnectingToSSID.Action = ConnectingToActions.CONN;\r\n if ($(event.relatedTarget).children('td:eq(1)').text() == ConnectedTo.ssid) {\r\n ConnectingToSSID.Action = ConnectingToActions.STS;\r\n }\r\n else {\r\n if (!$(event.relatedTarget).is(':last-child')) {\r\n ConnectingToSSID.ssid = $(event.relatedTarget).children('td:eq(1)').text();\r\n $('#manual_ssid').val(ConnectingToSSID.ssid);\r\n }\r\n else {\r\n ConnectingToSSID.Action = ConnectingToActions.MAN;\r\n ConnectingToSSID.ssid = '';\r\n $('#manual_ssid').val(ConnectingToSSID.ssid);\r\n }\r\n }\r\n }\r\n\r\n\r\n if (ConnectingToSSID.Action !== ConnectingToActions.STS) {\r\n $('.connecting-init').show();\r\n $('#manual_ssid').trigger('focus');\r\n }\r\n else {\r\n handleWifiDialog();\r\n }\r\n });\r\n\r\n $('#WifiConnectDialog')[0].addEventListener('hidden.bs.modal', function () {\r\n $('#WifiConnectDialog input').val('');\r\n });\r\n\r\n $('#uCnfrm')[0].addEventListener('shown.bs.modal', function () {\r\n $('#selectedFWURL').text($('#fw-url-input').val());\r\n });\r\n\r\n $('input#show-commands')[0].checked = LastCommandsState === 1;\r\n $('a[href^=\"#tab-commands\"]').hide();\r\n $('#load-nvs').on('click', function () {\r\n $('#nvsfilename').trigger('click');\r\n });\r\n $('#nvsfilename').on('change', function () {\r\n if (typeof window.FileReader !== 'function') {\r\n throw \"The file API isn't supported on this browser.\";\r\n }\r\n if (!this.files) {\r\n throw 'This browser does not support the `files` property of the file input.';\r\n }\r\n if (!this.files[0]) {\r\n return undefined;\r\n }\r\n\r\n const file = this.files[0];\r\n let fr = new FileReader();\r\n fr.onload = function (e) {\r\n let data = {};\r\n try {\r\n data = JSON.parse(e.target.result);\r\n } catch (ex) {\r\n alert('Parsing failed!\\r\\n ' + ex);\r\n }\r\n $('input.nvs').each(function (_index, entry) {\r\n $(this).parent().removeClass('bg-warning').removeClass('bg-success');\r\n if (data[entry.id]) {\r\n if (data[entry.id] !== entry.value) {\r\n console.log(\r\n 'Changed ' + entry.id + ' ' + entry.value + '==>' + data[entry.id]\r\n );\r\n $(this).parent().addClass('bg-warning');\r\n $(this).val(data[entry.id]);\r\n }\r\n else {\r\n $(this).parent().addClass('bg-success');\r\n }\r\n }\r\n });\r\n var changed = $(\"input.nvs\").children('.bg-warning');\r\n if (changed) {\r\n alert('Highlighted values were changed. Press Commit to change on the device');\r\n }\r\n }\r\n fr.readAsText(file);\r\n this.value = null;\r\n\r\n }\r\n );\r\n $('#clear-syslog').on('click', function () {\r\n messagecount = 0;\r\n messageseverity = 'MESSAGING_INFO';\r\n $('#msgcnt').text('');\r\n $('#syslogTable').html('');\r\n });\r\n\r\n $('#ok-credits').on('click', function () {\r\n $('#credits').slideUp('fast', function () { });\r\n $('#app').slideDown('fast', function () { });\r\n });\r\n\r\n $('#acredits').on('click', function (event) {\r\n event.preventDefault();\r\n $('#app').slideUp('fast', function () { });\r\n $('#credits').slideDown('fast', function () { });\r\n });\r\n\r\n $('input#show-commands').on('click', function () {\r\n this.checked = this.checked ? 1 : 0;\r\n if (this.checked) {\r\n $('a[href^=\"#tab-commands\"]').show();\r\n LastCommandsState = 1;\r\n } else {\r\n LastCommandsState = 0;\r\n $('a[href^=\"#tab-commands\"]').hide();\r\n }\r\n });\r\n\r\n $('#disable-squeezelite').on('click', function () {\r\n // this.checked = this.checked ? 1 : 0;\r\n // $('#disable-squeezelite').prop('checked')\r\n if (this.checked) {\r\n // Store the current value before overwriting it\r\n const currentValue = $('#cmd_opt_s').val();\r\n $('#cmd_opt_s').data('originalValue', currentValue);\r\n \r\n // Overwrite the value with '-disable'\r\n $('#cmd_opt_s').val('-disable');\r\n } else {\r\n // Retrieve the original value\r\n const originalValue = $('#cmd_opt_s').data('originalValue');\r\n \r\n // Restore the original value if it exists, otherwise set it to an empty string\r\n $('#cmd_opt_s').val(originalValue ? originalValue : '');\r\n }\r\n \r\n });\r\n\r\n \r\n\r\n $('input#show-nvs').on('click', function () {\r\n this.checked = this.checked ? 1 : 0;\r\n Cookies.set(\"show-nvs\", this.checked ? 'Y' : 'N');\r\n handleNVSVisible();\r\n });\r\n $('#btn_reboot_recovery').on('click', function () {\r\n handleReboot('recovery');\r\n });\r\n $('#btn_reboot').on('click', function () {\r\n handleReboot('reboot');\r\n });\r\n $('#btn_flash').on('click', function () {\r\n hFlash();\r\n });\r\n $('#save-autoexec1').on('click', function () {\r\n saveAutoexec1(false);\r\n });\r\n $('#commit-autoexec1').on('click', function () {\r\n saveAutoexec1(true);\r\n });\r\n $('#btn_disconnect').on('click', function () {\r\n ConnectedTo = {};\r\n refreshAPHTML2();\r\n $.ajax({\r\n url: '/connect.json',\r\n dataType: 'text',\r\n method: 'DELETE',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify({\r\n timestamp: Date.now(),\r\n }),\r\n });\r\n });\r\n $('#btnJoin').on('click', function () {\r\n handleConnect();\r\n });\r\n $('#reboot_nav').on('click', function () {\r\n handleReboot('reboot');\r\n });\r\n $('#reboot_ota_nav').on('click', function () {\r\n handleReboot('reboot_ota');\r\n });\r\n\r\n $('#save-as-nvs').on('click', function () {\r\n const config = getConfigJson(true);\r\n const a = document.createElement('a');\r\n a.href = URL.createObjectURL(\r\n new Blob([JSON.stringify(config, null, 2)], {\r\n type: 'text/plain',\r\n })\r\n );\r\n a.setAttribute(\r\n 'download',\r\n 'nvs_config_' + hostName + '_' + Date.now() + 'json'\r\n );\r\n document.body.appendChild(a);\r\n a.click();\r\n document.body.removeChild(a);\r\n });\r\n\r\n $('#save-nvs').on('click', function () {\r\n post_config(getConfigJson(false));\r\n });\r\n\r\n $('#fwUpload').on('click', function () {\r\n const fileInput = document.getElementById('flashfilename').files;\r\n if (fileInput.length === 0) {\r\n alert('No file selected!');\r\n } else {\r\n $('#fw-url-input').value = null;\r\n flashState.StartOTA();\r\n }\r\n\r\n });\r\n $('[name=output-tmpl]').on('click', function () {\r\n handleTemplateTypeRadio(this.id);\r\n });\r\n\r\n $('#chkUpdates').on('click', function () {\r\n $('#rTable').html('');\r\n $.getJSON(releaseURL, function (data) {\r\n let i = 0;\r\n const branches = [];\r\n data.forEach(function (release) {\r\n const namecomponents = release.name.split('#');\r\n const branch = namecomponents[3];\r\n if (!branches.includes(branch)) {\r\n branches.push(branch);\r\n }\r\n });\r\n let fwb = '';\r\n branches.forEach(function (branch) {\r\n fwb += '';\r\n });\r\n $('#fwbranch').append(fwb);\r\n\r\n data.forEach(function (release) {\r\n let url = '';\r\n release.assets.forEach(function (asset) {\r\n if (asset.name.match(/\\.bin$/)) {\r\n url = asset.browser_download_url;\r\n }\r\n });\r\n const namecomponents = release.name.split('#');\r\n const ver = namecomponents[0];\r\n const cfg = namecomponents[2];\r\n const branch = namecomponents[3];\r\n var bits = ver.substr(ver.lastIndexOf('-') + 1);\r\n bits = (bits == '32' || bits == '16') ? bits : '';\r\n\r\n let body = release.body;\r\n body = body.replace(/'/gi, '\"');\r\n body = body.replace(\r\n /[\\s\\S]+(### Revision Log[\\s\\S]+)### ESP-IDF Version Used[\\s\\S]+/,\r\n '$1'\r\n );\r\n body = body.replace(/- \\(.+?\\) /g, '- ').encodeHTML();\r\n $('#rTable').append(`\r\n ${ver}${new Date(release.created_at).toLocalShort()}\r\n ${cfg}${branch}${bits}`\r\n );\r\n });\r\n if (i > 7) {\r\n $('#releaseTable').append(\r\n \"\" +\r\n \"\" +\r\n \"\" +\r\n '' +\r\n ''\r\n );\r\n $('#showallbutton').on('click', function () {\r\n $('tr.hide').removeClass('hide');\r\n $('tr#showall').addClass('hide');\r\n });\r\n }\r\n $('#searchfw').css('display', 'inline');\r\n if (!setPlatformFilter(platform_name)) {\r\n setPlatformFilter(project_name)\r\n }\r\n $('#rTable tr.release').on('click', function () {\r\n var url = this.attributes['fwurl'].value;\r\n if (lmsBaseUrl) {\r\n url = url.replace(/.*\\/download\\//, lmsBaseUrl + '/plugins/SqueezeESP32/firmware/');\r\n }\r\n $('#fw-url-input').val(url);\r\n $('#start-flash').show();\r\n $('#rTable tr.release').removeClass('table-success table-warning');\r\n $(this).addClass('table-success table-warning');\r\n });\r\n\r\n }).fail(function () {\r\n alert('failed to fetch release history!');\r\n });\r\n });\r\n $('#fwcheck').on('click', function () {\r\n $('#releaseTable').html('');\r\n $('#fwbranch').empty();\r\n $.getJSON(releaseURL, function (data) {\r\n let i = 0;\r\n const branches = [];\r\n data.forEach(function (release) {\r\n const namecomponents = release.name.split('#');\r\n const branch = namecomponents[3];\r\n if (!branches.includes(branch)) {\r\n branches.push(branch);\r\n }\r\n });\r\n let fwb;\r\n branches.forEach(function (branch) {\r\n fwb += '';\r\n });\r\n $('#fwbranch').append(fwb);\r\n\r\n data.forEach(function (release) {\r\n let url = '';\r\n release.assets.forEach(function (asset) {\r\n if (asset.name.match(/\\.bin$/)) {\r\n url = asset.browser_download_url;\r\n }\r\n });\r\n const namecomponents = release.name.split('#');\r\n const ver = namecomponents[0];\r\n const idf = namecomponents[1];\r\n const cfg = namecomponents[2];\r\n const branch = namecomponents[3];\r\n\r\n let body = release.body;\r\n body = body.replace(/'/gi, '\"');\r\n body = body.replace(\r\n /[\\s\\S]+(### Revision Log[\\s\\S]+)### ESP-IDF Version Used[\\s\\S]+/,\r\n '$1'\r\n );\r\n body = body.replace(/- \\(.+?\\) /g, '- ');\r\n const trclass = i++ > 6 ? ' hide' : '';\r\n $('#releaseTable').append(\r\n \"\" +\r\n \"\" +\r\n ver +\r\n '' +\r\n '' +\r\n new Date(release.created_at).toLocalShort() +\r\n '' +\r\n '' +\r\n cfg +\r\n '' +\r\n '' +\r\n idf +\r\n '' +\r\n '' +\r\n branch +\r\n '' +\r\n \"\" +\r\n ''\r\n );\r\n });\r\n if (i > 7) {\r\n $('#releaseTable').append(\r\n \"\" +\r\n \"\" +\r\n \"\" +\r\n '' +\r\n ''\r\n );\r\n $('#showallbutton').on('click', function () {\r\n $('tr.hide').removeClass('hide');\r\n $('tr#showall').addClass('hide');\r\n });\r\n }\r\n $('#searchfw').css('display', 'inline');\r\n }).fail(function () {\r\n alert('failed to fetch release history!');\r\n });\r\n });\r\n\r\n $('#updateAP').on('click', function () {\r\n refreshAP();\r\n console.log('refresh AP');\r\n });\r\n\r\n // first time the page loads: attempt to get the connection status and start the wifi scan\r\n getConfig();\r\n getCommands();\r\n getMessages();\r\n checkStatus();\r\n\r\n});\r\n\r\n// eslint-disable-next-line no-unused-vars\r\nwindow.setURL = function (button) {\r\n let url = button.dataset.url;\r\n\r\n $('[data-bs-url^=\"http\"]')\r\n .addClass('btn-success')\r\n .removeClass('btn-danger');\r\n $('[data-bs-url=\"' + url + '\"]')\r\n .addClass('btn-danger')\r\n .removeClass('btn-success');\r\n\r\n // if user can proxy download through LMS, modify the URL\r\n if (lmsBaseUrl) {\r\n url = url.replace(/.*\\/download\\//, lmsBaseUrl + '/plugins/SqueezeESP32/firmware/');\r\n }\r\n\r\n $('#fwurl').val(url);\r\n}\r\n\r\n\r\nfunction rssiToIcon(rssi) {\r\n if (rssi >= -55) {\r\n return { 'label': '****', 'icon': `signal_wifi_statusbar_4_bar` };\r\n } else if (rssi >= -60) {\r\n return { 'label': '***', 'icon': `network_wifi_3_bar` };\r\n } else if (rssi >= -65) {\r\n return { 'label': '**', 'icon': `network_wifi_2_bar` };\r\n } else if (rssi >= -70) {\r\n return { 'label': '*', 'icon': `network_wifi_1_bar` };\r\n } else {\r\n return { 'label': '.', 'icon': `signal_wifi_statusbar_null` };\r\n }\r\n}\r\n\r\nfunction refreshAP() {\r\n if (ConnectedTo?.urc === connectReturnCode.ETH) return;\r\n $.ajaxSetup({\r\n timeout: 3000 //Time in milliseconds\r\n });\r\n $.getJSON('/scan.json', async function () {\r\n await sleep(2000);\r\n $.getJSON('/ap.json', function (data) {\r\n if (data.length > 0) {\r\n // sort by signal strength\r\n data.sort(function (a, b) {\r\n const x = a.rssi;\r\n const y = b.rssi;\r\n // eslint-disable-next-line no-nested-ternary\r\n return x < y ? 1 : x > y ? -1 : 0;\r\n });\r\n apList = data;\r\n refreshAPHTML2(apList);\r\n\r\n }\r\n });\r\n });\r\n}\r\nfunction formatAP(ssid, rssi, auth) {\r\n const rssi_icon = rssiToIcon(rssi);\r\n const auth_icon = { label: auth == 0 ? '🔓' : '🔒', icon: auth == 0 ? 'no_encryption' : 'lock' };\r\n\r\n return `${ssid}\r\n ${getIcon(rssi_icon)}\r\n \t\r\n ${getIcon(auth_icon)}\r\n `;\r\n}\r\nfunction refreshAPHTML2(data) {\r\n let h = '';\r\n $('#wifiTable tr td:first-of-type').text('');\r\n $('#wifiTable tr').removeClass('table-success table-warning');\r\n if (data) {\r\n data.forEach(function (e) {\r\n h += formatAP(e.ssid, e.rssi, e.auth);\r\n });\r\n $('#wifiTable').html(h);\r\n }\r\n if ($('.manual_add').length == 0) {\r\n $('#wifiTable').append(formatAP('Manual add', 0, 0));\r\n $('#wifiTable tr:last').addClass('table-light text-dark').addClass('manual_add');\r\n }\r\n if (ConnectedTo.ssid && (ConnectedTo.urc === connectReturnCode.OK || ConnectedTo.urc === connectReturnCode.RESTORE)) {\r\n const wifiSelector = `#wifiTable td:contains(\"${ConnectedTo.ssid}\")`;\r\n if ($(wifiSelector).filter(function () { return $(this).text() === ConnectedTo.ssid; }).length == 0) {\r\n $('#wifiTable').prepend(`${formatAP(ConnectedTo.ssid, ConnectedTo.rssi ?? 0, 0)}`);\r\n }\r\n $(wifiSelector).filter(function () { return $(this).text() === ConnectedTo.ssid; }).siblings().first().html('✓').parent().addClass((ConnectedTo.urc === connectReturnCode.OK ? 'table-success' : 'table-warning'));\r\n $('span#foot-if').html(`SSID: ${ConnectedTo.ssid}, IP: ${ConnectedTo.ip}`);\r\n $('#wifiStsIcon').html(rssiToIcon(ConnectedTo.rssi));\r\n\r\n }\r\n else if (ConnectedTo?.urc !== connectReturnCode.ETH) {\r\n $('span#foot-if').html('');\r\n }\r\n\r\n}\r\nfunction refreshETH() {\r\n\r\n if (ConnectedTo.urc === connectReturnCode.ETH) {\r\n $('span#foot-if').html(`Network: Ethernet, IP: ${ConnectedTo.ip}`);\r\n }\r\n}\r\nfunction showTask(task) {\r\n console.debug(\r\n this.toLocaleString() +\r\n '\\t' +\r\n task.nme +\r\n '\\t' +\r\n task.cpu +\r\n '\\t' +\r\n taskStates[task.st] +\r\n '\\t' +\r\n task.minstk +\r\n '\\t' +\r\n task.bprio +\r\n '\\t' +\r\n task.cprio +\r\n '\\t' +\r\n task.num\r\n );\r\n $('tbody#tasks').append(\r\n '' +\r\n task.num +\r\n '' +\r\n task.nme +\r\n '' +\r\n task.cpu +\r\n '' +\r\n taskStates[task.st] +\r\n '' +\r\n task.minstk +\r\n '' +\r\n task.bprio +\r\n '' +\r\n task.cprio +\r\n ''\r\n );\r\n}\r\nfunction btExists(name) {\r\n return getBTSinkOpt(name).length > 0;\r\n}\r\nfunction getBTSinkOpt(name) {\r\n return $(`${btSinkNamesOptSel} option:contains('${name}')`);\r\n}\r\nfunction getMessages() {\r\n $.ajaxSetup({\r\n timeout: messageInterval //Time in milliseconds\r\n });\r\n $.getJSON('/messages.json', async function (data) {\r\n for (const msg of data) {\r\n const msgAge = msg.current_time - msg.sent_time;\r\n var msgTime = new Date();\r\n msgTime.setTime(msgTime.getTime() - msgAge);\r\n switch (msg.class) {\r\n case 'MESSAGING_CLASS_OTA':\r\n flashState.EventOTAMessageClass(msg.message);\r\n break;\r\n case 'MESSAGING_CLASS_STATS':\r\n // for task states, check structure : task_state_t\r\n var statsData = JSON.parse(msg.message);\r\n console.debug(\r\n msgTime.toLocalShort() +\r\n ' - Number of running tasks: ' +\r\n statsData.ntasks\r\n );\r\n console.debug(\r\n msgTime.toLocalShort() +\r\n '\\tname' +\r\n '\\tcpu' +\r\n '\\tstate' +\r\n '\\tminstk' +\r\n '\\tbprio' +\r\n '\\tcprio' +\r\n '\\tnum'\r\n );\r\n if (statsData.tasks) {\r\n if ($('#tasks_sect').css('visibility') === 'collapse') {\r\n $('#tasks_sect').css('visibility', 'visible');\r\n }\r\n $('tbody#tasks').html('');\r\n statsData.tasks\r\n .sort(function (a, b) {\r\n return b.cpu - a.cpu;\r\n })\r\n .forEach(showTask, msgTime);\r\n } else if ($('#tasks_sect').css('visibility') === 'visible') {\r\n $('tbody#tasks').empty();\r\n $('#tasks_sect').css('visibility', 'collapse');\r\n }\r\n break;\r\n case 'MESSAGING_CLASS_SYSTEM':\r\n showMessage(msg, msgTime);\r\n break;\r\n case 'MESSAGING_CLASS_CFGCMD':\r\n var msgparts = msg.message.split(/([^\\n]*)\\n(.*)/gs);\r\n showCmdMessage(msgparts[1], msg.type, msgparts[2], true);\r\n break;\r\n case 'MESSAGING_CLASS_BT':\r\n if ($(\"#cfg-audio-bt_source-sink_name\").is('input')) {\r\n var attr = $(\"#cfg-audio-bt_source-sink_name\")[0].attributes;\r\n var attrs = '';\r\n for (var j = 0; j < attr.length; j++) {\r\n if (attr.item(j).name != \"type\") {\r\n attrs += `${attr.item(j).name} = \"${attr.item(j).value}\" `;\r\n }\r\n }\r\n var curOpt = $(\"#cfg-audio-bt_source-sink_name\")[0].value;\r\n $(\"#cfg-audio-bt_source-sink_name\").replaceWith(` `);\r\n }\r\n JSON.parse(msg.message).forEach(function (btEntry) {\r\n //\r\n // \r\n if (!btExists(btEntry.name)) {\r\n $(\"#cfg-audio-bt_source-sink_name\").append(``);\r\n showMessage({ type: msg.type, message: `BT Audio device found: ${btEntry.name} RSSI: ${btEntry.rssi} ` }, msgTime);\r\n }\r\n getBTSinkOpt(btEntry.name).attr('data-bs-description', `${btEntry.name} (${btEntry.rssi}dB)`)\r\n .attr('rssi', btEntry.rssi)\r\n .attr('value', btEntry.name)\r\n .text(`${btEntry.name} [${btEntry.rssi}dB]`).trigger('change');\r\n\r\n });\r\n $(btSinkNamesOptSel).append($(`${btSinkNamesOptSel} option`).remove().sort(function (a, b) {\r\n console.log(`${parseInt($(a).attr('rssi'))} < ${parseInt($(b).attr('rssi'))} ? `);\r\n return parseInt($(a).attr('rssi')) < parseInt($(b).attr('rssi')) ? 1 : -1;\r\n }));\r\n break;\r\n default:\r\n break;\r\n }\r\n }\r\n setTimeout(getMessages, messageInterval);\r\n }).fail(function (xhr, ajaxOptions, thrownError) {\r\n\r\n if (xhr.status == 404) {\r\n $('.orec').hide(); // system commands won't be available either\r\n messagesHeld = true;\r\n }\r\n else {\r\n handleExceptionResponse(xhr, ajaxOptions, thrownError);\r\n }\r\n if (xhr.status == 0 && xhr.readyState == 0) {\r\n // probably a timeout. Target is rebooting? \r\n setTimeout(getMessages, messageInterval * 2); // increase duration if a failure happens\r\n }\r\n else if (!messagesHeld) {\r\n // 404 here means we rebooted to an old recovery\r\n setTimeout(getMessages, messageInterval); // increase duration if a failure happens\r\n }\r\n\r\n }\r\n );\r\n\r\n /*\r\n Minstk is minimum stack space left\r\nBprio is base priority\r\ncprio is current priority\r\nnme is name\r\nst is task state. I provided a \"typedef\" that you can use to convert to text\r\ncpu is cpu percent used\r\n*/\r\n}\r\nfunction handleRecoveryMode(data) {\r\n const locRecovery = data.recovery ?? 0;\r\n if (locRecovery === 1) {\r\n recovery = true;\r\n $('.recovery_element').show();\r\n $('.ota_element').hide();\r\n $('#boot-button').html('Reboot');\r\n $('#boot-form').attr('action', '/reboot_ota.json');\r\n } else {\r\n if (!recovery && messagesHeld) {\r\n messagesHeld = false;\r\n setTimeout(getMessages, messageInterval); // increase duration if a failure happens\r\n }\r\n recovery = false;\r\n\r\n $('.recovery_element').hide();\r\n $('.ota_element').show();\r\n $('#boot-button').html('Recovery');\r\n $('#boot-form').attr('action', '/recovery.json');\r\n }\r\n\r\n}\r\n\r\nfunction hasConnectionChanged(data) {\r\n // gw: \"192.168.10.1\"\r\n // ip: \"192.168.10.225\"\r\n // netmask: \"255.255.255.0\"\r\n // ssid: \"MyTestSSID\"\r\n\r\n return (data.urc !== ConnectedTo.urc ||\r\n data.ssid !== ConnectedTo.ssid ||\r\n data.gw !== ConnectedTo.gw ||\r\n data.netmask !== ConnectedTo.netmask ||\r\n data.ip !== ConnectedTo.ip || data.rssi !== ConnectedTo.rssi)\r\n}\r\nfunction handleWifiDialog(data) {\r\n if ($('#WifiConnectDialog').is(':visible')) {\r\n if (ConnectedTo.ip) {\r\n $('#ipAddress').text(ConnectedTo.ip);\r\n }\r\n if (ConnectedTo.ssid) {\r\n $('#connectedToSSID').text(ConnectedTo.ssid);\r\n }\r\n if (ConnectedTo.gw) {\r\n $('#gateway').text(ConnectedTo.gw);\r\n }\r\n if (ConnectedTo.netmask) {\r\n $('#netmask').text(ConnectedTo.netmask);\r\n }\r\n if (ConnectingToSSID.Action === undefined || (ConnectingToSSID.Action && ConnectingToSSID.Action == ConnectingToActions.STS)) {\r\n $(\"*[class*='connecting']\").hide();\r\n $('.connecting-status').show();\r\n }\r\n if (SystemConfig.ap_ssid) {\r\n $('#apName').text(SystemConfig.ap_ssid.value);\r\n }\r\n if (SystemConfig.ap_pwd) {\r\n $('#apPass').text(SystemConfig.ap_pwd.value);\r\n }\r\n if (!data) {\r\n return;\r\n }\r\n else {\r\n switch (data.urc) {\r\n case connectReturnCode.OK:\r\n if (data.ssid && data.ssid === ConnectingToSSID.ssid) {\r\n $(\"*[class*='connecting']\").hide();\r\n $('.connecting-success').show();\r\n ConnectingToSSID.Action = ConnectingToActions.STS;\r\n }\r\n break;\r\n case connectReturnCode.FAIL:\r\n // \r\n if (ConnectingToSSID.Action != ConnectingToActions.STS && ConnectingToSSID.ssid == data.ssid) {\r\n $(\"*[class*='connecting']\").hide();\r\n $('.connecting-fail').show();\r\n }\r\n break;\r\n case connectReturnCode.LOST:\r\n\r\n break;\r\n case connectReturnCode.RESTORE:\r\n if (ConnectingToSSID.Action != ConnectingToActions.STS && ConnectingToSSID.ssid != data.ssid) {\r\n $(\"*[class*='connecting']\").hide();\r\n $('.connecting-fail').show();\r\n }\r\n break;\r\n case connectReturnCode.DISC:\r\n // that's a manual disconnect\r\n // if ($('#wifi-status').is(':visible')) {\r\n // $('#wifi-status').slideUp('fast', function() {});\r\n // $('span#foot-wifi').html('');\r\n\r\n // } \r\n break;\r\n default:\r\n break;\r\n }\r\n }\r\n\r\n }\r\n}\r\nfunction setIcons(offline) {\r\n $('.material-icons').each(function (_index, entry) {\r\n entry.textContent = entry.attributes[offline ? 'aria-label' : 'icon'].value;\r\n });\r\n}\r\nfunction handleNetworkStatus(data) {\r\n setIcons(!isConnected());\r\n if (hasConnectionChanged(data) || !data.urc) {\r\n ConnectedTo = data;\r\n $(\".if_eth\").hide();\r\n $('.if_wifi').hide();\r\n if (!data.urc || ConnectedTo.urc != connectReturnCode.ETH) {\r\n $('.if_wifi').show();\r\n refreshAPHTML2();\r\n }\r\n else {\r\n $(\".if_eth\").show();\r\n refreshETH();\r\n }\r\n\r\n }\r\n handleWifiDialog(data);\r\n}\r\n\r\n\r\n\r\nfunction batteryToIcon(voltage) {\r\n /* Assuming Li-ion 18650s as a power source, 3.9V per cell, or above is treated\r\n as full charge (>75% of capacity). 3.4V is empty. The gauge is loosely\r\n following the graph here:\r\n https://learn.adafruit.com/li-ion-and-lipoly-batteries/voltages\r\n using the 0.2C discharge profile for the rest of the values.\r\n*/\r\n\r\n for (const iconEntry of batIcons) {\r\n for (const entryRanges of iconEntry.ranges) {\r\n if (inRange(voltage, entryRanges.f, entryRanges.t)) {\r\n return { label: iconEntry.label, icon: iconEntry.icon };\r\n }\r\n }\r\n }\r\n\r\n\r\n return { label: '▪▪▪▪', icon: \"battery_full\" };\r\n}\r\nfunction checkStatus() {\r\n $.ajaxSetup({\r\n timeout: statusInterval //Time in milliseconds\r\n });\r\n $.getJSON('/status.json', function (data) {\r\n handleRecoveryMode(data);\r\n handleNVSVisible();\r\n handleNetworkStatus(data);\r\n handlebtstate(data);\r\n flashState.EventTargetStatus(data);\r\n if(data.depth) {\r\n depth = data.depth;\r\n if(depth==16){\r\n $('#cmd_opt_R').show();\r\n }\r\n else{\r\n $('#cmd_opt_R').hide();\r\n }\r\n }\r\n\r\n\r\n if (data.project_name && data.project_name !== '') {\r\n project_name = data.project_name;\r\n }\r\n if (data.platform_name && data.platform_name !== '') {\r\n platform_name = data.platform_name;\r\n }\r\n if (board_model === '') board_model = project_name;\r\n if (board_model === '') board_model = 'Squeezelite-ESP32';\r\n if (data.version && data.version !== '') {\r\n versionName = data.version;\r\n $(\"#navtitle\").html(`${board_model}${recovery ? '
[recovery]' : ''}`);\r\n $('span#foot-fw').html(`fw: ${versionName}, mode: ${recovery ? \"Recovery\" : project_name}`);\r\n } else {\r\n $('span#flash-status').html('');\r\n }\r\n if (data.Voltage) {\r\n const bat_icon = batteryToIcon(data.Voltage);\r\n $('#battery').html(`${getIcon(bat_icon)}`);\r\n $('#battery').attr(\"aria-label\", bat_icon.label);\r\n $('#battery').attr(\"icon\", bat_icon.icon);\r\n $('#battery').show();\r\n } else {\r\n $('#battery').hide();\r\n }\r\n if ((data.message ?? '') != '' && prevmessage != data.message) {\r\n // supporting older recovery firmwares - messages will come from the status.json structure\r\n prevmessage = data.message;\r\n showLocalMessage(data.message, 'MESSAGING_INFO')\r\n }\r\n is_i2c_locked = data.is_i2c_locked;\r\n if (is_i2c_locked) {\r\n $('flds-cfg-hw-preset').hide();\r\n }\r\n else {\r\n $('flds-cfg-hw-preset').show();\r\n }\r\n $(\"button[onclick*='handleReboot']\").removeClass('rebooting');\r\n\r\n if (typeof lmsBaseUrl == \"undefined\" || data.lms_ip != prevLMSIP && data.lms_ip && data.lms_port) {\r\n const baseUrl = 'http://' + data.lms_ip + ':' + data.lms_port;\r\n prevLMSIP = data.lms_ip;\r\n $.ajax({\r\n url: baseUrl + '/plugins/SqueezeESP32/firmware/-check.bin',\r\n type: 'HEAD',\r\n dataType: 'text',\r\n cache: false,\r\n error: function () {\r\n // define the value, so we don't check it any more.\r\n lmsBaseUrl = '';\r\n },\r\n success: function () {\r\n lmsBaseUrl = baseUrl;\r\n }\r\n });\r\n }\r\n $('#o_jack').css({ display: Number(data.Jack) ? 'inline' : 'none' });\r\n setTimeout(checkStatus, statusInterval);\r\n }).fail(function (xhr, ajaxOptions, thrownError) {\r\n handleExceptionResponse(xhr, ajaxOptions, thrownError);\r\n if (xhr.status == 0 && xhr.readyState == 0) {\r\n // probably a timeout. Target is rebooting? \r\n setTimeout(checkStatus, messageInterval * 2); // increase duration if a failure happens\r\n }\r\n else {\r\n setTimeout(checkStatus, messageInterval); // increase duration if a failure happens\r\n }\r\n });\r\n}\r\n// eslint-disable-next-line no-unused-vars\r\nwindow.runCommand = function (button, reboot) {\r\n let cmdstring = button.attributes.cmdname.value;\r\n showCmdMessage(\r\n button.attributes.cmdname.value,\r\n 'MESSAGING_INFO',\r\n 'Executing.',\r\n false\r\n );\r\n const fields = document.getElementById('flds-' + cmdstring);\r\n const allfields = fields?.querySelectorAll('select,input');\r\n if (cmdstring === 'cfg-hw-preset') return handleHWPreset(allfields, reboot);\r\n cmdstring += ' ';\r\n if (fields) {\r\n for (const field of allfields) {\r\n let qts = '';\r\n let opt = '';\r\n let attr = field.attributes;\r\n let isSelect = $(field).is('select');\r\n const hasValue = attr?.hasvalue?.value === 'true';\r\n const validVal = (isSelect && field.value !== '--') || (!isSelect && field.value !== '');\r\n\r\n if (!hasValue || hasValue && validVal) {\r\n if (attr?.longopts?.value !== 'undefined') {\r\n opt += '--' + attr?.longopts?.value;\r\n } else if (attr?.shortopts?.value !== 'undefined') {\r\n opt = '-' + attr.shortopts.value;\r\n }\r\n\r\n if (attr?.hasvalue?.value === 'true') {\r\n if (attr?.value !== '') {\r\n qts = /\\s/.test(field.value) ? '\"' : '';\r\n cmdstring += opt + ' ' + qts + field.value + qts + ' ';\r\n }\r\n } else {\r\n // this is a checkbox\r\n if (field?.checked) {\r\n cmdstring += opt + ' ';\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n console.log(cmdstring);\r\n\r\n const data = {\r\n timestamp: Date.now(),\r\n };\r\n data.command = cmdstring;\r\n\r\n $.ajax({\r\n url: '/commands.json',\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify(data),\r\n error: function (xhr, _ajaxOptions, thrownError) {\r\n var cmd = JSON.parse(this.data).command;\r\n if (xhr.status == 404) {\r\n showCmdMessage(\r\n cmd.substr(0, cmd.indexOf(' ')),\r\n 'MESSAGING_ERROR',\r\n `${recovery ? 'Limited recovery mode active. Unsupported action ' : 'Unexpected error while processing command'}`,\r\n true\r\n );\r\n }\r\n else {\r\n handleExceptionResponse(xhr, _ajaxOptions, thrownError);\r\n showCmdMessage(\r\n cmd.substr(0, cmd.indexOf(' ') - 1),\r\n 'MESSAGING_ERROR',\r\n `Unexpected error ${(thrownError !== '') ? thrownError : 'with return status = ' + xhr.status}`,\r\n true\r\n );\r\n }\r\n },\r\n success: function (response) {\r\n $('.orec').show();\r\n console.log(response);\r\n if (\r\n JSON.parse(response).Result === 'Success' &&\r\n reboot\r\n ) {\r\n delayReboot(2500, button.attributes.cmdname.value);\r\n }\r\n },\r\n });\r\n}\r\nfunction getLongOps(data, name, longopts) {\r\n return data.values[name] !== undefined ? data.values[name][longopts] : \"\";\r\n}\r\nfunction getCommands() {\r\n $.ajaxSetup({\r\n timeout: 7000 //Time in milliseconds\r\n });\r\n $.getJSON('/commands.json', function (data) {\r\n console.log(data);\r\n $('.orec').show();\r\n data.commands.forEach(function (command) {\r\n if ($('#flds-' + command.name).length === 0) {\r\n const cmdParts = command.name.split('-');\r\n const isConfig = cmdParts[0] === 'cfg';\r\n const targetDiv = '#tab-' + cmdParts[0] + '-' + cmdParts[1];\r\n let innerhtml = '';\r\n innerhtml += `
${command.help.encodeHTML().replace(/\\n/g, '
')}
`;\r\n if (command.argtable) {\r\n command.argtable.forEach(function (arg) {\r\n let placeholder = arg.datatype || '';\r\n const ctrlname = command.name + '-' + arg.longopts;\r\n const curvalue = getLongOps(data, command.name, arg.longopts);\r\n\r\n let attributes = 'hasvalue=' + arg.hasvalue + ' ';\r\n attributes += 'longopts=\"' + arg.longopts + '\" ';\r\n attributes += 'shortopts=\"' + arg.shortopts + '\" ';\r\n attributes += 'checkbox=' + arg.checkbox + ' ';\r\n attributes += 'cmdname=\"' + command.name + '\" ';\r\n attributes += 'id=\"' + ctrlname + '\" name=\"' + ctrlname + '\" ';\r\n if (arg.longopts && arg.longopts.startsWith('_')){\r\n attributes += \"readonly \";\r\n }\r\n let extraclass = arg.mincount > 0 ? 'is-invalid' : '';\r\n if (arg.glossary === 'hidden') {\r\n attributes += ' style=\"visibility: hidden;\"';\r\n }\r\n if (arg.checkbox) {\r\n innerhtml += `
`;\r\n } else if (arg.remark) {\r\n innerhtml += `
`;\r\n } else {\r\n innerhtml += `
`;\r\n if (placeholder.includes('|')) {\r\n extraclass = placeholder.startsWith('+') ? ' multiple ' : '';\r\n placeholder = placeholder\r\n .replace('<', '')\r\n .replace('=', '')\r\n .replace('>', '');\r\n innerhtml += `';\r\n } else {\r\n innerhtml += ``;\r\n }\r\n } \r\n\r\n if (!arg.remark) {\r\n innerhtml += `Previous value: ${arg.checkbox ? (curvalue ? 'Checked' : 'Unchecked') : (curvalue || '')}`;\r\n }\r\n innerhtml += `
`;\r\n });\r\n }\r\n innerhtml += `
\r\n
\r\n
\r\n Result\r\n
\r\n
\r\n
`;\r\n if (isConfig) {\r\n innerhtml +=\r\n `\r\n`;\r\n } else {\r\n innerhtml += ``;\r\n }\r\n innerhtml += '
';\r\n if (isConfig) {\r\n $(targetDiv).append(innerhtml);\r\n } else {\r\n $('#commands-list').append(innerhtml);\r\n }\r\n }\r\n });\r\n $(\".sclk\").off('click').on('click', function () { runCommand(this, false); });\r\n $(\".cclk\").off('click').on('click', function () { runCommand(this, true); });\r\n data.commands.forEach(function (command) {\r\n $('[cmdname=' + command.name + ']:input').val('');\r\n $('[cmdname=' + command.name + ']:checkbox').prop('checked', false);\r\n if (command.argtable) {\r\n command.argtable.forEach(function (arg) {\r\n const ctrlselector = '#' + command.name + '-' + arg.longopts;\r\n const ctrlValue = getLongOps(data, command.name, arg.longopts);\r\n if (arg.checkbox) {\r\n $(ctrlselector)[0].checked = ctrlValue;\r\n } else if (!arg.remark) {\r\n if (ctrlValue !== undefined) {\r\n $(ctrlselector)\r\n .val(ctrlValue)\r\n .trigger('change');\r\n if (arg.mincount && arg.mincount > 0) {\r\n $(ctrlselector).removeClass('is-invalid');\r\n $(ctrlselector).addClass('is-valid');\r\n }\r\n }\r\n if (\r\n $(ctrlselector)[0].value.length === 0 &&\r\n (arg.datatype || '').includes('|')\r\n ) {\r\n $(ctrlselector)[0].value = '--';\r\n }\r\n }\r\n });\r\n }\r\n });\r\n loadPresets();\r\n }).fail(function (xhr, ajaxOptions, thrownError) {\r\n if (xhr.status == 404) {\r\n $('.orec').hide();\r\n }\r\n else {\r\n handleExceptionResponse(xhr, ajaxOptions, thrownError);\r\n }\r\n $('#commands-list').empty();\r\n\r\n });\r\n}\r\n\r\nfunction getConfig() {\r\n $.ajaxSetup({\r\n timeout: 7000 //Time in milliseconds\r\n });\r\n $.getJSON('/config.json', function (entries) {\r\n $('#nvsTable tr').remove();\r\n const data = (entries.config ? entries.config : entries);\r\n SystemConfig = data;\r\n commandBTSinkName = '';\r\n Object.keys(data)\r\n .sort()\r\n .forEach(function (key) {\r\n let val = data[key].value;\r\n if (key === 'autoexec') {\r\n\r\n } else if (key === 'host_name') {\r\n val = val.replaceAll('\"', '');\r\n $('input#dhcp-name1').val(val);\r\n $('input#dhcp-name2').val(val);\r\n if ($('#cmd_opt_n').length == 0) {\r\n $('#cmd_opt_n').val(val);\r\n }\r\n document.title = val;\r\n hostName = val;\r\n } else if (key === 'rel_api') {\r\n releaseURL = val;\r\n }\r\n else if (key === 'enable_airplay') {\r\n $(\"#s_airplay\").css({ display: isEnabled(val) ? 'inline' : 'none' })\r\n }\r\n else if (key === 'enable_cspot') {\r\n $(\"#s_cspot\").css({ display: isEnabled(val) ? 'inline' : 'none' })\r\n }\r\n else if (key == 'preset_name') {\r\n preset_name = val;\r\n }\r\n else if (key == 'board_model') {\r\n board_model = val;\r\n }\r\n\r\n $('tbody#nvsTable').append(\r\n '' +\r\n '' +\r\n key +\r\n '' +\r\n \"\" +\r\n \"' +\r\n '' +\r\n ''\r\n );\r\n $('input#' + key).val(data[key].value);\r\n });\r\n if(commandBTSinkName.length > 0) {\r\n // persist the sink name found in the autoexec1 command line\r\n $('#cfg-audio-bt_source-sink_name').val(commandBTSinkName);\r\n }\r\n $('tbody#nvsTable').append(\r\n \"\"\r\n );\r\n if (entries.gpio) {\r\n $('#pins').show();\r\n $('tbody#gpiotable tr').remove();\r\n entries.gpio.forEach(function (gpioEntry) {\r\n $('tbody#gpiotable').append(\r\n '' +\r\n gpioEntry.group +\r\n '' +\r\n gpioEntry.name +\r\n '' +\r\n gpioEntry.gpio +\r\n '' +\r\n (gpioEntry.fixed ? 'Fixed' : 'Configuration') +\r\n ''\r\n );\r\n });\r\n }\r\n else {\r\n $('#pins').hide();\r\n }\r\n }).fail(function (xhr, ajaxOptions, thrownError) {\r\n handleExceptionResponse(xhr, ajaxOptions, thrownError);\r\n });\r\n}\r\n\r\nfunction processSqueezeliteCommandLine(val) {\r\n const parsed = parseSqueezeliteCommandLine(val);\r\n if (parsed.output.toUpperCase().startsWith('I2S')) {\r\n handleTemplateTypeRadio('i2s');\r\n } else if (parsed.output.toUpperCase().startsWith('SPDIF')) {\r\n handleTemplateTypeRadio('spdif');\r\n } else if (parsed.output.toUpperCase().startsWith('BT')) {\r\n if(parsed.otherOptions.btname){ \r\n commandBTSinkName= parsed.otherOptions.btname;\r\n }\r\n handleTemplateTypeRadio('bt');\r\n\r\n }\r\n Object.keys(parsed.options).forEach(function (key) {\r\n const option = parsed.options[key];\r\n if (!$(`#cmd_opt_${key}`).hasOwnProperty('checked')) {\r\n $(`#cmd_opt_${key}`).val(option);\r\n } else {\r\n $(`#cmd_opt_${key}`)[0].checked = option;\r\n }\r\n });\r\n if (parsed.options.hasOwnProperty('u')) {\r\n // parse -u v[:i] and check the appropriate radio button with id #resample_v\r\n const [resampleValue, resampleInterpolation] = parsed.options.u.split(':');\r\n $(`#resample_${resampleValue}`).prop('checked', true);\r\n // if resampleinterpolation is set, check resample_i checkbox\r\n if (resampleInterpolation) {\r\n $('#resample_i').prop('checked', true);\r\n }\r\n }\r\n if (parsed.options.hasOwnProperty('s')) {\r\n // parse -u v[:i] and check the appropriate radio button with id #resample_v\r\n if(parsed.options.s === '-disable'){\r\n $('#disable-squeezelite')[0].checked = true;\r\n }\r\n else {\r\n $('#disable-squeezelite')[0].checked = false;\r\n }\r\n }\r\n\r\n \r\n\r\n\r\n}\r\n\r\nfunction showLocalMessage(message, severity) {\r\n const msg = {\r\n message: message,\r\n type: severity,\r\n };\r\n showMessage(msg, new Date());\r\n}\r\n\r\nfunction showMessage(msg, msgTime) {\r\n let color = 'table-success';\r\n\r\n if (msg.type === 'MESSAGING_WARNING') {\r\n color = 'table-warning';\r\n if (messageseverity === 'MESSAGING_INFO') {\r\n messageseverity = 'MESSAGING_WARNING';\r\n }\r\n } else if (msg.type === 'MESSAGING_ERROR') {\r\n if (\r\n messageseverity === 'MESSAGING_INFO' ||\r\n messageseverity === 'MESSAGING_WARNING'\r\n ) {\r\n messageseverity = 'MESSAGING_ERROR';\r\n }\r\n color = 'table-danger';\r\n }\r\n if (++messagecount > 0) {\r\n $('#msgcnt').removeClass('badge-success');\r\n $('#msgcnt').removeClass('badge-warning');\r\n $('#msgcnt').removeClass('badge-danger');\r\n $('#msgcnt').addClass(pillcolors[messageseverity]);\r\n $('#msgcnt').text(messagecount);\r\n }\r\n\r\n $('#syslogTable').append(\r\n \"\" +\r\n '' +\r\n msgTime.toLocalShort() +\r\n '' +\r\n '' +\r\n msg.message.encodeHTML() +\r\n '' +\r\n ''\r\n );\r\n}\r\n\r\nfunction inRange(x, min, max) {\r\n return (x - min) * (x - max) <= 0;\r\n}\r\n\r\nfunction sleep(ms) {\r\n return new Promise(resolve => setTimeout(resolve, ms));\r\n}\r\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nrequire(\"bootstrap\");\nrequire(\"./sass/main.scss\");\nrequire(\"./assets/images/favicon-32x32.png\");\nrequire(\"./js/custom.js\");\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t826: 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunksqueezelite_esp32\"] = self[\"webpackChunksqueezelite_esp32\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [987], () => (__webpack_require__(607)))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["deferred","he","require","Promise","get_control_option_value","obj","ctrl","id","val","opt","$","concat","attr","checked","replace","includes","handleNVSVisible","nvs_previous_checked","isEnabled","Cookies","get","recovery","show","hide","undefined","match","window","bootstrap","String","prototype","format","Object","assign","args","arguments","this","number","encodeHTML","encode","Date","toLocalShort","toLocaleString","dateStyle","timeStyle","nvsTypes","btIcons","bt_playing","bt_disconnected","bt_neutral","bt_connecting","bt_connected","bt_disabled","play_arrow","pause","stop","batIcons","icon","label","ranges","f","t","btStateIcons","desc","sub","pillcolors","MESSAGING_INFO","MESSAGING_WARNING","MESSAGING_ERROR","connectReturnCode","OK","FAIL","DISC","LOST","RESTORE","ETH","taskStates","flashState","NONE","REBOOT_TO_RECOVERY","SET_FWURL","FLASHING","DONE","UPLOADING","ERROR","UPLOADCOMPLETE","_state","olderRecovery","statusText","flashURL","flashFileName","statusPercent","Completed","prevRecovery","updateModal","Modal","document","getElementById","reset","UpdateProgress","removeClass","prop","value","isStateError","html","parent","isStateUploadComplete","isStateNone","isStateRebootRecovery","isStateSetUrl","isStateFlashing","isStateDone","isStateUploading","init","SetStateError","addClass","SetStateNone","SetStateRebootRecovery","SetStatusText","ajax","url","context","dataType","method","cache","contentType","data","JSON","stringify","timestamp","now","error","xhr","_ajaxOptions","thrownError","_xhr$status","setOTAError","status","complete","response","SetStateSetUrl","post_config","fwurl","type","SetStateFlashing","SetStateDone","SetStateUploading","SetStateUploadComplete","isFlashExecuting","toString","_this","keys","find","x","setOTATargets","fileInput","files","length","message","SetStatusPercent","ShowDialog","pct","pctChanged","txt","changed","css","text","StartOTA","logEvent","name","TargetReadyStartOTA","UploadLocalFile","xhttp","XMLHttpRequest","boundHandleUploadProgressEvent","HandleUploadProgressEvent","bind","boundsetOTAError","upload","addEventListener","onreadystatechange","readyState","open","send","console","Math","round","loaded","total","EventTargetStatus","_data$ota_pct","_data$ota_dsc","ota_pct","ota_dsc","EventOTAMessageClass","otaData","parse","fun","log","hideSurrounding","presetsloaded","messageInterval","confPayload","config","handleExceptionResponse","isConnected","ConnectedTo","hasOwnProperty","ip","getIcon","icons","handleTemplateTypeRadio","outtype","children","display","output","commandDefaults","forEach","key","showLocalMessage","showCmdMessage","cmdname","msgtype","msgtext","append","color","escapedtext","substring","hFlash","handleReboot","link","delayReboot","lmsBaseUrl","releaseURL","messagesHeld","commandBTSinkName","i2s","b","C","W","Z","o","spdif","bt","validOptions","codecs","messagecount","messageseverity","SystemConfig","LastCommandsState","hostName","versionName","prevmessage","project_name","board_model","platform_name","preset_name","btSinkNamesOptSel","ConnectingToSSID","prevLMSIP","ConnectingToActions","getConfigJson","slimMode","each","_index","entry","nvsType","parseInt","attributes","nvs_type","duration","empty","resolve","delay","then","rdata","HideCmdMessage","getCommands","getConfig","setPlatformFilter","filter","toUpperCase","trigger","renderError","fieldname","errorFieldName","errorField","field","after","rssiToIcon","rssi","refreshAP","_ConnectedTo","urc","ajaxSetup","timeout","getJSON","_asyncToGenerator","_regeneratorRuntime","_callee","_context","prev","next","sleep","sort","a","y","refreshAPHTML2","formatAP","ssid","auth","rssi_icon","auth_icon","_ConnectedTo2","h","e","_ConnectedTo$rssi","wifiSelector","prepend","siblings","first","showTask","task","debug","nme","cpu","st","minstk","bprio","cprio","num","getBTSinkOpt","getMessages","_ref2","_callee2","_iterator","_step","_loop","msgTime","statsData","msgparts","attrs","j","curOpt","_context3","_createForOfIteratorHelper","msg","msgAge","_context2","current_time","sent_time","setTime","getTime","t0","abrupt","ntasks","tasks","showMessage","split","is","item","replaceWith","btEntry","remove","s","n","done","delegateYield","t1","finish","setTimeout","_x","apply","fail","ajaxOptions","handleWifiDialog","gw","netmask","Action","STS","ap_ssid","ap_pwd","setIcons","offline","textContent","handleNetworkStatus","hasConnectionChanged","checkStatus","_data$message","_data$recovery","handleRecoveryMode","tt","bt_status","bt_sub_status","iconindex","handlebtstate","depth","version","Voltage","bat_icon","voltage","_i3","_batIcons","_step2","iconEntry","_iterator2","entryRanges","err","batteryToIcon","is_i2c_locked","lms_ip","lms_port","baseUrl","success","Number","Jack","getLongOps","longopts","values","commands","command","cmdParts","isConfig","targetDiv","innerhtml","help","argtable","arg","placeholder","datatype","ctrlname","curvalue","hasvalue","shortopts","checkbox","startsWith","extraclass","mincount","glossary","remark","choice","off","on","runCommand","ctrlselector","ctrlValue","_","jqxhr","textStatus","entries","replaceAll","title","gpio","gpioEntry","fixed","group","severity","ms","reason","_resolve","reject","saveAutoexec1","commandLine","_get_control_option_v","optStr","resample","options","_i","_Object$entries","_Object$entries$_i","_slicedToArray","option","concatenateOptions","autoexec1","responseText","result","Result","handleDisconnect","handleConnect","pwd","dhcpname","ready","index","not","_get_control_option_v2","invalid","map","trim","join","test","event","relatedTarget","CONN","MAN","FileReader","file","fr","onload","target","ex","alert","readAsText","slideUp","slideDown","preventDefault","currentValue","originalValue","set","createElement","href","URL","createObjectURL","Blob","setAttribute","body","appendChild","click","removeChild","branches","release","branch","push","fwb","assets","asset","browser_download_url","namecomponents","ver","cfg","bits","substr","lastIndexOf","created_at","i","idf","trclass","setURL","button","dataset","reboot","cmdstring","fields","allfields","querySelectorAll","selJson","cmd","model_config","_i2","_Object$entries2","_Object$entries2$_i","storedval","handleHWPreset","_step3","_iterator3","_attr$hasvalue","qts","isSelect","hasValue","validVal","_attr$longopts","_attr$shortopts","_attr$hasvalue2","_attr$longopts2","indexOf","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","module","__webpack_modules__","call","m","O","chunkIds","fn","priority","notFulfilled","Infinity","fulfilled","every","splice","r","getter","__esModule","d","definition","defineProperty","enumerable","g","globalThis","Function","Symbol","toStringTag","nmd","paths","installedChunks","chunkId","webpackJsonpCallback","parentChunkLoadingFunction","moreModules","runtime","some","chunkLoadingGlobal","self","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file diff --git a/components/wifi-manager/webapp/dist/js/index.4135c4.bundle.js.map b/components/wifi-manager/webapp/dist/js/index.4135c4.bundle.js.map deleted file mode 100644 index 2a04f349b..000000000 --- a/components/wifi-manager/webapp/dist/js/index.4135c4.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"./js/index.4135c4.bundle.js","mappings":"uBAAIA,E,omCCAJ,IAAIC,EAAKC,EAAQ,KACbC,EAAUD,EAAAA,KAAAA,QA6Bd,SAASE,EAAyBC,GAChC,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AAoB,OAC7FwC,EAAsBxC,EAAoBQ,EAAEgC,E","sources":["webpack://squeezelite-esp32/webpack/runtime/chunk loaded","webpack://squeezelite-esp32/./src/js/custom.js","webpack://squeezelite-esp32/./src/index.ts","webpack://squeezelite-esp32/webpack/bootstrap","webpack://squeezelite-esp32/webpack/runtime/compat get default export","webpack://squeezelite-esp32/webpack/runtime/define property getters","webpack://squeezelite-esp32/webpack/runtime/global","webpack://squeezelite-esp32/webpack/runtime/hasOwnProperty shorthand","webpack://squeezelite-esp32/webpack/runtime/make namespace object","webpack://squeezelite-esp32/webpack/runtime/node module decorator","webpack://squeezelite-esp32/webpack/runtime/jsonp chunk loading","webpack://squeezelite-esp32/webpack/startup"],"sourcesContent":["var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var he = require('he');\r\nvar Promise = require('es6-promise').Promise;\r\nwindow.bootstrap = require('bootstrap');\r\nimport Cookies from 'js-cookie';\r\n\r\n\r\n\r\nif (!String.prototype.format) {\r\n Object.assign(String.prototype, {\r\n format() {\r\n const args = arguments;\r\n return this.replace(/{(\\d+)}/g, function (match, number) {\r\n return typeof args[number] !== 'undefined' ? args[number] : match;\r\n });\r\n },\r\n });\r\n}\r\nif (!String.prototype.encodeHTML) {\r\n Object.assign(String.prototype, {\r\n encodeHTML() {\r\n return he.encode(this).replace(/\\n/g, '
');\r\n },\r\n });\r\n}\r\nObject.assign(Date.prototype, {\r\n toLocalShort() {\r\n const opt = { dateStyle: 'short', timeStyle: 'short' };\r\n return this.toLocaleString(undefined, opt);\r\n },\r\n});\r\nfunction get_control_option_value(obj) {\r\n let ctrl,id,val,opt;\r\n let radio = false;\r\n let checked = false;\r\n if (typeof (obj) === 'string') {\r\n id = obj;\r\n ctrl = $(`#${id}`);\r\n } else {\r\n id = $(obj).attr('id');\r\n ctrl = $(obj);\r\n }\r\n if(ctrl.attr('type') === 'checkbox'){\r\n opt = $(obj).checked?id.replace('cmd_opt_', ''):'';\r\n val = true;\r\n }\r\n else {\r\n opt = id.replace('cmd_opt_', '');\r\n val = $(obj).val();\r\n val = `${val.includes(\" \") ? '\"' : ''}${val}${val.includes(\" \") ? '\"' : ''}`;\r\n }\r\n\r\n return { opt, val };\r\n}\r\nfunction handleNVSVisible() {\r\n let nvs_previous_checked = isEnabled(Cookies.get(\"show-nvs\"));\r\n $('input#show-nvs')[0].checked = nvs_previous_checked;\r\n if ($('input#show-nvs')[0].checked || recovery) {\r\n $('*[href*=\"-nvs\"]').show();\r\n } else {\r\n $('*[href*=\"-nvs\"]').hide();\r\n }\r\n}\r\nfunction concatenateOptions(options) {\r\n let commandLine = ' ';\r\n for (const [option, value] of Object.entries(options)) {\r\n if (option !== 'n' && option !== 'o') {\r\n commandLine += `-${option} `;\r\n if (value !== true) {\r\n commandLine += `${value} `;\r\n }\r\n }\r\n }\r\n return commandLine;\r\n}\r\n\r\nfunction isEnabled(val) {\r\n return val != undefined && typeof val === 'string' && val.match(\"[Yy1]\");\r\n}\r\n\r\nconst nvsTypes = {\r\n NVS_TYPE_U8: 0x01,\r\n /*! < Type uint8_t */\r\n NVS_TYPE_I8: 0x11,\r\n /*! < Type int8_t */\r\n NVS_TYPE_U16: 0x02,\r\n /*! < Type uint16_t */\r\n NVS_TYPE_I16: 0x12,\r\n /*! < Type int16_t */\r\n NVS_TYPE_U32: 0x04,\r\n /*! < Type uint32_t */\r\n NVS_TYPE_I32: 0x14,\r\n /*! < Type int32_t */\r\n NVS_TYPE_U64: 0x08,\r\n /*! < Type uint64_t */\r\n NVS_TYPE_I64: 0x18,\r\n /*! < Type int64_t */\r\n NVS_TYPE_STR: 0x21,\r\n /*! < Type string */\r\n NVS_TYPE_BLOB: 0x42,\r\n /*! < Type blob */\r\n NVS_TYPE_ANY: 0xff /*! < Must be last */,\r\n};\r\nconst btIcons = {\r\n bt_playing: { 'label': '', 'icon': 'media_bluetooth_on' },\r\n bt_disconnected: { 'label': '', 'icon': 'media_bluetooth_off' },\r\n bt_neutral: { 'label': '', 'icon': 'bluetooth' },\r\n bt_connecting: { 'label': '', 'icon': 'bluetooth_searching' },\r\n bt_connected: { 'label': '', 'icon': 'bluetooth_connected' },\r\n bt_disabled: { 'label': '', 'icon': 'bluetooth_disabled' },\r\n play_arrow: { 'label': '', 'icon': 'play_circle_filled' },\r\n pause: { 'label': '', 'icon': 'pause_circle' },\r\n stop: { 'label': '', 'icon': 'stop_circle' },\r\n '': { 'label': '', 'icon': '' }\r\n};\r\nconst batIcons = [\r\n { icon: \"battery_0_bar\", label: '▪', ranges: [{ f: 5.8, t: 6.8 }, { f: 8.8, t: 10.2 }] },\r\n { icon: \"battery_2_bar\", label: '▪▪', ranges: [{ f: 6.8, t: 7.4 }, { f: 10.2, t: 11.1 }] },\r\n { icon: \"battery_3_bar\", label: '▪▪▪', ranges: [{ f: 7.4, t: 7.5 }, { f: 11.1, t: 11.25 }] },\r\n { icon: \"battery_4_bar\", label: '▪▪▪▪', ranges: [{ f: 7.5, t: 7.8 }, { f: 11.25, t: 11.7 }] }\r\n];\r\nconst btStateIcons = [\r\n { desc: 'Idle', sub: ['bt_neutral'] },\r\n { desc: 'Discovering', sub: ['bt_connecting'] },\r\n { desc: 'Discovered', sub: ['bt_connecting'] },\r\n { desc: 'Unconnected', sub: ['bt_disconnected'] },\r\n { desc: 'Connecting', sub: ['bt_connecting'] },\r\n {\r\n desc: 'Connected',\r\n sub: ['bt_connected', 'play_arrow', 'bt_playing', 'pause', 'stop'],\r\n },\r\n { desc: 'Disconnecting', sub: ['bt_disconnected'] },\r\n];\r\n\r\nconst pillcolors = {\r\n MESSAGING_INFO: 'badge-success',\r\n MESSAGING_WARNING: 'badge-warning',\r\n MESSAGING_ERROR: 'badge-danger',\r\n};\r\nconst connectReturnCode = {\r\n OK: 0,\r\n FAIL: 1,\r\n DISC: 2,\r\n LOST: 3,\r\n RESTORE: 4,\r\n ETH: 5\r\n}\r\nconst taskStates = {\r\n 0: 'eRunning',\r\n /*! < A task is querying the state of itself, so must be running. */\r\n 1: 'eReady',\r\n /*! < The task being queried is in a read or pending ready list. */\r\n 2: 'eBlocked',\r\n /*! < The task being queried is in the Blocked state. */\r\n 3: 'eSuspended',\r\n /*! < The task being queried is in the Suspended state, or is in the Blocked state with an infinite time out. */\r\n 4: 'eDeleted',\r\n};\r\nlet flashState = {\r\n NONE: 0,\r\n REBOOT_TO_RECOVERY: 2,\r\n SET_FWURL: 5,\r\n FLASHING: 6,\r\n DONE: 7,\r\n UPLOADING: 8,\r\n ERROR: 9,\r\n UPLOADCOMPLETE: 10,\r\n _state: -1,\r\n olderRecovery: false,\r\n statusText: '',\r\n flashURL: '',\r\n flashFileName: '',\r\n statusPercent: 0,\r\n Completed: false,\r\n recovery: false,\r\n prevRecovery: false,\r\n updateModal: new bootstrap.Modal(document.getElementById('otadiv'), {}),\r\n reset: function () {\r\n\r\n this.olderRecovery = false;\r\n this.statusText = '';\r\n this.statusPercent = -1;\r\n this.flashURL = '';\r\n this.flashFileName = undefined;\r\n this.UpdateProgress();\r\n $('#rTable tr.release').removeClass('table-success table-warning');\r\n $('.flact').prop('disabled', false);\r\n $('#flashfilename').value = null;\r\n $('#fw-url-input').value = null;\r\n if (!this.isStateError()) {\r\n $('span#flash-status').html('');\r\n $('#fwProgressLabel').parent().removeClass('bg-danger');\r\n }\r\n this._state = this.NONE\r\n return this;\r\n },\r\n isStateUploadComplete: function () {\r\n return this._state == this.UPLOADCOMPLETE;\r\n },\r\n isStateError: function () {\r\n return this._state == this.ERROR;\r\n },\r\n isStateNone: function () {\r\n return this._state == this.NONE;\r\n },\r\n isStateRebootRecovery: function () {\r\n return this._state == this.REBOOT_TO_RECOVERY;\r\n },\r\n isStateSetUrl: function () {\r\n return this._state == this.SET_FWURL;\r\n },\r\n isStateFlashing: function () {\r\n return this._state == this.FLASHING;\r\n },\r\n isStateDone: function () {\r\n return this._state == this.DONE;\r\n },\r\n isStateUploading: function () {\r\n return this._state == this.UPLOADING;\r\n },\r\n init: function () {\r\n this._state = this.NONE;\r\n return this;\r\n },\r\n\r\n SetStateError: function () {\r\n this._state = this.ERROR;\r\n $('#fwProgressLabel').parent().addClass('bg-danger');\r\n return this;\r\n },\r\n SetStateNone: function () {\r\n this._state = this.NONE;\r\n return this;\r\n },\r\n SetStateRebootRecovery: function () {\r\n this._state = this.REBOOT_TO_RECOVERY;\r\n // Reboot system to recovery mode\r\n this.SetStatusText('Starting recovery mode.')\r\n $.ajax({\r\n url: '/recovery.json',\r\n context: this,\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify({\r\n timestamp: Date.now(),\r\n }),\r\n error: function (xhr, _ajaxOptions, thrownError) {\r\n this.setOTAError(`Unexpected error while trying to restart to recovery. (status=${xhr.status ?? ''}, error=${thrownError ?? ''} ) `);\r\n },\r\n complete: function (response) {\r\n this.SetStatusText('Waiting for system to boot.')\r\n },\r\n });\r\n return this;\r\n },\r\n SetStateSetUrl: function () {\r\n this._state = this.SET_FWURL;\r\n this.statusText = 'Sending firmware download location.';\r\n let confData = {\r\n fwurl: {\r\n value: this.flashURL,\r\n type: 33,\r\n }\r\n };\r\n post_config(confData);\r\n return this;\r\n },\r\n SetStateFlashing: function () {\r\n this._state = this.FLASHING;\r\n return this;\r\n },\r\n SetStateDone: function () {\r\n this._state = this.DONE;\r\n this.reset();\r\n return this;\r\n },\r\n SetStateUploading: function () {\r\n this._state = this.UPLOADING;\r\n return this.SetStatusText('Sending file to device.');\r\n },\r\n SetStateUploadComplete: function () {\r\n this._state = this.UPLOADCOMPLETE;\r\n return this;\r\n },\r\n\r\n isFlashExecuting: function () {\r\n return true === (this._state != this.UPLOADING && (this.statusText !== '' || this.statusPercent >= 0));\r\n },\r\n\r\n\r\n\r\n toString: function () {\r\n let keys = Object.keys(this);\r\n return keys.find(x => this[x] === this._state);\r\n },\r\n\r\n setOTATargets: function () {\r\n this.flashURL = '';\r\n this.flashFileName = '';\r\n this.flashURL = $('#fw-url-input').val();\r\n let fileInput = $('#flashfilename')[0].files;\r\n if (fileInput.length > 0) {\r\n this.flashFileName = fileInput[0];\r\n }\r\n if (this.flashFileName.length == 0 && this.flashURL.length == 0) {\r\n this.setOTAError('Invalid url or file. Cannot start OTA');\r\n }\r\n return this;\r\n },\r\n\r\n setOTAError: function (message) {\r\n this.SetStateError().SetStatusPercent(0).SetStatusText(message).reset();\r\n return this;\r\n },\r\n\r\n ShowDialog: function () {\r\n if (!this.isStateNone()) {\r\n this.updateModal.show();\r\n $('.flact').prop('disabled', true);\r\n }\r\n return this;\r\n },\r\n\r\n SetStatusPercent: function (pct) {\r\n var pctChanged = (this.statusPercent != pct);\r\n this.statusPercent = pct;\r\n if (pctChanged) {\r\n if (!this.isStateUploading() && !this.isStateFlashing()) {\r\n this.SetStateFlashing();\r\n }\r\n if (pct == 100) {\r\n if (this.isStateFlashing()) {\r\n this.SetStateDone();\r\n }\r\n else if (this.isStateUploading()) {\r\n this.statusPercent = 0;\r\n this.SetStateFlashing();\r\n }\r\n }\r\n this.UpdateProgress().ShowDialog();\r\n }\r\n return this;\r\n },\r\n SetStatusText: function (txt) {\r\n var changed = (this.statusText != txt);\r\n this.statusText = txt;\r\n if (changed) {\r\n $('span#flash-status').html(this.statusText);\r\n this.ShowDialog();\r\n }\r\n\r\n return this;\r\n },\r\n UpdateProgress: function () {\r\n $('.progress-bar')\r\n .css('width', this.statusPercent + '%')\r\n .attr('aria-valuenow', this.statusPercent)\r\n .text(this.statusPercent + '%')\r\n $('.progress-bar').html((this.isStateDone() ? 100 : this.statusPercent) + '%');\r\n return this;\r\n },\r\n StartOTA: function () {\r\n this.logEvent(this.StartOTA.name);\r\n $('#fwProgressLabel').parent().removeClass('bg-danger');\r\n this.setOTATargets();\r\n if (this.isStateError()) {\r\n return this;\r\n }\r\n if (!recovery) {\r\n this.SetStateRebootRecovery();\r\n }\r\n else {\r\n this.SetStateFlashing().TargetReadyStartOTA();\r\n }\r\n\r\n return this;\r\n },\r\n UploadLocalFile: function () {\r\n this.SetStateUploading();\r\n const xhttp = new XMLHttpRequest();\r\n xhttp.context = this;\r\n var boundHandleUploadProgressEvent = this.HandleUploadProgressEvent.bind(this);\r\n var boundsetOTAError = this.setOTAError.bind(this);\r\n xhttp.upload.addEventListener(\"progress\", boundHandleUploadProgressEvent, false);\r\n xhttp.onreadystatechange = function () {\r\n if (xhttp.readyState === 4) {\r\n if (xhttp.status === 0 || xhttp.status === 404) {\r\n boundsetOTAError(`Upload Failed. Recovery version might not support uploading. Please use web update instead.`);\r\n }\r\n }\r\n };\r\n xhttp.open('POST', '/flash.json', true);\r\n xhttp.send(this.flashFileName);\r\n },\r\n TargetReadyStartOTA: function () {\r\n if (recovery && this.prevRecovery && !this.isStateRebootRecovery() && !this.isStateFlashing()) {\r\n // this should only execute once, while being in a valid state\r\n return this;\r\n }\r\n\r\n this.logEvent(this.TargetReadyStartOTA.name);\r\n if (!recovery) {\r\n console.error('Event TargetReadyStartOTA fired in the wrong mode ');\r\n return this;\r\n }\r\n this.prevRecovery = true;\r\n\r\n if (this.flashFileName !== '') {\r\n this.UploadLocalFile();\r\n }\r\n else if (this.flashURL != '') {\r\n this.SetStateSetUrl();\r\n }\r\n else {\r\n this.setOTAError('Invalid URL or file name while trying to start the OTa process')\r\n }\r\n },\r\n HandleUploadProgressEvent: function (data) {\r\n this.logEvent(this.HandleUploadProgressEvent.name);\r\n this.SetStateUploading().SetStatusPercent(Math.round(data.loaded / data.total * 100)).SetStatusText('Uploading file to device');\r\n },\r\n EventTargetStatus: function (data) {\r\n if (!this.isStateNone()) {\r\n this.logEvent(this.EventTargetStatus.name);\r\n }\r\n if (data.ota_pct ?? -1 >= 0) {\r\n this.olderRecovery = true;\r\n this.SetStatusPercent(data.ota_pct);\r\n }\r\n if ((data.ota_dsc ?? '') != '') {\r\n this.olderRecovery = true;\r\n this.SetStatusText(data.ota_dsc);\r\n }\r\n\r\n if (data.recovery != undefined) {\r\n this.recovery = data.recovery === 1 ? true : false;\r\n }\r\n if (this.isStateRebootRecovery() && this.recovery) {\r\n this.TargetReadyStartOTA();\r\n }\r\n },\r\n EventOTAMessageClass: function (data) {\r\n this.logEvent(this.EventOTAMessageClass.name);\r\n var otaData = JSON.parse(data);\r\n this.SetStatusPercent(otaData.ota_pct).SetStatusText(otaData.ota_dsc);\r\n },\r\n logEvent: function (fun) {\r\n console.log(`${fun}, flash state ${this.toString()}, recovery: ${this.recovery}, ota pct: ${this.statusPercent}, ota desc: ${this.statusText}`);\r\n }\r\n\r\n};\r\nwindow.hideSurrounding = function (obj) {\r\n $(obj).parent().parent().hide();\r\n}\r\n\r\nlet presetsloaded = false;\r\nlet is_i2c_locked = false;\r\nlet statusInterval = 2000;\r\nlet messageInterval = 2500;\r\nfunction post_config(data) {\r\n let confPayload = {\r\n timestamp: Date.now(),\r\n config: data\r\n };\r\n $.ajax({\r\n url: '/config.json',\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify(confPayload),\r\n error: handleExceptionResponse,\r\n });\r\n}\r\n\r\n\r\nwindow.hFlash = function () {\r\n // reset file upload selection if any;\r\n $('#flashfilename').value = null\r\n flashState.StartOTA();\r\n}\r\nwindow.handleReboot = function (link) {\r\n if (link == 'reboot_ota') {\r\n $('#reboot_ota_nav').removeClass('active').prop(\"disabled\", true); delayReboot(500, '', 'reboot_ota');\r\n }\r\n else {\r\n $('#reboot_nav').removeClass('active'); delayReboot(500, '', link);\r\n }\r\n}\r\n\r\nfunction parseSqueezeliteCommandLine(commandLine) {\r\n const options = {};\r\n let output, name;\r\n let otherValues = '';\r\n\r\n const argRegex = /(\"[^\"]+\"|'[^']+'|\\S+)/g;\r\n const args = commandLine.match(argRegex);\r\n\r\n let i = 0;\r\n\r\n while (i < args.length) {\r\n const arg = args[i];\r\n\r\n if (arg.startsWith('-')) {\r\n const option = arg.slice(1);\r\n\r\n if (option === '') {\r\n otherValues += args.slice(i).join(' ');\r\n break;\r\n }\r\n\r\n let value = true;\r\n\r\n if (i + 1 < args.length && !args[i + 1].startsWith('-')) {\r\n value = args[i + 1].replace(/\"/g, '').replace(/'/g, '');\r\n i++;\r\n }\r\n\r\n options[option] = value;\r\n } else {\r\n otherValues += arg + ' ';\r\n }\r\n\r\n i++;\r\n }\r\n\r\n otherValues = otherValues.trim();\r\n output = getOutput(options);\r\n name = getName(options);\r\n let otherOptions={btname:null,n:null};\r\n // assign o and n options to otheroptions if present\r\n if (options.o && output.toUpperCase() === 'BT') {\r\n let temp = parseSqueezeliteCommandLine(options.o);\r\n if(temp.name) {\r\n otherOptions.btname = temp.name;\r\n }\r\n delete options.o;\r\n }\r\n if (options.n) {\r\n otherOptions['n'] = options.n;\r\n delete options.n;\r\n }\r\n return { name, output, options, otherValues,otherOptions }; \r\n}\r\n\r\nfunction getOutput(options) {\r\n let output;\r\n if (options.o){\r\n output = options.o.replace(/\"/g, '').replace(/'/g, '');\r\n /* set output as the first alphanumerical word in the command line */\r\n if (output.indexOf(' ') > 0) {\r\n output = output.substring(0, output.indexOf(' '));\r\n }\r\n }\r\n return output;\r\n}\r\n\r\nfunction getName(options) {\r\n let name;\r\n /* if n option present, assign to name variable */\r\n if (options.n){\r\n name = options.n.replace(/\"/g, '').replace(/'/g, '');\r\n }\r\n return name;\r\n}\r\n\r\n\r\nfunction isConnected() {\r\n return ConnectedTo.hasOwnProperty('ip') && ConnectedTo.ip != '0.0.0.0' && ConnectedTo.ip != '';\r\n}\r\nfunction getIcon(icons) {\r\n return isConnected() ? icons.icon : icons.label;\r\n}\r\nfunction handlebtstate(data) {\r\n let icon = '';\r\n let tt = '';\r\n if (data.bt_status !== undefined && data.bt_sub_status !== undefined) {\r\n const iconindex = btStateIcons[data.bt_status].sub[data.bt_sub_status];\r\n if (iconindex) {\r\n icon = btIcons[iconindex];\r\n tt = btStateIcons[data.bt_status].desc;\r\n } else {\r\n icon = btIcons.bt_connected;\r\n tt = 'Output status';\r\n }\r\n }\r\n\r\n $('#o_type').attr('title', tt);\r\n $('#o_bt').html(isConnected() ? icon.label : icon.text);\r\n}\r\nfunction handleTemplateTypeRadio(outtype) {\r\n $('#o_type').children('span').css({ display: 'none' });\r\n let changed = false;\r\n if (outtype === 'bt') {\r\n changed = output !== 'bt' && output !== '';\r\n output = 'bt';\r\n } else if (outtype === 'spdif') {\r\n changed = output !== 'spdif' && output !== '';\r\n output = 'spdif';\r\n } else {\r\n changed = output !== 'i2s' && output !== '';\r\n output = 'i2s';\r\n }\r\n $('#' + output).prop('checked', true);\r\n $('#o_' + output).css({ display: 'inline' });\r\n if (changed) {\r\n Object.keys(commandDefaults[output]).forEach(function (key) {\r\n $(`#cmd_opt_${key}`).val(commandDefaults[output][key]);\r\n });\r\n }\r\n}\r\n\r\nfunction handleExceptionResponse(xhr, _ajaxOptions, thrownError) {\r\n console.log(xhr.status);\r\n console.log(thrownError);\r\n if (thrownError !== '') {\r\n showLocalMessage(thrownError, 'MESSAGING_ERROR');\r\n }\r\n}\r\nfunction HideCmdMessage(cmdname) {\r\n $('#toast_' + cmdname)\r\n .removeClass('table-success')\r\n .removeClass('table-warning')\r\n .removeClass('table-danger')\r\n .addClass('table-success')\r\n .removeClass('show');\r\n $('#msg_' + cmdname).html('');\r\n}\r\nfunction showCmdMessage(cmdname, msgtype, msgtext, append = false) {\r\n let color = 'table-success';\r\n if (msgtype === 'MESSAGING_WARNING') {\r\n color = 'table-warning';\r\n } else if (msgtype === 'MESSAGING_ERROR') {\r\n color = 'table-danger';\r\n }\r\n $('#toast_' + cmdname)\r\n .removeClass('table-success')\r\n .removeClass('table-warning')\r\n .removeClass('table-danger')\r\n .addClass(color)\r\n .addClass('show');\r\n let escapedtext = msgtext\r\n .substring(0, msgtext.length - 1)\r\n .encodeHTML()\r\n .replace(/\\n/g, '
');\r\n escapedtext =\r\n ($('#msg_' + cmdname).html().length > 0 && append\r\n ? $('#msg_' + cmdname).html() + '
'\r\n : '') + escapedtext;\r\n $('#msg_' + cmdname).html(escapedtext);\r\n}\r\n\r\nlet releaseURL =\r\n 'https://api.github.com/repos/sle118/squeezelite-esp32/releases';\r\n\r\nlet recovery = false;\r\nlet messagesHeld = false;\r\nlet commandBTSinkName = '';\r\nconst commandHeader = 'squeezelite ';\r\nconst commandDefaults = {\r\n i2s: { b: \"500:2000\", C: \"30\", W: \"\", Z: \"96000\", o: \"I2S\" },\r\n spdif: { b: \"500:2000\", C: \"30\", W: \"\", Z: \"48000\", o: \"SPDIF\" },\r\n bt: { b: \"500:2000\", C: \"30\", W: \"\", Z: \"44100\", o: \"BT\" },\r\n};\r\nlet validOptions = {\r\n codecs: ['flac', 'pcm', 'mp3', 'ogg', 'aac', 'wma', 'alac', 'dsd', 'mad', 'mpg']\r\n};\r\n\r\n//let blockFlashButton = false;\r\nlet apList = null;\r\n//let selectedSSID = '';\r\n//let checkStatusInterval = null;\r\nlet messagecount = 0;\r\nlet messageseverity = 'MESSAGING_INFO';\r\nlet SystemConfig = {};\r\nlet LastCommandsState = null;\r\nvar output = '';\r\nlet hostName = '';\r\nlet versionName = 'Squeezelite-ESP32';\r\nlet prevmessage = '';\r\nlet project_name = versionName;\r\nlet depth = 16;\r\nlet board_model = '';\r\nlet platform_name = versionName;\r\nlet preset_name = '';\r\nlet btSinkNamesOptSel = '#cfg-audio-bt_source-sink_name';\r\nlet ConnectedTo = {};\r\nlet ConnectingToSSID = {};\r\nlet lmsBaseUrl;\r\nlet prevLMSIP = '';\r\nconst ConnectingToActions = {\r\n 'CONN': 0, 'MAN': 1, 'STS': 2,\r\n}\r\n\r\nPromise.prototype.delay = function (duration) {\r\n return this.then(\r\n function (value) {\r\n return new Promise(function (resolve) {\r\n setTimeout(function () {\r\n resolve(value);\r\n }, duration);\r\n });\r\n },\r\n function (reason) {\r\n return new Promise(function (_resolve, reject) {\r\n setTimeout(function () {\r\n reject(reason);\r\n }, duration);\r\n });\r\n }\r\n );\r\n};\r\n\r\nfunction getConfigJson(slimMode) {\r\n const config = {};\r\n $('input.nvs').each(function (_index, entry) {\r\n if (!slimMode) {\r\n const nvsType = parseInt(entry.attributes.nvs_type.value, 10);\r\n if (entry.id !== '') {\r\n config[entry.id] = {};\r\n if (\r\n nvsType === nvsTypes.NVS_TYPE_U8 ||\r\n nvsType === nvsTypes.NVS_TYPE_I8 ||\r\n nvsType === nvsTypes.NVS_TYPE_U16 ||\r\n nvsType === nvsTypes.NVS_TYPE_I16 ||\r\n nvsType === nvsTypes.NVS_TYPE_U32 ||\r\n nvsType === nvsTypes.NVS_TYPE_I32 ||\r\n nvsType === nvsTypes.NVS_TYPE_U64 ||\r\n nvsType === nvsTypes.NVS_TYPE_I64\r\n ) {\r\n config[entry.id].value = parseInt(entry.value);\r\n } else {\r\n config[entry.id].value = entry.value;\r\n }\r\n config[entry.id].type = nvsType;\r\n }\r\n } else {\r\n config[entry.id] = entry.value;\r\n }\r\n });\r\n const key = $('#nvs-new-key').val();\r\n const val = $('#nvs-new-value').val();\r\n if (key !== '') {\r\n if (!slimMode) {\r\n config[key] = {};\r\n config[key].value = val;\r\n config[key].type = 33;\r\n } else {\r\n config[key] = val;\r\n }\r\n }\r\n return config;\r\n}\r\n\r\nfunction handleHWPreset(allfields, reboot) {\r\n\r\n const selJson = JSON.parse(allfields[0].value);\r\n var cmd = allfields[0].attributes.cmdname.value;\r\n\r\n console.log(`selected model: ${selJson.name}`);\r\n let confPayload = {\r\n timestamp: Date.now(),\r\n config: { model_config: { value: selJson.name, type: 33 } }\r\n };\r\n for (const [name, value] of Object.entries(selJson.config)) {\r\n const storedval = (typeof value === 'string' || value instanceof String) ? value : JSON.stringify(value);\r\n confPayload.config[name] = {\r\n value: storedval,\r\n type: 33,\r\n }\r\n showCmdMessage(\r\n cmd,\r\n 'MESSAGING_INFO',\r\n `Setting ${name}=${storedval} `,\r\n true\r\n );\r\n }\r\n\r\n showCmdMessage(\r\n cmd,\r\n 'MESSAGING_INFO',\r\n `Committing `,\r\n true\r\n );\r\n $.ajax({\r\n url: '/config.json',\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify(confPayload),\r\n error: function (xhr, _ajaxOptions, thrownError) {\r\n handleExceptionResponse(xhr, _ajaxOptions, thrownError);\r\n showCmdMessage(\r\n cmd,\r\n 'MESSAGING_ERROR',\r\n `Unexpected error ${(thrownError !== '') ? thrownError : 'with return status = ' + xhr.status} `,\r\n true\r\n );\r\n },\r\n success: function (response) {\r\n showCmdMessage(\r\n cmd,\r\n 'MESSAGING_INFO',\r\n `Saving complete `,\r\n true\r\n );\r\n console.log(response);\r\n if (reboot) {\r\n delayReboot(2500, cmd);\r\n }\r\n },\r\n });\r\n}\r\n\r\n\r\n// pull json file from https://gist.githubusercontent.com/sle118/dae585e157b733a639c12dc70f0910c5/raw/b462691f69e2ad31ac95c547af6ec97afb0f53db/squeezelite-esp32-presets.json and\r\nfunction loadPresets() {\r\n if ($(\"#cfg-hw-preset-model_config\").length == 0) return;\r\n if (presetsloaded) return;\r\n presetsloaded = true;\r\n $('#cfg-hw-preset-model_config').html('');\r\n $.getJSON(\r\n 'https://gist.githubusercontent.com/sle118/dae585e157b733a639c12dc70f0910c5/raw/',\r\n { _: new Date().getTime() },\r\n function (data) {\r\n $.each(data, function (key, val) {\r\n $('#cfg-hw-preset-model_config').append(``);\r\n if (preset_name !== '' && preset_name == val.name) {\r\n $('#cfg-hw-preset-model_config').val(preset_name);\r\n }\r\n });\r\n if (preset_name !== '') {\r\n ('#prev_preset').show().val(preset_name);\r\n }\r\n }\r\n\r\n ).fail(function (jqxhr, textStatus, error) {\r\n const err = textStatus + ', ' + error;\r\n console.log('Request Failed: ' + err);\r\n }\r\n );\r\n}\r\n\r\nfunction delayReboot(duration, cmdname, ota = 'reboot') {\r\n const url = '/' + ota + '.json';\r\n $('tbody#tasks').empty();\r\n $('#tasks_sect').css('visibility', 'collapse');\r\n Promise.resolve({ cmdname: cmdname, url: url })\r\n .delay(duration)\r\n .then(function (data) {\r\n if (data.cmdname.length > 0) {\r\n showCmdMessage(\r\n data.cmdname,\r\n 'MESSAGING_WARNING',\r\n 'System is rebooting.\\n',\r\n true\r\n );\r\n } else {\r\n showLocalMessage('System is rebooting.\\n', 'MESSAGING_WARNING');\r\n }\r\n console.log('now triggering reboot');\r\n $(\"button[onclick*='handleReboot']\").addClass('rebooting');\r\n $.ajax({\r\n url: data.url,\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify({\r\n timestamp: Date.now(),\r\n }),\r\n error: handleExceptionResponse,\r\n complete: function () {\r\n console.log('reboot call completed');\r\n Promise.resolve(data)\r\n .delay(6000)\r\n .then(function (rdata) {\r\n if (rdata.cmdname.length > 0) {\r\n HideCmdMessage(rdata.cmdname);\r\n }\r\n getCommands();\r\n getConfig();\r\n });\r\n },\r\n });\r\n });\r\n}\r\n// eslint-disable-next-line no-unused-vars\r\nwindow.saveAutoexec1 = function (apply) {\r\n showCmdMessage('cfg-audio-tmpl', 'MESSAGING_INFO', 'Saving.\\n', false);\r\n let commandLine = `${commandHeader} -o ${output} `;\r\n $('.sqcmd').each(function () {\r\n let { opt, val } = get_control_option_value($(this));\r\n if ((opt && opt.length>0 ) && typeof(val) == 'boolean' || val.length > 0) {\r\n const optStr=opt===':'?opt:(` -${opt} `);\r\n val = typeof(val) == 'boolean'?'':val;\r\n commandLine += `${optStr} ${val}`;\r\n }\r\n });\r\n const resample=$('#cmd_opt_R input[name=resample]:checked');\r\n if (resample.length>0 && resample.attr('suffix')!=='') {\r\n commandLine += resample.attr('suffix');\r\n // now check resample_i option and if checked, add suffix to command line\r\n if ($('#resample_i').is(\":checked\") && resample.attr('aint') =='true') {\r\n commandLine += $('#resample_i').attr('suffix');\r\n }\r\n}\r\n\r\n \r\n if (output === 'bt') {\r\n showCmdMessage(\r\n 'cfg-audio-tmpl',\r\n 'MESSAGING_INFO',\r\n 'Remember to configure the Bluetooth audio device name.\\n',\r\n true\r\n );\r\n }\r\n commandLine += concatenateOptions(options);\r\n const data = {\r\n timestamp: Date.now(),\r\n };\r\n data.config = {\r\n autoexec1: { value: commandLine, type: 33 },\r\n // autoexec: {\r\n // value: $('#disable-squeezelite').prop('checked') ? '0' : '1',\r\n // type: 33,\r\n // },\r\n };\r\n\r\n $.ajax({\r\n url: '/config.json',\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify(data),\r\n error: handleExceptionResponse,\r\n complete: function (response) {\r\n if (\r\n response.responseText &&\r\n JSON.parse(response.responseText).result === 'OK'\r\n ) {\r\n showCmdMessage('cfg-audio-tmpl', 'MESSAGING_INFO', 'Done.\\n', true);\r\n if (apply) {\r\n delayReboot(1500, 'cfg-audio-tmpl');\r\n }\r\n } else if (JSON.parse(response.responseText).result) {\r\n showCmdMessage(\r\n 'cfg-audio-tmpl',\r\n 'MESSAGING_WARNING',\r\n JSON.parse(response.responseText).Result + '\\n',\r\n true\r\n );\r\n } else {\r\n showCmdMessage(\r\n 'cfg-audio-tmpl',\r\n 'MESSAGING_ERROR',\r\n response.statusText + '\\n'\r\n );\r\n }\r\n console.log(response.responseText);\r\n },\r\n });\r\n console.log('sent data:', JSON.stringify(data));\r\n}\r\nwindow.handleDisconnect = function () {\r\n $.ajax({\r\n url: '/connect.json',\r\n dataType: 'text',\r\n method: 'DELETE',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify({\r\n timestamp: Date.now(),\r\n }),\r\n });\r\n}\r\nfunction setPlatformFilter(val) {\r\n if ($('.upf').filter(function () { return $(this).text().toUpperCase() === val.toUpperCase() }).length > 0) {\r\n $('#splf').val(val).trigger('input');\r\n return true;\r\n }\r\n return false;\r\n}\r\nwindow.handleConnect = function () {\r\n ConnectingToSSID.ssid = $('#manual_ssid').val();\r\n ConnectingToSSID.pwd = $('#manual_pwd').val();\r\n ConnectingToSSID.dhcpname = $('#dhcp-name2').val();\r\n $(\"*[class*='connecting']\").hide();\r\n $('#ssid-wait').text(ConnectingToSSID.ssid);\r\n $('.connecting').show();\r\n $.ajax({\r\n url: '/connect.json',\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify({\r\n timestamp: Date.now(),\r\n ssid: ConnectingToSSID.ssid,\r\n pwd: ConnectingToSSID.pwd\r\n }),\r\n error: handleExceptionResponse,\r\n });\r\n\r\n // now we can re-set the intervals regardless of result\r\n\r\n}\r\nfunction renderError(opt,error){\r\n const fieldname = `cmd_opt_${opt}`;\r\n let errorFieldName=`${fieldname}-error`;\r\n let errorField=$(`#${errorFieldName}`);\r\n let field=$(`#${fieldname}`);\r\n \r\n if (!errorField || errorField.length ==0) {\r\n field.after(`
`);\r\n errorField=$(`#${errorFieldName}`);\r\n }\r\n if(error.length ==0){\r\n errorField.hide();\r\n field.removeClass('is-invalid');\r\n field.addClass('is-valid');\r\n errorField.text('');\r\n }\r\n else { \r\n errorField.show();\r\n errorField.text(error);\r\n field.removeClass('is-valid');\r\n field.addClass('is-invalid');\r\n }\r\n return errorField;\r\n}\r\n$(document).ready(function () {\r\n $('.material-icons').each(function (_index, entry) {\r\n entry.attributes['icon'] = entry.textContent;\r\n });\r\n setIcons(true);\r\n handleNVSVisible();\r\n flashState.init();\r\n $('#fw-url-input').on('input', function () {\r\n if ($(this).val().length > 8 && ($(this).val().startsWith('http://') || $(this).val().startsWith('https://'))) {\r\n $('#start-flash').show();\r\n }\r\n else {\r\n $('#start-flash').hide();\r\n }\r\n });\r\n $('.upSrch').on('input', function () {\r\n const val = this.value;\r\n $(\"#rTable tr\").removeClass(this.id + '_hide');\r\n if (val.length > 0) {\r\n $(`#rTable td:nth-child(${$(this).parent().index() + 1})`).filter(function () {\r\n return !$(this).text().toUpperCase().includes(val.toUpperCase());\r\n }).parent().addClass(this.id + '_hide');\r\n }\r\n $('[class*=\"_hide\"]').hide();\r\n $('#rTable tr').not('[class*=\"_hide\"]').show()\r\n\r\n });\r\n setTimeout(refreshAP, 1500);\r\n /* add validation for cmd_opt_c, which accepts a comma separated list. \r\n getting known codecs from validOptions.codecs array\r\n use bootstrap classes to highlight the error with an overlay message */\r\n $('#options input').on('input', function () {\r\n const { opt, val } = get_control_option_value(this);\r\n if (opt === 'c' || opt === 'e') {\r\n const fieldname = `cmd_opt_${opt}_codec-error`;\r\n \r\n const values = val.split(',').map(function (item) {\r\n return item.trim();\r\n });\r\n /* get a list of invalid codecs */\r\n const invalid = values.filter(function (item) {\r\n return !validOptions.codecs.includes(item);\r\n });\r\n renderError(opt,invalid.length > 0 ? `Invalid codec(s) ${invalid.join(', ')}` : '');\r\n }\r\n /* add validation for cmd_opt_m, which accepts a mac_address */\r\n if (opt === 'm') {\r\n const mac_regex = /^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$/;\r\n renderError(opt,mac_regex.test(val) ? '' : 'Invalid MAC address');\r\n }\r\n if (opt === 'r') {\r\n const rateRegex = /^(\\d+\\.?\\d*|\\.\\d+)-(\\d+\\.?\\d*|\\.\\d+)$|^(\\d+\\.?\\d*)$|^(\\d+\\.?\\d*,)+\\d+\\.?\\d*$/;\r\n renderError(opt,rateRegex.test(val)?'':`Invalid rate(s) ${val}. Acceptable format: |-|,,`);\r\n }\r\n\r\n\r\n\r\n }\r\n\r\n\r\n );\r\n\r\n\r\n\r\n\r\n\r\n $('#WifiConnectDialog')[0].addEventListener('shown.bs.modal', function (event) {\r\n $(\"*[class*='connecting']\").hide();\r\n\r\n if (event?.relatedTarget) {\r\n ConnectingToSSID.Action = ConnectingToActions.CONN;\r\n if ($(event.relatedTarget).children('td:eq(1)').text() == ConnectedTo.ssid) {\r\n ConnectingToSSID.Action = ConnectingToActions.STS;\r\n }\r\n else {\r\n if (!$(event.relatedTarget).is(':last-child')) {\r\n ConnectingToSSID.ssid = $(event.relatedTarget).children('td:eq(1)').text();\r\n $('#manual_ssid').val(ConnectingToSSID.ssid);\r\n }\r\n else {\r\n ConnectingToSSID.Action = ConnectingToActions.MAN;\r\n ConnectingToSSID.ssid = '';\r\n $('#manual_ssid').val(ConnectingToSSID.ssid);\r\n }\r\n }\r\n }\r\n\r\n\r\n if (ConnectingToSSID.Action !== ConnectingToActions.STS) {\r\n $('.connecting-init').show();\r\n $('#manual_ssid').trigger('focus');\r\n }\r\n else {\r\n handleWifiDialog();\r\n }\r\n });\r\n\r\n $('#WifiConnectDialog')[0].addEventListener('hidden.bs.modal', function () {\r\n $('#WifiConnectDialog input').val('');\r\n });\r\n\r\n $('#uCnfrm')[0].addEventListener('shown.bs.modal', function () {\r\n $('#selectedFWURL').text($('#fw-url-input').val());\r\n });\r\n\r\n $('input#show-commands')[0].checked = LastCommandsState === 1;\r\n $('a[href^=\"#tab-commands\"]').hide();\r\n $('#load-nvs').on('click', function () {\r\n $('#nvsfilename').trigger('click');\r\n });\r\n $('#nvsfilename').on('change', function () {\r\n if (typeof window.FileReader !== 'function') {\r\n throw \"The file API isn't supported on this browser.\";\r\n }\r\n if (!this.files) {\r\n throw 'This browser does not support the `files` property of the file input.';\r\n }\r\n if (!this.files[0]) {\r\n return undefined;\r\n }\r\n\r\n const file = this.files[0];\r\n let fr = new FileReader();\r\n fr.onload = function (e) {\r\n let data = {};\r\n try {\r\n data = JSON.parse(e.target.result);\r\n } catch (ex) {\r\n alert('Parsing failed!\\r\\n ' + ex);\r\n }\r\n $('input.nvs').each(function (_index, entry) {\r\n $(this).parent().removeClass('bg-warning').removeClass('bg-success');\r\n if (data[entry.id]) {\r\n if (data[entry.id] !== entry.value) {\r\n console.log(\r\n 'Changed ' + entry.id + ' ' + entry.value + '==>' + data[entry.id]\r\n );\r\n $(this).parent().addClass('bg-warning');\r\n $(this).val(data[entry.id]);\r\n }\r\n else {\r\n $(this).parent().addClass('bg-success');\r\n }\r\n }\r\n });\r\n var changed = $(\"input.nvs\").children('.bg-warning');\r\n if (changed) {\r\n alert('Highlighted values were changed. Press Commit to change on the device');\r\n }\r\n }\r\n fr.readAsText(file);\r\n this.value = null;\r\n\r\n }\r\n );\r\n $('#clear-syslog').on('click', function () {\r\n messagecount = 0;\r\n messageseverity = 'MESSAGING_INFO';\r\n $('#msgcnt').text('');\r\n $('#syslogTable').html('');\r\n });\r\n\r\n $('#ok-credits').on('click', function () {\r\n $('#credits').slideUp('fast', function () { });\r\n $('#app').slideDown('fast', function () { });\r\n });\r\n\r\n $('#acredits').on('click', function (event) {\r\n event.preventDefault();\r\n $('#app').slideUp('fast', function () { });\r\n $('#credits').slideDown('fast', function () { });\r\n });\r\n\r\n $('input#show-commands').on('click', function () {\r\n this.checked = this.checked ? 1 : 0;\r\n if (this.checked) {\r\n $('a[href^=\"#tab-commands\"]').show();\r\n LastCommandsState = 1;\r\n } else {\r\n LastCommandsState = 0;\r\n $('a[href^=\"#tab-commands\"]').hide();\r\n }\r\n });\r\n\r\n $('#disable-squeezelite').on('click', function () {\r\n // this.checked = this.checked ? 1 : 0;\r\n // $('#disable-squeezelite').prop('checked')\r\n if (this.checked) {\r\n // Store the current value before overwriting it\r\n const currentValue = $('#cmd_opt_s').val();\r\n $('#cmd_opt_s').data('originalValue', currentValue);\r\n \r\n // Overwrite the value with '-disable'\r\n $('#cmd_opt_s').val('-disable');\r\n } else {\r\n // Retrieve the original value\r\n const originalValue = $('#cmd_opt_s').data('originalValue');\r\n \r\n // Restore the original value if it exists, otherwise set it to an empty string\r\n $('#cmd_opt_s').val(originalValue ? originalValue : '');\r\n }\r\n \r\n });\r\n\r\n \r\n\r\n $('input#show-nvs').on('click', function () {\r\n this.checked = this.checked ? 1 : 0;\r\n Cookies.set(\"show-nvs\", this.checked ? 'Y' : 'N');\r\n handleNVSVisible();\r\n });\r\n $('#btn_reboot_recovery').on('click', function () {\r\n handleReboot('recovery');\r\n });\r\n $('#btn_reboot').on('click', function () {\r\n handleReboot('reboot');\r\n });\r\n $('#btn_flash').on('click', function () {\r\n hFlash();\r\n });\r\n $('#save-autoexec1').on('click', function () {\r\n saveAutoexec1(false);\r\n });\r\n $('#commit-autoexec1').on('click', function () {\r\n saveAutoexec1(true);\r\n });\r\n $('#btn_disconnect').on('click', function () {\r\n ConnectedTo = {};\r\n refreshAPHTML2();\r\n $.ajax({\r\n url: '/connect.json',\r\n dataType: 'text',\r\n method: 'DELETE',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify({\r\n timestamp: Date.now(),\r\n }),\r\n });\r\n });\r\n $('#btnJoin').on('click', function () {\r\n handleConnect();\r\n });\r\n $('#reboot_nav').on('click', function () {\r\n handleReboot('reboot');\r\n });\r\n $('#reboot_ota_nav').on('click', function () {\r\n handleReboot('reboot_ota');\r\n });\r\n\r\n $('#save-as-nvs').on('click', function () {\r\n const config = getConfigJson(true);\r\n const a = document.createElement('a');\r\n a.href = URL.createObjectURL(\r\n new Blob([JSON.stringify(config, null, 2)], {\r\n type: 'text/plain',\r\n })\r\n );\r\n a.setAttribute(\r\n 'download',\r\n 'nvs_config_' + hostName + '_' + Date.now() + 'json'\r\n );\r\n document.body.appendChild(a);\r\n a.click();\r\n document.body.removeChild(a);\r\n });\r\n\r\n $('#save-nvs').on('click', function () {\r\n post_config(getConfigJson(false));\r\n });\r\n\r\n $('#fwUpload').on('click', function () {\r\n const fileInput = document.getElementById('flashfilename').files;\r\n if (fileInput.length === 0) {\r\n alert('No file selected!');\r\n } else {\r\n $('#fw-url-input').value = null;\r\n flashState.StartOTA();\r\n }\r\n\r\n });\r\n $('[name=output-tmpl]').on('click', function () {\r\n handleTemplateTypeRadio(this.id);\r\n });\r\n\r\n $('#chkUpdates').on('click', function () {\r\n $('#rTable').html('');\r\n $.getJSON(releaseURL, function (data) {\r\n let i = 0;\r\n const branches = [];\r\n data.forEach(function (release) {\r\n const namecomponents = release.name.split('#');\r\n const branch = namecomponents[3];\r\n if (!branches.includes(branch)) {\r\n branches.push(branch);\r\n }\r\n });\r\n let fwb = '';\r\n branches.forEach(function (branch) {\r\n fwb += '';\r\n });\r\n $('#fwbranch').append(fwb);\r\n\r\n data.forEach(function (release) {\r\n let url = '';\r\n release.assets.forEach(function (asset) {\r\n if (asset.name.match(/\\.bin$/)) {\r\n url = asset.browser_download_url;\r\n }\r\n });\r\n const namecomponents = release.name.split('#');\r\n const ver = namecomponents[0];\r\n const cfg = namecomponents[2];\r\n const branch = namecomponents[3];\r\n var bits = ver.substr(ver.lastIndexOf('-') + 1);\r\n bits = (bits == '32' || bits == '16') ? bits : '';\r\n\r\n let body = release.body;\r\n body = body.replace(/'/gi, '\"');\r\n body = body.replace(\r\n /[\\s\\S]+(### Revision Log[\\s\\S]+)### ESP-IDF Version Used[\\s\\S]+/,\r\n '$1'\r\n );\r\n body = body.replace(/- \\(.+?\\) /g, '- ').encodeHTML();\r\n $('#rTable').append(`\r\n ${ver}${new Date(release.created_at).toLocalShort()}\r\n ${cfg}${branch}${bits}`\r\n );\r\n });\r\n if (i > 7) {\r\n $('#releaseTable').append(\r\n \"\" +\r\n \"\" +\r\n \"\" +\r\n '' +\r\n ''\r\n );\r\n $('#showallbutton').on('click', function () {\r\n $('tr.hide').removeClass('hide');\r\n $('tr#showall').addClass('hide');\r\n });\r\n }\r\n $('#searchfw').css('display', 'inline');\r\n if (!setPlatformFilter(platform_name)) {\r\n setPlatformFilter(project_name)\r\n }\r\n $('#rTable tr.release').on('click', function () {\r\n var url = this.attributes['fwurl'].value;\r\n if (lmsBaseUrl) {\r\n url = url.replace(/.*\\/download\\//, lmsBaseUrl + '/plugins/SqueezeESP32/firmware/');\r\n }\r\n $('#fw-url-input').val(url);\r\n $('#start-flash').show();\r\n $('#rTable tr.release').removeClass('table-success table-warning');\r\n $(this).addClass('table-success table-warning');\r\n });\r\n\r\n }).fail(function () {\r\n alert('failed to fetch release history!');\r\n });\r\n });\r\n $('#fwcheck').on('click', function () {\r\n $('#releaseTable').html('');\r\n $('#fwbranch').empty();\r\n $.getJSON(releaseURL, function (data) {\r\n let i = 0;\r\n const branches = [];\r\n data.forEach(function (release) {\r\n const namecomponents = release.name.split('#');\r\n const branch = namecomponents[3];\r\n if (!branches.includes(branch)) {\r\n branches.push(branch);\r\n }\r\n });\r\n let fwb;\r\n branches.forEach(function (branch) {\r\n fwb += '';\r\n });\r\n $('#fwbranch').append(fwb);\r\n\r\n data.forEach(function (release) {\r\n let url = '';\r\n release.assets.forEach(function (asset) {\r\n if (asset.name.match(/\\.bin$/)) {\r\n url = asset.browser_download_url;\r\n }\r\n });\r\n const namecomponents = release.name.split('#');\r\n const ver = namecomponents[0];\r\n const idf = namecomponents[1];\r\n const cfg = namecomponents[2];\r\n const branch = namecomponents[3];\r\n\r\n let body = release.body;\r\n body = body.replace(/'/gi, '\"');\r\n body = body.replace(\r\n /[\\s\\S]+(### Revision Log[\\s\\S]+)### ESP-IDF Version Used[\\s\\S]+/,\r\n '$1'\r\n );\r\n body = body.replace(/- \\(.+?\\) /g, '- ');\r\n const trclass = i++ > 6 ? ' hide' : '';\r\n $('#releaseTable').append(\r\n \"\" +\r\n \"\" +\r\n ver +\r\n '' +\r\n '' +\r\n new Date(release.created_at).toLocalShort() +\r\n '' +\r\n '' +\r\n cfg +\r\n '' +\r\n '' +\r\n idf +\r\n '' +\r\n '' +\r\n branch +\r\n '' +\r\n \"\" +\r\n ''\r\n );\r\n });\r\n if (i > 7) {\r\n $('#releaseTable').append(\r\n \"\" +\r\n \"\" +\r\n \"\" +\r\n '' +\r\n ''\r\n );\r\n $('#showallbutton').on('click', function () {\r\n $('tr.hide').removeClass('hide');\r\n $('tr#showall').addClass('hide');\r\n });\r\n }\r\n $('#searchfw').css('display', 'inline');\r\n }).fail(function () {\r\n alert('failed to fetch release history!');\r\n });\r\n });\r\n\r\n $('#updateAP').on('click', function () {\r\n refreshAP();\r\n console.log('refresh AP');\r\n });\r\n\r\n // first time the page loads: attempt to get the connection status and start the wifi scan\r\n getConfig();\r\n getCommands();\r\n getMessages();\r\n checkStatus();\r\n\r\n});\r\n\r\n// eslint-disable-next-line no-unused-vars\r\nwindow.setURL = function (button) {\r\n let url = button.dataset.url;\r\n\r\n $('[data-bs-url^=\"http\"]')\r\n .addClass('btn-success')\r\n .removeClass('btn-danger');\r\n $('[data-bs-url=\"' + url + '\"]')\r\n .addClass('btn-danger')\r\n .removeClass('btn-success');\r\n\r\n // if user can proxy download through LMS, modify the URL\r\n if (lmsBaseUrl) {\r\n url = url.replace(/.*\\/download\\//, lmsBaseUrl + '/plugins/SqueezeESP32/firmware/');\r\n }\r\n\r\n $('#fwurl').val(url);\r\n}\r\n\r\n\r\nfunction rssiToIcon(rssi) {\r\n if (rssi >= -55) {\r\n return { 'label': '****', 'icon': `signal_wifi_statusbar_4_bar` };\r\n } else if (rssi >= -60) {\r\n return { 'label': '***', 'icon': `network_wifi_3_bar` };\r\n } else if (rssi >= -65) {\r\n return { 'label': '**', 'icon': `network_wifi_2_bar` };\r\n } else if (rssi >= -70) {\r\n return { 'label': '*', 'icon': `network_wifi_1_bar` };\r\n } else {\r\n return { 'label': '.', 'icon': `signal_wifi_statusbar_null` };\r\n }\r\n}\r\n\r\nfunction refreshAP() {\r\n if (ConnectedTo?.urc === connectReturnCode.ETH) return;\r\n $.ajaxSetup({\r\n timeout: 3000 //Time in milliseconds\r\n });\r\n $.getJSON('/scan.json', async function () {\r\n await sleep(2000);\r\n $.getJSON('/ap.json', function (data) {\r\n if (data.length > 0) {\r\n // sort by signal strength\r\n data.sort(function (a, b) {\r\n const x = a.rssi;\r\n const y = b.rssi;\r\n // eslint-disable-next-line no-nested-ternary\r\n return x < y ? 1 : x > y ? -1 : 0;\r\n });\r\n apList = data;\r\n refreshAPHTML2(apList);\r\n\r\n }\r\n });\r\n });\r\n}\r\nfunction formatAP(ssid, rssi, auth) {\r\n const rssi_icon = rssiToIcon(rssi);\r\n const auth_icon = { label: auth == 0 ? '🔓' : '🔒', icon: auth == 0 ? 'no_encryption' : 'lock' };\r\n\r\n return `${ssid}\r\n ${getIcon(rssi_icon)}\r\n \t\r\n ${getIcon(auth_icon)}\r\n `;\r\n}\r\nfunction refreshAPHTML2(data) {\r\n let h = '';\r\n $('#wifiTable tr td:first-of-type').text('');\r\n $('#wifiTable tr').removeClass('table-success table-warning');\r\n if (data) {\r\n data.forEach(function (e) {\r\n h += formatAP(e.ssid, e.rssi, e.auth);\r\n });\r\n $('#wifiTable').html(h);\r\n }\r\n if ($('.manual_add').length == 0) {\r\n $('#wifiTable').append(formatAP('Manual add', 0, 0));\r\n $('#wifiTable tr:last').addClass('table-light text-dark').addClass('manual_add');\r\n }\r\n if (ConnectedTo.ssid && (ConnectedTo.urc === connectReturnCode.OK || ConnectedTo.urc === connectReturnCode.RESTORE)) {\r\n const wifiSelector = `#wifiTable td:contains(\"${ConnectedTo.ssid}\")`;\r\n if ($(wifiSelector).filter(function () { return $(this).text() === ConnectedTo.ssid; }).length == 0) {\r\n $('#wifiTable').prepend(`${formatAP(ConnectedTo.ssid, ConnectedTo.rssi ?? 0, 0)}`);\r\n }\r\n $(wifiSelector).filter(function () { return $(this).text() === ConnectedTo.ssid; }).siblings().first().html('✓').parent().addClass((ConnectedTo.urc === connectReturnCode.OK ? 'table-success' : 'table-warning'));\r\n $('span#foot-if').html(`SSID: ${ConnectedTo.ssid}, IP: ${ConnectedTo.ip}`);\r\n $('#wifiStsIcon').html(rssiToIcon(ConnectedTo.rssi));\r\n\r\n }\r\n else if (ConnectedTo?.urc !== connectReturnCode.ETH) {\r\n $('span#foot-if').html('');\r\n }\r\n\r\n}\r\nfunction refreshETH() {\r\n\r\n if (ConnectedTo.urc === connectReturnCode.ETH) {\r\n $('span#foot-if').html(`Network: Ethernet, IP: ${ConnectedTo.ip}`);\r\n }\r\n}\r\nfunction showTask(task) {\r\n console.debug(\r\n this.toLocaleString() +\r\n '\\t' +\r\n task.nme +\r\n '\\t' +\r\n task.cpu +\r\n '\\t' +\r\n taskStates[task.st] +\r\n '\\t' +\r\n task.minstk +\r\n '\\t' +\r\n task.bprio +\r\n '\\t' +\r\n task.cprio +\r\n '\\t' +\r\n task.num\r\n );\r\n $('tbody#tasks').append(\r\n '' +\r\n task.num +\r\n '' +\r\n task.nme +\r\n '' +\r\n task.cpu +\r\n '' +\r\n taskStates[task.st] +\r\n '' +\r\n task.minstk +\r\n '' +\r\n task.bprio +\r\n '' +\r\n task.cprio +\r\n ''\r\n );\r\n}\r\nfunction btExists(name) {\r\n return getBTSinkOpt(name).length > 0;\r\n}\r\nfunction getBTSinkOpt(name) {\r\n return $(`${btSinkNamesOptSel} option:contains('${name}')`);\r\n}\r\nfunction getMessages() {\r\n $.ajaxSetup({\r\n timeout: messageInterval //Time in milliseconds\r\n });\r\n $.getJSON('/messages.json', async function (data) {\r\n for (const msg of data) {\r\n const msgAge = msg.current_time - msg.sent_time;\r\n var msgTime = new Date();\r\n msgTime.setTime(msgTime.getTime() - msgAge);\r\n switch (msg.class) {\r\n case 'MESSAGING_CLASS_OTA':\r\n flashState.EventOTAMessageClass(msg.message);\r\n break;\r\n case 'MESSAGING_CLASS_STATS':\r\n // for task states, check structure : task_state_t\r\n var statsData = JSON.parse(msg.message);\r\n console.debug(\r\n msgTime.toLocalShort() +\r\n ' - Number of running tasks: ' +\r\n statsData.ntasks\r\n );\r\n console.debug(\r\n msgTime.toLocalShort() +\r\n '\\tname' +\r\n '\\tcpu' +\r\n '\\tstate' +\r\n '\\tminstk' +\r\n '\\tbprio' +\r\n '\\tcprio' +\r\n '\\tnum'\r\n );\r\n if (statsData.tasks) {\r\n if ($('#tasks_sect').css('visibility') === 'collapse') {\r\n $('#tasks_sect').css('visibility', 'visible');\r\n }\r\n $('tbody#tasks').html('');\r\n statsData.tasks\r\n .sort(function (a, b) {\r\n return b.cpu - a.cpu;\r\n })\r\n .forEach(showTask, msgTime);\r\n } else if ($('#tasks_sect').css('visibility') === 'visible') {\r\n $('tbody#tasks').empty();\r\n $('#tasks_sect').css('visibility', 'collapse');\r\n }\r\n break;\r\n case 'MESSAGING_CLASS_SYSTEM':\r\n showMessage(msg, msgTime);\r\n break;\r\n case 'MESSAGING_CLASS_CFGCMD':\r\n var msgparts = msg.message.split(/([^\\n]*)\\n(.*)/gs);\r\n showCmdMessage(msgparts[1], msg.type, msgparts[2], true);\r\n break;\r\n case 'MESSAGING_CLASS_BT':\r\n if ($(\"#cfg-audio-bt_source-sink_name\").is('input')) {\r\n var attr = $(\"#cfg-audio-bt_source-sink_name\")[0].attributes;\r\n var attrs = '';\r\n for (var j = 0; j < attr.length; j++) {\r\n if (attr.item(j).name != \"type\") {\r\n attrs += `${attr.item(j).name} = \"${attr.item(j).value}\" `;\r\n }\r\n }\r\n var curOpt = $(\"#cfg-audio-bt_source-sink_name\")[0].value;\r\n $(\"#cfg-audio-bt_source-sink_name\").replaceWith(` `);\r\n }\r\n JSON.parse(msg.message).forEach(function (btEntry) {\r\n //\r\n // \r\n if (!btExists(btEntry.name)) {\r\n $(\"#cfg-audio-bt_source-sink_name\").append(``);\r\n showMessage({ type: msg.type, message: `BT Audio device found: ${btEntry.name} RSSI: ${btEntry.rssi} ` }, msgTime);\r\n }\r\n getBTSinkOpt(btEntry.name).attr('data-bs-description', `${btEntry.name} (${btEntry.rssi}dB)`)\r\n .attr('rssi', btEntry.rssi)\r\n .attr('value', btEntry.name)\r\n .text(`${btEntry.name} [${btEntry.rssi}dB]`).trigger('change');\r\n\r\n });\r\n $(btSinkNamesOptSel).append($(`${btSinkNamesOptSel} option`).remove().sort(function (a, b) {\r\n console.log(`${parseInt($(a).attr('rssi'))} < ${parseInt($(b).attr('rssi'))} ? `);\r\n return parseInt($(a).attr('rssi')) < parseInt($(b).attr('rssi')) ? 1 : -1;\r\n }));\r\n break;\r\n default:\r\n break;\r\n }\r\n }\r\n setTimeout(getMessages, messageInterval);\r\n }).fail(function (xhr, ajaxOptions, thrownError) {\r\n\r\n if (xhr.status == 404) {\r\n $('.orec').hide(); // system commands won't be available either\r\n messagesHeld = true;\r\n }\r\n else {\r\n handleExceptionResponse(xhr, ajaxOptions, thrownError);\r\n }\r\n if (xhr.status == 0 && xhr.readyState == 0) {\r\n // probably a timeout. Target is rebooting? \r\n setTimeout(getMessages, messageInterval * 2); // increase duration if a failure happens\r\n }\r\n else if (!messagesHeld) {\r\n // 404 here means we rebooted to an old recovery\r\n setTimeout(getMessages, messageInterval); // increase duration if a failure happens\r\n }\r\n\r\n }\r\n );\r\n\r\n /*\r\n Minstk is minimum stack space left\r\nBprio is base priority\r\ncprio is current priority\r\nnme is name\r\nst is task state. I provided a \"typedef\" that you can use to convert to text\r\ncpu is cpu percent used\r\n*/\r\n}\r\nfunction handleRecoveryMode(data) {\r\n const locRecovery = data.recovery ?? 0;\r\n if (locRecovery === 1) {\r\n recovery = true;\r\n $('.recovery_element').show();\r\n $('.ota_element').hide();\r\n $('#boot-button').html('Reboot');\r\n $('#boot-form').attr('action', '/reboot_ota.json');\r\n } else {\r\n if (!recovery && messagesHeld) {\r\n messagesHeld = false;\r\n setTimeout(getMessages, messageInterval); // increase duration if a failure happens\r\n }\r\n recovery = false;\r\n\r\n $('.recovery_element').hide();\r\n $('.ota_element').show();\r\n $('#boot-button').html('Recovery');\r\n $('#boot-form').attr('action', '/recovery.json');\r\n }\r\n\r\n}\r\n\r\nfunction hasConnectionChanged(data) {\r\n // gw: \"192.168.10.1\"\r\n // ip: \"192.168.10.225\"\r\n // netmask: \"255.255.255.0\"\r\n // ssid: \"MyTestSSID\"\r\n\r\n return (data.urc !== ConnectedTo.urc ||\r\n data.ssid !== ConnectedTo.ssid ||\r\n data.gw !== ConnectedTo.gw ||\r\n data.netmask !== ConnectedTo.netmask ||\r\n data.ip !== ConnectedTo.ip || data.rssi !== ConnectedTo.rssi)\r\n}\r\nfunction handleWifiDialog(data) {\r\n if ($('#WifiConnectDialog').is(':visible')) {\r\n if (ConnectedTo.ip) {\r\n $('#ipAddress').text(ConnectedTo.ip);\r\n }\r\n if (ConnectedTo.ssid) {\r\n $('#connectedToSSID').text(ConnectedTo.ssid);\r\n }\r\n if (ConnectedTo.gw) {\r\n $('#gateway').text(ConnectedTo.gw);\r\n }\r\n if (ConnectedTo.netmask) {\r\n $('#netmask').text(ConnectedTo.netmask);\r\n }\r\n if (ConnectingToSSID.Action === undefined || (ConnectingToSSID.Action && ConnectingToSSID.Action == ConnectingToActions.STS)) {\r\n $(\"*[class*='connecting']\").hide();\r\n $('.connecting-status').show();\r\n }\r\n if (SystemConfig.ap_ssid) {\r\n $('#apName').text(SystemConfig.ap_ssid.value);\r\n }\r\n if (SystemConfig.ap_pwd) {\r\n $('#apPass').text(SystemConfig.ap_pwd.value);\r\n }\r\n if (!data) {\r\n return;\r\n }\r\n else {\r\n switch (data.urc) {\r\n case connectReturnCode.OK:\r\n if (data.ssid && data.ssid === ConnectingToSSID.ssid) {\r\n $(\"*[class*='connecting']\").hide();\r\n $('.connecting-success').show();\r\n ConnectingToSSID.Action = ConnectingToActions.STS;\r\n }\r\n break;\r\n case connectReturnCode.FAIL:\r\n // \r\n if (ConnectingToSSID.Action != ConnectingToActions.STS && ConnectingToSSID.ssid == data.ssid) {\r\n $(\"*[class*='connecting']\").hide();\r\n $('.connecting-fail').show();\r\n }\r\n break;\r\n case connectReturnCode.LOST:\r\n\r\n break;\r\n case connectReturnCode.RESTORE:\r\n if (ConnectingToSSID.Action != ConnectingToActions.STS && ConnectingToSSID.ssid != data.ssid) {\r\n $(\"*[class*='connecting']\").hide();\r\n $('.connecting-fail').show();\r\n }\r\n break;\r\n case connectReturnCode.DISC:\r\n // that's a manual disconnect\r\n // if ($('#wifi-status').is(':visible')) {\r\n // $('#wifi-status').slideUp('fast', function() {});\r\n // $('span#foot-wifi').html('');\r\n\r\n // } \r\n break;\r\n default:\r\n break;\r\n }\r\n }\r\n\r\n }\r\n}\r\nfunction setIcons(offline) {\r\n $('.material-icons').each(function (_index, entry) {\r\n entry.textContent = entry.attributes[offline ? 'aria-label' : 'icon'].value;\r\n });\r\n}\r\nfunction handleNetworkStatus(data) {\r\n setIcons(!isConnected());\r\n if (hasConnectionChanged(data) || !data.urc) {\r\n ConnectedTo = data;\r\n $(\".if_eth\").hide();\r\n $('.if_wifi').hide();\r\n if (!data.urc || ConnectedTo.urc != connectReturnCode.ETH) {\r\n $('.if_wifi').show();\r\n refreshAPHTML2();\r\n }\r\n else {\r\n $(\".if_eth\").show();\r\n refreshETH();\r\n }\r\n\r\n }\r\n handleWifiDialog(data);\r\n}\r\n\r\n\r\n\r\nfunction batteryToIcon(voltage) {\r\n /* Assuming Li-ion 18650s as a power source, 3.9V per cell, or above is treated\r\n as full charge (>75% of capacity). 3.4V is empty. The gauge is loosely\r\n following the graph here:\r\n https://learn.adafruit.com/li-ion-and-lipoly-batteries/voltages\r\n using the 0.2C discharge profile for the rest of the values.\r\n*/\r\n\r\n for (const iconEntry of batIcons) {\r\n for (const entryRanges of iconEntry.ranges) {\r\n if (inRange(voltage, entryRanges.f, entryRanges.t)) {\r\n return { label: iconEntry.label, icon: iconEntry.icon };\r\n }\r\n }\r\n }\r\n\r\n\r\n return { label: '▪▪▪▪', icon: \"battery_full\" };\r\n}\r\nfunction checkStatus() {\r\n $.ajaxSetup({\r\n timeout: statusInterval //Time in milliseconds\r\n });\r\n $.getJSON('/status.json', function (data) {\r\n handleRecoveryMode(data);\r\n handleNVSVisible();\r\n handleNetworkStatus(data);\r\n handlebtstate(data);\r\n flashState.EventTargetStatus(data);\r\n if(data.depth) {\r\n depth = data.depth;\r\n if(depth==16){\r\n $('#cmd_opt_R').show();\r\n }\r\n else{\r\n $('#cmd_opt_R').hide();\r\n }\r\n }\r\n\r\n\r\n if (data.project_name && data.project_name !== '') {\r\n project_name = data.project_name;\r\n }\r\n if (data.platform_name && data.platform_name !== '') {\r\n platform_name = data.platform_name;\r\n }\r\n if (board_model === '') board_model = project_name;\r\n if (board_model === '') board_model = 'Squeezelite-ESP32';\r\n if (data.version && data.version !== '') {\r\n versionName = data.version;\r\n $(\"#navtitle\").html(`${board_model}${recovery ? '
[recovery]' : ''}`);\r\n $('span#foot-fw').html(`fw: ${versionName}, mode: ${recovery ? \"Recovery\" : project_name}`);\r\n } else {\r\n $('span#flash-status').html('');\r\n }\r\n if (data.Voltage) {\r\n const bat_icon = batteryToIcon(data.Voltage);\r\n $('#battery').html(`${getIcon(bat_icon)}`);\r\n $('#battery').attr(\"aria-label\", bat_icon.label);\r\n $('#battery').attr(\"icon\", bat_icon.icon);\r\n $('#battery').show();\r\n } else {\r\n $('#battery').hide();\r\n }\r\n if ((data.message ?? '') != '' && prevmessage != data.message) {\r\n // supporting older recovery firmwares - messages will come from the status.json structure\r\n prevmessage = data.message;\r\n showLocalMessage(data.message, 'MESSAGING_INFO')\r\n }\r\n is_i2c_locked = data.is_i2c_locked;\r\n if (is_i2c_locked) {\r\n $('flds-cfg-hw-preset').hide();\r\n }\r\n else {\r\n $('flds-cfg-hw-preset').show();\r\n }\r\n $(\"button[onclick*='handleReboot']\").removeClass('rebooting');\r\n\r\n if (typeof lmsBaseUrl == \"undefined\" || data.lms_ip != prevLMSIP && data.lms_ip && data.lms_port) {\r\n const baseUrl = 'http://' + data.lms_ip + ':' + data.lms_port;\r\n prevLMSIP = data.lms_ip;\r\n $.ajax({\r\n url: baseUrl + '/plugins/SqueezeESP32/firmware/-check.bin',\r\n type: 'HEAD',\r\n dataType: 'text',\r\n cache: false,\r\n error: function () {\r\n // define the value, so we don't check it any more.\r\n lmsBaseUrl = '';\r\n },\r\n success: function () {\r\n lmsBaseUrl = baseUrl;\r\n }\r\n });\r\n }\r\n $('#o_jack').css({ display: Number(data.Jack) ? 'inline' : 'none' });\r\n setTimeout(checkStatus, statusInterval);\r\n }).fail(function (xhr, ajaxOptions, thrownError) {\r\n handleExceptionResponse(xhr, ajaxOptions, thrownError);\r\n if (xhr.status == 0 && xhr.readyState == 0) {\r\n // probably a timeout. Target is rebooting? \r\n setTimeout(checkStatus, messageInterval * 2); // increase duration if a failure happens\r\n }\r\n else {\r\n setTimeout(checkStatus, messageInterval); // increase duration if a failure happens\r\n }\r\n });\r\n}\r\n// eslint-disable-next-line no-unused-vars\r\nwindow.runCommand = function (button, reboot) {\r\n let cmdstring = button.attributes.cmdname.value;\r\n showCmdMessage(\r\n button.attributes.cmdname.value,\r\n 'MESSAGING_INFO',\r\n 'Executing.',\r\n false\r\n );\r\n const fields = document.getElementById('flds-' + cmdstring);\r\n const allfields = fields?.querySelectorAll('select,input');\r\n if (cmdstring === 'cfg-hw-preset') return handleHWPreset(allfields, reboot);\r\n cmdstring += ' ';\r\n if (fields) {\r\n for (const field of allfields) {\r\n let qts = '';\r\n let opt = '';\r\n let attr = field.attributes;\r\n let isSelect = $(field).is('select');\r\n const hasValue = attr?.hasvalue?.value === 'true';\r\n const validVal = (isSelect && field.value !== '--') || (!isSelect && field.value !== '');\r\n\r\n if (!hasValue || hasValue && validVal) {\r\n if (attr?.longopts?.value !== 'undefined') {\r\n opt += '--' + attr?.longopts?.value;\r\n } else if (attr?.shortopts?.value !== 'undefined') {\r\n opt = '-' + attr.shortopts.value;\r\n }\r\n\r\n if (attr?.hasvalue?.value === 'true') {\r\n if (attr?.value !== '') {\r\n qts = /\\s/.test(field.value) ? '\"' : '';\r\n cmdstring += opt + ' ' + qts + field.value + qts + ' ';\r\n }\r\n } else {\r\n // this is a checkbox\r\n if (field?.checked) {\r\n cmdstring += opt + ' ';\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n console.log(cmdstring);\r\n\r\n const data = {\r\n timestamp: Date.now(),\r\n };\r\n data.command = cmdstring;\r\n\r\n $.ajax({\r\n url: '/commands.json',\r\n dataType: 'text',\r\n method: 'POST',\r\n cache: false,\r\n contentType: 'application/json; charset=utf-8',\r\n data: JSON.stringify(data),\r\n error: function (xhr, _ajaxOptions, thrownError) {\r\n var cmd = JSON.parse(this.data).command;\r\n if (xhr.status == 404) {\r\n showCmdMessage(\r\n cmd.substr(0, cmd.indexOf(' ')),\r\n 'MESSAGING_ERROR',\r\n `${recovery ? 'Limited recovery mode active. Unsupported action ' : 'Unexpected error while processing command'}`,\r\n true\r\n );\r\n }\r\n else {\r\n handleExceptionResponse(xhr, _ajaxOptions, thrownError);\r\n showCmdMessage(\r\n cmd.substr(0, cmd.indexOf(' ') - 1),\r\n 'MESSAGING_ERROR',\r\n `Unexpected error ${(thrownError !== '') ? thrownError : 'with return status = ' + xhr.status}`,\r\n true\r\n );\r\n }\r\n },\r\n success: function (response) {\r\n $('.orec').show();\r\n console.log(response);\r\n if (\r\n JSON.parse(response).Result === 'Success' &&\r\n reboot\r\n ) {\r\n delayReboot(2500, button.attributes.cmdname.value);\r\n }\r\n },\r\n });\r\n}\r\nfunction getLongOps(data, name, longopts) {\r\n return data.values[name] !== undefined ? data.values[name][longopts] : \"\";\r\n}\r\nfunction getCommands() {\r\n $.ajaxSetup({\r\n timeout: 7000 //Time in milliseconds\r\n });\r\n $.getJSON('/commands.json', function (data) {\r\n console.log(data);\r\n $('.orec').show();\r\n data.commands.forEach(function (command) {\r\n if ($('#flds-' + command.name).length === 0) {\r\n const cmdParts = command.name.split('-');\r\n const isConfig = cmdParts[0] === 'cfg';\r\n const targetDiv = '#tab-' + cmdParts[0] + '-' + cmdParts[1];\r\n let innerhtml = '';\r\n innerhtml += `
${command.help.encodeHTML().replace(/\\n/g, '
')}
`;\r\n if (command.argtable) {\r\n command.argtable.forEach(function (arg) {\r\n let placeholder = arg.datatype || '';\r\n const ctrlname = command.name + '-' + arg.longopts;\r\n const curvalue = getLongOps(data, command.name, arg.longopts);\r\n\r\n let attributes = 'hasvalue=' + arg.hasvalue + ' ';\r\n attributes += 'longopts=\"' + arg.longopts + '\" ';\r\n attributes += 'shortopts=\"' + arg.shortopts + '\" ';\r\n attributes += 'checkbox=' + arg.checkbox + ' ';\r\n attributes += 'cmdname=\"' + command.name + '\" ';\r\n attributes += 'id=\"' + ctrlname + '\" name=\"' + ctrlname + '\" ';\r\n if (arg.longopts && arg.longopts.startsWith('_')){\r\n attributes += \"readonly \";\r\n }\r\n let extraclass = arg.mincount > 0 ? 'is-invalid' : '';\r\n if (arg.glossary === 'hidden') {\r\n attributes += ' style=\"visibility: hidden;\"';\r\n }\r\n if (arg.checkbox) {\r\n innerhtml += `
`;\r\n } else if (arg.remark) {\r\n innerhtml += `
`;\r\n } else {\r\n innerhtml += `
`;\r\n if (placeholder.includes('|')) {\r\n extraclass = placeholder.startsWith('+') ? ' multiple ' : '';\r\n placeholder = placeholder\r\n .replace('<', '')\r\n .replace('=', '')\r\n .replace('>', '');\r\n innerhtml += `';\r\n } else {\r\n innerhtml += ``;\r\n }\r\n } \r\n\r\n if (!arg.remark) {\r\n innerhtml += `Previous value: ${arg.checkbox ? (curvalue ? 'Checked' : 'Unchecked') : (curvalue || '')}`;\r\n }\r\n innerhtml += `
`;\r\n });\r\n }\r\n innerhtml += `
\r\n
\r\n
\r\n Result\r\n
\r\n
\r\n
`;\r\n if (isConfig) {\r\n innerhtml +=\r\n `\r\n`;\r\n } else {\r\n innerhtml += ``;\r\n }\r\n innerhtml += '
';\r\n if (isConfig) {\r\n $(targetDiv).append(innerhtml);\r\n } else {\r\n $('#commands-list').append(innerhtml);\r\n }\r\n }\r\n });\r\n $(\".sclk\").off('click').on('click', function () { runCommand(this, false); });\r\n $(\".cclk\").off('click').on('click', function () { runCommand(this, true); });\r\n data.commands.forEach(function (command) {\r\n $('[cmdname=' + command.name + ']:input').val('');\r\n $('[cmdname=' + command.name + ']:checkbox').prop('checked', false);\r\n if (command.argtable) {\r\n command.argtable.forEach(function (arg) {\r\n const ctrlselector = '#' + command.name + '-' + arg.longopts;\r\n const ctrlValue = getLongOps(data, command.name, arg.longopts);\r\n if (arg.checkbox) {\r\n $(ctrlselector)[0].checked = ctrlValue;\r\n } else if (!arg.remark) {\r\n if (ctrlValue !== undefined) {\r\n $(ctrlselector)\r\n .val(ctrlValue)\r\n .trigger('change');\r\n }\r\n if (\r\n $(ctrlselector)[0].value.length === 0 &&\r\n (arg.datatype || '').includes('|')\r\n ) {\r\n $(ctrlselector)[0].value = '--';\r\n }\r\n }\r\n if (arg.mincount && arg.mincount > 0) {\r\n $(ctrlselector).removeClass('is-invalid');\r\n $(ctrlselector).addClass('is-valid');\r\n }\r\n });\r\n }\r\n });\r\n loadPresets();\r\n }).fail(function (xhr, ajaxOptions, thrownError) {\r\n if (xhr.status == 404) {\r\n $('.orec').hide();\r\n }\r\n else {\r\n handleExceptionResponse(xhr, ajaxOptions, thrownError);\r\n }\r\n $('#commands-list').empty();\r\n\r\n });\r\n}\r\n\r\nfunction getConfig() {\r\n $.ajaxSetup({\r\n timeout: 7000 //Time in milliseconds\r\n });\r\n $.getJSON('/config.json', function (entries) {\r\n $('#nvsTable tr').remove();\r\n const data = (entries.config ? entries.config : entries);\r\n SystemConfig = data;\r\n commandBTSinkName = '';\r\n Object.keys(data)\r\n .sort()\r\n .forEach(function (key) {\r\n let val = data[key].value;\r\n if (key === 'autoexec') {\r\n\r\n } else if (key === 'host_name') {\r\n val = val.replaceAll('\"', '');\r\n $('input#dhcp-name1').val(val);\r\n $('input#dhcp-name2').val(val);\r\n if ($('#cmd_opt_n').length == 0) {\r\n $('#cmd_opt_n').val(val);\r\n }\r\n document.title = val;\r\n hostName = val;\r\n } else if (key === 'rel_api') {\r\n releaseURL = val;\r\n }\r\n else if (key === 'enable_airplay') {\r\n $(\"#s_airplay\").css({ display: isEnabled(val) ? 'inline' : 'none' })\r\n }\r\n else if (key === 'enable_cspot') {\r\n $(\"#s_cspot\").css({ display: isEnabled(val) ? 'inline' : 'none' })\r\n }\r\n else if (key == 'preset_name') {\r\n preset_name = val;\r\n }\r\n else if (key == 'board_model') {\r\n board_model = val;\r\n }\r\n\r\n $('tbody#nvsTable').append(\r\n '' +\r\n '' +\r\n key +\r\n '' +\r\n \"\" +\r\n \"' +\r\n '' +\r\n ''\r\n );\r\n $('input#' + key).val(data[key].value);\r\n });\r\n if(commandBTSinkName.length > 0) {\r\n // persist the sink name found in the autoexec1 command line\r\n $('#cfg-audio-bt_source-sink_name').val(commandBTSinkName);\r\n }\r\n $('tbody#nvsTable').append(\r\n \"\"\r\n );\r\n if (entries.gpio) {\r\n $('#pins').show();\r\n $('tbody#gpiotable tr').remove();\r\n entries.gpio.forEach(function (gpioEntry) {\r\n $('tbody#gpiotable').append(\r\n '' +\r\n gpioEntry.group +\r\n '' +\r\n gpioEntry.name +\r\n '' +\r\n gpioEntry.gpio +\r\n '' +\r\n (gpioEntry.fixed ? 'Fixed' : 'Configuration') +\r\n ''\r\n );\r\n });\r\n }\r\n else {\r\n $('#pins').hide();\r\n }\r\n }).fail(function (xhr, ajaxOptions, thrownError) {\r\n handleExceptionResponse(xhr, ajaxOptions, thrownError);\r\n });\r\n}\r\n\r\nfunction processSqueezeliteCommandLine(val) {\r\n const parsed = parseSqueezeliteCommandLine(val);\r\n if (parsed.output.toUpperCase().startsWith('I2S')) {\r\n handleTemplateTypeRadio('i2s');\r\n } else if (parsed.output.toUpperCase().startsWith('SPDIF')) {\r\n handleTemplateTypeRadio('spdif');\r\n } else if (parsed.output.toUpperCase().startsWith('BT')) {\r\n if(parsed.otherOptions.btname){ \r\n commandBTSinkName= parsed.otherOptions.btname;\r\n }\r\n handleTemplateTypeRadio('bt');\r\n\r\n }\r\n Object.keys(parsed.options).forEach(function (key) {\r\n const option = parsed.options[key];\r\n if (!$(`#cmd_opt_${key}`).hasOwnProperty('checked')) {\r\n $(`#cmd_opt_${key}`).val(option);\r\n } else {\r\n $(`#cmd_opt_${key}`)[0].checked = option;\r\n }\r\n });\r\n if (parsed.options.hasOwnProperty('u')) {\r\n // parse -u v[:i] and check the appropriate radio button with id #resample_v\r\n const [resampleValue, resampleInterpolation] = parsed.options.u.split(':');\r\n $(`#resample_${resampleValue}`).prop('checked', true);\r\n // if resampleinterpolation is set, check resample_i checkbox\r\n if (resampleInterpolation) {\r\n $('#resample_i').prop('checked', true);\r\n }\r\n }\r\n if (parsed.options.hasOwnProperty('s')) {\r\n // parse -u v[:i] and check the appropriate radio button with id #resample_v\r\n if(parsed.options.s === '-disable'){\r\n $('#disable-squeezelite')[0].checked = true;\r\n }\r\n else {\r\n $('#disable-squeezelite')[0].checked = false;\r\n }\r\n }\r\n\r\n \r\n\r\n\r\n}\r\n\r\nfunction showLocalMessage(message, severity) {\r\n const msg = {\r\n message: message,\r\n type: severity,\r\n };\r\n showMessage(msg, new Date());\r\n}\r\n\r\nfunction showMessage(msg, msgTime) {\r\n let color = 'table-success';\r\n\r\n if (msg.type === 'MESSAGING_WARNING') {\r\n color = 'table-warning';\r\n if (messageseverity === 'MESSAGING_INFO') {\r\n messageseverity = 'MESSAGING_WARNING';\r\n }\r\n } else if (msg.type === 'MESSAGING_ERROR') {\r\n if (\r\n messageseverity === 'MESSAGING_INFO' ||\r\n messageseverity === 'MESSAGING_WARNING'\r\n ) {\r\n messageseverity = 'MESSAGING_ERROR';\r\n }\r\n color = 'table-danger';\r\n }\r\n if (++messagecount > 0) {\r\n $('#msgcnt').removeClass('badge-success');\r\n $('#msgcnt').removeClass('badge-warning');\r\n $('#msgcnt').removeClass('badge-danger');\r\n $('#msgcnt').addClass(pillcolors[messageseverity]);\r\n $('#msgcnt').text(messagecount);\r\n }\r\n\r\n $('#syslogTable').append(\r\n \"\" +\r\n '' +\r\n msgTime.toLocalShort() +\r\n '' +\r\n '' +\r\n msg.message.encodeHTML() +\r\n '' +\r\n ''\r\n );\r\n}\r\n\r\nfunction inRange(x, min, max) {\r\n return (x - min) * (x - max) <= 0;\r\n}\r\n\r\nfunction sleep(ms) {\r\n return new Promise(resolve => setTimeout(resolve, ms));\r\n}\r\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nrequire(\"bootstrap\");\nrequire(\"./sass/main.scss\");\nrequire(\"./assets/images/favicon-32x32.png\");\nrequire(\"./js/custom.js\");\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t826: 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunksqueezelite_esp32\"] = self[\"webpackChunksqueezelite_esp32\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [987], () => (__webpack_require__(607)))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["deferred","he","require","Promise","get_control_option_value","obj","ctrl","id","val","opt","$","concat","attr","checked","replace","includes","handleNVSVisible","nvs_previous_checked","isEnabled","Cookies","get","recovery","show","hide","undefined","match","window","bootstrap","String","prototype","format","Object","assign","args","arguments","this","number","encodeHTML","encode","Date","toLocalShort","toLocaleString","dateStyle","timeStyle","nvsTypes","btIcons","bt_playing","bt_disconnected","bt_neutral","bt_connecting","bt_connected","bt_disabled","play_arrow","pause","stop","batIcons","icon","label","ranges","f","t","btStateIcons","desc","sub","pillcolors","MESSAGING_INFO","MESSAGING_WARNING","MESSAGING_ERROR","connectReturnCode","OK","FAIL","DISC","LOST","RESTORE","ETH","taskStates","flashState","NONE","REBOOT_TO_RECOVERY","SET_FWURL","FLASHING","DONE","UPLOADING","ERROR","UPLOADCOMPLETE","_state","olderRecovery","statusText","flashURL","flashFileName","statusPercent","Completed","prevRecovery","updateModal","Modal","document","getElementById","reset","UpdateProgress","removeClass","prop","value","isStateError","html","parent","isStateUploadComplete","isStateNone","isStateRebootRecovery","isStateSetUrl","isStateFlashing","isStateDone","isStateUploading","init","SetStateError","addClass","SetStateNone","SetStateRebootRecovery","SetStatusText","ajax","url","context","dataType","method","cache","contentType","data","JSON","stringify","timestamp","now","error","xhr","_ajaxOptions","thrownError","_xhr$status","setOTAError","status","complete","response","SetStateSetUrl","post_config","fwurl","type","SetStateFlashing","SetStateDone","SetStateUploading","SetStateUploadComplete","isFlashExecuting","toString","_this","keys","find","x","setOTATargets","fileInput","files","length","message","SetStatusPercent","ShowDialog","pct","pctChanged","txt","changed","css","text","StartOTA","logEvent","name","TargetReadyStartOTA","UploadLocalFile","xhttp","XMLHttpRequest","boundHandleUploadProgressEvent","HandleUploadProgressEvent","bind","boundsetOTAError","upload","addEventListener","onreadystatechange","readyState","open","send","console","Math","round","loaded","total","EventTargetStatus","_data$ota_pct","_data$ota_dsc","ota_pct","ota_dsc","EventOTAMessageClass","otaData","parse","fun","log","hideSurrounding","presetsloaded","messageInterval","confPayload","config","handleExceptionResponse","isConnected","ConnectedTo","hasOwnProperty","ip","getIcon","icons","handleTemplateTypeRadio","outtype","children","display","output","commandDefaults","forEach","key","showLocalMessage","showCmdMessage","cmdname","msgtype","msgtext","append","color","escapedtext","substring","hFlash","handleReboot","link","delayReboot","lmsBaseUrl","releaseURL","messagesHeld","commandBTSinkName","i2s","b","C","W","Z","o","spdif","bt","validOptions","codecs","messagecount","messageseverity","SystemConfig","LastCommandsState","hostName","versionName","prevmessage","project_name","board_model","platform_name","preset_name","btSinkNamesOptSel","ConnectingToSSID","prevLMSIP","ConnectingToActions","getConfigJson","slimMode","each","_index","entry","nvsType","parseInt","attributes","nvs_type","duration","empty","resolve","delay","then","rdata","HideCmdMessage","getCommands","getConfig","setPlatformFilter","filter","toUpperCase","trigger","renderError","fieldname","errorFieldName","errorField","field","after","rssiToIcon","rssi","refreshAP","_ConnectedTo","urc","ajaxSetup","timeout","getJSON","_asyncToGenerator","_regeneratorRuntime","_callee","_context","prev","next","sleep","sort","a","y","refreshAPHTML2","formatAP","ssid","auth","rssi_icon","auth_icon","_ConnectedTo2","h","e","_ConnectedTo$rssi","wifiSelector","prepend","siblings","first","showTask","task","debug","nme","cpu","st","minstk","bprio","cprio","num","getBTSinkOpt","getMessages","_ref2","_callee2","_iterator","_step","_loop","msgTime","statsData","msgparts","attrs","j","curOpt","_context3","_createForOfIteratorHelper","msg","msgAge","_context2","current_time","sent_time","setTime","getTime","t0","abrupt","ntasks","tasks","showMessage","split","is","item","replaceWith","btEntry","remove","s","n","done","delegateYield","t1","finish","setTimeout","_x","apply","fail","ajaxOptions","handleWifiDialog","gw","netmask","Action","STS","ap_ssid","ap_pwd","setIcons","offline","textContent","handleNetworkStatus","hasConnectionChanged","checkStatus","_data$message","_data$recovery","handleRecoveryMode","tt","bt_status","bt_sub_status","iconindex","handlebtstate","depth","version","Voltage","bat_icon","voltage","_i3","_batIcons","_step2","iconEntry","_iterator2","entryRanges","err","batteryToIcon","is_i2c_locked","lms_ip","lms_port","baseUrl","success","Number","Jack","getLongOps","longopts","values","commands","command","cmdParts","isConfig","targetDiv","innerhtml","help","argtable","arg","placeholder","datatype","ctrlname","curvalue","hasvalue","shortopts","checkbox","startsWith","extraclass","mincount","glossary","remark","choice","off","on","runCommand","ctrlselector","ctrlValue","_","jqxhr","textStatus","entries","replaceAll","title","gpio","gpioEntry","fixed","group","severity","ms","reason","_resolve","reject","saveAutoexec1","commandLine","_get_control_option_v","optStr","resample","options","_i","_Object$entries","_Object$entries$_i","_slicedToArray","option","concatenateOptions","autoexec1","responseText","result","Result","handleDisconnect","handleConnect","pwd","dhcpname","ready","index","not","_get_control_option_v2","invalid","map","trim","join","test","event","relatedTarget","CONN","MAN","FileReader","file","fr","onload","target","ex","alert","readAsText","slideUp","slideDown","preventDefault","currentValue","originalValue","set","createElement","href","URL","createObjectURL","Blob","setAttribute","body","appendChild","click","removeChild","branches","release","branch","push","fwb","assets","asset","browser_download_url","namecomponents","ver","cfg","bits","substr","lastIndexOf","created_at","i","idf","trclass","setURL","button","dataset","reboot","cmdstring","fields","allfields","querySelectorAll","selJson","cmd","model_config","_i2","_Object$entries2","_Object$entries2$_i","storedval","handleHWPreset","_step3","_iterator3","_attr$hasvalue","qts","isSelect","hasValue","validVal","_attr$longopts","_attr$shortopts","_attr$hasvalue2","_attr$longopts2","indexOf","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","module","__webpack_modules__","call","m","O","chunkIds","fn","priority","notFulfilled","Infinity","fulfilled","every","splice","r","getter","__esModule","d","definition","defineProperty","enumerable","g","globalThis","Function","Symbol","toStringTag","nmd","paths","installedChunks","chunkId","webpackJsonpCallback","parentChunkLoadingFunction","moreModules","runtime","some","chunkLoadingGlobal","self","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file diff --git a/components/wifi-manager/webapp/dist/js/node_vendors.4135c4.bundle.js b/components/wifi-manager/webapp/dist/js/node_vendors.1d06b9.bundle.js similarity index 99% rename from components/wifi-manager/webapp/dist/js/node_vendors.4135c4.bundle.js rename to components/wifi-manager/webapp/dist/js/node_vendors.1d06b9.bundle.js index 7052ad775..2debb0ade 100644 --- a/components/wifi-manager/webapp/dist/js/node_vendors.4135c4.bundle.js +++ b/components/wifi-manager/webapp/dist/js/node_vendors.1d06b9.bundle.js @@ -1,2 +1,2 @@ (self.webpackChunksqueezelite_esp32=self.webpackChunksqueezelite_esp32||[]).push([[987],{138:(e,t,r)=>{"use strict";r.r(t),r.d(t,{Alert:()=>Ct,Button:()=>St,Carousel:()=>lr,Collapse:()=>xr,Dropdown:()=>Wr,Modal:()=>kn,Offcanvas:()=>Wn,Popover:()=>gi,ScrollSpy:()=>Ti,Tab:()=>Xi,Toast:()=>uo,Tooltip:()=>di});var n={};r.r(n),r.d(n,{afterMain:()=>E,afterRead:()=>w,afterWrite:()=>T,applyStyles:()=>O,arrow:()=>Z,auto:()=>l,basePlacements:()=>c,beforeMain:()=>_,beforeRead:()=>b,beforeWrite:()=>A,bottom:()=>o,clippingParents:()=>d,computeStyles:()=>ne,createPopper:()=>Oe,createPopperBase:()=>Ne,createPopperLite:()=>je,detectOverflow:()=>ye,end:()=>p,eventListeners:()=>oe,flip:()=>we,hide:()=>Ee,left:()=>a,main:()=>x,modifierPhases:()=>q,offset:()=>Ae,placements:()=>v,popper:()=>h,popperGenerator:()=>Le,popperOffsets:()=>De,preventOverflow:()=>Te,read:()=>y,reference:()=>g,right:()=>s,start:()=>u,top:()=>i,variationPlacements:()=>m,viewport:()=>f,write:()=>D});var i="top",o="bottom",s="right",a="left",l="auto",c=[i,o,s,a],u="start",p="end",d="clippingParents",f="viewport",h="popper",g="reference",m=c.reduce((function(e,t){return e.concat([t+"-"+u,t+"-"+p])}),[]),v=[].concat(c,[l]).reduce((function(e,t){return e.concat([t,t+"-"+u,t+"-"+p])}),[]),b="beforeRead",y="read",w="afterRead",_="beforeMain",x="main",E="afterMain",A="beforeWrite",D="write",T="afterWrite",q=[b,y,w,_,x,E,A,D,T];function C(e){return e?(e.nodeName||"").toLowerCase():null}function k(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function S(e){return e instanceof k(e).Element||e instanceof Element}function L(e){return e instanceof k(e).HTMLElement||e instanceof HTMLElement}function N(e){return"undefined"!=typeof ShadowRoot&&(e instanceof k(e).ShadowRoot||e instanceof ShadowRoot)}const O={name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var r=t.styles[e]||{},n=t.attributes[e]||{},i=t.elements[e];L(i)&&C(i)&&(Object.assign(i.style,r),Object.keys(n).forEach((function(e){var t=n[e];!1===t?i.removeAttribute(e):i.setAttribute(e,!0===t?"":t)})))}))},effect:function(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach((function(e){var n=t.elements[e],i=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:r[e]).reduce((function(e,t){return e[t]="",e}),{});L(n)&&C(n)&&(Object.assign(n.style,o),Object.keys(i).forEach((function(e){n.removeAttribute(e)})))}))}},requires:["computeStyles"]};function j(e){return e.split("-")[0]}var R=Math.max,B=Math.min,F=Math.round;function I(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map((function(e){return e.brand+"/"+e.version})).join(" "):navigator.userAgent}function P(){return!/^((?!chrome|android).)*safari/i.test(I())}function H(e,t,r){void 0===t&&(t=!1),void 0===r&&(r=!1);var n=e.getBoundingClientRect(),i=1,o=1;t&&L(e)&&(i=e.offsetWidth>0&&F(n.width)/e.offsetWidth||1,o=e.offsetHeight>0&&F(n.height)/e.offsetHeight||1);var s=(S(e)?k(e):window).visualViewport,a=!P()&&r,l=(n.left+(a&&s?s.offsetLeft:0))/i,c=(n.top+(a&&s?s.offsetTop:0))/o,u=n.width/i,p=n.height/o;return{width:u,height:p,top:c,right:l+u,bottom:c+p,left:l,x:l,y:c}}function M(e){var t=H(e),r=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:n}}function U(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&N(r)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function V(e){return k(e).getComputedStyle(e)}function $(e){return["table","td","th"].indexOf(C(e))>=0}function z(e){return((S(e)?e.ownerDocument:e.document)||window.document).documentElement}function G(e){return"html"===C(e)?e:e.assignedSlot||e.parentNode||(N(e)?e.host:null)||z(e)}function W(e){return L(e)&&"fixed"!==V(e).position?e.offsetParent:null}function Y(e){for(var t=k(e),r=W(e);r&&$(r)&&"static"===V(r).position;)r=W(r);return r&&("html"===C(r)||"body"===C(r)&&"static"===V(r).position)?t:r||function(e){var t=/firefox/i.test(I());if(/Trident/i.test(I())&&L(e)&&"fixed"===V(e).position)return null;var r=G(e);for(N(r)&&(r=r.host);L(r)&&["html","body"].indexOf(C(r))<0;){var n=V(r);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return r;r=r.parentNode}return null}(e)||t}function X(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function K(e,t,r){return R(e,B(t,r))}function J(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e)}function Q(e,t){return t.reduce((function(t,r){return t[r]=e,t}),{})}const Z={name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,r=e.state,n=e.name,l=e.options,u=r.elements.arrow,p=r.modifiersData.popperOffsets,d=j(r.placement),f=X(d),h=[a,s].indexOf(d)>=0?"height":"width";if(u&&p){var g=function(e,t){return J("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:Q(e,c))}(l.padding,r),m=M(u),v="y"===f?i:a,b="y"===f?o:s,y=r.rects.reference[h]+r.rects.reference[f]-p[f]-r.rects.popper[h],w=p[f]-r.rects.reference[f],_=Y(u),x=_?"y"===f?_.clientHeight||0:_.clientWidth||0:0,E=y/2-w/2,A=g[v],D=x-m[h]-g[b],T=x/2-m[h]/2+E,q=K(A,T,D),C=f;r.modifiersData[n]=((t={})[C]=q,t.centerOffset=q-T,t)}},effect:function(e){var t=e.state,r=e.options.element,n=void 0===r?"[data-popper-arrow]":r;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&U(t.elements.popper,n)&&(t.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function ee(e){return e.split("-")[1]}var te={top:"auto",right:"auto",bottom:"auto",left:"auto"};function re(e){var t,r=e.popper,n=e.popperRect,l=e.placement,c=e.variation,u=e.offsets,d=e.position,f=e.gpuAcceleration,h=e.adaptive,g=e.roundOffsets,m=e.isFixed,v=u.x,b=void 0===v?0:v,y=u.y,w=void 0===y?0:y,_="function"==typeof g?g({x:b,y:w}):{x:b,y:w};b=_.x,w=_.y;var x=u.hasOwnProperty("x"),E=u.hasOwnProperty("y"),A=a,D=i,T=window;if(h){var q=Y(r),C="clientHeight",S="clientWidth";if(q===k(r)&&"static"!==V(q=z(r)).position&&"absolute"===d&&(C="scrollHeight",S="scrollWidth"),l===i||(l===a||l===s)&&c===p)D=o,w-=(m&&q===T&&T.visualViewport?T.visualViewport.height:q[C])-n.height,w*=f?1:-1;if(l===a||(l===i||l===o)&&c===p)A=s,b-=(m&&q===T&&T.visualViewport?T.visualViewport.width:q[S])-n.width,b*=f?1:-1}var L,N=Object.assign({position:d},h&&te),O=!0===g?function(e,t){var r=e.x,n=e.y,i=t.devicePixelRatio||1;return{x:F(r*i)/i||0,y:F(n*i)/i||0}}({x:b,y:w},k(r)):{x:b,y:w};return b=O.x,w=O.y,f?Object.assign({},N,((L={})[D]=E?"0":"",L[A]=x?"0":"",L.transform=(T.devicePixelRatio||1)<=1?"translate("+b+"px, "+w+"px)":"translate3d("+b+"px, "+w+"px, 0)",L)):Object.assign({},N,((t={})[D]=E?w+"px":"",t[A]=x?b+"px":"",t.transform="",t))}const ne={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,r=e.options,n=r.gpuAcceleration,i=void 0===n||n,o=r.adaptive,s=void 0===o||o,a=r.roundOffsets,l=void 0===a||a,c={placement:j(t.placement),variation:ee(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,re(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:s,roundOffsets:l})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,re(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}};var ie={passive:!0};const oe={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,r=e.instance,n=e.options,i=n.scroll,o=void 0===i||i,s=n.resize,a=void 0===s||s,l=k(t.elements.popper),c=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&c.forEach((function(e){e.addEventListener("scroll",r.update,ie)})),a&&l.addEventListener("resize",r.update,ie),function(){o&&c.forEach((function(e){e.removeEventListener("scroll",r.update,ie)})),a&&l.removeEventListener("resize",r.update,ie)}},data:{}};var se={left:"right",right:"left",bottom:"top",top:"bottom"};function ae(e){return e.replace(/left|right|bottom|top/g,(function(e){return se[e]}))}var le={start:"end",end:"start"};function ce(e){return e.replace(/start|end/g,(function(e){return le[e]}))}function ue(e){var t=k(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function pe(e){return H(z(e)).left+ue(e).scrollLeft}function de(e){var t=V(e),r=t.overflow,n=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+i+n)}function fe(e){return["html","body","#document"].indexOf(C(e))>=0?e.ownerDocument.body:L(e)&&de(e)?e:fe(G(e))}function he(e,t){var r;void 0===t&&(t=[]);var n=fe(e),i=n===(null==(r=e.ownerDocument)?void 0:r.body),o=k(n),s=i?[o].concat(o.visualViewport||[],de(n)?n:[]):n,a=t.concat(s);return i?a:a.concat(he(G(s)))}function ge(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function me(e,t,r){return t===f?ge(function(e,t){var r=k(e),n=z(e),i=r.visualViewport,o=n.clientWidth,s=n.clientHeight,a=0,l=0;if(i){o=i.width,s=i.height;var c=P();(c||!c&&"fixed"===t)&&(a=i.offsetLeft,l=i.offsetTop)}return{width:o,height:s,x:a+pe(e),y:l}}(e,r)):S(t)?function(e,t){var r=H(e,!1,"fixed"===t);return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}(t,r):ge(function(e){var t,r=z(e),n=ue(e),i=null==(t=e.ownerDocument)?void 0:t.body,o=R(r.scrollWidth,r.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),s=R(r.scrollHeight,r.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),a=-n.scrollLeft+pe(e),l=-n.scrollTop;return"rtl"===V(i||r).direction&&(a+=R(r.clientWidth,i?i.clientWidth:0)-o),{width:o,height:s,x:a,y:l}}(z(e)))}function ve(e,t,r,n){var i="clippingParents"===t?function(e){var t=he(G(e)),r=["absolute","fixed"].indexOf(V(e).position)>=0&&L(e)?Y(e):e;return S(r)?t.filter((function(e){return S(e)&&U(e,r)&&"body"!==C(e)})):[]}(e):[].concat(t),o=[].concat(i,[r]),s=o[0],a=o.reduce((function(t,r){var i=me(e,r,n);return t.top=R(i.top,t.top),t.right=B(i.right,t.right),t.bottom=B(i.bottom,t.bottom),t.left=R(i.left,t.left),t}),me(e,s,n));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function be(e){var t,r=e.reference,n=e.element,l=e.placement,c=l?j(l):null,d=l?ee(l):null,f=r.x+r.width/2-n.width/2,h=r.y+r.height/2-n.height/2;switch(c){case i:t={x:f,y:r.y-n.height};break;case o:t={x:f,y:r.y+r.height};break;case s:t={x:r.x+r.width,y:h};break;case a:t={x:r.x-n.width,y:h};break;default:t={x:r.x,y:r.y}}var g=c?X(c):null;if(null!=g){var m="y"===g?"height":"width";switch(d){case u:t[g]=t[g]-(r[m]/2-n[m]/2);break;case p:t[g]=t[g]+(r[m]/2-n[m]/2)}}return t}function ye(e,t){void 0===t&&(t={});var r=t,n=r.placement,a=void 0===n?e.placement:n,l=r.strategy,u=void 0===l?e.strategy:l,p=r.boundary,m=void 0===p?d:p,v=r.rootBoundary,b=void 0===v?f:v,y=r.elementContext,w=void 0===y?h:y,_=r.altBoundary,x=void 0!==_&&_,E=r.padding,A=void 0===E?0:E,D=J("number"!=typeof A?A:Q(A,c)),T=w===h?g:h,q=e.rects.popper,C=e.elements[x?T:w],k=ve(S(C)?C:C.contextElement||z(e.elements.popper),m,b,u),L=H(e.elements.reference),N=be({reference:L,element:q,strategy:"absolute",placement:a}),O=ge(Object.assign({},q,N)),j=w===h?O:L,R={top:k.top-j.top+D.top,bottom:j.bottom-k.bottom+D.bottom,left:k.left-j.left+D.left,right:j.right-k.right+D.right},B=e.modifiersData.offset;if(w===h&&B){var F=B[a];Object.keys(R).forEach((function(e){var t=[s,o].indexOf(e)>=0?1:-1,r=[i,o].indexOf(e)>=0?"y":"x";R[e]+=F[r]*t}))}return R}const we={name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,r=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var p=r.mainAxis,d=void 0===p||p,f=r.altAxis,h=void 0===f||f,g=r.fallbackPlacements,b=r.padding,y=r.boundary,w=r.rootBoundary,_=r.altBoundary,x=r.flipVariations,E=void 0===x||x,A=r.allowedAutoPlacements,D=t.options.placement,T=j(D),q=g||(T===D||!E?[ae(D)]:function(e){if(j(e)===l)return[];var t=ae(e);return[ce(e),t,ce(t)]}(D)),C=[D].concat(q).reduce((function(e,r){return e.concat(j(r)===l?function(e,t){void 0===t&&(t={});var r=t,n=r.placement,i=r.boundary,o=r.rootBoundary,s=r.padding,a=r.flipVariations,l=r.allowedAutoPlacements,u=void 0===l?v:l,p=ee(n),d=p?a?m:m.filter((function(e){return ee(e)===p})):c,f=d.filter((function(e){return u.indexOf(e)>=0}));0===f.length&&(f=d);var h=f.reduce((function(t,r){return t[r]=ye(e,{placement:r,boundary:i,rootBoundary:o,padding:s})[j(r)],t}),{});return Object.keys(h).sort((function(e,t){return h[e]-h[t]}))}(t,{placement:r,boundary:y,rootBoundary:w,padding:b,flipVariations:E,allowedAutoPlacements:A}):r)}),[]),k=t.rects.reference,S=t.rects.popper,L=new Map,N=!0,O=C[0],R=0;R=0,H=P?"width":"height",M=ye(t,{placement:B,boundary:y,rootBoundary:w,altBoundary:_,padding:b}),U=P?I?s:a:I?o:i;k[H]>S[H]&&(U=ae(U));var V=ae(U),$=[];if(d&&$.push(M[F]<=0),h&&$.push(M[U]<=0,M[V]<=0),$.every((function(e){return e}))){O=B,N=!1;break}L.set(B,$)}if(N)for(var z=function(e){var t=C.find((function(t){var r=L.get(t);if(r)return r.slice(0,e).every((function(e){return e}))}));if(t)return O=t,"break"},G=E?3:1;G>0;G--){if("break"===z(G))break}t.placement!==O&&(t.modifiersData[n]._skip=!0,t.placement=O,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function _e(e,t,r){return void 0===r&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function xe(e){return[i,s,o,a].some((function(t){return e[t]>=0}))}const Ee={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,r=e.name,n=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,s=ye(t,{elementContext:"reference"}),a=ye(t,{altBoundary:!0}),l=_e(s,n),c=_e(a,i,o),u=xe(l),p=xe(c);t.modifiersData[r]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:u,hasPopperEscaped:p},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":p})}};const Ae={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,r=e.options,n=e.name,o=r.offset,l=void 0===o?[0,0]:o,c=v.reduce((function(e,r){return e[r]=function(e,t,r){var n=j(e),o=[a,i].indexOf(n)>=0?-1:1,l="function"==typeof r?r(Object.assign({},t,{placement:e})):r,c=l[0],u=l[1];return c=c||0,u=(u||0)*o,[a,s].indexOf(n)>=0?{x:u,y:c}:{x:c,y:u}}(r,t.rects,l),e}),{}),u=c[t.placement],p=u.x,d=u.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=p,t.modifiersData.popperOffsets.y+=d),t.modifiersData[n]=c}};const De={name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,r=e.name;t.modifiersData[r]=be({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}};const Te={name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,r=e.options,n=e.name,l=r.mainAxis,c=void 0===l||l,p=r.altAxis,d=void 0!==p&&p,f=r.boundary,h=r.rootBoundary,g=r.altBoundary,m=r.padding,v=r.tether,b=void 0===v||v,y=r.tetherOffset,w=void 0===y?0:y,_=ye(t,{boundary:f,rootBoundary:h,padding:m,altBoundary:g}),x=j(t.placement),E=ee(t.placement),A=!E,D=X(x),T="x"===D?"y":"x",q=t.modifiersData.popperOffsets,C=t.rects.reference,k=t.rects.popper,S="function"==typeof w?w(Object.assign({},t.rects,{placement:t.placement})):w,L="number"==typeof S?{mainAxis:S,altAxis:S}:Object.assign({mainAxis:0,altAxis:0},S),N=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,O={x:0,y:0};if(q){if(c){var F,I="y"===D?i:a,P="y"===D?o:s,H="y"===D?"height":"width",U=q[D],V=U+_[I],$=U-_[P],z=b?-k[H]/2:0,G=E===u?C[H]:k[H],W=E===u?-k[H]:-C[H],J=t.elements.arrow,Q=b&&J?M(J):{width:0,height:0},Z=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},te=Z[I],re=Z[P],ne=K(0,C[H],Q[H]),ie=A?C[H]/2-z-ne-te-L.mainAxis:G-ne-te-L.mainAxis,oe=A?-C[H]/2+z+ne+re+L.mainAxis:W+ne+re+L.mainAxis,se=t.elements.arrow&&Y(t.elements.arrow),ae=se?"y"===D?se.clientTop||0:se.clientLeft||0:0,le=null!=(F=null==N?void 0:N[D])?F:0,ce=U+oe-le,ue=K(b?B(V,U+ie-le-ae):V,U,b?R($,ce):$);q[D]=ue,O[D]=ue-U}if(d){var pe,de="x"===D?i:a,fe="x"===D?o:s,he=q[T],ge="y"===T?"height":"width",me=he+_[de],ve=he-_[fe],be=-1!==[i,a].indexOf(x),we=null!=(pe=null==N?void 0:N[T])?pe:0,_e=be?me:he-C[ge]-k[ge]-we+L.altAxis,xe=be?he+C[ge]+k[ge]-we-L.altAxis:ve,Ee=b&&be?function(e,t,r){var n=K(e,t,r);return n>r?r:n}(_e,he,xe):K(b?_e:me,he,b?xe:ve);q[T]=Ee,O[T]=Ee-he}t.modifiersData[n]=O}},requiresIfExists:["offset"]};function qe(e,t,r){void 0===r&&(r=!1);var n,i,o=L(t),s=L(t)&&function(e){var t=e.getBoundingClientRect(),r=F(t.width)/e.offsetWidth||1,n=F(t.height)/e.offsetHeight||1;return 1!==r||1!==n}(t),a=z(t),l=H(e,s,r),c={scrollLeft:0,scrollTop:0},u={x:0,y:0};return(o||!o&&!r)&&(("body"!==C(t)||de(a))&&(c=(n=t)!==k(n)&&L(n)?{scrollLeft:(i=n).scrollLeft,scrollTop:i.scrollTop}:ue(n)),L(t)?((u=H(t,!0)).x+=t.clientLeft,u.y+=t.clientTop):a&&(u.x=pe(a))),{x:l.left+c.scrollLeft-u.x,y:l.top+c.scrollTop-u.y,width:l.width,height:l.height}}function Ce(e){var t=new Map,r=new Set,n=[];function i(e){r.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!r.has(e)){var n=t.get(e);n&&i(n)}})),n.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){r.has(e.name)||i(e)})),n}var ke={placement:"bottom",modifiers:[],strategy:"absolute"};function Se(){for(var e=arguments.length,t=new Array(e),r=0;rRe.has(e)&&Re.get(e).get(t)||null,remove(e,t){if(!Re.has(e))return;const r=Re.get(e);r.delete(t),0===r.size&&Re.delete(e)}},Fe="transitionend",Ie=e=>(e&&window.CSS&&window.CSS.escape&&(e=e.replace(/#([^\s"#']+)/g,((e,t)=>`#${CSS.escape(t)}`))),e),Pe=e=>{e.dispatchEvent(new Event(Fe))},He=e=>!(!e||"object"!=typeof e)&&(void 0!==e.jquery&&(e=e[0]),void 0!==e.nodeType),Me=e=>He(e)?e.jquery?e[0]:e:"string"==typeof e&&e.length>0?document.querySelector(Ie(e)):null,Ue=e=>{if(!He(e)||0===e.getClientRects().length)return!1;const t="visible"===getComputedStyle(e).getPropertyValue("visibility"),r=e.closest("details:not([open])");if(!r)return t;if(r!==e){const t=e.closest("summary");if(t&&t.parentNode!==r)return!1;if(null===t)return!1}return t},Ve=e=>!e||e.nodeType!==Node.ELEMENT_NODE||(!!e.classList.contains("disabled")||(void 0!==e.disabled?e.disabled:e.hasAttribute("disabled")&&"false"!==e.getAttribute("disabled"))),$e=e=>{if(!document.documentElement.attachShadow)return null;if("function"==typeof e.getRootNode){const t=e.getRootNode();return t instanceof ShadowRoot?t:null}return e instanceof ShadowRoot?e:e.parentNode?$e(e.parentNode):null},ze=()=>{},Ge=e=>{e.offsetHeight},We=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,Ye=[],Xe=()=>"rtl"===document.documentElement.dir,Ke=e=>{var t;t=()=>{const t=We();if(t){const r=e.NAME,n=t.fn[r];t.fn[r]=e.jQueryInterface,t.fn[r].Constructor=e,t.fn[r].noConflict=()=>(t.fn[r]=n,e.jQueryInterface)}},"loading"===document.readyState?(Ye.length||document.addEventListener("DOMContentLoaded",(()=>{for(const e of Ye)e()})),Ye.push(t)):t()},Je=(e,t=[],r=e)=>"function"==typeof e?e(...t):r,Qe=(e,t,r=!0)=>{if(!r)return void Je(e);const n=(e=>{if(!e)return 0;let{transitionDuration:t,transitionDelay:r}=window.getComputedStyle(e);const n=Number.parseFloat(t),i=Number.parseFloat(r);return n||i?(t=t.split(",")[0],r=r.split(",")[0],1e3*(Number.parseFloat(t)+Number.parseFloat(r))):0})(t)+5;let i=!1;const o=({target:r})=>{r===t&&(i=!0,t.removeEventListener(Fe,o),Je(e))};t.addEventListener(Fe,o),setTimeout((()=>{i||Pe(t)}),n)},Ze=(e,t,r,n)=>{const i=e.length;let o=e.indexOf(t);return-1===o?!r&&n?e[i-1]:e[0]:(o+=r?1:-1,n&&(o=(o+i)%i),e[Math.max(0,Math.min(o,i-1))])},et=/[^.]*(?=\..*)\.|.*/,tt=/\..*/,rt=/::\d+$/,nt={};let it=1;const ot={mouseenter:"mouseover",mouseleave:"mouseout"},st=new Set(["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"]);function at(e,t){return t&&`${t}::${it++}`||e.uidEvent||it++}function lt(e){const t=at(e);return e.uidEvent=t,nt[t]=nt[t]||{},nt[t]}function ct(e,t,r=null){return Object.values(e).find((e=>e.callable===t&&e.delegationSelector===r))}function ut(e,t,r){const n="string"==typeof t,i=n?r:t||r;let o=ht(e);return st.has(o)||(o=e),[n,i,o]}function pt(e,t,r,n,i){if("string"!=typeof t||!e)return;let[o,s,a]=ut(t,r,n);if(t in ot){const e=e=>function(t){if(!t.relatedTarget||t.relatedTarget!==t.delegateTarget&&!t.delegateTarget.contains(t.relatedTarget))return e.call(this,t)};s=e(s)}const l=lt(e),c=l[a]||(l[a]={}),u=ct(c,s,o?r:null);if(u)return void(u.oneOff=u.oneOff&&i);const p=at(s,t.replace(et,"")),d=o?function(e,t,r){return function n(i){const o=e.querySelectorAll(t);for(let{target:s}=i;s&&s!==this;s=s.parentNode)for(const a of o)if(a===s)return mt(i,{delegateTarget:s}),n.oneOff&>.off(e,i.type,t,r),r.apply(s,[i])}}(e,r,s):function(e,t){return function r(n){return mt(n,{delegateTarget:e}),r.oneOff&>.off(e,n.type,t),t.apply(e,[n])}}(e,s);d.delegationSelector=o?r:null,d.callable=s,d.oneOff=i,d.uidEvent=p,c[p]=d,e.addEventListener(a,d,o)}function dt(e,t,r,n,i){const o=ct(t[r],n,i);o&&(e.removeEventListener(r,o,Boolean(i)),delete t[r][o.uidEvent])}function ft(e,t,r,n){const i=t[r]||{};for(const[o,s]of Object.entries(i))o.includes(n)&&dt(e,t,r,s.callable,s.delegationSelector)}function ht(e){return e=e.replace(tt,""),ot[e]||e}const gt={on(e,t,r,n){pt(e,t,r,n,!1)},one(e,t,r,n){pt(e,t,r,n,!0)},off(e,t,r,n){if("string"!=typeof t||!e)return;const[i,o,s]=ut(t,r,n),a=s!==t,l=lt(e),c=l[s]||{},u=t.startsWith(".");if(void 0===o){if(u)for(const r of Object.keys(l))ft(e,l,r,t.slice(1));for(const[r,n]of Object.entries(c)){const i=r.replace(rt,"");a&&!t.includes(i)||dt(e,l,s,n.callable,n.delegationSelector)}}else{if(!Object.keys(c).length)return;dt(e,l,s,o,i?r:null)}},trigger(e,t,r){if("string"!=typeof t||!e)return null;const n=We();let i=null,o=!0,s=!0,a=!1;t!==ht(t)&&n&&(i=n.Event(t,r),n(e).trigger(i),o=!i.isPropagationStopped(),s=!i.isImmediatePropagationStopped(),a=i.isDefaultPrevented());const l=mt(new Event(t,{bubbles:o,cancelable:!0}),r);return a&&l.preventDefault(),s&&e.dispatchEvent(l),l.defaultPrevented&&i&&i.preventDefault(),l}};function mt(e,t={}){for(const[r,n]of Object.entries(t))try{e[r]=n}catch(t){Object.defineProperty(e,r,{configurable:!0,get:()=>n})}return e}function vt(e){if("true"===e)return!0;if("false"===e)return!1;if(e===Number(e).toString())return Number(e);if(""===e||"null"===e)return null;if("string"!=typeof e)return e;try{return JSON.parse(decodeURIComponent(e))}catch(t){return e}}function bt(e){return e.replace(/[A-Z]/g,(e=>`-${e.toLowerCase()}`))}const yt={setDataAttribute(e,t,r){e.setAttribute(`data-bs-${bt(t)}`,r)},removeDataAttribute(e,t){e.removeAttribute(`data-bs-${bt(t)}`)},getDataAttributes(e){if(!e)return{};const t={},r=Object.keys(e.dataset).filter((e=>e.startsWith("bs")&&!e.startsWith("bsConfig")));for(const n of r){let r=n.replace(/^bs/,"");r=r.charAt(0).toLowerCase()+r.slice(1,r.length),t[r]=vt(e.dataset[n])}return t},getDataAttribute:(e,t)=>vt(e.getAttribute(`data-bs-${bt(t)}`))};class wt{static get Default(){return{}}static get DefaultType(){return{}}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}_getConfig(e){return e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}_configAfterMerge(e){return e}_mergeConfigObj(e,t){const r=He(t)?yt.getDataAttribute(t,"config"):{};return{...this.constructor.Default,..."object"==typeof r?r:{},...He(t)?yt.getDataAttributes(t):{},..."object"==typeof e?e:{}}}_typeCheckConfig(e,t=this.constructor.DefaultType){for(const[n,i]of Object.entries(t)){const t=e[n],o=He(t)?"element":null==(r=t)?`${r}`:Object.prototype.toString.call(r).match(/\s([a-z]+)/i)[1].toLowerCase();if(!new RegExp(i).test(o))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${n}" provided type "${o}" but expected type "${i}".`)}var r}}class _t extends wt{constructor(e,t){super(),(e=Me(e))&&(this._element=e,this._config=this._getConfig(t),Be.set(this._element,this.constructor.DATA_KEY,this))}dispose(){Be.remove(this._element,this.constructor.DATA_KEY),gt.off(this._element,this.constructor.EVENT_KEY);for(const e of Object.getOwnPropertyNames(this))this[e]=null}_queueCallback(e,t,r=!0){Qe(e,t,r)}_getConfig(e){return e=this._mergeConfigObj(e,this._element),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}static getInstance(e){return Be.get(Me(e),this.DATA_KEY)}static getOrCreateInstance(e,t={}){return this.getInstance(e)||new this(e,"object"==typeof t?t:null)}static get VERSION(){return"5.3.2"}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(e){return`${e}${this.EVENT_KEY}`}}const xt=e=>{let t=e.getAttribute("data-bs-target");if(!t||"#"===t){let r=e.getAttribute("href");if(!r||!r.includes("#")&&!r.startsWith("."))return null;r.includes("#")&&!r.startsWith("#")&&(r=`#${r.split("#")[1]}`),t=r&&"#"!==r?Ie(r.trim()):null}return t},Et={find:(e,t=document.documentElement)=>[].concat(...Element.prototype.querySelectorAll.call(t,e)),findOne:(e,t=document.documentElement)=>Element.prototype.querySelector.call(t,e),children:(e,t)=>[].concat(...e.children).filter((e=>e.matches(t))),parents(e,t){const r=[];let n=e.parentNode.closest(t);for(;n;)r.push(n),n=n.parentNode.closest(t);return r},prev(e,t){let r=e.previousElementSibling;for(;r;){if(r.matches(t))return[r];r=r.previousElementSibling}return[]},next(e,t){let r=e.nextElementSibling;for(;r;){if(r.matches(t))return[r];r=r.nextElementSibling}return[]},focusableChildren(e){const t=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map((e=>`${e}:not([tabindex^="-"])`)).join(",");return this.find(t,e).filter((e=>!Ve(e)&&Ue(e)))},getSelectorFromElement(e){const t=xt(e);return t&&Et.findOne(t)?t:null},getElementFromSelector(e){const t=xt(e);return t?Et.findOne(t):null},getMultipleElementsFromSelector(e){const t=xt(e);return t?Et.find(t):[]}},At=(e,t="hide")=>{const r=`click.dismiss${e.EVENT_KEY}`,n=e.NAME;gt.on(document,r,`[data-bs-dismiss="${n}"]`,(function(r){if(["A","AREA"].includes(this.tagName)&&r.preventDefault(),Ve(this))return;const i=Et.getElementFromSelector(this)||this.closest(`.${n}`);e.getOrCreateInstance(i)[t]()}))},Dt=".bs.alert",Tt=`close${Dt}`,qt=`closed${Dt}`;class Ct extends _t{static get NAME(){return"alert"}close(){if(gt.trigger(this._element,Tt).defaultPrevented)return;this._element.classList.remove("show");const e=this._element.classList.contains("fade");this._queueCallback((()=>this._destroyElement()),this._element,e)}_destroyElement(){this._element.remove(),gt.trigger(this._element,qt),this.dispose()}static jQueryInterface(e){return this.each((function(){const t=Ct.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}At(Ct,"close"),Ke(Ct);const kt='[data-bs-toggle="button"]';class St extends _t{static get NAME(){return"button"}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle("active"))}static jQueryInterface(e){return this.each((function(){const t=St.getOrCreateInstance(this);"toggle"===e&&t[e]()}))}}gt.on(document,"click.bs.button.data-api",kt,(e=>{e.preventDefault();const t=e.target.closest(kt);St.getOrCreateInstance(t).toggle()})),Ke(St);const Lt=".bs.swipe",Nt=`touchstart${Lt}`,Ot=`touchmove${Lt}`,jt=`touchend${Lt}`,Rt=`pointerdown${Lt}`,Bt=`pointerup${Lt}`,Ft={endCallback:null,leftCallback:null,rightCallback:null},It={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"};class Pt extends wt{constructor(e,t){super(),this._element=e,e&&Pt.isSupported()&&(this._config=this._getConfig(t),this._deltaX=0,this._supportPointerEvents=Boolean(window.PointerEvent),this._initEvents())}static get Default(){return Ft}static get DefaultType(){return It}static get NAME(){return"swipe"}dispose(){gt.off(this._element,Lt)}_start(e){this._supportPointerEvents?this._eventIsPointerPenTouch(e)&&(this._deltaX=e.clientX):this._deltaX=e.touches[0].clientX}_end(e){this._eventIsPointerPenTouch(e)&&(this._deltaX=e.clientX-this._deltaX),this._handleSwipe(),Je(this._config.endCallback)}_move(e){this._deltaX=e.touches&&e.touches.length>1?0:e.touches[0].clientX-this._deltaX}_handleSwipe(){const e=Math.abs(this._deltaX);if(e<=40)return;const t=e/this._deltaX;this._deltaX=0,t&&Je(t>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(gt.on(this._element,Rt,(e=>this._start(e))),gt.on(this._element,Bt,(e=>this._end(e))),this._element.classList.add("pointer-event")):(gt.on(this._element,Nt,(e=>this._start(e))),gt.on(this._element,Ot,(e=>this._move(e))),gt.on(this._element,jt,(e=>this._end(e))))}_eventIsPointerPenTouch(e){return this._supportPointerEvents&&("pen"===e.pointerType||"touch"===e.pointerType)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}}const Ht=".bs.carousel",Mt=".data-api",Ut="next",Vt="prev",$t="left",zt="right",Gt=`slide${Ht}`,Wt=`slid${Ht}`,Yt=`keydown${Ht}`,Xt=`mouseenter${Ht}`,Kt=`mouseleave${Ht}`,Jt=`dragstart${Ht}`,Qt=`load${Ht}${Mt}`,Zt=`click${Ht}${Mt}`,er="carousel",tr="active",rr=".active",nr=".carousel-item",ir=rr+nr,or={ArrowLeft:zt,ArrowRight:$t},sr={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},ar={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"};class lr extends _t{constructor(e,t){super(e,t),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=Et.findOne(".carousel-indicators",this._element),this._addEventListeners(),this._config.ride===er&&this.cycle()}static get Default(){return sr}static get DefaultType(){return ar}static get NAME(){return"carousel"}next(){this._slide(Ut)}nextWhenVisible(){!document.hidden&&Ue(this._element)&&this.next()}prev(){this._slide(Vt)}pause(){this._isSliding&&Pe(this._element),this._clearInterval()}cycle(){this._clearInterval(),this._updateInterval(),this._interval=setInterval((()=>this.nextWhenVisible()),this._config.interval)}_maybeEnableCycle(){this._config.ride&&(this._isSliding?gt.one(this._element,Wt,(()=>this.cycle())):this.cycle())}to(e){const t=this._getItems();if(e>t.length-1||e<0)return;if(this._isSliding)return void gt.one(this._element,Wt,(()=>this.to(e)));const r=this._getItemIndex(this._getActive());if(r===e)return;const n=e>r?Ut:Vt;this._slide(n,t[e])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(e){return e.defaultInterval=e.interval,e}_addEventListeners(){this._config.keyboard&>.on(this._element,Yt,(e=>this._keydown(e))),"hover"===this._config.pause&&(gt.on(this._element,Xt,(()=>this.pause())),gt.on(this._element,Kt,(()=>this._maybeEnableCycle()))),this._config.touch&&Pt.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(const e of Et.find(".carousel-item img",this._element))gt.on(e,Jt,(e=>e.preventDefault()));const e={leftCallback:()=>this._slide(this._directionToOrder($t)),rightCallback:()=>this._slide(this._directionToOrder(zt)),endCallback:()=>{"hover"===this._config.pause&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout((()=>this._maybeEnableCycle()),500+this._config.interval))}};this._swipeHelper=new Pt(this._element,e)}_keydown(e){if(/input|textarea/i.test(e.target.tagName))return;const t=or[e.key];t&&(e.preventDefault(),this._slide(this._directionToOrder(t)))}_getItemIndex(e){return this._getItems().indexOf(e)}_setActiveIndicatorElement(e){if(!this._indicatorsElement)return;const t=Et.findOne(rr,this._indicatorsElement);t.classList.remove(tr),t.removeAttribute("aria-current");const r=Et.findOne(`[data-bs-slide-to="${e}"]`,this._indicatorsElement);r&&(r.classList.add(tr),r.setAttribute("aria-current","true"))}_updateInterval(){const e=this._activeElement||this._getActive();if(!e)return;const t=Number.parseInt(e.getAttribute("data-bs-interval"),10);this._config.interval=t||this._config.defaultInterval}_slide(e,t=null){if(this._isSliding)return;const r=this._getActive(),n=e===Ut,i=t||Ze(this._getItems(),r,n,this._config.wrap);if(i===r)return;const o=this._getItemIndex(i),s=t=>gt.trigger(this._element,t,{relatedTarget:i,direction:this._orderToDirection(e),from:this._getItemIndex(r),to:o});if(s(Gt).defaultPrevented)return;if(!r||!i)return;const a=Boolean(this._interval);this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(o),this._activeElement=i;const l=n?"carousel-item-start":"carousel-item-end",c=n?"carousel-item-next":"carousel-item-prev";i.classList.add(c),Ge(i),r.classList.add(l),i.classList.add(l);this._queueCallback((()=>{i.classList.remove(l,c),i.classList.add(tr),r.classList.remove(tr,c,l),this._isSliding=!1,s(Wt)}),r,this._isAnimated()),a&&this.cycle()}_isAnimated(){return this._element.classList.contains("slide")}_getActive(){return Et.findOne(ir,this._element)}_getItems(){return Et.find(nr,this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(e){return Xe()?e===$t?Vt:Ut:e===$t?Ut:Vt}_orderToDirection(e){return Xe()?e===Vt?$t:zt:e===Vt?zt:$t}static jQueryInterface(e){return this.each((function(){const t=lr.getOrCreateInstance(this,e);if("number"!=typeof e){if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}else t.to(e)}))}}gt.on(document,Zt,"[data-bs-slide], [data-bs-slide-to]",(function(e){const t=Et.getElementFromSelector(this);if(!t||!t.classList.contains(er))return;e.preventDefault();const r=lr.getOrCreateInstance(t),n=this.getAttribute("data-bs-slide-to");return n?(r.to(n),void r._maybeEnableCycle()):"next"===yt.getDataAttribute(this,"slide")?(r.next(),void r._maybeEnableCycle()):(r.prev(),void r._maybeEnableCycle())})),gt.on(window,Qt,(()=>{const e=Et.find('[data-bs-ride="carousel"]');for(const t of e)lr.getOrCreateInstance(t)})),Ke(lr);const cr=".bs.collapse",ur=`show${cr}`,pr=`shown${cr}`,dr=`hide${cr}`,fr=`hidden${cr}`,hr=`click${cr}.data-api`,gr="show",mr="collapse",vr="collapsing",br=`:scope .${mr} .${mr}`,yr='[data-bs-toggle="collapse"]',wr={parent:null,toggle:!0},_r={parent:"(null|element)",toggle:"boolean"};class xr extends _t{constructor(e,t){super(e,t),this._isTransitioning=!1,this._triggerArray=[];const r=Et.find(yr);for(const e of r){const t=Et.getSelectorFromElement(e),r=Et.find(t).filter((e=>e===this._element));null!==t&&r.length&&this._triggerArray.push(e)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return wr}static get DefaultType(){return _r}static get NAME(){return"collapse"}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let e=[];if(this._config.parent&&(e=this._getFirstLevelChildren(".collapse.show, .collapse.collapsing").filter((e=>e!==this._element)).map((e=>xr.getOrCreateInstance(e,{toggle:!1})))),e.length&&e[0]._isTransitioning)return;if(gt.trigger(this._element,ur).defaultPrevented)return;for(const t of e)t.hide();const t=this._getDimension();this._element.classList.remove(mr),this._element.classList.add(vr),this._element.style[t]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const r=`scroll${t[0].toUpperCase()+t.slice(1)}`;this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove(vr),this._element.classList.add(mr,gr),this._element.style[t]="",gt.trigger(this._element,pr)}),this._element,!0),this._element.style[t]=`${this._element[r]}px`}hide(){if(this._isTransitioning||!this._isShown())return;if(gt.trigger(this._element,dr).defaultPrevented)return;const e=this._getDimension();this._element.style[e]=`${this._element.getBoundingClientRect()[e]}px`,Ge(this._element),this._element.classList.add(vr),this._element.classList.remove(mr,gr);for(const e of this._triggerArray){const t=Et.getElementFromSelector(e);t&&!this._isShown(t)&&this._addAriaAndCollapsedClass([e],!1)}this._isTransitioning=!0;this._element.style[e]="",this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove(vr),this._element.classList.add(mr),gt.trigger(this._element,fr)}),this._element,!0)}_isShown(e=this._element){return e.classList.contains(gr)}_configAfterMerge(e){return e.toggle=Boolean(e.toggle),e.parent=Me(e.parent),e}_getDimension(){return this._element.classList.contains("collapse-horizontal")?"width":"height"}_initializeChildren(){if(!this._config.parent)return;const e=this._getFirstLevelChildren(yr);for(const t of e){const e=Et.getElementFromSelector(t);e&&this._addAriaAndCollapsedClass([t],this._isShown(e))}}_getFirstLevelChildren(e){const t=Et.find(br,this._config.parent);return Et.find(e,this._config.parent).filter((e=>!t.includes(e)))}_addAriaAndCollapsedClass(e,t){if(e.length)for(const r of e)r.classList.toggle("collapsed",!t),r.setAttribute("aria-expanded",t)}static jQueryInterface(e){const t={};return"string"==typeof e&&/show|hide/.test(e)&&(t.toggle=!1),this.each((function(){const r=xr.getOrCreateInstance(this,t);if("string"==typeof e){if(void 0===r[e])throw new TypeError(`No method named "${e}"`);r[e]()}}))}}gt.on(document,hr,yr,(function(e){("A"===e.target.tagName||e.delegateTarget&&"A"===e.delegateTarget.tagName)&&e.preventDefault();for(const e of Et.getMultipleElementsFromSelector(this))xr.getOrCreateInstance(e,{toggle:!1}).toggle()})),Ke(xr);const Er="dropdown",Ar=".bs.dropdown",Dr=".data-api",Tr="ArrowUp",qr="ArrowDown",Cr=`hide${Ar}`,kr=`hidden${Ar}`,Sr=`show${Ar}`,Lr=`shown${Ar}`,Nr=`click${Ar}${Dr}`,Or=`keydown${Ar}${Dr}`,jr=`keyup${Ar}${Dr}`,Rr="show",Br='[data-bs-toggle="dropdown"]:not(.disabled):not(:disabled)',Fr=`${Br}.${Rr}`,Ir=".dropdown-menu",Pr=Xe()?"top-end":"top-start",Hr=Xe()?"top-start":"top-end",Mr=Xe()?"bottom-end":"bottom-start",Ur=Xe()?"bottom-start":"bottom-end",Vr=Xe()?"left-start":"right-start",$r=Xe()?"right-start":"left-start",zr={autoClose:!0,boundary:"clippingParents",display:"dynamic",offset:[0,2],popperConfig:null,reference:"toggle"},Gr={autoClose:"(boolean|string)",boundary:"(string|element)",display:"string",offset:"(array|string|function)",popperConfig:"(null|object|function)",reference:"(string|element|object)"};class Wr extends _t{constructor(e,t){super(e,t),this._popper=null,this._parent=this._element.parentNode,this._menu=Et.next(this._element,Ir)[0]||Et.prev(this._element,Ir)[0]||Et.findOne(Ir,this._parent),this._inNavbar=this._detectNavbar()}static get Default(){return zr}static get DefaultType(){return Gr}static get NAME(){return Er}toggle(){return this._isShown()?this.hide():this.show()}show(){if(Ve(this._element)||this._isShown())return;const e={relatedTarget:this._element};if(!gt.trigger(this._element,Sr,e).defaultPrevented){if(this._createPopper(),"ontouchstart"in document.documentElement&&!this._parent.closest(".navbar-nav"))for(const e of[].concat(...document.body.children))gt.on(e,"mouseover",ze);this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add(Rr),this._element.classList.add(Rr),gt.trigger(this._element,Lr,e)}}hide(){if(Ve(this._element)||!this._isShown())return;const e={relatedTarget:this._element};this._completeHide(e)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(e){if(!gt.trigger(this._element,Cr,e).defaultPrevented){if("ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))gt.off(e,"mouseover",ze);this._popper&&this._popper.destroy(),this._menu.classList.remove(Rr),this._element.classList.remove(Rr),this._element.setAttribute("aria-expanded","false"),yt.removeDataAttribute(this._menu,"popper"),gt.trigger(this._element,kr,e)}}_getConfig(e){if("object"==typeof(e=super._getConfig(e)).reference&&!He(e.reference)&&"function"!=typeof e.reference.getBoundingClientRect)throw new TypeError(`${Er.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return e}_createPopper(){if(void 0===n)throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");let e=this._element;"parent"===this._config.reference?e=this._parent:He(this._config.reference)?e=Me(this._config.reference):"object"==typeof this._config.reference&&(e=this._config.reference);const t=this._getPopperConfig();this._popper=Oe(e,this._menu,t)}_isShown(){return this._menu.classList.contains(Rr)}_getPlacement(){const e=this._parent;if(e.classList.contains("dropend"))return Vr;if(e.classList.contains("dropstart"))return $r;if(e.classList.contains("dropup-center"))return"top";if(e.classList.contains("dropdown-center"))return"bottom";const t="end"===getComputedStyle(this._menu).getPropertyValue("--bs-position").trim();return e.classList.contains("dropup")?t?Hr:Pr:t?Ur:Mr}_detectNavbar(){return null!==this._element.closest(".navbar")}_getOffset(){const{offset:e}=this._config;return"string"==typeof e?e.split(",").map((e=>Number.parseInt(e,10))):"function"==typeof e?t=>e(t,this._element):e}_getPopperConfig(){const e={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||"static"===this._config.display)&&(yt.setDataAttribute(this._menu,"popper","static"),e.modifiers=[{name:"applyStyles",enabled:!1}]),{...e,...Je(this._config.popperConfig,[e])}}_selectMenuItem({key:e,target:t}){const r=Et.find(".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",this._menu).filter((e=>Ue(e)));r.length&&Ze(r,t,e===qr,!r.includes(t)).focus()}static jQueryInterface(e){return this.each((function(){const t=Wr.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}static clearMenus(e){if(2===e.button||"keyup"===e.type&&"Tab"!==e.key)return;const t=Et.find(Fr);for(const r of t){const t=Wr.getInstance(r);if(!t||!1===t._config.autoClose)continue;const n=e.composedPath(),i=n.includes(t._menu);if(n.includes(t._element)||"inside"===t._config.autoClose&&!i||"outside"===t._config.autoClose&&i)continue;if(t._menu.contains(e.target)&&("keyup"===e.type&&"Tab"===e.key||/input|select|option|textarea|form/i.test(e.target.tagName)))continue;const o={relatedTarget:t._element};"click"===e.type&&(o.clickEvent=e),t._completeHide(o)}}static dataApiKeydownHandler(e){const t=/input|textarea/i.test(e.target.tagName),r="Escape"===e.key,n=[Tr,qr].includes(e.key);if(!n&&!r)return;if(t&&!r)return;e.preventDefault();const i=this.matches(Br)?this:Et.prev(this,Br)[0]||Et.next(this,Br)[0]||Et.findOne(Br,e.delegateTarget.parentNode),o=Wr.getOrCreateInstance(i);if(n)return e.stopPropagation(),o.show(),void o._selectMenuItem(e);o._isShown()&&(e.stopPropagation(),o.hide(),i.focus())}}gt.on(document,Or,Br,Wr.dataApiKeydownHandler),gt.on(document,Or,Ir,Wr.dataApiKeydownHandler),gt.on(document,Nr,Wr.clearMenus),gt.on(document,jr,Wr.clearMenus),gt.on(document,Nr,Br,(function(e){e.preventDefault(),Wr.getOrCreateInstance(this).toggle()})),Ke(Wr);const Yr="backdrop",Xr="show",Kr=`mousedown.bs.${Yr}`,Jr={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},Qr={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"};class Zr extends wt{constructor(e){super(),this._config=this._getConfig(e),this._isAppended=!1,this._element=null}static get Default(){return Jr}static get DefaultType(){return Qr}static get NAME(){return Yr}show(e){if(!this._config.isVisible)return void Je(e);this._append();const t=this._getElement();this._config.isAnimated&&Ge(t),t.classList.add(Xr),this._emulateAnimation((()=>{Je(e)}))}hide(e){this._config.isVisible?(this._getElement().classList.remove(Xr),this._emulateAnimation((()=>{this.dispose(),Je(e)}))):Je(e)}dispose(){this._isAppended&&(gt.off(this._element,Kr),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){const e=document.createElement("div");e.className=this._config.className,this._config.isAnimated&&e.classList.add("fade"),this._element=e}return this._element}_configAfterMerge(e){return e.rootElement=Me(e.rootElement),e}_append(){if(this._isAppended)return;const e=this._getElement();this._config.rootElement.append(e),gt.on(e,Kr,(()=>{Je(this._config.clickCallback)})),this._isAppended=!0}_emulateAnimation(e){Qe(e,this._getElement(),this._config.isAnimated)}}const en=".bs.focustrap",tn=`focusin${en}`,rn=`keydown.tab${en}`,nn="backward",on={autofocus:!0,trapElement:null},sn={autofocus:"boolean",trapElement:"element"};class an extends wt{constructor(e){super(),this._config=this._getConfig(e),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return on}static get DefaultType(){return sn}static get NAME(){return"focustrap"}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),gt.off(document,en),gt.on(document,tn,(e=>this._handleFocusin(e))),gt.on(document,rn,(e=>this._handleKeydown(e))),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,gt.off(document,en))}_handleFocusin(e){const{trapElement:t}=this._config;if(e.target===document||e.target===t||t.contains(e.target))return;const r=Et.focusableChildren(t);0===r.length?t.focus():this._lastTabNavDirection===nn?r[r.length-1].focus():r[0].focus()}_handleKeydown(e){"Tab"===e.key&&(this._lastTabNavDirection=e.shiftKey?nn:"forward")}}const ln=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",cn=".sticky-top",un="padding-right",pn="margin-right";class dn{constructor(){this._element=document.body}getWidth(){const e=document.documentElement.clientWidth;return Math.abs(window.innerWidth-e)}hide(){const e=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,un,(t=>t+e)),this._setElementAttributes(ln,un,(t=>t+e)),this._setElementAttributes(cn,pn,(t=>t-e))}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,un),this._resetElementAttributes(ln,un),this._resetElementAttributes(cn,pn)}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(e,t,r){const n=this.getWidth();this._applyManipulationCallback(e,(e=>{if(e!==this._element&&window.innerWidth>e.clientWidth+n)return;this._saveInitialAttribute(e,t);const i=window.getComputedStyle(e).getPropertyValue(t);e.style.setProperty(t,`${r(Number.parseFloat(i))}px`)}))}_saveInitialAttribute(e,t){const r=e.style.getPropertyValue(t);r&&yt.setDataAttribute(e,t,r)}_resetElementAttributes(e,t){this._applyManipulationCallback(e,(e=>{const r=yt.getDataAttribute(e,t);null!==r?(yt.removeDataAttribute(e,t),e.style.setProperty(t,r)):e.style.removeProperty(t)}))}_applyManipulationCallback(e,t){if(He(e))t(e);else for(const r of Et.find(e,this._element))t(r)}}const fn=".bs.modal",hn=`hide${fn}`,gn=`hidePrevented${fn}`,mn=`hidden${fn}`,vn=`show${fn}`,bn=`shown${fn}`,yn=`resize${fn}`,wn=`click.dismiss${fn}`,_n=`mousedown.dismiss${fn}`,xn=`keydown.dismiss${fn}`,En=`click${fn}.data-api`,An="modal-open",Dn="show",Tn="modal-static",qn={backdrop:!0,focus:!0,keyboard:!0},Cn={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"};class kn extends _t{constructor(e,t){super(e,t),this._dialog=Et.findOne(".modal-dialog",this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new dn,this._addEventListeners()}static get Default(){return qn}static get DefaultType(){return Cn}static get NAME(){return"modal"}toggle(e){return this._isShown?this.hide():this.show(e)}show(e){if(this._isShown||this._isTransitioning)return;gt.trigger(this._element,vn,{relatedTarget:e}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add(An),this._adjustDialog(),this._backdrop.show((()=>this._showElement(e))))}hide(){if(!this._isShown||this._isTransitioning)return;gt.trigger(this._element,hn).defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove(Dn),this._queueCallback((()=>this._hideModal()),this._element,this._isAnimated()))}dispose(){gt.off(window,fn),gt.off(this._dialog,fn),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new Zr({isVisible:Boolean(this._config.backdrop),isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new an({trapElement:this._element})}_showElement(e){document.body.contains(this._element)||document.body.append(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.scrollTop=0;const t=Et.findOne(".modal-body",this._dialog);t&&(t.scrollTop=0),Ge(this._element),this._element.classList.add(Dn);this._queueCallback((()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,gt.trigger(this._element,bn,{relatedTarget:e})}),this._dialog,this._isAnimated())}_addEventListeners(){gt.on(this._element,xn,(e=>{"Escape"===e.key&&(this._config.keyboard?this.hide():this._triggerBackdropTransition())})),gt.on(window,yn,(()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()})),gt.on(this._element,_n,(e=>{gt.one(this._element,wn,(t=>{this._element===e.target&&this._element===t.target&&("static"!==this._config.backdrop?this._config.backdrop&&this.hide():this._triggerBackdropTransition())}))}))}_hideModal(){this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._backdrop.hide((()=>{document.body.classList.remove(An),this._resetAdjustments(),this._scrollBar.reset(),gt.trigger(this._element,mn)}))}_isAnimated(){return this._element.classList.contains("fade")}_triggerBackdropTransition(){if(gt.trigger(this._element,gn).defaultPrevented)return;const e=this._element.scrollHeight>document.documentElement.clientHeight,t=this._element.style.overflowY;"hidden"===t||this._element.classList.contains(Tn)||(e||(this._element.style.overflowY="hidden"),this._element.classList.add(Tn),this._queueCallback((()=>{this._element.classList.remove(Tn),this._queueCallback((()=>{this._element.style.overflowY=t}),this._dialog)}),this._dialog),this._element.focus())}_adjustDialog(){const e=this._element.scrollHeight>document.documentElement.clientHeight,t=this._scrollBar.getWidth(),r=t>0;if(r&&!e){const e=Xe()?"paddingLeft":"paddingRight";this._element.style[e]=`${t}px`}if(!r&&e){const e=Xe()?"paddingRight":"paddingLeft";this._element.style[e]=`${t}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(e,t){return this.each((function(){const r=kn.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===r[e])throw new TypeError(`No method named "${e}"`);r[e](t)}}))}}gt.on(document,En,'[data-bs-toggle="modal"]',(function(e){const t=Et.getElementFromSelector(this);["A","AREA"].includes(this.tagName)&&e.preventDefault(),gt.one(t,vn,(e=>{e.defaultPrevented||gt.one(t,mn,(()=>{Ue(this)&&this.focus()}))}));const r=Et.findOne(".modal.show");r&&kn.getInstance(r).hide();kn.getOrCreateInstance(t).toggle(this)})),At(kn),Ke(kn);const Sn=".bs.offcanvas",Ln=".data-api",Nn=`load${Sn}${Ln}`,On="show",jn="showing",Rn="hiding",Bn=".offcanvas.show",Fn=`show${Sn}`,In=`shown${Sn}`,Pn=`hide${Sn}`,Hn=`hidePrevented${Sn}`,Mn=`hidden${Sn}`,Un=`resize${Sn}`,Vn=`click${Sn}${Ln}`,$n=`keydown.dismiss${Sn}`,zn={backdrop:!0,keyboard:!0,scroll:!1},Gn={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"};class Wn extends _t{constructor(e,t){super(e,t),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return zn}static get DefaultType(){return Gn}static get NAME(){return"offcanvas"}toggle(e){return this._isShown?this.hide():this.show(e)}show(e){if(this._isShown)return;if(gt.trigger(this._element,Fn,{relatedTarget:e}).defaultPrevented)return;this._isShown=!0,this._backdrop.show(),this._config.scroll||(new dn).hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(jn);this._queueCallback((()=>{this._config.scroll&&!this._config.backdrop||this._focustrap.activate(),this._element.classList.add(On),this._element.classList.remove(jn),gt.trigger(this._element,In,{relatedTarget:e})}),this._element,!0)}hide(){if(!this._isShown)return;if(gt.trigger(this._element,Pn).defaultPrevented)return;this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add(Rn),this._backdrop.hide();this._queueCallback((()=>{this._element.classList.remove(On,Rn),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||(new dn).reset(),gt.trigger(this._element,Mn)}),this._element,!0)}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){const e=Boolean(this._config.backdrop);return new Zr({className:"offcanvas-backdrop",isVisible:e,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:e?()=>{"static"!==this._config.backdrop?this.hide():gt.trigger(this._element,Hn)}:null})}_initializeFocusTrap(){return new an({trapElement:this._element})}_addEventListeners(){gt.on(this._element,$n,(e=>{"Escape"===e.key&&(this._config.keyboard?this.hide():gt.trigger(this._element,Hn))}))}static jQueryInterface(e){return this.each((function(){const t=Wn.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}gt.on(document,Vn,'[data-bs-toggle="offcanvas"]',(function(e){const t=Et.getElementFromSelector(this);if(["A","AREA"].includes(this.tagName)&&e.preventDefault(),Ve(this))return;gt.one(t,Mn,(()=>{Ue(this)&&this.focus()}));const r=Et.findOne(Bn);r&&r!==t&&Wn.getInstance(r).hide();Wn.getOrCreateInstance(t).toggle(this)})),gt.on(window,Nn,(()=>{for(const e of Et.find(Bn))Wn.getOrCreateInstance(e).show()})),gt.on(window,Un,(()=>{for(const e of Et.find("[aria-modal][class*=show][class*=offcanvas-]"))"fixed"!==getComputedStyle(e).position&&Wn.getOrCreateInstance(e).hide()})),At(Wn),Ke(Wn);const Yn={"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},Xn=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),Kn=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i,Jn=(e,t)=>{const r=e.nodeName.toLowerCase();return t.includes(r)?!Xn.has(r)||Boolean(Kn.test(e.nodeValue)):t.filter((e=>e instanceof RegExp)).some((e=>e.test(r)))};const Qn={allowList:Yn,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"
"},Zn={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},ei={entry:"(string|element|function|null)",selector:"(string|element)"};class ti extends wt{constructor(e){super(),this._config=this._getConfig(e)}static get Default(){return Qn}static get DefaultType(){return Zn}static get NAME(){return"TemplateFactory"}getContent(){return Object.values(this._config.content).map((e=>this._resolvePossibleFunction(e))).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(e){return this._checkContent(e),this._config.content={...this._config.content,...e},this}toHtml(){const e=document.createElement("div");e.innerHTML=this._maybeSanitize(this._config.template);for(const[t,r]of Object.entries(this._config.content))this._setContent(e,r,t);const t=e.children[0],r=this._resolvePossibleFunction(this._config.extraClass);return r&&t.classList.add(...r.split(" ")),t}_typeCheckConfig(e){super._typeCheckConfig(e),this._checkContent(e.content)}_checkContent(e){for(const[t,r]of Object.entries(e))super._typeCheckConfig({selector:t,entry:r},ei)}_setContent(e,t,r){const n=Et.findOne(r,e);n&&((t=this._resolvePossibleFunction(t))?He(t)?this._putElementInTemplate(Me(t),n):this._config.html?n.innerHTML=this._maybeSanitize(t):n.textContent=t:n.remove())}_maybeSanitize(e){return this._config.sanitize?function(e,t,r){if(!e.length)return e;if(r&&"function"==typeof r)return r(e);const n=(new window.DOMParser).parseFromString(e,"text/html"),i=[].concat(...n.body.querySelectorAll("*"));for(const e of i){const r=e.nodeName.toLowerCase();if(!Object.keys(t).includes(r)){e.remove();continue}const n=[].concat(...e.attributes),i=[].concat(t["*"]||[],t[r]||[]);for(const t of n)Jn(t,i)||e.removeAttribute(t.nodeName)}return n.body.innerHTML}(e,this._config.allowList,this._config.sanitizeFn):e}_resolvePossibleFunction(e){return Je(e,[this])}_putElementInTemplate(e,t){if(this._config.html)return t.innerHTML="",void t.append(e);t.textContent=e.textContent}}const ri=new Set(["sanitize","allowList","sanitizeFn"]),ni="fade",ii="show",oi=".modal",si="hide.bs.modal",ai="hover",li="focus",ci={AUTO:"auto",TOP:"top",RIGHT:Xe()?"left":"right",BOTTOM:"bottom",LEFT:Xe()?"right":"left"},ui={allowList:Yn,animation:!0,boundary:"clippingParents",container:!1,customClass:"",delay:0,fallbackPlacements:["top","right","bottom","left"],html:!1,offset:[0,6],placement:"top",popperConfig:null,sanitize:!0,sanitizeFn:null,selector:!1,template:'',title:"",trigger:"hover focus"},pi={allowList:"object",animation:"boolean",boundary:"(string|element)",container:"(string|element|boolean)",customClass:"(string|function)",delay:"(number|object)",fallbackPlacements:"array",html:"boolean",offset:"(array|string|function)",placement:"(string|function)",popperConfig:"(null|object|function)",sanitize:"boolean",sanitizeFn:"(null|function)",selector:"(string|boolean)",template:"string",title:"(string|element|function)",trigger:"string"};class di extends _t{constructor(e,t){if(void 0===n)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(e,t),this._isEnabled=!0,this._timeout=0,this._isHovered=null,this._activeTrigger={},this._popper=null,this._templateFactory=null,this._newContent=null,this.tip=null,this._setListeners(),this._config.selector||this._fixTitle()}static get Default(){return ui}static get DefaultType(){return pi}static get NAME(){return"tooltip"}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(){this._isEnabled&&(this._activeTrigger.click=!this._activeTrigger.click,this._isShown()?this._leave():this._enter())}dispose(){clearTimeout(this._timeout),gt.off(this._element.closest(oi),si,this._hideModalHandler),this._element.getAttribute("data-bs-original-title")&&this._element.setAttribute("title",this._element.getAttribute("data-bs-original-title")),this._disposePopper(),super.dispose()}show(){if("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(!this._isWithContent()||!this._isEnabled)return;const e=gt.trigger(this._element,this.constructor.eventName("show")),t=($e(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(e.defaultPrevented||!t)return;this._disposePopper();const r=this._getTipElement();this._element.setAttribute("aria-describedby",r.getAttribute("id"));const{container:n}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(n.append(r),gt.trigger(this._element,this.constructor.eventName("inserted"))),this._popper=this._createPopper(r),r.classList.add(ii),"ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))gt.on(e,"mouseover",ze);this._queueCallback((()=>{gt.trigger(this._element,this.constructor.eventName("shown")),!1===this._isHovered&&this._leave(),this._isHovered=!1}),this.tip,this._isAnimated())}hide(){if(!this._isShown())return;if(gt.trigger(this._element,this.constructor.eventName("hide")).defaultPrevented)return;if(this._getTipElement().classList.remove(ii),"ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))gt.off(e,"mouseover",ze);this._activeTrigger.click=!1,this._activeTrigger[li]=!1,this._activeTrigger[ai]=!1,this._isHovered=null;this._queueCallback((()=>{this._isWithActiveTrigger()||(this._isHovered||this._disposePopper(),this._element.removeAttribute("aria-describedby"),gt.trigger(this._element,this.constructor.eventName("hidden")))}),this.tip,this._isAnimated())}update(){this._popper&&this._popper.update()}_isWithContent(){return Boolean(this._getTitle())}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._newContent||this._getContentForTemplate())),this.tip}_createTipElement(e){const t=this._getTemplateFactory(e).toHtml();if(!t)return null;t.classList.remove(ni,ii),t.classList.add(`bs-${this.constructor.NAME}-auto`);const r=(e=>{do{e+=Math.floor(1e6*Math.random())}while(document.getElementById(e));return e})(this.constructor.NAME).toString();return t.setAttribute("id",r),this._isAnimated()&&t.classList.add(ni),t}setContent(e){this._newContent=e,this._isShown()&&(this._disposePopper(),this.show())}_getTemplateFactory(e){return this._templateFactory?this._templateFactory.changeContent(e):this._templateFactory=new ti({...this._config,content:e,extraClass:this._resolvePossibleFunction(this._config.customClass)}),this._templateFactory}_getContentForTemplate(){return{".tooltip-inner":this._getTitle()}}_getTitle(){return this._resolvePossibleFunction(this._config.title)||this._element.getAttribute("data-bs-original-title")}_initializeOnDelegatedTarget(e){return this.constructor.getOrCreateInstance(e.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains(ni)}_isShown(){return this.tip&&this.tip.classList.contains(ii)}_createPopper(e){const t=Je(this._config.placement,[this,e,this._element]),r=ci[t.toUpperCase()];return Oe(this._element,e,this._getPopperConfig(r))}_getOffset(){const{offset:e}=this._config;return"string"==typeof e?e.split(",").map((e=>Number.parseInt(e,10))):"function"==typeof e?t=>e(t,this._element):e}_resolvePossibleFunction(e){return Je(e,[this._element])}_getPopperConfig(e){const t={placement:e,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"preSetPlacement",enabled:!0,phase:"beforeMain",fn:e=>{this._getTipElement().setAttribute("data-popper-placement",e.state.placement)}}]};return{...t,...Je(this._config.popperConfig,[t])}}_setListeners(){const e=this._config.trigger.split(" ");for(const t of e)if("click"===t)gt.on(this._element,this.constructor.eventName("click"),this._config.selector,(e=>{this._initializeOnDelegatedTarget(e).toggle()}));else if("manual"!==t){const e=t===ai?this.constructor.eventName("mouseenter"):this.constructor.eventName("focusin"),r=t===ai?this.constructor.eventName("mouseleave"):this.constructor.eventName("focusout");gt.on(this._element,e,this._config.selector,(e=>{const t=this._initializeOnDelegatedTarget(e);t._activeTrigger["focusin"===e.type?li:ai]=!0,t._enter()})),gt.on(this._element,r,this._config.selector,(e=>{const t=this._initializeOnDelegatedTarget(e);t._activeTrigger["focusout"===e.type?li:ai]=t._element.contains(e.relatedTarget),t._leave()}))}this._hideModalHandler=()=>{this._element&&this.hide()},gt.on(this._element.closest(oi),si,this._hideModalHandler)}_fixTitle(){const e=this._element.getAttribute("title");e&&(this._element.getAttribute("aria-label")||this._element.textContent.trim()||this._element.setAttribute("aria-label",e),this._element.setAttribute("data-bs-original-title",e),this._element.removeAttribute("title"))}_enter(){this._isShown()||this._isHovered?this._isHovered=!0:(this._isHovered=!0,this._setTimeout((()=>{this._isHovered&&this.show()}),this._config.delay.show))}_leave(){this._isWithActiveTrigger()||(this._isHovered=!1,this._setTimeout((()=>{this._isHovered||this.hide()}),this._config.delay.hide))}_setTimeout(e,t){clearTimeout(this._timeout),this._timeout=setTimeout(e,t)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(e){const t=yt.getDataAttributes(this._element);for(const e of Object.keys(t))ri.has(e)&&delete t[e];return e={...t,..."object"==typeof e&&e?e:{}},e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}_configAfterMerge(e){return e.container=!1===e.container?document.body:Me(e.container),"number"==typeof e.delay&&(e.delay={show:e.delay,hide:e.delay}),"number"==typeof e.title&&(e.title=e.title.toString()),"number"==typeof e.content&&(e.content=e.content.toString()),e}_getDelegateConfig(){const e={};for(const[t,r]of Object.entries(this._config))this.constructor.Default[t]!==r&&(e[t]=r);return e.selector=!1,e.trigger="manual",e}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null),this.tip&&(this.tip.remove(),this.tip=null)}static jQueryInterface(e){return this.each((function(){const t=di.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}Ke(di);const fi={...di.Default,content:"",offset:[0,8],placement:"right",template:'',trigger:"click"},hi={...di.DefaultType,content:"(null|string|element|function)"};class gi extends di{static get Default(){return fi}static get DefaultType(){return hi}static get NAME(){return"popover"}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{".popover-header":this._getTitle(),".popover-body":this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(e){return this.each((function(){const t=gi.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}Ke(gi);const mi=".bs.scrollspy",vi=`activate${mi}`,bi=`click${mi}`,yi=`load${mi}.data-api`,wi="active",_i="[href]",xi=".nav-link",Ei=`${xi}, .nav-item > ${xi}, .list-group-item`,Ai={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null,threshold:[.1,.5,1]},Di={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element",threshold:"array"};class Ti extends _t{constructor(e,t){super(e,t),this._targetLinks=new Map,this._observableSections=new Map,this._rootElement="visible"===getComputedStyle(this._element).overflowY?null:this._element,this._activeTarget=null,this._observer=null,this._previousScrollData={visibleEntryTop:0,parentScrollTop:0},this.refresh()}static get Default(){return Ai}static get DefaultType(){return Di}static get NAME(){return"scrollspy"}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(const e of this._observableSections.values())this._observer.observe(e)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(e){return e.target=Me(e.target)||document.body,e.rootMargin=e.offset?`${e.offset}px 0px -30%`:e.rootMargin,"string"==typeof e.threshold&&(e.threshold=e.threshold.split(",").map((e=>Number.parseFloat(e)))),e}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(gt.off(this._config.target,bi),gt.on(this._config.target,bi,_i,(e=>{const t=this._observableSections.get(e.target.hash);if(t){e.preventDefault();const r=this._rootElement||window,n=t.offsetTop-this._element.offsetTop;if(r.scrollTo)return void r.scrollTo({top:n,behavior:"smooth"});r.scrollTop=n}})))}_getNewObserver(){const e={root:this._rootElement,threshold:this._config.threshold,rootMargin:this._config.rootMargin};return new IntersectionObserver((e=>this._observerCallback(e)),e)}_observerCallback(e){const t=e=>this._targetLinks.get(`#${e.target.id}`),r=e=>{this._previousScrollData.visibleEntryTop=e.target.offsetTop,this._process(t(e))},n=(this._rootElement||document.documentElement).scrollTop,i=n>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=n;for(const o of e){if(!o.isIntersecting){this._activeTarget=null,this._clearActiveClass(t(o));continue}const e=o.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(i&&e){if(r(o),!n)return}else i||e||r(o)}}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;const e=Et.find(_i,this._config.target);for(const t of e){if(!t.hash||Ve(t))continue;const e=Et.findOne(decodeURI(t.hash),this._element);Ue(e)&&(this._targetLinks.set(decodeURI(t.hash),t),this._observableSections.set(t.hash,e))}}_process(e){this._activeTarget!==e&&(this._clearActiveClass(this._config.target),this._activeTarget=e,e.classList.add(wi),this._activateParents(e),gt.trigger(this._element,vi,{relatedTarget:e}))}_activateParents(e){if(e.classList.contains("dropdown-item"))Et.findOne(".dropdown-toggle",e.closest(".dropdown")).classList.add(wi);else for(const t of Et.parents(e,".nav, .list-group"))for(const e of Et.prev(t,Ei))e.classList.add(wi)}_clearActiveClass(e){e.classList.remove(wi);const t=Et.find(`${_i}.${wi}`,e);for(const e of t)e.classList.remove(wi)}static jQueryInterface(e){return this.each((function(){const t=Ti.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}))}}gt.on(window,yi,(()=>{for(const e of Et.find('[data-bs-spy="scroll"]'))Ti.getOrCreateInstance(e)})),Ke(Ti);const qi=".bs.tab",Ci=`hide${qi}`,ki=`hidden${qi}`,Si=`show${qi}`,Li=`shown${qi}`,Ni=`click${qi}`,Oi=`keydown${qi}`,ji=`load${qi}`,Ri="ArrowLeft",Bi="ArrowRight",Fi="ArrowUp",Ii="ArrowDown",Pi="Home",Hi="End",Mi="active",Ui="fade",Vi="show",$i=".dropdown-toggle",zi=`:not(${$i})`,Gi='[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',Wi=`${`.nav-link${zi}, .list-group-item${zi}, [role="tab"]${zi}`}, ${Gi}`,Yi=`.${Mi}[data-bs-toggle="tab"], .${Mi}[data-bs-toggle="pill"], .${Mi}[data-bs-toggle="list"]`;class Xi extends _t{constructor(e){super(e),this._parent=this._element.closest('.list-group, .nav, [role="tablist"]'),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),gt.on(this._element,Oi,(e=>this._keydown(e))))}static get NAME(){return"tab"}show(){const e=this._element;if(this._elemIsActive(e))return;const t=this._getActiveElem(),r=t?gt.trigger(t,Ci,{relatedTarget:e}):null;gt.trigger(e,Si,{relatedTarget:t}).defaultPrevented||r&&r.defaultPrevented||(this._deactivate(t,e),this._activate(e,t))}_activate(e,t){if(!e)return;e.classList.add(Mi),this._activate(Et.getElementFromSelector(e));this._queueCallback((()=>{"tab"===e.getAttribute("role")?(e.removeAttribute("tabindex"),e.setAttribute("aria-selected",!0),this._toggleDropDown(e,!0),gt.trigger(e,Li,{relatedTarget:t})):e.classList.add(Vi)}),e,e.classList.contains(Ui))}_deactivate(e,t){if(!e)return;e.classList.remove(Mi),e.blur(),this._deactivate(Et.getElementFromSelector(e));this._queueCallback((()=>{"tab"===e.getAttribute("role")?(e.setAttribute("aria-selected",!1),e.setAttribute("tabindex","-1"),this._toggleDropDown(e,!1),gt.trigger(e,ki,{relatedTarget:t})):e.classList.remove(Vi)}),e,e.classList.contains(Ui))}_keydown(e){if(![Ri,Bi,Fi,Ii,Pi,Hi].includes(e.key))return;e.stopPropagation(),e.preventDefault();const t=this._getChildren().filter((e=>!Ve(e)));let r;if([Pi,Hi].includes(e.key))r=t[e.key===Pi?0:t.length-1];else{const n=[Bi,Ii].includes(e.key);r=Ze(t,e.target,n,!0)}r&&(r.focus({preventScroll:!0}),Xi.getOrCreateInstance(r).show())}_getChildren(){return Et.find(Wi,this._parent)}_getActiveElem(){return this._getChildren().find((e=>this._elemIsActive(e)))||null}_setInitialAttributes(e,t){this._setAttributeIfNotExists(e,"role","tablist");for(const e of t)this._setInitialAttributesOnChild(e)}_setInitialAttributesOnChild(e){e=this._getInnerElement(e);const t=this._elemIsActive(e),r=this._getOuterElement(e);e.setAttribute("aria-selected",t),r!==e&&this._setAttributeIfNotExists(r,"role","presentation"),t||e.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(e,"role","tab"),this._setInitialAttributesOnTargetPanel(e)}_setInitialAttributesOnTargetPanel(e){const t=Et.getElementFromSelector(e);t&&(this._setAttributeIfNotExists(t,"role","tabpanel"),e.id&&this._setAttributeIfNotExists(t,"aria-labelledby",`${e.id}`))}_toggleDropDown(e,t){const r=this._getOuterElement(e);if(!r.classList.contains("dropdown"))return;const n=(e,n)=>{const i=Et.findOne(e,r);i&&i.classList.toggle(n,t)};n($i,Mi),n(".dropdown-menu",Vi),r.setAttribute("aria-expanded",t)}_setAttributeIfNotExists(e,t,r){e.hasAttribute(t)||e.setAttribute(t,r)}_elemIsActive(e){return e.classList.contains(Mi)}_getInnerElement(e){return e.matches(Wi)?e:Et.findOne(Wi,e)}_getOuterElement(e){return e.closest(".nav-item, .list-group-item")||e}static jQueryInterface(e){return this.each((function(){const t=Xi.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}))}}gt.on(document,Ni,Gi,(function(e){["A","AREA"].includes(this.tagName)&&e.preventDefault(),Ve(this)||Xi.getOrCreateInstance(this).show()})),gt.on(window,ji,(()=>{for(const e of Et.find(Yi))Xi.getOrCreateInstance(e)})),Ke(Xi);const Ki=".bs.toast",Ji=`mouseover${Ki}`,Qi=`mouseout${Ki}`,Zi=`focusin${Ki}`,eo=`focusout${Ki}`,to=`hide${Ki}`,ro=`hidden${Ki}`,no=`show${Ki}`,io=`shown${Ki}`,oo="hide",so="show",ao="showing",lo={animation:"boolean",autohide:"boolean",delay:"number"},co={animation:!0,autohide:!0,delay:5e3};class uo extends _t{constructor(e,t){super(e,t),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return co}static get DefaultType(){return lo}static get NAME(){return"toast"}show(){if(gt.trigger(this._element,no).defaultPrevented)return;this._clearTimeout(),this._config.animation&&this._element.classList.add("fade");this._element.classList.remove(oo),Ge(this._element),this._element.classList.add(so,ao),this._queueCallback((()=>{this._element.classList.remove(ao),gt.trigger(this._element,io),this._maybeScheduleHide()}),this._element,this._config.animation)}hide(){if(!this.isShown())return;if(gt.trigger(this._element,to).defaultPrevented)return;this._element.classList.add(ao),this._queueCallback((()=>{this._element.classList.add(oo),this._element.classList.remove(ao,so),gt.trigger(this._element,ro)}),this._element,this._config.animation)}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(so),super.dispose()}isShown(){return this._element.classList.contains(so)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout((()=>{this.hide()}),this._config.delay)))}_onInteraction(e,t){switch(e.type){case"mouseover":case"mouseout":this._hasMouseInteraction=t;break;case"focusin":case"focusout":this._hasKeyboardInteraction=t}if(t)return void this._clearTimeout();const r=e.relatedTarget;this._element===r||this._element.contains(r)||this._maybeScheduleHide()}_setListeners(){gt.on(this._element,Ji,(e=>this._onInteraction(e,!0))),gt.on(this._element,Qi,(e=>this._onInteraction(e,!1))),gt.on(this._element,Zi,(e=>this._onInteraction(e,!0))),gt.on(this._element,eo,(e=>this._onInteraction(e,!1)))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(e){return this.each((function(){const t=uo.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}At(uo),Ke(uo)},702:function(e,t,r){e.exports=function(){"use strict";function e(e){var t=typeof e;return null!==e&&("object"===t||"function"===t)}function t(e){return"function"==typeof e}var n=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},i=0,o=void 0,s=void 0,a=function(e,t){w[i]=e,w[i+1]=t,2===(i+=2)&&(s?s(_):E())};function l(e){s=e}function c(e){a=e}var u="undefined"!=typeof window?window:void 0,p=u||{},d=p.MutationObserver||p.WebKitMutationObserver,f="undefined"==typeof self&&"undefined"!=typeof process&&"[object process]"==={}.toString.call(process),h="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function g(){return function(){return process.nextTick(_)}}function m(){return void 0!==o?function(){o(_)}:y()}function v(){var e=0,t=new d(_),r=document.createTextNode("");return t.observe(r,{characterData:!0}),function(){r.data=e=++e%2}}function b(){var e=new MessageChannel;return e.port1.onmessage=_,function(){return e.port2.postMessage(0)}}function y(){var e=setTimeout;return function(){return e(_,1)}}var w=new Array(1e3);function _(){for(var e=0;e\u20D2|\u205F\u200A|\u219D\u0338|\u2202\u0338|\u2220\u20D2|\u2229\uFE00|\u222A\uFE00|\u223C\u20D2|\u223D\u0331|\u223E\u0333|\u2242\u0338|\u224B\u0338|\u224D\u20D2|\u224E\u0338|\u224F\u0338|\u2250\u0338|\u2261\u20E5|\u2264\u20D2|\u2265\u20D2|\u2266\u0338|\u2267\u0338|\u2268\uFE00|\u2269\uFE00|\u226A\u0338|\u226A\u20D2|\u226B\u0338|\u226B\u20D2|\u227F\u0338|\u2282\u20D2|\u2283\u20D2|\u228A\uFE00|\u228B\uFE00|\u228F\u0338|\u2290\u0338|\u2293\uFE00|\u2294\uFE00|\u22B4\u20D2|\u22B5\u20D2|\u22D8\u0338|\u22D9\u0338|\u22DA\uFE00|\u22DB\uFE00|\u22F5\u0338|\u22F9\u0338|\u2933\u0338|\u29CF\u0338|\u29D0\u0338|\u2A6D\u0338|\u2A70\u0338|\u2A7D\u0338|\u2A7E\u0338|\u2AA1\u0338|\u2AA2\u0338|\u2AAC\uFE00|\u2AAD\uFE00|\u2AAF\u0338|\u2AB0\u0338|\u2AC5\u0338|\u2AC6\u0338|\u2ACB\uFE00|\u2ACC\uFE00|\u2AFD\u20E5|[\xA0-\u0113\u0116-\u0122\u0124-\u012B\u012E-\u014D\u0150-\u017E\u0192\u01B5\u01F5\u0237\u02C6\u02C7\u02D8-\u02DD\u0311\u0391-\u03A1\u03A3-\u03A9\u03B1-\u03C9\u03D1\u03D2\u03D5\u03D6\u03DC\u03DD\u03F0\u03F1\u03F5\u03F6\u0401-\u040C\u040E-\u044F\u0451-\u045C\u045E\u045F\u2002-\u2005\u2007-\u2010\u2013-\u2016\u2018-\u201A\u201C-\u201E\u2020-\u2022\u2025\u2026\u2030-\u2035\u2039\u203A\u203E\u2041\u2043\u2044\u204F\u2057\u205F-\u2063\u20AC\u20DB\u20DC\u2102\u2105\u210A-\u2113\u2115-\u211E\u2122\u2124\u2127-\u2129\u212C\u212D\u212F-\u2131\u2133-\u2138\u2145-\u2148\u2153-\u215E\u2190-\u219B\u219D-\u21A7\u21A9-\u21AE\u21B0-\u21B3\u21B5-\u21B7\u21BA-\u21DB\u21DD\u21E4\u21E5\u21F5\u21FD-\u2205\u2207-\u2209\u220B\u220C\u220F-\u2214\u2216-\u2218\u221A\u221D-\u2238\u223A-\u2257\u2259\u225A\u225C\u225F-\u2262\u2264-\u228B\u228D-\u229B\u229D-\u22A5\u22A7-\u22B0\u22B2-\u22BB\u22BD-\u22DB\u22DE-\u22E3\u22E6-\u22F7\u22F9-\u22FE\u2305\u2306\u2308-\u2310\u2312\u2313\u2315\u2316\u231C-\u231F\u2322\u2323\u232D\u232E\u2336\u233D\u233F\u237C\u23B0\u23B1\u23B4-\u23B6\u23DC-\u23DF\u23E2\u23E7\u2423\u24C8\u2500\u2502\u250C\u2510\u2514\u2518\u251C\u2524\u252C\u2534\u253C\u2550-\u256C\u2580\u2584\u2588\u2591-\u2593\u25A1\u25AA\u25AB\u25AD\u25AE\u25B1\u25B3-\u25B5\u25B8\u25B9\u25BD-\u25BF\u25C2\u25C3\u25CA\u25CB\u25EC\u25EF\u25F8-\u25FC\u2605\u2606\u260E\u2640\u2642\u2660\u2663\u2665\u2666\u266A\u266D-\u266F\u2713\u2717\u2720\u2736\u2758\u2772\u2773\u27C8\u27C9\u27E6-\u27ED\u27F5-\u27FA\u27FC\u27FF\u2902-\u2905\u290C-\u2913\u2916\u2919-\u2920\u2923-\u292A\u2933\u2935-\u2939\u293C\u293D\u2945\u2948-\u294B\u294E-\u2976\u2978\u2979\u297B-\u297F\u2985\u2986\u298B-\u2996\u299A\u299C\u299D\u29A4-\u29B7\u29B9\u29BB\u29BC\u29BE-\u29C5\u29C9\u29CD-\u29D0\u29DC-\u29DE\u29E3-\u29E5\u29EB\u29F4\u29F6\u2A00-\u2A02\u2A04\u2A06\u2A0C\u2A0D\u2A10-\u2A17\u2A22-\u2A27\u2A29\u2A2A\u2A2D-\u2A31\u2A33-\u2A3C\u2A3F\u2A40\u2A42-\u2A4D\u2A50\u2A53-\u2A58\u2A5A-\u2A5D\u2A5F\u2A66\u2A6A\u2A6D-\u2A75\u2A77-\u2A9A\u2A9D-\u2AA2\u2AA4-\u2AB0\u2AB3-\u2AC8\u2ACB\u2ACC\u2ACF-\u2ADB\u2AE4\u2AE6-\u2AE9\u2AEB-\u2AF3\u2AFD\uFB00-\uFB04]|\uD835[\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDCCF\uDD04\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDD6B]/g,p={"­":"shy","‌":"zwnj","‍":"zwj","‎":"lrm","⁣":"ic","⁢":"it","⁡":"af","‏":"rlm","​":"ZeroWidthSpace","⁠":"NoBreak","̑":"DownBreve","⃛":"tdot","⃜":"DotDot","\t":"Tab","\n":"NewLine"," ":"puncsp"," ":"MediumSpace"," ":"thinsp"," ":"hairsp"," ":"emsp13"," ":"ensp"," ":"emsp14"," ":"emsp"," ":"numsp"," ":"nbsp","  ":"ThickSpace","‾":"oline",_:"lowbar","‐":"dash","–":"ndash","—":"mdash","―":"horbar",",":"comma",";":"semi","⁏":"bsemi",":":"colon","⩴":"Colone","!":"excl","¡":"iexcl","?":"quest","¿":"iquest",".":"period","‥":"nldr","…":"mldr","·":"middot","'":"apos","‘":"lsquo","’":"rsquo","‚":"sbquo","‹":"lsaquo","›":"rsaquo",'"':"quot","“":"ldquo","”":"rdquo","„":"bdquo","«":"laquo","»":"raquo","(":"lpar",")":"rpar","[":"lsqb","]":"rsqb","{":"lcub","}":"rcub","⌈":"lceil","⌉":"rceil","⌊":"lfloor","⌋":"rfloor","⦅":"lopar","⦆":"ropar","⦋":"lbrke","⦌":"rbrke","⦍":"lbrkslu","⦎":"rbrksld","⦏":"lbrksld","⦐":"rbrkslu","⦑":"langd","⦒":"rangd","⦓":"lparlt","⦔":"rpargt","⦕":"gtlPar","⦖":"ltrPar","⟦":"lobrk","⟧":"robrk","⟨":"lang","⟩":"rang","⟪":"Lang","⟫":"Rang","⟬":"loang","⟭":"roang","❲":"lbbrk","❳":"rbbrk","‖":"Vert","§":"sect","¶":"para","@":"commat","*":"ast","/":"sol",undefined:null,"&":"amp","#":"num","%":"percnt","‰":"permil","‱":"pertenk","†":"dagger","‡":"Dagger","•":"bull","⁃":"hybull","′":"prime","″":"Prime","‴":"tprime","⁗":"qprime","‵":"bprime","⁁":"caret","`":"grave","´":"acute","˜":"tilde","^":"Hat","¯":"macr","˘":"breve","˙":"dot","¨":"die","˚":"ring","˝":"dblac","¸":"cedil","˛":"ogon",ˆ:"circ",ˇ:"caron","°":"deg","©":"copy","®":"reg","℗":"copysr",℘:"wp","℞":"rx","℧":"mho","℩":"iiota","←":"larr","↚":"nlarr","→":"rarr","↛":"nrarr","↑":"uarr","↓":"darr","↔":"harr","↮":"nharr","↕":"varr","↖":"nwarr","↗":"nearr","↘":"searr","↙":"swarr","↝":"rarrw","↝̸":"nrarrw","↞":"Larr","↟":"Uarr","↠":"Rarr","↡":"Darr","↢":"larrtl","↣":"rarrtl","↤":"mapstoleft","↥":"mapstoup","↦":"map","↧":"mapstodown","↩":"larrhk","↪":"rarrhk","↫":"larrlp","↬":"rarrlp","↭":"harrw","↰":"lsh","↱":"rsh","↲":"ldsh","↳":"rdsh","↵":"crarr","↶":"cularr","↷":"curarr","↺":"olarr","↻":"orarr","↼":"lharu","↽":"lhard","↾":"uharr","↿":"uharl","⇀":"rharu","⇁":"rhard","⇂":"dharr","⇃":"dharl","⇄":"rlarr","⇅":"udarr","⇆":"lrarr","⇇":"llarr","⇈":"uuarr","⇉":"rrarr","⇊":"ddarr","⇋":"lrhar","⇌":"rlhar","⇐":"lArr","⇍":"nlArr","⇑":"uArr","⇒":"rArr","⇏":"nrArr","⇓":"dArr","⇔":"iff","⇎":"nhArr","⇕":"vArr","⇖":"nwArr","⇗":"neArr","⇘":"seArr","⇙":"swArr","⇚":"lAarr","⇛":"rAarr","⇝":"zigrarr","⇤":"larrb","⇥":"rarrb","⇵":"duarr","⇽":"loarr","⇾":"roarr","⇿":"hoarr","∀":"forall","∁":"comp","∂":"part","∂̸":"npart","∃":"exist","∄":"nexist","∅":"empty","∇":"Del","∈":"in","∉":"notin","∋":"ni","∌":"notni","϶":"bepsi","∏":"prod","∐":"coprod","∑":"sum","+":"plus","±":"pm","÷":"div","×":"times","<":"lt","≮":"nlt","<⃒":"nvlt","=":"equals","≠":"ne","=⃥":"bne","⩵":"Equal",">":"gt","≯":"ngt",">⃒":"nvgt","¬":"not","|":"vert","¦":"brvbar","−":"minus","∓":"mp","∔":"plusdo","⁄":"frasl","∖":"setmn","∗":"lowast","∘":"compfn","√":"Sqrt","∝":"prop","∞":"infin","∟":"angrt","∠":"ang","∠⃒":"nang","∡":"angmsd","∢":"angsph","∣":"mid","∤":"nmid","∥":"par","∦":"npar","∧":"and","∨":"or","∩":"cap","∩︀":"caps","∪":"cup","∪︀":"cups","∫":"int","∬":"Int","∭":"tint","⨌":"qint","∮":"oint","∯":"Conint","∰":"Cconint","∱":"cwint","∲":"cwconint","∳":"awconint","∴":"there4","∵":"becaus","∶":"ratio","∷":"Colon","∸":"minusd","∺":"mDDot","∻":"homtht","∼":"sim","≁":"nsim","∼⃒":"nvsim","∽":"bsim","∽̱":"race","∾":"ac","∾̳":"acE","∿":"acd","≀":"wr","≂":"esim","≂̸":"nesim","≃":"sime","≄":"nsime","≅":"cong","≇":"ncong","≆":"simne","≈":"ap","≉":"nap","≊":"ape","≋":"apid","≋̸":"napid","≌":"bcong","≍":"CupCap","≭":"NotCupCap","≍⃒":"nvap","≎":"bump","≎̸":"nbump","≏":"bumpe","≏̸":"nbumpe","≐":"doteq","≐̸":"nedot","≑":"eDot","≒":"efDot","≓":"erDot","≔":"colone","≕":"ecolon","≖":"ecir","≗":"cire","≙":"wedgeq","≚":"veeeq","≜":"trie","≟":"equest","≡":"equiv","≢":"nequiv","≡⃥":"bnequiv","≤":"le","≰":"nle","≤⃒":"nvle","≥":"ge","≱":"nge","≥⃒":"nvge","≦":"lE","≦̸":"nlE","≧":"gE","≧̸":"ngE","≨︀":"lvnE","≨":"lnE","≩":"gnE","≩︀":"gvnE","≪":"ll","≪̸":"nLtv","≪⃒":"nLt","≫":"gg","≫̸":"nGtv","≫⃒":"nGt","≬":"twixt","≲":"lsim","≴":"nlsim","≳":"gsim","≵":"ngsim","≶":"lg","≸":"ntlg","≷":"gl","≹":"ntgl","≺":"pr","⊀":"npr","≻":"sc","⊁":"nsc","≼":"prcue","⋠":"nprcue","≽":"sccue","⋡":"nsccue","≾":"prsim","≿":"scsim","≿̸":"NotSucceedsTilde","⊂":"sub","⊄":"nsub","⊂⃒":"vnsub","⊃":"sup","⊅":"nsup","⊃⃒":"vnsup","⊆":"sube","⊈":"nsube","⊇":"supe","⊉":"nsupe","⊊︀":"vsubne","⊊":"subne","⊋︀":"vsupne","⊋":"supne","⊍":"cupdot","⊎":"uplus","⊏":"sqsub","⊏̸":"NotSquareSubset","⊐":"sqsup","⊐̸":"NotSquareSuperset","⊑":"sqsube","⋢":"nsqsube","⊒":"sqsupe","⋣":"nsqsupe","⊓":"sqcap","⊓︀":"sqcaps","⊔":"sqcup","⊔︀":"sqcups","⊕":"oplus","⊖":"ominus","⊗":"otimes","⊘":"osol","⊙":"odot","⊚":"ocir","⊛":"oast","⊝":"odash","⊞":"plusb","⊟":"minusb","⊠":"timesb","⊡":"sdotb","⊢":"vdash","⊬":"nvdash","⊣":"dashv","⊤":"top","⊥":"bot","⊧":"models","⊨":"vDash","⊭":"nvDash","⊩":"Vdash","⊮":"nVdash","⊪":"Vvdash","⊫":"VDash","⊯":"nVDash","⊰":"prurel","⊲":"vltri","⋪":"nltri","⊳":"vrtri","⋫":"nrtri","⊴":"ltrie","⋬":"nltrie","⊴⃒":"nvltrie","⊵":"rtrie","⋭":"nrtrie","⊵⃒":"nvrtrie","⊶":"origof","⊷":"imof","⊸":"mumap","⊹":"hercon","⊺":"intcal","⊻":"veebar","⊽":"barvee","⊾":"angrtvb","⊿":"lrtri","⋀":"Wedge","⋁":"Vee","⋂":"xcap","⋃":"xcup","⋄":"diam","⋅":"sdot","⋆":"Star","⋇":"divonx","⋈":"bowtie","⋉":"ltimes","⋊":"rtimes","⋋":"lthree","⋌":"rthree","⋍":"bsime","⋎":"cuvee","⋏":"cuwed","⋐":"Sub","⋑":"Sup","⋒":"Cap","⋓":"Cup","⋔":"fork","⋕":"epar","⋖":"ltdot","⋗":"gtdot","⋘":"Ll","⋘̸":"nLl","⋙":"Gg","⋙̸":"nGg","⋚︀":"lesg","⋚":"leg","⋛":"gel","⋛︀":"gesl","⋞":"cuepr","⋟":"cuesc","⋦":"lnsim","⋧":"gnsim","⋨":"prnsim","⋩":"scnsim","⋮":"vellip","⋯":"ctdot","⋰":"utdot","⋱":"dtdot","⋲":"disin","⋳":"isinsv","⋴":"isins","⋵":"isindot","⋵̸":"notindot","⋶":"notinvc","⋷":"notinvb","⋹":"isinE","⋹̸":"notinE","⋺":"nisd","⋻":"xnis","⋼":"nis","⋽":"notnivc","⋾":"notnivb","⌅":"barwed","⌆":"Barwed","⌌":"drcrop","⌍":"dlcrop","⌎":"urcrop","⌏":"ulcrop","⌐":"bnot","⌒":"profline","⌓":"profsurf","⌕":"telrec","⌖":"target","⌜":"ulcorn","⌝":"urcorn","⌞":"dlcorn","⌟":"drcorn","⌢":"frown","⌣":"smile","⌭":"cylcty","⌮":"profalar","⌶":"topbot","⌽":"ovbar","⌿":"solbar","⍼":"angzarr","⎰":"lmoust","⎱":"rmoust","⎴":"tbrk","⎵":"bbrk","⎶":"bbrktbrk","⏜":"OverParenthesis","⏝":"UnderParenthesis","⏞":"OverBrace","⏟":"UnderBrace","⏢":"trpezium","⏧":"elinters","␣":"blank","─":"boxh","│":"boxv","┌":"boxdr","┐":"boxdl","└":"boxur","┘":"boxul","├":"boxvr","┤":"boxvl","┬":"boxhd","┴":"boxhu","┼":"boxvh","═":"boxH","║":"boxV","╒":"boxdR","╓":"boxDr","╔":"boxDR","╕":"boxdL","╖":"boxDl","╗":"boxDL","╘":"boxuR","╙":"boxUr","╚":"boxUR","╛":"boxuL","╜":"boxUl","╝":"boxUL","╞":"boxvR","╟":"boxVr","╠":"boxVR","╡":"boxvL","╢":"boxVl","╣":"boxVL","╤":"boxHd","╥":"boxhD","╦":"boxHD","╧":"boxHu","╨":"boxhU","╩":"boxHU","╪":"boxvH","╫":"boxVh","╬":"boxVH","▀":"uhblk","▄":"lhblk","█":"block","░":"blk14","▒":"blk12","▓":"blk34","□":"squ","▪":"squf","▫":"EmptyVerySmallSquare","▭":"rect","▮":"marker","▱":"fltns","△":"xutri","▴":"utrif","▵":"utri","▸":"rtrif","▹":"rtri","▽":"xdtri","▾":"dtrif","▿":"dtri","◂":"ltrif","◃":"ltri","◊":"loz","○":"cir","◬":"tridot","◯":"xcirc","◸":"ultri","◹":"urtri","◺":"lltri","◻":"EmptySmallSquare","◼":"FilledSmallSquare","★":"starf","☆":"star","☎":"phone","♀":"female","♂":"male","♠":"spades","♣":"clubs","♥":"hearts","♦":"diams","♪":"sung","✓":"check","✗":"cross","✠":"malt","✶":"sext","❘":"VerticalSeparator","⟈":"bsolhsub","⟉":"suphsol","⟵":"xlarr","⟶":"xrarr","⟷":"xharr","⟸":"xlArr","⟹":"xrArr","⟺":"xhArr","⟼":"xmap","⟿":"dzigrarr","⤂":"nvlArr","⤃":"nvrArr","⤄":"nvHarr","⤅":"Map","⤌":"lbarr","⤍":"rbarr","⤎":"lBarr","⤏":"rBarr","⤐":"RBarr","⤑":"DDotrahd","⤒":"UpArrowBar","⤓":"DownArrowBar","⤖":"Rarrtl","⤙":"latail","⤚":"ratail","⤛":"lAtail","⤜":"rAtail","⤝":"larrfs","⤞":"rarrfs","⤟":"larrbfs","⤠":"rarrbfs","⤣":"nwarhk","⤤":"nearhk","⤥":"searhk","⤦":"swarhk","⤧":"nwnear","⤨":"toea","⤩":"tosa","⤪":"swnwar","⤳":"rarrc","⤳̸":"nrarrc","⤵":"cudarrr","⤶":"ldca","⤷":"rdca","⤸":"cudarrl","⤹":"larrpl","⤼":"curarrm","⤽":"cularrp","⥅":"rarrpl","⥈":"harrcir","⥉":"Uarrocir","⥊":"lurdshar","⥋":"ldrushar","⥎":"LeftRightVector","⥏":"RightUpDownVector","⥐":"DownLeftRightVector","⥑":"LeftUpDownVector","⥒":"LeftVectorBar","⥓":"RightVectorBar","⥔":"RightUpVectorBar","⥕":"RightDownVectorBar","⥖":"DownLeftVectorBar","⥗":"DownRightVectorBar","⥘":"LeftUpVectorBar","⥙":"LeftDownVectorBar","⥚":"LeftTeeVector","⥛":"RightTeeVector","⥜":"RightUpTeeVector","⥝":"RightDownTeeVector","⥞":"DownLeftTeeVector","⥟":"DownRightTeeVector","⥠":"LeftUpTeeVector","⥡":"LeftDownTeeVector","⥢":"lHar","⥣":"uHar","⥤":"rHar","⥥":"dHar","⥦":"luruhar","⥧":"ldrdhar","⥨":"ruluhar","⥩":"rdldhar","⥪":"lharul","⥫":"llhard","⥬":"rharul","⥭":"lrhard","⥮":"udhar","⥯":"duhar","⥰":"RoundImplies","⥱":"erarr","⥲":"simrarr","⥳":"larrsim","⥴":"rarrsim","⥵":"rarrap","⥶":"ltlarr","⥸":"gtrarr","⥹":"subrarr","⥻":"suplarr","⥼":"lfisht","⥽":"rfisht","⥾":"ufisht","⥿":"dfisht","⦚":"vzigzag","⦜":"vangrt","⦝":"angrtvbd","⦤":"ange","⦥":"range","⦦":"dwangle","⦧":"uwangle","⦨":"angmsdaa","⦩":"angmsdab","⦪":"angmsdac","⦫":"angmsdad","⦬":"angmsdae","⦭":"angmsdaf","⦮":"angmsdag","⦯":"angmsdah","⦰":"bemptyv","⦱":"demptyv","⦲":"cemptyv","⦳":"raemptyv","⦴":"laemptyv","⦵":"ohbar","⦶":"omid","⦷":"opar","⦹":"operp","⦻":"olcross","⦼":"odsold","⦾":"olcir","⦿":"ofcir","⧀":"olt","⧁":"ogt","⧂":"cirscir","⧃":"cirE","⧄":"solb","⧅":"bsolb","⧉":"boxbox","⧍":"trisb","⧎":"rtriltri","⧏":"LeftTriangleBar","⧏̸":"NotLeftTriangleBar","⧐":"RightTriangleBar","⧐̸":"NotRightTriangleBar","⧜":"iinfin","⧝":"infintie","⧞":"nvinfin","⧣":"eparsl","⧤":"smeparsl","⧥":"eqvparsl","⧫":"lozf","⧴":"RuleDelayed","⧶":"dsol","⨀":"xodot","⨁":"xoplus","⨂":"xotime","⨄":"xuplus","⨆":"xsqcup","⨍":"fpartint","⨐":"cirfnint","⨑":"awint","⨒":"rppolint","⨓":"scpolint","⨔":"npolint","⨕":"pointint","⨖":"quatint","⨗":"intlarhk","⨢":"pluscir","⨣":"plusacir","⨤":"simplus","⨥":"plusdu","⨦":"plussim","⨧":"plustwo","⨩":"mcomma","⨪":"minusdu","⨭":"loplus","⨮":"roplus","⨯":"Cross","⨰":"timesd","⨱":"timesbar","⨳":"smashp","⨴":"lotimes","⨵":"rotimes","⨶":"otimesas","⨷":"Otimes","⨸":"odiv","⨹":"triplus","⨺":"triminus","⨻":"tritime","⨼":"iprod","⨿":"amalg","⩀":"capdot","⩂":"ncup","⩃":"ncap","⩄":"capand","⩅":"cupor","⩆":"cupcap","⩇":"capcup","⩈":"cupbrcap","⩉":"capbrcup","⩊":"cupcup","⩋":"capcap","⩌":"ccups","⩍":"ccaps","⩐":"ccupssm","⩓":"And","⩔":"Or","⩕":"andand","⩖":"oror","⩗":"orslope","⩘":"andslope","⩚":"andv","⩛":"orv","⩜":"andd","⩝":"ord","⩟":"wedbar","⩦":"sdote","⩪":"simdot","⩭":"congdot","⩭̸":"ncongdot","⩮":"easter","⩯":"apacir","⩰":"apE","⩰̸":"napE","⩱":"eplus","⩲":"pluse","⩳":"Esim","⩷":"eDDot","⩸":"equivDD","⩹":"ltcir","⩺":"gtcir","⩻":"ltquest","⩼":"gtquest","⩽":"les","⩽̸":"nles","⩾":"ges","⩾̸":"nges","⩿":"lesdot","⪀":"gesdot","⪁":"lesdoto","⪂":"gesdoto","⪃":"lesdotor","⪄":"gesdotol","⪅":"lap","⪆":"gap","⪇":"lne","⪈":"gne","⪉":"lnap","⪊":"gnap","⪋":"lEg","⪌":"gEl","⪍":"lsime","⪎":"gsime","⪏":"lsimg","⪐":"gsiml","⪑":"lgE","⪒":"glE","⪓":"lesges","⪔":"gesles","⪕":"els","⪖":"egs","⪗":"elsdot","⪘":"egsdot","⪙":"el","⪚":"eg","⪝":"siml","⪞":"simg","⪟":"simlE","⪠":"simgE","⪡":"LessLess","⪡̸":"NotNestedLessLess","⪢":"GreaterGreater","⪢̸":"NotNestedGreaterGreater","⪤":"glj","⪥":"gla","⪦":"ltcc","⪧":"gtcc","⪨":"lescc","⪩":"gescc","⪪":"smt","⪫":"lat","⪬":"smte","⪬︀":"smtes","⪭":"late","⪭︀":"lates","⪮":"bumpE","⪯":"pre","⪯̸":"npre","⪰":"sce","⪰̸":"nsce","⪳":"prE","⪴":"scE","⪵":"prnE","⪶":"scnE","⪷":"prap","⪸":"scap","⪹":"prnap","⪺":"scnap","⪻":"Pr","⪼":"Sc","⪽":"subdot","⪾":"supdot","⪿":"subplus","⫀":"supplus","⫁":"submult","⫂":"supmult","⫃":"subedot","⫄":"supedot","⫅":"subE","⫅̸":"nsubE","⫆":"supE","⫆̸":"nsupE","⫇":"subsim","⫈":"supsim","⫋︀":"vsubnE","⫋":"subnE","⫌︀":"vsupnE","⫌":"supnE","⫏":"csub","⫐":"csup","⫑":"csube","⫒":"csupe","⫓":"subsup","⫔":"supsub","⫕":"subsub","⫖":"supsup","⫗":"suphsub","⫘":"supdsub","⫙":"forkv","⫚":"topfork","⫛":"mlcp","⫤":"Dashv","⫦":"Vdashl","⫧":"Barv","⫨":"vBar","⫩":"vBarv","⫫":"Vbar","⫬":"Not","⫭":"bNot","⫮":"rnmid","⫯":"cirmid","⫰":"midcir","⫱":"topcir","⫲":"nhpar","⫳":"parsim","⫽":"parsl","⫽⃥":"nparsl","♭":"flat","♮":"natur","♯":"sharp","¤":"curren","¢":"cent",$:"dollar","£":"pound","¥":"yen","€":"euro","¹":"sup1","½":"half","⅓":"frac13","¼":"frac14","⅕":"frac15","⅙":"frac16","⅛":"frac18","²":"sup2","⅔":"frac23","⅖":"frac25","³":"sup3","¾":"frac34","⅗":"frac35","⅜":"frac38","⅘":"frac45","⅚":"frac56","⅝":"frac58","⅞":"frac78",𝒶:"ascr",𝕒:"aopf",𝔞:"afr",𝔸:"Aopf",𝔄:"Afr",𝒜:"Ascr",ª:"ordf",á:"aacute",Á:"Aacute",à:"agrave",À:"Agrave",ă:"abreve",Ă:"Abreve",â:"acirc",Â:"Acirc",å:"aring",Å:"angst",ä:"auml",Ä:"Auml",ã:"atilde",Ã:"Atilde",ą:"aogon",Ą:"Aogon",ā:"amacr",Ā:"Amacr",æ:"aelig",Æ:"AElig",𝒷:"bscr",𝕓:"bopf",𝔟:"bfr",𝔹:"Bopf",ℬ:"Bscr",𝔅:"Bfr",𝔠:"cfr",𝒸:"cscr",𝕔:"copf",ℭ:"Cfr",𝒞:"Cscr",ℂ:"Copf",ć:"cacute",Ć:"Cacute",ĉ:"ccirc",Ĉ:"Ccirc",č:"ccaron",Č:"Ccaron",ċ:"cdot",Ċ:"Cdot",ç:"ccedil",Ç:"Ccedil","℅":"incare",𝔡:"dfr",ⅆ:"dd",𝕕:"dopf",𝒹:"dscr",𝒟:"Dscr",𝔇:"Dfr",ⅅ:"DD",𝔻:"Dopf",ď:"dcaron",Ď:"Dcaron",đ:"dstrok",Đ:"Dstrok",ð:"eth",Ð:"ETH",ⅇ:"ee",ℯ:"escr",𝔢:"efr",𝕖:"eopf",ℰ:"Escr",𝔈:"Efr",𝔼:"Eopf",é:"eacute",É:"Eacute",è:"egrave",È:"Egrave",ê:"ecirc",Ê:"Ecirc",ě:"ecaron",Ě:"Ecaron",ë:"euml",Ë:"Euml",ė:"edot",Ė:"Edot",ę:"eogon",Ę:"Eogon",ē:"emacr",Ē:"Emacr",𝔣:"ffr",𝕗:"fopf",𝒻:"fscr",𝔉:"Ffr",𝔽:"Fopf",ℱ:"Fscr",ff:"fflig",ffi:"ffilig",ffl:"ffllig",fi:"filig",fj:"fjlig",fl:"fllig",ƒ:"fnof",ℊ:"gscr",𝕘:"gopf",𝔤:"gfr",𝒢:"Gscr",𝔾:"Gopf",𝔊:"Gfr",ǵ:"gacute",ğ:"gbreve",Ğ:"Gbreve",ĝ:"gcirc",Ĝ:"Gcirc",ġ:"gdot",Ġ:"Gdot",Ģ:"Gcedil",𝔥:"hfr",ℎ:"planckh",𝒽:"hscr",𝕙:"hopf",ℋ:"Hscr",ℌ:"Hfr",ℍ:"Hopf",ĥ:"hcirc",Ĥ:"Hcirc",ℏ:"hbar",ħ:"hstrok",Ħ:"Hstrok",𝕚:"iopf",𝔦:"ifr",𝒾:"iscr",ⅈ:"ii",𝕀:"Iopf",ℐ:"Iscr",ℑ:"Im",í:"iacute",Í:"Iacute",ì:"igrave",Ì:"Igrave",î:"icirc",Î:"Icirc",ï:"iuml",Ï:"Iuml",ĩ:"itilde",Ĩ:"Itilde",İ:"Idot",į:"iogon",Į:"Iogon",ī:"imacr",Ī:"Imacr",ij:"ijlig",IJ:"IJlig",ı:"imath",𝒿:"jscr",𝕛:"jopf",𝔧:"jfr",𝒥:"Jscr",𝔍:"Jfr",𝕁:"Jopf",ĵ:"jcirc",Ĵ:"Jcirc",ȷ:"jmath",𝕜:"kopf",𝓀:"kscr",𝔨:"kfr",𝒦:"Kscr",𝕂:"Kopf",𝔎:"Kfr",ķ:"kcedil",Ķ:"Kcedil",𝔩:"lfr",𝓁:"lscr",ℓ:"ell",𝕝:"lopf",ℒ:"Lscr",𝔏:"Lfr",𝕃:"Lopf",ĺ:"lacute",Ĺ:"Lacute",ľ:"lcaron",Ľ:"Lcaron",ļ:"lcedil",Ļ:"Lcedil",ł:"lstrok",Ł:"Lstrok",ŀ:"lmidot",Ŀ:"Lmidot",𝔪:"mfr",𝕞:"mopf",𝓂:"mscr",𝔐:"Mfr",𝕄:"Mopf",ℳ:"Mscr",𝔫:"nfr",𝕟:"nopf",𝓃:"nscr",ℕ:"Nopf",𝒩:"Nscr",𝔑:"Nfr",ń:"nacute",Ń:"Nacute",ň:"ncaron",Ň:"Ncaron",ñ:"ntilde",Ñ:"Ntilde",ņ:"ncedil",Ņ:"Ncedil","№":"numero",ŋ:"eng",Ŋ:"ENG",𝕠:"oopf",𝔬:"ofr",ℴ:"oscr",𝒪:"Oscr",𝔒:"Ofr",𝕆:"Oopf",º:"ordm",ó:"oacute",Ó:"Oacute",ò:"ograve",Ò:"Ograve",ô:"ocirc",Ô:"Ocirc",ö:"ouml",Ö:"Ouml",ő:"odblac",Ő:"Odblac",õ:"otilde",Õ:"Otilde",ø:"oslash",Ø:"Oslash",ō:"omacr",Ō:"Omacr",œ:"oelig",Œ:"OElig",𝔭:"pfr",𝓅:"pscr",𝕡:"popf",ℙ:"Popf",𝔓:"Pfr",𝒫:"Pscr",𝕢:"qopf",𝔮:"qfr",𝓆:"qscr",𝒬:"Qscr",𝔔:"Qfr",ℚ:"Qopf",ĸ:"kgreen",𝔯:"rfr",𝕣:"ropf",𝓇:"rscr",ℛ:"Rscr",ℜ:"Re",ℝ:"Ropf",ŕ:"racute",Ŕ:"Racute",ř:"rcaron",Ř:"Rcaron",ŗ:"rcedil",Ŗ:"Rcedil",𝕤:"sopf",𝓈:"sscr",𝔰:"sfr",𝕊:"Sopf",𝔖:"Sfr",𝒮:"Sscr","Ⓢ":"oS",ś:"sacute",Ś:"Sacute",ŝ:"scirc",Ŝ:"Scirc",š:"scaron",Š:"Scaron",ş:"scedil",Ş:"Scedil",ß:"szlig",𝔱:"tfr",𝓉:"tscr",𝕥:"topf",𝒯:"Tscr",𝔗:"Tfr",𝕋:"Topf",ť:"tcaron",Ť:"Tcaron",ţ:"tcedil",Ţ:"Tcedil","™":"trade",ŧ:"tstrok",Ŧ:"Tstrok",𝓊:"uscr",𝕦:"uopf",𝔲:"ufr",𝕌:"Uopf",𝔘:"Ufr",𝒰:"Uscr",ú:"uacute",Ú:"Uacute",ù:"ugrave",Ù:"Ugrave",ŭ:"ubreve",Ŭ:"Ubreve",û:"ucirc",Û:"Ucirc",ů:"uring",Ů:"Uring",ü:"uuml",Ü:"Uuml",ű:"udblac",Ű:"Udblac",ũ:"utilde",Ũ:"Utilde",ų:"uogon",Ų:"Uogon",ū:"umacr",Ū:"Umacr",𝔳:"vfr",𝕧:"vopf",𝓋:"vscr",𝔙:"Vfr",𝕍:"Vopf",𝒱:"Vscr",𝕨:"wopf",𝓌:"wscr",𝔴:"wfr",𝒲:"Wscr",𝕎:"Wopf",𝔚:"Wfr",ŵ:"wcirc",Ŵ:"Wcirc",𝔵:"xfr",𝓍:"xscr",𝕩:"xopf",𝕏:"Xopf",𝔛:"Xfr",𝒳:"Xscr",𝔶:"yfr",𝓎:"yscr",𝕪:"yopf",𝒴:"Yscr",𝔜:"Yfr",𝕐:"Yopf",ý:"yacute",Ý:"Yacute",ŷ:"ycirc",Ŷ:"Ycirc",ÿ:"yuml",Ÿ:"Yuml",𝓏:"zscr",𝔷:"zfr",𝕫:"zopf",ℨ:"Zfr",ℤ:"Zopf",𝒵:"Zscr",ź:"zacute",Ź:"Zacute",ž:"zcaron",Ž:"Zcaron",ż:"zdot",Ż:"Zdot",Ƶ:"imped",þ:"thorn",Þ:"THORN",ʼn:"napos",α:"alpha",Α:"Alpha",β:"beta",Β:"Beta",γ:"gamma",Γ:"Gamma",δ:"delta",Δ:"Delta",ε:"epsi",ϵ:"epsiv",Ε:"Epsilon",ϝ:"gammad",Ϝ:"Gammad",ζ:"zeta",Ζ:"Zeta",η:"eta",Η:"Eta",θ:"theta",ϑ:"thetav",Θ:"Theta",ι:"iota",Ι:"Iota",κ:"kappa",ϰ:"kappav",Κ:"Kappa",λ:"lambda",Λ:"Lambda",μ:"mu",µ:"micro",Μ:"Mu",ν:"nu",Ν:"Nu",ξ:"xi",Ξ:"Xi",ο:"omicron",Ο:"Omicron",π:"pi",ϖ:"piv",Π:"Pi",ρ:"rho",ϱ:"rhov",Ρ:"Rho",σ:"sigma",Σ:"Sigma",ς:"sigmaf",τ:"tau",Τ:"Tau",υ:"upsi",Υ:"Upsilon",ϒ:"Upsi",φ:"phi",ϕ:"phiv",Φ:"Phi",χ:"chi",Χ:"Chi",ψ:"psi",Ψ:"Psi",ω:"omega",Ω:"ohm",а:"acy",А:"Acy",б:"bcy",Б:"Bcy",в:"vcy",В:"Vcy",г:"gcy",Г:"Gcy",ѓ:"gjcy",Ѓ:"GJcy",д:"dcy",Д:"Dcy",ђ:"djcy",Ђ:"DJcy",е:"iecy",Е:"IEcy",ё:"iocy",Ё:"IOcy",є:"jukcy",Є:"Jukcy",ж:"zhcy",Ж:"ZHcy",з:"zcy",З:"Zcy",ѕ:"dscy",Ѕ:"DScy",и:"icy",И:"Icy",і:"iukcy",І:"Iukcy",ї:"yicy",Ї:"YIcy",й:"jcy",Й:"Jcy",ј:"jsercy",Ј:"Jsercy",к:"kcy",К:"Kcy",ќ:"kjcy",Ќ:"KJcy",л:"lcy",Л:"Lcy",љ:"ljcy",Љ:"LJcy",м:"mcy",М:"Mcy",н:"ncy",Н:"Ncy",њ:"njcy",Њ:"NJcy",о:"ocy",О:"Ocy",п:"pcy",П:"Pcy",р:"rcy",Р:"Rcy",с:"scy",С:"Scy",т:"tcy",Т:"Tcy",ћ:"tshcy",Ћ:"TSHcy",у:"ucy",У:"Ucy",ў:"ubrcy",Ў:"Ubrcy",ф:"fcy",Ф:"Fcy",х:"khcy",Х:"KHcy",ц:"tscy",Ц:"TScy",ч:"chcy",Ч:"CHcy",џ:"dzcy",Џ:"DZcy",ш:"shcy",Ш:"SHcy",щ:"shchcy",Щ:"SHCHcy",ъ:"hardcy",Ъ:"HARDcy",ы:"ycy",Ы:"Ycy",ь:"softcy",Ь:"SOFTcy",э:"ecy",Э:"Ecy",ю:"yucy",Ю:"YUcy",я:"yacy",Я:"YAcy",ℵ:"aleph",ℶ:"beth",ℷ:"gimel",ℸ:"daleth"},d=/["&'<>`]/g,f={'"':""","&":"&","'":"'","<":"<",">":">","`":"`"},h=/&#(?:[xX][^a-fA-F0-9]|[^0-9xX])/,g=/[\0-\x08\x0B\x0E-\x1F\x7F-\x9F\uFDD0-\uFDEF\uFFFE\uFFFF]|[\uD83F\uD87F\uD8BF\uD8FF\uD93F\uD97F\uD9BF\uD9FF\uDA3F\uDA7F\uDABF\uDAFF\uDB3F\uDB7F\uDBBF\uDBFF][\uDFFE\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,m=/&(CounterClockwiseContourIntegral|DoubleLongLeftRightArrow|ClockwiseContourIntegral|NotNestedGreaterGreater|NotSquareSupersetEqual|DiacriticalDoubleAcute|NotRightTriangleEqual|NotSucceedsSlantEqual|NotPrecedesSlantEqual|CloseCurlyDoubleQuote|NegativeVeryThinSpace|DoubleContourIntegral|FilledVerySmallSquare|CapitalDifferentialD|OpenCurlyDoubleQuote|EmptyVerySmallSquare|NestedGreaterGreater|DoubleLongRightArrow|NotLeftTriangleEqual|NotGreaterSlantEqual|ReverseUpEquilibrium|DoubleLeftRightArrow|NotSquareSubsetEqual|NotDoubleVerticalBar|RightArrowLeftArrow|NotGreaterFullEqual|NotRightTriangleBar|SquareSupersetEqual|DownLeftRightVector|DoubleLongLeftArrow|leftrightsquigarrow|LeftArrowRightArrow|NegativeMediumSpace|blacktriangleright|RightDownVectorBar|PrecedesSlantEqual|RightDoubleBracket|SucceedsSlantEqual|NotLeftTriangleBar|RightTriangleEqual|SquareIntersection|RightDownTeeVector|ReverseEquilibrium|NegativeThickSpace|longleftrightarrow|Longleftrightarrow|LongLeftRightArrow|DownRightTeeVector|DownRightVectorBar|GreaterSlantEqual|SquareSubsetEqual|LeftDownVectorBar|LeftDoubleBracket|VerticalSeparator|rightleftharpoons|NotGreaterGreater|NotSquareSuperset|blacktriangleleft|blacktriangledown|NegativeThinSpace|LeftDownTeeVector|NotLessSlantEqual|leftrightharpoons|DoubleUpDownArrow|DoubleVerticalBar|LeftTriangleEqual|FilledSmallSquare|twoheadrightarrow|NotNestedLessLess|DownLeftTeeVector|DownLeftVectorBar|RightAngleBracket|NotTildeFullEqual|NotReverseElement|RightUpDownVector|DiacriticalTilde|NotSucceedsTilde|circlearrowright|NotPrecedesEqual|rightharpoondown|DoubleRightArrow|NotSucceedsEqual|NonBreakingSpace|NotRightTriangle|LessEqualGreater|RightUpTeeVector|LeftAngleBracket|GreaterFullEqual|DownArrowUpArrow|RightUpVectorBar|twoheadleftarrow|GreaterEqualLess|downharpoonright|RightTriangleBar|ntrianglerighteq|NotSupersetEqual|LeftUpDownVector|DiacriticalAcute|rightrightarrows|vartriangleright|UpArrowDownArrow|DiacriticalGrave|UnderParenthesis|EmptySmallSquare|LeftUpVectorBar|leftrightarrows|DownRightVector|downharpoonleft|trianglerighteq|ShortRightArrow|OverParenthesis|DoubleLeftArrow|DoubleDownArrow|NotSquareSubset|bigtriangledown|ntrianglelefteq|UpperRightArrow|curvearrowright|vartriangleleft|NotLeftTriangle|nleftrightarrow|LowerRightArrow|NotHumpDownHump|NotGreaterTilde|rightthreetimes|LeftUpTeeVector|NotGreaterEqual|straightepsilon|LeftTriangleBar|rightsquigarrow|ContourIntegral|rightleftarrows|CloseCurlyQuote|RightDownVector|LeftRightVector|nLeftrightarrow|leftharpoondown|circlearrowleft|SquareSuperset|OpenCurlyQuote|hookrightarrow|HorizontalLine|DiacriticalDot|NotLessGreater|ntriangleright|DoubleRightTee|InvisibleComma|InvisibleTimes|LowerLeftArrow|DownLeftVector|NotSubsetEqual|curvearrowleft|trianglelefteq|NotVerticalBar|TildeFullEqual|downdownarrows|NotGreaterLess|RightTeeVector|ZeroWidthSpace|looparrowright|LongRightArrow|doublebarwedge|ShortLeftArrow|ShortDownArrow|RightVectorBar|GreaterGreater|ReverseElement|rightharpoonup|LessSlantEqual|leftthreetimes|upharpoonright|rightarrowtail|LeftDownVector|Longrightarrow|NestedLessLess|UpperLeftArrow|nshortparallel|leftleftarrows|leftrightarrow|Leftrightarrow|LeftRightArrow|longrightarrow|upharpoonleft|RightArrowBar|ApplyFunction|LeftTeeVector|leftarrowtail|NotEqualTilde|varsubsetneqq|varsupsetneqq|RightTeeArrow|SucceedsEqual|SucceedsTilde|LeftVectorBar|SupersetEqual|hookleftarrow|DifferentialD|VerticalTilde|VeryThinSpace|blacktriangle|bigtriangleup|LessFullEqual|divideontimes|leftharpoonup|UpEquilibrium|ntriangleleft|RightTriangle|measuredangle|shortparallel|longleftarrow|Longleftarrow|LongLeftArrow|DoubleLeftTee|Poincareplane|PrecedesEqual|triangleright|DoubleUpArrow|RightUpVector|fallingdotseq|looparrowleft|PrecedesTilde|NotTildeEqual|NotTildeTilde|smallsetminus|Proportional|triangleleft|triangledown|UnderBracket|NotHumpEqual|exponentiale|ExponentialE|NotLessTilde|HilbertSpace|RightCeiling|blacklozenge|varsupsetneq|HumpDownHump|GreaterEqual|VerticalLine|LeftTeeArrow|NotLessEqual|DownTeeArrow|LeftTriangle|varsubsetneq|Intersection|NotCongruent|DownArrowBar|LeftUpVector|LeftArrowBar|risingdotseq|GreaterTilde|RoundImplies|SquareSubset|ShortUpArrow|NotSuperset|quaternions|precnapprox|backepsilon|preccurlyeq|OverBracket|blacksquare|MediumSpace|VerticalBar|circledcirc|circleddash|CircleMinus|CircleTimes|LessGreater|curlyeqprec|curlyeqsucc|diamondsuit|UpDownArrow|Updownarrow|RuleDelayed|Rrightarrow|updownarrow|RightVector|nRightarrow|nrightarrow|eqslantless|LeftCeiling|Equilibrium|SmallCircle|expectation|NotSucceeds|thickapprox|GreaterLess|SquareUnion|NotPrecedes|NotLessLess|straightphi|succnapprox|succcurlyeq|SubsetEqual|sqsupseteq|Proportion|Laplacetrf|ImaginaryI|supsetneqq|NotGreater|gtreqqless|NotElement|ThickSpace|TildeEqual|TildeTilde|Fouriertrf|rmoustache|EqualTilde|eqslantgtr|UnderBrace|LeftVector|UpArrowBar|nLeftarrow|nsubseteqq|subsetneqq|nsupseteqq|nleftarrow|succapprox|lessapprox|UpTeeArrow|upuparrows|curlywedge|lesseqqgtr|varepsilon|varnothing|RightFloor|complement|CirclePlus|sqsubseteq|Lleftarrow|circledast|RightArrow|Rightarrow|rightarrow|lmoustache|Bernoullis|precapprox|mapstoleft|mapstodown|longmapsto|dotsquare|downarrow|DoubleDot|nsubseteq|supsetneq|leftarrow|nsupseteq|subsetneq|ThinSpace|ngeqslant|subseteqq|HumpEqual|NotSubset|triangleq|NotCupCap|lesseqgtr|heartsuit|TripleDot|Leftarrow|Coproduct|Congruent|varpropto|complexes|gvertneqq|LeftArrow|LessTilde|supseteqq|MinusPlus|CircleDot|nleqslant|NotExists|gtreqless|nparallel|UnionPlus|LeftFloor|checkmark|CenterDot|centerdot|Mellintrf|gtrapprox|bigotimes|OverBrace|spadesuit|therefore|pitchfork|rationals|PlusMinus|Backslash|Therefore|DownBreve|backsimeq|backprime|DownArrow|nshortmid|Downarrow|lvertneqq|eqvparsl|imagline|imagpart|infintie|integers|Integral|intercal|LessLess|Uarrocir|intlarhk|sqsupset|angmsdaf|sqsubset|llcorner|vartheta|cupbrcap|lnapprox|Superset|SuchThat|succnsim|succneqq|angmsdag|biguplus|curlyvee|trpezium|Succeeds|NotTilde|bigwedge|angmsdah|angrtvbd|triminus|cwconint|fpartint|lrcorner|smeparsl|subseteq|urcorner|lurdshar|laemptyv|DDotrahd|approxeq|ldrushar|awconint|mapstoup|backcong|shortmid|triangle|geqslant|gesdotol|timesbar|circledR|circledS|setminus|multimap|naturals|scpolint|ncongdot|RightTee|boxminus|gnapprox|boxtimes|andslope|thicksim|angmsdaa|varsigma|cirfnint|rtriltri|angmsdab|rppolint|angmsdac|barwedge|drbkarow|clubsuit|thetasym|bsolhsub|capbrcup|dzigrarr|doteqdot|DotEqual|dotminus|UnderBar|NotEqual|realpart|otimesas|ulcorner|hksearow|hkswarow|parallel|PartialD|elinters|emptyset|plusacir|bbrktbrk|angmsdad|pointint|bigoplus|angmsdae|Precedes|bigsqcup|varkappa|notindot|supseteq|precneqq|precnsim|profalar|profline|profsurf|leqslant|lesdotor|raemptyv|subplus|notnivb|notnivc|subrarr|zigrarr|vzigzag|submult|subedot|Element|between|cirscir|larrbfs|larrsim|lotimes|lbrksld|lbrkslu|lozenge|ldrdhar|dbkarow|bigcirc|epsilon|simrarr|simplus|ltquest|Epsilon|luruhar|gtquest|maltese|npolint|eqcolon|npreceq|bigodot|ddagger|gtrless|bnequiv|harrcir|ddotseq|equivDD|backsim|demptyv|nsqsube|nsqsupe|Upsilon|nsubset|upsilon|minusdu|nsucceq|swarrow|nsupset|coloneq|searrow|boxplus|napprox|natural|asympeq|alefsym|congdot|nearrow|bigstar|diamond|supplus|tritime|LeftTee|nvinfin|triplus|NewLine|nvltrie|nvrtrie|nwarrow|nexists|Diamond|ruluhar|Implies|supmult|angzarr|suplarr|suphsub|questeq|because|digamma|Because|olcross|bemptyv|omicron|Omicron|rotimes|NoBreak|intprod|angrtvb|orderof|uwangle|suphsol|lesdoto|orslope|DownTee|realine|cudarrl|rdldhar|OverBar|supedot|lessdot|supdsub|topfork|succsim|rbrkslu|rbrksld|pertenk|cudarrr|isindot|planckh|lessgtr|pluscir|gesdoto|plussim|plustwo|lesssim|cularrp|rarrsim|Cayleys|notinva|notinvb|notinvc|UpArrow|Uparrow|uparrow|NotLess|dwangle|precsim|Product|curarrm|Cconint|dotplus|rarrbfs|ccupssm|Cedilla|cemptyv|notniva|quatint|frac35|frac38|frac45|frac56|frac58|frac78|tridot|xoplus|gacute|gammad|Gammad|lfisht|lfloor|bigcup|sqsupe|gbreve|Gbreve|lharul|sqsube|sqcups|Gcedil|apacir|llhard|lmidot|Lmidot|lmoust|andand|sqcaps|approx|Abreve|spades|circeq|tprime|divide|topcir|Assign|topbot|gesdot|divonx|xuplus|timesd|gesles|atilde|solbar|SOFTcy|loplus|timesb|lowast|lowbar|dlcorn|dlcrop|softcy|dollar|lparlt|thksim|lrhard|Atilde|lsaquo|smashp|bigvee|thinsp|wreath|bkarow|lsquor|lstrok|Lstrok|lthree|ltimes|ltlarr|DotDot|simdot|ltrPar|weierp|xsqcup|angmsd|sigmav|sigmaf|zeetrf|Zcaron|zcaron|mapsto|vsupne|thetav|cirmid|marker|mcomma|Zacute|vsubnE|there4|gtlPar|vsubne|bottom|gtrarr|SHCHcy|shchcy|midast|midcir|middot|minusb|minusd|gtrdot|bowtie|sfrown|mnplus|models|colone|seswar|Colone|mstpos|searhk|gtrsim|nacute|Nacute|boxbox|telrec|hairsp|Tcedil|nbumpe|scnsim|ncaron|Ncaron|ncedil|Ncedil|hamilt|Scedil|nearhk|hardcy|HARDcy|tcedil|Tcaron|commat|nequiv|nesear|tcaron|target|hearts|nexist|varrho|scedil|Scaron|scaron|hellip|Sacute|sacute|hercon|swnwar|compfn|rtimes|rthree|rsquor|rsaquo|zacute|wedgeq|homtht|barvee|barwed|Barwed|rpargt|horbar|conint|swarhk|roplus|nltrie|hslash|hstrok|Hstrok|rmoust|Conint|bprime|hybull|hyphen|iacute|Iacute|supsup|supsub|supsim|varphi|coprod|brvbar|agrave|Supset|supset|igrave|Igrave|notinE|Agrave|iiiint|iinfin|copysr|wedbar|Verbar|vangrt|becaus|incare|verbar|inodot|bullet|drcorn|intcal|drcrop|cularr|vellip|Utilde|bumpeq|cupcap|dstrok|Dstrok|CupCap|cupcup|cupdot|eacute|Eacute|supdot|iquest|easter|ecaron|Ecaron|ecolon|isinsv|utilde|itilde|Itilde|curarr|succeq|Bumpeq|cacute|ulcrop|nparsl|Cacute|nprcue|egrave|Egrave|nrarrc|nrarrw|subsup|subsub|nrtrie|jsercy|nsccue|Jsercy|kappav|kcedil|Kcedil|subsim|ulcorn|nsimeq|egsdot|veebar|kgreen|capand|elsdot|Subset|subset|curren|aacute|lacute|Lacute|emptyv|ntilde|Ntilde|lagran|lambda|Lambda|capcap|Ugrave|langle|subdot|emsp13|numero|emsp14|nvdash|nvDash|nVdash|nVDash|ugrave|ufisht|nvHarr|larrfs|nvlArr|larrhk|larrlp|larrpl|nvrArr|Udblac|nwarhk|larrtl|nwnear|oacute|Oacute|latail|lAtail|sstarf|lbrace|odblac|Odblac|lbrack|udblac|odsold|eparsl|lcaron|Lcaron|ograve|Ograve|lcedil|Lcedil|Aacute|ssmile|ssetmn|squarf|ldquor|capcup|ominus|cylcty|rharul|eqcirc|dagger|rfloor|rfisht|Dagger|daleth|equals|origof|capdot|equest|dcaron|Dcaron|rdquor|oslash|Oslash|otilde|Otilde|otimes|Otimes|urcrop|Ubreve|ubreve|Yacute|Uacute|uacute|Rcedil|rcedil|urcorn|parsim|Rcaron|Vdashl|rcaron|Tstrok|percnt|period|permil|Exists|yacute|rbrack|rbrace|phmmat|ccaron|Ccaron|planck|ccedil|plankv|tstrok|female|plusdo|plusdu|ffilig|plusmn|ffllig|Ccedil|rAtail|dfisht|bernou|ratail|Rarrtl|rarrtl|angsph|rarrpl|rarrlp|rarrhk|xwedge|xotime|forall|ForAll|Vvdash|vsupnE|preceq|bigcap|frac12|frac13|frac14|primes|rarrfs|prnsim|frac15|Square|frac16|square|lesdot|frac18|frac23|propto|prurel|rarrap|rangle|puncsp|frac25|Racute|qprime|racute|lesges|frac34|abreve|AElig|eqsim|utdot|setmn|urtri|Equal|Uring|seArr|uring|searr|dashv|Dashv|mumap|nabla|iogon|Iogon|sdote|sdotb|scsim|napid|napos|equiv|natur|Acirc|dblac|erarr|nbump|iprod|erDot|ucirc|awint|esdot|angrt|ncong|isinE|scnap|Scirc|scirc|ndash|isins|Ubrcy|nearr|neArr|isinv|nedot|ubrcy|acute|Ycirc|iukcy|Iukcy|xutri|nesim|caret|jcirc|Jcirc|caron|twixt|ddarr|sccue|exist|jmath|sbquo|ngeqq|angst|ccaps|lceil|ngsim|UpTee|delta|Delta|rtrif|nharr|nhArr|nhpar|rtrie|jukcy|Jukcy|kappa|rsquo|Kappa|nlarr|nlArr|TSHcy|rrarr|aogon|Aogon|fflig|xrarr|tshcy|ccirc|nleqq|filig|upsih|nless|dharl|nlsim|fjlig|ropar|nltri|dharr|robrk|roarr|fllig|fltns|roang|rnmid|subnE|subne|lAarr|trisb|Ccirc|acirc|ccups|blank|VDash|forkv|Vdash|langd|cedil|blk12|blk14|laquo|strns|diams|notin|vDash|larrb|blk34|block|disin|uplus|vdash|vBarv|aelig|starf|Wedge|check|xrArr|lates|lbarr|lBarr|notni|lbbrk|bcong|frasl|lbrke|frown|vrtri|vprop|vnsup|gamma|Gamma|wedge|xodot|bdquo|srarr|doteq|ldquo|boxdl|boxdL|gcirc|Gcirc|boxDl|boxDL|boxdr|boxdR|boxDr|TRADE|trade|rlhar|boxDR|vnsub|npart|vltri|rlarr|boxhd|boxhD|nprec|gescc|nrarr|nrArr|boxHd|boxHD|boxhu|boxhU|nrtri|boxHu|clubs|boxHU|times|colon|Colon|gimel|xlArr|Tilde|nsime|tilde|nsmid|nspar|THORN|thorn|xlarr|nsube|nsubE|thkap|xhArr|comma|nsucc|boxul|boxuL|nsupe|nsupE|gneqq|gnsim|boxUl|boxUL|grave|boxur|boxuR|boxUr|boxUR|lescc|angle|bepsi|boxvh|varpi|boxvH|numsp|Theta|gsime|gsiml|theta|boxVh|boxVH|boxvl|gtcir|gtdot|boxvL|boxVl|boxVL|crarr|cross|Cross|nvsim|boxvr|nwarr|nwArr|sqsup|dtdot|Uogon|lhard|lharu|dtrif|ocirc|Ocirc|lhblk|duarr|odash|sqsub|Hacek|sqcup|llarr|duhar|oelig|OElig|ofcir|boxvR|uogon|lltri|boxVr|csube|uuarr|ohbar|csupe|ctdot|olarr|olcir|harrw|oline|sqcap|omacr|Omacr|omega|Omega|boxVR|aleph|lneqq|lnsim|loang|loarr|rharu|lobrk|hcirc|operp|oplus|rhard|Hcirc|orarr|Union|order|ecirc|Ecirc|cuepr|szlig|cuesc|breve|reals|eDDot|Breve|hoarr|lopar|utrif|rdquo|Umacr|umacr|efDot|swArr|ultri|alpha|rceil|ovbar|swarr|Wcirc|wcirc|smtes|smile|bsemi|lrarr|aring|parsl|lrhar|bsime|uhblk|lrtri|cupor|Aring|uharr|uharl|slarr|rbrke|bsolb|lsime|rbbrk|RBarr|lsimg|phone|rBarr|rbarr|icirc|lsquo|Icirc|emacr|Emacr|ratio|simne|plusb|simlE|simgE|simeq|pluse|ltcir|ltdot|empty|xharr|xdtri|iexcl|Alpha|ltrie|rarrw|pound|ltrif|xcirc|bumpe|prcue|bumpE|asymp|amacr|cuvee|Sigma|sigma|iiint|udhar|iiota|ijlig|IJlig|supnE|imacr|Imacr|prime|Prime|image|prnap|eogon|Eogon|rarrc|mdash|mDDot|cuwed|imath|supne|imped|Amacr|udarr|prsim|micro|rarrb|cwint|raquo|infin|eplus|range|rangd|Ucirc|radic|minus|amalg|veeeq|rAarr|epsiv|ycirc|quest|sharp|quot|zwnj|Qscr|race|qscr|Qopf|qopf|qint|rang|Rang|Zscr|zscr|Zopf|zopf|rarr|rArr|Rarr|Pscr|pscr|prop|prod|prnE|prec|ZHcy|zhcy|prap|Zeta|zeta|Popf|popf|Zdot|plus|zdot|Yuml|yuml|phiv|YUcy|yucy|Yscr|yscr|perp|Yopf|yopf|part|para|YIcy|Ouml|rcub|yicy|YAcy|rdca|ouml|osol|Oscr|rdsh|yacy|real|oscr|xvee|andd|rect|andv|Xscr|oror|ordm|ordf|xscr|ange|aopf|Aopf|rHar|Xopf|opar|Oopf|xopf|xnis|rhov|oopf|omid|xmap|oint|apid|apos|ogon|ascr|Ascr|odot|odiv|xcup|xcap|ocir|oast|nvlt|nvle|nvgt|nvge|nvap|Wscr|wscr|auml|ntlg|ntgl|nsup|nsub|nsim|Nscr|nscr|nsce|Wopf|ring|npre|wopf|npar|Auml|Barv|bbrk|Nopf|nopf|nmid|nLtv|beta|ropf|Ropf|Beta|beth|nles|rpar|nleq|bnot|bNot|nldr|NJcy|rscr|Rscr|Vscr|vscr|rsqb|njcy|bopf|nisd|Bopf|rtri|Vopf|nGtv|ngtr|vopf|boxh|boxH|boxv|nges|ngeq|boxV|bscr|scap|Bscr|bsim|Vert|vert|bsol|bull|bump|caps|cdot|ncup|scnE|ncap|nbsp|napE|Cdot|cent|sdot|Vbar|nang|vBar|chcy|Mscr|mscr|sect|semi|CHcy|Mopf|mopf|sext|circ|cire|mldr|mlcp|cirE|comp|shcy|SHcy|vArr|varr|cong|copf|Copf|copy|COPY|malt|male|macr|lvnE|cscr|ltri|sime|ltcc|simg|Cscr|siml|csub|Uuml|lsqb|lsim|uuml|csup|Lscr|lscr|utri|smid|lpar|cups|smte|lozf|darr|Lopf|Uscr|solb|lopf|sopf|Sopf|lneq|uscr|spar|dArr|lnap|Darr|dash|Sqrt|LJcy|ljcy|lHar|dHar|Upsi|upsi|diam|lesg|djcy|DJcy|leqq|dopf|Dopf|dscr|Dscr|dscy|ldsh|ldca|squf|DScy|sscr|Sscr|dsol|lcub|late|star|Star|Uopf|Larr|lArr|larr|uopf|dtri|dzcy|sube|subE|Lang|lang|Kscr|kscr|Kopf|kopf|KJcy|kjcy|KHcy|khcy|DZcy|ecir|edot|eDot|Jscr|jscr|succ|Jopf|jopf|Edot|uHar|emsp|ensp|Iuml|iuml|eopf|isin|Iscr|iscr|Eopf|epar|sung|epsi|escr|sup1|sup2|sup3|Iota|iota|supe|supE|Iopf|iopf|IOcy|iocy|Escr|esim|Esim|imof|Uarr|QUOT|uArr|uarr|euml|IEcy|iecy|Idot|Euml|euro|excl|Hscr|hscr|Hopf|hopf|TScy|tscy|Tscr|hbar|tscr|flat|tbrk|fnof|hArr|harr|half|fopf|Fopf|tdot|gvnE|fork|trie|gtcc|fscr|Fscr|gdot|gsim|Gscr|gscr|Gopf|gopf|gneq|Gdot|tosa|gnap|Topf|topf|geqq|toea|GJcy|gjcy|tint|gesl|mid|Sfr|ggg|top|ges|gla|glE|glj|geq|gne|gEl|gel|gnE|Gcy|gcy|gap|Tfr|tfr|Tcy|tcy|Hat|Tau|Ffr|tau|Tab|hfr|Hfr|ffr|Fcy|fcy|icy|Icy|iff|ETH|eth|ifr|Ifr|Eta|eta|int|Int|Sup|sup|ucy|Ucy|Sum|sum|jcy|ENG|ufr|Ufr|eng|Jcy|jfr|els|ell|egs|Efr|efr|Jfr|uml|kcy|Kcy|Ecy|ecy|kfr|Kfr|lap|Sub|sub|lat|lcy|Lcy|leg|Dot|dot|lEg|leq|les|squ|div|die|lfr|Lfr|lgE|Dfr|dfr|Del|deg|Dcy|dcy|lne|lnE|sol|loz|smt|Cup|lrm|cup|lsh|Lsh|sim|shy|map|Map|mcy|Mcy|mfr|Mfr|mho|gfr|Gfr|sfr|cir|Chi|chi|nap|Cfr|vcy|Vcy|cfr|Scy|scy|ncy|Ncy|vee|Vee|Cap|cap|nfr|scE|sce|Nfr|nge|ngE|nGg|vfr|Vfr|ngt|bot|nGt|nis|niv|Rsh|rsh|nle|nlE|bne|Bfr|bfr|nLl|nlt|nLt|Bcy|bcy|not|Not|rlm|wfr|Wfr|npr|nsc|num|ocy|ast|Ocy|ofr|xfr|Xfr|Ofr|ogt|ohm|apE|olt|Rho|ape|rho|Rfr|rfr|ord|REG|ang|reg|orv|And|and|AMP|Rcy|amp|Afr|ycy|Ycy|yen|yfr|Yfr|rcy|par|pcy|Pcy|pfr|Pfr|phi|Phi|afr|Acy|acy|zcy|Zcy|piv|acE|acd|zfr|Zfr|pre|prE|psi|Psi|qfr|Qfr|zwj|Or|ge|Gg|gt|gg|el|oS|lt|Lt|LT|Re|lg|gl|eg|ne|Im|it|le|DD|wp|wr|nu|Nu|dd|lE|Sc|sc|pi|Pi|ee|af|ll|Ll|rx|gE|xi|pm|Xi|ic|pr|Pr|in|ni|mp|mu|ac|Mu|or|ap|Gt|GT|ii);|&(Aacute|Agrave|Atilde|Ccedil|Eacute|Egrave|Iacute|Igrave|Ntilde|Oacute|Ograve|Oslash|Otilde|Uacute|Ugrave|Yacute|aacute|agrave|atilde|brvbar|ccedil|curren|divide|eacute|egrave|frac12|frac14|frac34|iacute|igrave|iquest|middot|ntilde|oacute|ograve|oslash|otilde|plusmn|uacute|ugrave|yacute|AElig|Acirc|Aring|Ecirc|Icirc|Ocirc|THORN|Ucirc|acirc|acute|aelig|aring|cedil|ecirc|icirc|iexcl|laquo|micro|ocirc|pound|raquo|szlig|thorn|times|ucirc|Auml|COPY|Euml|Iuml|Ouml|QUOT|Uuml|auml|cent|copy|euml|iuml|macr|nbsp|ordf|ordm|ouml|para|quot|sect|sup1|sup2|sup3|uuml|yuml|AMP|ETH|REG|amp|deg|eth|not|reg|shy|uml|yen|GT|LT|gt|lt)(?!;)([=a-zA-Z0-9]?)|&#([0-9]+)(;?)|&#[xX]([a-fA-F0-9]+)(;?)|&([0-9a-zA-Z]+)/g,v={aacute:"á",Aacute:"Á",abreve:"ă",Abreve:"Ă",ac:"∾",acd:"∿",acE:"∾̳",acirc:"â",Acirc:"Â",acute:"´",acy:"а",Acy:"А",aelig:"æ",AElig:"Æ",af:"⁡",afr:"𝔞",Afr:"𝔄",agrave:"à",Agrave:"À",alefsym:"ℵ",aleph:"ℵ",alpha:"α",Alpha:"Α",amacr:"ā",Amacr:"Ā",amalg:"⨿",amp:"&",AMP:"&",and:"∧",And:"⩓",andand:"⩕",andd:"⩜",andslope:"⩘",andv:"⩚",ang:"∠",ange:"⦤",angle:"∠",angmsd:"∡",angmsdaa:"⦨",angmsdab:"⦩",angmsdac:"⦪",angmsdad:"⦫",angmsdae:"⦬",angmsdaf:"⦭",angmsdag:"⦮",angmsdah:"⦯",angrt:"∟",angrtvb:"⊾",angrtvbd:"⦝",angsph:"∢",angst:"Å",angzarr:"⍼",aogon:"ą",Aogon:"Ą",aopf:"𝕒",Aopf:"𝔸",ap:"≈",apacir:"⩯",ape:"≊",apE:"⩰",apid:"≋",apos:"'",ApplyFunction:"⁡",approx:"≈",approxeq:"≊",aring:"å",Aring:"Å",ascr:"𝒶",Ascr:"𝒜",Assign:"≔",ast:"*",asymp:"≈",asympeq:"≍",atilde:"ã",Atilde:"Ã",auml:"ä",Auml:"Ä",awconint:"∳",awint:"⨑",backcong:"≌",backepsilon:"϶",backprime:"‵",backsim:"∽",backsimeq:"⋍",Backslash:"∖",Barv:"⫧",barvee:"⊽",barwed:"⌅",Barwed:"⌆",barwedge:"⌅",bbrk:"⎵",bbrktbrk:"⎶",bcong:"≌",bcy:"б",Bcy:"Б",bdquo:"„",becaus:"∵",because:"∵",Because:"∵",bemptyv:"⦰",bepsi:"϶",bernou:"ℬ",Bernoullis:"ℬ",beta:"β",Beta:"Β",beth:"ℶ",between:"≬",bfr:"𝔟",Bfr:"𝔅",bigcap:"⋂",bigcirc:"◯",bigcup:"⋃",bigodot:"⨀",bigoplus:"⨁",bigotimes:"⨂",bigsqcup:"⨆",bigstar:"★",bigtriangledown:"▽",bigtriangleup:"△",biguplus:"⨄",bigvee:"⋁",bigwedge:"⋀",bkarow:"⤍",blacklozenge:"⧫",blacksquare:"▪",blacktriangle:"▴",blacktriangledown:"▾",blacktriangleleft:"◂",blacktriangleright:"▸",blank:"␣",blk12:"▒",blk14:"░",blk34:"▓",block:"█",bne:"=⃥",bnequiv:"≡⃥",bnot:"⌐",bNot:"⫭",bopf:"𝕓",Bopf:"𝔹",bot:"⊥",bottom:"⊥",bowtie:"⋈",boxbox:"⧉",boxdl:"┐",boxdL:"╕",boxDl:"╖",boxDL:"╗",boxdr:"┌",boxdR:"╒",boxDr:"╓",boxDR:"╔",boxh:"─",boxH:"═",boxhd:"┬",boxhD:"╥",boxHd:"╤",boxHD:"╦",boxhu:"┴",boxhU:"╨",boxHu:"╧",boxHU:"╩",boxminus:"⊟",boxplus:"⊞",boxtimes:"⊠",boxul:"┘",boxuL:"╛",boxUl:"╜",boxUL:"╝",boxur:"└",boxuR:"╘",boxUr:"╙",boxUR:"╚",boxv:"│",boxV:"║",boxvh:"┼",boxvH:"╪",boxVh:"╫",boxVH:"╬",boxvl:"┤",boxvL:"╡",boxVl:"╢",boxVL:"╣",boxvr:"├",boxvR:"╞",boxVr:"╟",boxVR:"╠",bprime:"‵",breve:"˘",Breve:"˘",brvbar:"¦",bscr:"𝒷",Bscr:"ℬ",bsemi:"⁏",bsim:"∽",bsime:"⋍",bsol:"\\",bsolb:"⧅",bsolhsub:"⟈",bull:"•",bullet:"•",bump:"≎",bumpe:"≏",bumpE:"⪮",bumpeq:"≏",Bumpeq:"≎",cacute:"ć",Cacute:"Ć",cap:"∩",Cap:"⋒",capand:"⩄",capbrcup:"⩉",capcap:"⩋",capcup:"⩇",capdot:"⩀",CapitalDifferentialD:"ⅅ",caps:"∩︀",caret:"⁁",caron:"ˇ",Cayleys:"ℭ",ccaps:"⩍",ccaron:"č",Ccaron:"Č",ccedil:"ç",Ccedil:"Ç",ccirc:"ĉ",Ccirc:"Ĉ",Cconint:"∰",ccups:"⩌",ccupssm:"⩐",cdot:"ċ",Cdot:"Ċ",cedil:"¸",Cedilla:"¸",cemptyv:"⦲",cent:"¢",centerdot:"·",CenterDot:"·",cfr:"𝔠",Cfr:"ℭ",chcy:"ч",CHcy:"Ч",check:"✓",checkmark:"✓",chi:"χ",Chi:"Χ",cir:"○",circ:"ˆ",circeq:"≗",circlearrowleft:"↺",circlearrowright:"↻",circledast:"⊛",circledcirc:"⊚",circleddash:"⊝",CircleDot:"⊙",circledR:"®",circledS:"Ⓢ",CircleMinus:"⊖",CirclePlus:"⊕",CircleTimes:"⊗",cire:"≗",cirE:"⧃",cirfnint:"⨐",cirmid:"⫯",cirscir:"⧂",ClockwiseContourIntegral:"∲",CloseCurlyDoubleQuote:"”",CloseCurlyQuote:"’",clubs:"♣",clubsuit:"♣",colon:":",Colon:"∷",colone:"≔",Colone:"⩴",coloneq:"≔",comma:",",commat:"@",comp:"∁",compfn:"∘",complement:"∁",complexes:"ℂ",cong:"≅",congdot:"⩭",Congruent:"≡",conint:"∮",Conint:"∯",ContourIntegral:"∮",copf:"𝕔",Copf:"ℂ",coprod:"∐",Coproduct:"∐",copy:"©",COPY:"©",copysr:"℗",CounterClockwiseContourIntegral:"∳",crarr:"↵",cross:"✗",Cross:"⨯",cscr:"𝒸",Cscr:"𝒞",csub:"⫏",csube:"⫑",csup:"⫐",csupe:"⫒",ctdot:"⋯",cudarrl:"⤸",cudarrr:"⤵",cuepr:"⋞",cuesc:"⋟",cularr:"↶",cularrp:"⤽",cup:"∪",Cup:"⋓",cupbrcap:"⩈",cupcap:"⩆",CupCap:"≍",cupcup:"⩊",cupdot:"⊍",cupor:"⩅",cups:"∪︀",curarr:"↷",curarrm:"⤼",curlyeqprec:"⋞",curlyeqsucc:"⋟",curlyvee:"⋎",curlywedge:"⋏",curren:"¤",curvearrowleft:"↶",curvearrowright:"↷",cuvee:"⋎",cuwed:"⋏",cwconint:"∲",cwint:"∱",cylcty:"⌭",dagger:"†",Dagger:"‡",daleth:"ℸ",darr:"↓",dArr:"⇓",Darr:"↡",dash:"‐",dashv:"⊣",Dashv:"⫤",dbkarow:"⤏",dblac:"˝",dcaron:"ď",Dcaron:"Ď",dcy:"д",Dcy:"Д",dd:"ⅆ",DD:"ⅅ",ddagger:"‡",ddarr:"⇊",DDotrahd:"⤑",ddotseq:"⩷",deg:"°",Del:"∇",delta:"δ",Delta:"Δ",demptyv:"⦱",dfisht:"⥿",dfr:"𝔡",Dfr:"𝔇",dHar:"⥥",dharl:"⇃",dharr:"⇂",DiacriticalAcute:"´",DiacriticalDot:"˙",DiacriticalDoubleAcute:"˝",DiacriticalGrave:"`",DiacriticalTilde:"˜",diam:"⋄",diamond:"⋄",Diamond:"⋄",diamondsuit:"♦",diams:"♦",die:"¨",DifferentialD:"ⅆ",digamma:"ϝ",disin:"⋲",div:"÷",divide:"÷",divideontimes:"⋇",divonx:"⋇",djcy:"ђ",DJcy:"Ђ",dlcorn:"⌞",dlcrop:"⌍",dollar:"$",dopf:"𝕕",Dopf:"𝔻",dot:"˙",Dot:"¨",DotDot:"⃜",doteq:"≐",doteqdot:"≑",DotEqual:"≐",dotminus:"∸",dotplus:"∔",dotsquare:"⊡",doublebarwedge:"⌆",DoubleContourIntegral:"∯",DoubleDot:"¨",DoubleDownArrow:"⇓",DoubleLeftArrow:"⇐",DoubleLeftRightArrow:"⇔",DoubleLeftTee:"⫤",DoubleLongLeftArrow:"⟸",DoubleLongLeftRightArrow:"⟺",DoubleLongRightArrow:"⟹",DoubleRightArrow:"⇒",DoubleRightTee:"⊨",DoubleUpArrow:"⇑",DoubleUpDownArrow:"⇕",DoubleVerticalBar:"∥",downarrow:"↓",Downarrow:"⇓",DownArrow:"↓",DownArrowBar:"⤓",DownArrowUpArrow:"⇵",DownBreve:"̑",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",DownLeftRightVector:"⥐",DownLeftTeeVector:"⥞",DownLeftVector:"↽",DownLeftVectorBar:"⥖",DownRightTeeVector:"⥟",DownRightVector:"⇁",DownRightVectorBar:"⥗",DownTee:"⊤",DownTeeArrow:"↧",drbkarow:"⤐",drcorn:"⌟",drcrop:"⌌",dscr:"𝒹",Dscr:"𝒟",dscy:"ѕ",DScy:"Ѕ",dsol:"⧶",dstrok:"đ",Dstrok:"Đ",dtdot:"⋱",dtri:"▿",dtrif:"▾",duarr:"⇵",duhar:"⥯",dwangle:"⦦",dzcy:"џ",DZcy:"Џ",dzigrarr:"⟿",eacute:"é",Eacute:"É",easter:"⩮",ecaron:"ě",Ecaron:"Ě",ecir:"≖",ecirc:"ê",Ecirc:"Ê",ecolon:"≕",ecy:"э",Ecy:"Э",eDDot:"⩷",edot:"ė",eDot:"≑",Edot:"Ė",ee:"ⅇ",efDot:"≒",efr:"𝔢",Efr:"𝔈",eg:"⪚",egrave:"è",Egrave:"È",egs:"⪖",egsdot:"⪘",el:"⪙",Element:"∈",elinters:"⏧",ell:"ℓ",els:"⪕",elsdot:"⪗",emacr:"ē",Emacr:"Ē",empty:"∅",emptyset:"∅",EmptySmallSquare:"◻",emptyv:"∅",EmptyVerySmallSquare:"▫",emsp:" ",emsp13:" ",emsp14:" ",eng:"ŋ",ENG:"Ŋ",ensp:" ",eogon:"ę",Eogon:"Ę",eopf:"𝕖",Eopf:"𝔼",epar:"⋕",eparsl:"⧣",eplus:"⩱",epsi:"ε",epsilon:"ε",Epsilon:"Ε",epsiv:"ϵ",eqcirc:"≖",eqcolon:"≕",eqsim:"≂",eqslantgtr:"⪖",eqslantless:"⪕",Equal:"⩵",equals:"=",EqualTilde:"≂",equest:"≟",Equilibrium:"⇌",equiv:"≡",equivDD:"⩸",eqvparsl:"⧥",erarr:"⥱",erDot:"≓",escr:"ℯ",Escr:"ℰ",esdot:"≐",esim:"≂",Esim:"⩳",eta:"η",Eta:"Η",eth:"ð",ETH:"Ð",euml:"ë",Euml:"Ë",euro:"€",excl:"!",exist:"∃",Exists:"∃",expectation:"ℰ",exponentiale:"ⅇ",ExponentialE:"ⅇ",fallingdotseq:"≒",fcy:"ф",Fcy:"Ф",female:"♀",ffilig:"ffi",fflig:"ff",ffllig:"ffl",ffr:"𝔣",Ffr:"𝔉",filig:"fi",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"fl",fltns:"▱",fnof:"ƒ",fopf:"𝕗",Fopf:"𝔽",forall:"∀",ForAll:"∀",fork:"⋔",forkv:"⫙",Fouriertrf:"ℱ",fpartint:"⨍",frac12:"½",frac13:"⅓",frac14:"¼",frac15:"⅕",frac16:"⅙",frac18:"⅛",frac23:"⅔",frac25:"⅖",frac34:"¾",frac35:"⅗",frac38:"⅜",frac45:"⅘",frac56:"⅚",frac58:"⅝",frac78:"⅞",frasl:"⁄",frown:"⌢",fscr:"𝒻",Fscr:"ℱ",gacute:"ǵ",gamma:"γ",Gamma:"Γ",gammad:"ϝ",Gammad:"Ϝ",gap:"⪆",gbreve:"ğ",Gbreve:"Ğ",Gcedil:"Ģ",gcirc:"ĝ",Gcirc:"Ĝ",gcy:"г",Gcy:"Г",gdot:"ġ",Gdot:"Ġ",ge:"≥",gE:"≧",gel:"⋛",gEl:"⪌",geq:"≥",geqq:"≧",geqslant:"⩾",ges:"⩾",gescc:"⪩",gesdot:"⪀",gesdoto:"⪂",gesdotol:"⪄",gesl:"⋛︀",gesles:"⪔",gfr:"𝔤",Gfr:"𝔊",gg:"≫",Gg:"⋙",ggg:"⋙",gimel:"ℷ",gjcy:"ѓ",GJcy:"Ѓ",gl:"≷",gla:"⪥",glE:"⪒",glj:"⪤",gnap:"⪊",gnapprox:"⪊",gne:"⪈",gnE:"≩",gneq:"⪈",gneqq:"≩",gnsim:"⋧",gopf:"𝕘",Gopf:"𝔾",grave:"`",GreaterEqual:"≥",GreaterEqualLess:"⋛",GreaterFullEqual:"≧",GreaterGreater:"⪢",GreaterLess:"≷",GreaterSlantEqual:"⩾",GreaterTilde:"≳",gscr:"ℊ",Gscr:"𝒢",gsim:"≳",gsime:"⪎",gsiml:"⪐",gt:">",Gt:"≫",GT:">",gtcc:"⪧",gtcir:"⩺",gtdot:"⋗",gtlPar:"⦕",gtquest:"⩼",gtrapprox:"⪆",gtrarr:"⥸",gtrdot:"⋗",gtreqless:"⋛",gtreqqless:"⪌",gtrless:"≷",gtrsim:"≳",gvertneqq:"≩︀",gvnE:"≩︀",Hacek:"ˇ",hairsp:" ",half:"½",hamilt:"ℋ",hardcy:"ъ",HARDcy:"Ъ",harr:"↔",hArr:"⇔",harrcir:"⥈",harrw:"↭",Hat:"^",hbar:"ℏ",hcirc:"ĥ",Hcirc:"Ĥ",hearts:"♥",heartsuit:"♥",hellip:"…",hercon:"⊹",hfr:"𝔥",Hfr:"ℌ",HilbertSpace:"ℋ",hksearow:"⤥",hkswarow:"⤦",hoarr:"⇿",homtht:"∻",hookleftarrow:"↩",hookrightarrow:"↪",hopf:"𝕙",Hopf:"ℍ",horbar:"―",HorizontalLine:"─",hscr:"𝒽",Hscr:"ℋ",hslash:"ℏ",hstrok:"ħ",Hstrok:"Ħ",HumpDownHump:"≎",HumpEqual:"≏",hybull:"⁃",hyphen:"‐",iacute:"í",Iacute:"Í",ic:"⁣",icirc:"î",Icirc:"Î",icy:"и",Icy:"И",Idot:"İ",iecy:"е",IEcy:"Е",iexcl:"¡",iff:"⇔",ifr:"𝔦",Ifr:"ℑ",igrave:"ì",Igrave:"Ì",ii:"ⅈ",iiiint:"⨌",iiint:"∭",iinfin:"⧜",iiota:"℩",ijlig:"ij",IJlig:"IJ",Im:"ℑ",imacr:"ī",Imacr:"Ī",image:"ℑ",ImaginaryI:"ⅈ",imagline:"ℐ",imagpart:"ℑ",imath:"ı",imof:"⊷",imped:"Ƶ",Implies:"⇒",in:"∈",incare:"℅",infin:"∞",infintie:"⧝",inodot:"ı",int:"∫",Int:"∬",intcal:"⊺",integers:"ℤ",Integral:"∫",intercal:"⊺",Intersection:"⋂",intlarhk:"⨗",intprod:"⨼",InvisibleComma:"⁣",InvisibleTimes:"⁢",iocy:"ё",IOcy:"Ё",iogon:"į",Iogon:"Į",iopf:"𝕚",Iopf:"𝕀",iota:"ι",Iota:"Ι",iprod:"⨼",iquest:"¿",iscr:"𝒾",Iscr:"ℐ",isin:"∈",isindot:"⋵",isinE:"⋹",isins:"⋴",isinsv:"⋳",isinv:"∈",it:"⁢",itilde:"ĩ",Itilde:"Ĩ",iukcy:"і",Iukcy:"І",iuml:"ï",Iuml:"Ï",jcirc:"ĵ",Jcirc:"Ĵ",jcy:"й",Jcy:"Й",jfr:"𝔧",Jfr:"𝔍",jmath:"ȷ",jopf:"𝕛",Jopf:"𝕁",jscr:"𝒿",Jscr:"𝒥",jsercy:"ј",Jsercy:"Ј",jukcy:"є",Jukcy:"Є",kappa:"κ",Kappa:"Κ",kappav:"ϰ",kcedil:"ķ",Kcedil:"Ķ",kcy:"к",Kcy:"К",kfr:"𝔨",Kfr:"𝔎",kgreen:"ĸ",khcy:"х",KHcy:"Х",kjcy:"ќ",KJcy:"Ќ",kopf:"𝕜",Kopf:"𝕂",kscr:"𝓀",Kscr:"𝒦",lAarr:"⇚",lacute:"ĺ",Lacute:"Ĺ",laemptyv:"⦴",lagran:"ℒ",lambda:"λ",Lambda:"Λ",lang:"⟨",Lang:"⟪",langd:"⦑",langle:"⟨",lap:"⪅",Laplacetrf:"ℒ",laquo:"«",larr:"←",lArr:"⇐",Larr:"↞",larrb:"⇤",larrbfs:"⤟",larrfs:"⤝",larrhk:"↩",larrlp:"↫",larrpl:"⤹",larrsim:"⥳",larrtl:"↢",lat:"⪫",latail:"⤙",lAtail:"⤛",late:"⪭",lates:"⪭︀",lbarr:"⤌",lBarr:"⤎",lbbrk:"❲",lbrace:"{",lbrack:"[",lbrke:"⦋",lbrksld:"⦏",lbrkslu:"⦍",lcaron:"ľ",Lcaron:"Ľ",lcedil:"ļ",Lcedil:"Ļ",lceil:"⌈",lcub:"{",lcy:"л",Lcy:"Л",ldca:"⤶",ldquo:"“",ldquor:"„",ldrdhar:"⥧",ldrushar:"⥋",ldsh:"↲",le:"≤",lE:"≦",LeftAngleBracket:"⟨",leftarrow:"←",Leftarrow:"⇐",LeftArrow:"←",LeftArrowBar:"⇤",LeftArrowRightArrow:"⇆",leftarrowtail:"↢",LeftCeiling:"⌈",LeftDoubleBracket:"⟦",LeftDownTeeVector:"⥡",LeftDownVector:"⇃",LeftDownVectorBar:"⥙",LeftFloor:"⌊",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",leftrightarrow:"↔",Leftrightarrow:"⇔",LeftRightArrow:"↔",leftrightarrows:"⇆",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",LeftRightVector:"⥎",LeftTee:"⊣",LeftTeeArrow:"↤",LeftTeeVector:"⥚",leftthreetimes:"⋋",LeftTriangle:"⊲",LeftTriangleBar:"⧏",LeftTriangleEqual:"⊴",LeftUpDownVector:"⥑",LeftUpTeeVector:"⥠",LeftUpVector:"↿",LeftUpVectorBar:"⥘",LeftVector:"↼",LeftVectorBar:"⥒",leg:"⋚",lEg:"⪋",leq:"≤",leqq:"≦",leqslant:"⩽",les:"⩽",lescc:"⪨",lesdot:"⩿",lesdoto:"⪁",lesdotor:"⪃",lesg:"⋚︀",lesges:"⪓",lessapprox:"⪅",lessdot:"⋖",lesseqgtr:"⋚",lesseqqgtr:"⪋",LessEqualGreater:"⋚",LessFullEqual:"≦",LessGreater:"≶",lessgtr:"≶",LessLess:"⪡",lesssim:"≲",LessSlantEqual:"⩽",LessTilde:"≲",lfisht:"⥼",lfloor:"⌊",lfr:"𝔩",Lfr:"𝔏",lg:"≶",lgE:"⪑",lHar:"⥢",lhard:"↽",lharu:"↼",lharul:"⥪",lhblk:"▄",ljcy:"љ",LJcy:"Љ",ll:"≪",Ll:"⋘",llarr:"⇇",llcorner:"⌞",Lleftarrow:"⇚",llhard:"⥫",lltri:"◺",lmidot:"ŀ",Lmidot:"Ŀ",lmoust:"⎰",lmoustache:"⎰",lnap:"⪉",lnapprox:"⪉",lne:"⪇",lnE:"≨",lneq:"⪇",lneqq:"≨",lnsim:"⋦",loang:"⟬",loarr:"⇽",lobrk:"⟦",longleftarrow:"⟵",Longleftarrow:"⟸",LongLeftArrow:"⟵",longleftrightarrow:"⟷",Longleftrightarrow:"⟺",LongLeftRightArrow:"⟷",longmapsto:"⟼",longrightarrow:"⟶",Longrightarrow:"⟹",LongRightArrow:"⟶",looparrowleft:"↫",looparrowright:"↬",lopar:"⦅",lopf:"𝕝",Lopf:"𝕃",loplus:"⨭",lotimes:"⨴",lowast:"∗",lowbar:"_",LowerLeftArrow:"↙",LowerRightArrow:"↘",loz:"◊",lozenge:"◊",lozf:"⧫",lpar:"(",lparlt:"⦓",lrarr:"⇆",lrcorner:"⌟",lrhar:"⇋",lrhard:"⥭",lrm:"‎",lrtri:"⊿",lsaquo:"‹",lscr:"𝓁",Lscr:"ℒ",lsh:"↰",Lsh:"↰",lsim:"≲",lsime:"⪍",lsimg:"⪏",lsqb:"[",lsquo:"‘",lsquor:"‚",lstrok:"ł",Lstrok:"Ł",lt:"<",Lt:"≪",LT:"<",ltcc:"⪦",ltcir:"⩹",ltdot:"⋖",lthree:"⋋",ltimes:"⋉",ltlarr:"⥶",ltquest:"⩻",ltri:"◃",ltrie:"⊴",ltrif:"◂",ltrPar:"⦖",lurdshar:"⥊",luruhar:"⥦",lvertneqq:"≨︀",lvnE:"≨︀",macr:"¯",male:"♂",malt:"✠",maltese:"✠",map:"↦",Map:"⤅",mapsto:"↦",mapstodown:"↧",mapstoleft:"↤",mapstoup:"↥",marker:"▮",mcomma:"⨩",mcy:"м",Mcy:"М",mdash:"—",mDDot:"∺",measuredangle:"∡",MediumSpace:" ",Mellintrf:"ℳ",mfr:"𝔪",Mfr:"𝔐",mho:"℧",micro:"µ",mid:"∣",midast:"*",midcir:"⫰",middot:"·",minus:"−",minusb:"⊟",minusd:"∸",minusdu:"⨪",MinusPlus:"∓",mlcp:"⫛",mldr:"…",mnplus:"∓",models:"⊧",mopf:"𝕞",Mopf:"𝕄",mp:"∓",mscr:"𝓂",Mscr:"ℳ",mstpos:"∾",mu:"μ",Mu:"Μ",multimap:"⊸",mumap:"⊸",nabla:"∇",nacute:"ń",Nacute:"Ń",nang:"∠⃒",nap:"≉",napE:"⩰̸",napid:"≋̸",napos:"ʼn",napprox:"≉",natur:"♮",natural:"♮",naturals:"ℕ",nbsp:" ",nbump:"≎̸",nbumpe:"≏̸",ncap:"⩃",ncaron:"ň",Ncaron:"Ň",ncedil:"ņ",Ncedil:"Ņ",ncong:"≇",ncongdot:"⩭̸",ncup:"⩂",ncy:"н",Ncy:"Н",ndash:"–",ne:"≠",nearhk:"⤤",nearr:"↗",neArr:"⇗",nearrow:"↗",nedot:"≐̸",NegativeMediumSpace:"​",NegativeThickSpace:"​",NegativeThinSpace:"​",NegativeVeryThinSpace:"​",nequiv:"≢",nesear:"⤨",nesim:"≂̸",NestedGreaterGreater:"≫",NestedLessLess:"≪",NewLine:"\n",nexist:"∄",nexists:"∄",nfr:"𝔫",Nfr:"𝔑",nge:"≱",ngE:"≧̸",ngeq:"≱",ngeqq:"≧̸",ngeqslant:"⩾̸",nges:"⩾̸",nGg:"⋙̸",ngsim:"≵",ngt:"≯",nGt:"≫⃒",ngtr:"≯",nGtv:"≫̸",nharr:"↮",nhArr:"⇎",nhpar:"⫲",ni:"∋",nis:"⋼",nisd:"⋺",niv:"∋",njcy:"њ",NJcy:"Њ",nlarr:"↚",nlArr:"⇍",nldr:"‥",nle:"≰",nlE:"≦̸",nleftarrow:"↚",nLeftarrow:"⇍",nleftrightarrow:"↮",nLeftrightarrow:"⇎",nleq:"≰",nleqq:"≦̸",nleqslant:"⩽̸",nles:"⩽̸",nless:"≮",nLl:"⋘̸",nlsim:"≴",nlt:"≮",nLt:"≪⃒",nltri:"⋪",nltrie:"⋬",nLtv:"≪̸",nmid:"∤",NoBreak:"⁠",NonBreakingSpace:" ",nopf:"𝕟",Nopf:"ℕ",not:"¬",Not:"⫬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",notin:"∉",notindot:"⋵̸",notinE:"⋹̸",notinva:"∉",notinvb:"⋷",notinvc:"⋶",NotLeftTriangle:"⋪",NotLeftTriangleBar:"⧏̸",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",notni:"∌",notniva:"∌",notnivb:"⋾",notnivc:"⋽",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangle:"⋫",NotRightTriangleBar:"⧐̸",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",npar:"∦",nparallel:"∦",nparsl:"⫽⃥",npart:"∂̸",npolint:"⨔",npr:"⊀",nprcue:"⋠",npre:"⪯̸",nprec:"⊀",npreceq:"⪯̸",nrarr:"↛",nrArr:"⇏",nrarrc:"⤳̸",nrarrw:"↝̸",nrightarrow:"↛",nRightarrow:"⇏",nrtri:"⋫",nrtrie:"⋭",nsc:"⊁",nsccue:"⋡",nsce:"⪰̸",nscr:"𝓃",Nscr:"𝒩",nshortmid:"∤",nshortparallel:"∦",nsim:"≁",nsime:"≄",nsimeq:"≄",nsmid:"∤",nspar:"∦",nsqsube:"⋢",nsqsupe:"⋣",nsub:"⊄",nsube:"⊈",nsubE:"⫅̸",nsubset:"⊂⃒",nsubseteq:"⊈",nsubseteqq:"⫅̸",nsucc:"⊁",nsucceq:"⪰̸",nsup:"⊅",nsupe:"⊉",nsupE:"⫆̸",nsupset:"⊃⃒",nsupseteq:"⊉",nsupseteqq:"⫆̸",ntgl:"≹",ntilde:"ñ",Ntilde:"Ñ",ntlg:"≸",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",nu:"ν",Nu:"Ν",num:"#",numero:"№",numsp:" ",nvap:"≍⃒",nvdash:"⊬",nvDash:"⊭",nVdash:"⊮",nVDash:"⊯",nvge:"≥⃒",nvgt:">⃒",nvHarr:"⤄",nvinfin:"⧞",nvlArr:"⤂",nvle:"≤⃒",nvlt:"<⃒",nvltrie:"⊴⃒",nvrArr:"⤃",nvrtrie:"⊵⃒",nvsim:"∼⃒",nwarhk:"⤣",nwarr:"↖",nwArr:"⇖",nwarrow:"↖",nwnear:"⤧",oacute:"ó",Oacute:"Ó",oast:"⊛",ocir:"⊚",ocirc:"ô",Ocirc:"Ô",ocy:"о",Ocy:"О",odash:"⊝",odblac:"ő",Odblac:"Ő",odiv:"⨸",odot:"⊙",odsold:"⦼",oelig:"œ",OElig:"Œ",ofcir:"⦿",ofr:"𝔬",Ofr:"𝔒",ogon:"˛",ograve:"ò",Ograve:"Ò",ogt:"⧁",ohbar:"⦵",ohm:"Ω",oint:"∮",olarr:"↺",olcir:"⦾",olcross:"⦻",oline:"‾",olt:"⧀",omacr:"ō",Omacr:"Ō",omega:"ω",Omega:"Ω",omicron:"ο",Omicron:"Ο",omid:"⦶",ominus:"⊖",oopf:"𝕠",Oopf:"𝕆",opar:"⦷",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"‘",operp:"⦹",oplus:"⊕",or:"∨",Or:"⩔",orarr:"↻",ord:"⩝",order:"ℴ",orderof:"ℴ",ordf:"ª",ordm:"º",origof:"⊶",oror:"⩖",orslope:"⩗",orv:"⩛",oS:"Ⓢ",oscr:"ℴ",Oscr:"𝒪",oslash:"ø",Oslash:"Ø",osol:"⊘",otilde:"õ",Otilde:"Õ",otimes:"⊗",Otimes:"⨷",otimesas:"⨶",ouml:"ö",Ouml:"Ö",ovbar:"⌽",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",par:"∥",para:"¶",parallel:"∥",parsim:"⫳",parsl:"⫽",part:"∂",PartialD:"∂",pcy:"п",Pcy:"П",percnt:"%",period:".",permil:"‰",perp:"⊥",pertenk:"‱",pfr:"𝔭",Pfr:"𝔓",phi:"φ",Phi:"Φ",phiv:"ϕ",phmmat:"ℳ",phone:"☎",pi:"π",Pi:"Π",pitchfork:"⋔",piv:"ϖ",planck:"ℏ",planckh:"ℎ",plankv:"ℏ",plus:"+",plusacir:"⨣",plusb:"⊞",pluscir:"⨢",plusdo:"∔",plusdu:"⨥",pluse:"⩲",PlusMinus:"±",plusmn:"±",plussim:"⨦",plustwo:"⨧",pm:"±",Poincareplane:"ℌ",pointint:"⨕",popf:"𝕡",Popf:"ℙ",pound:"£",pr:"≺",Pr:"⪻",prap:"⪷",prcue:"≼",pre:"⪯",prE:"⪳",prec:"≺",precapprox:"⪷",preccurlyeq:"≼",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",preceq:"⪯",precnapprox:"⪹",precneqq:"⪵",precnsim:"⋨",precsim:"≾",prime:"′",Prime:"″",primes:"ℙ",prnap:"⪹",prnE:"⪵",prnsim:"⋨",prod:"∏",Product:"∏",profalar:"⌮",profline:"⌒",profsurf:"⌓",prop:"∝",Proportion:"∷",Proportional:"∝",propto:"∝",prsim:"≾",prurel:"⊰",pscr:"𝓅",Pscr:"𝒫",psi:"ψ",Psi:"Ψ",puncsp:" ",qfr:"𝔮",Qfr:"𝔔",qint:"⨌",qopf:"𝕢",Qopf:"ℚ",qprime:"⁗",qscr:"𝓆",Qscr:"𝒬",quaternions:"ℍ",quatint:"⨖",quest:"?",questeq:"≟",quot:'"',QUOT:'"',rAarr:"⇛",race:"∽̱",racute:"ŕ",Racute:"Ŕ",radic:"√",raemptyv:"⦳",rang:"⟩",Rang:"⟫",rangd:"⦒",range:"⦥",rangle:"⟩",raquo:"»",rarr:"→",rArr:"⇒",Rarr:"↠",rarrap:"⥵",rarrb:"⇥",rarrbfs:"⤠",rarrc:"⤳",rarrfs:"⤞",rarrhk:"↪",rarrlp:"↬",rarrpl:"⥅",rarrsim:"⥴",rarrtl:"↣",Rarrtl:"⤖",rarrw:"↝",ratail:"⤚",rAtail:"⤜",ratio:"∶",rationals:"ℚ",rbarr:"⤍",rBarr:"⤏",RBarr:"⤐",rbbrk:"❳",rbrace:"}",rbrack:"]",rbrke:"⦌",rbrksld:"⦎",rbrkslu:"⦐",rcaron:"ř",Rcaron:"Ř",rcedil:"ŗ",Rcedil:"Ŗ",rceil:"⌉",rcub:"}",rcy:"р",Rcy:"Р",rdca:"⤷",rdldhar:"⥩",rdquo:"”",rdquor:"”",rdsh:"↳",Re:"ℜ",real:"ℜ",realine:"ℛ",realpart:"ℜ",reals:"ℝ",rect:"▭",reg:"®",REG:"®",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",rfisht:"⥽",rfloor:"⌋",rfr:"𝔯",Rfr:"ℜ",rHar:"⥤",rhard:"⇁",rharu:"⇀",rharul:"⥬",rho:"ρ",Rho:"Ρ",rhov:"ϱ",RightAngleBracket:"⟩",rightarrow:"→",Rightarrow:"⇒",RightArrow:"→",RightArrowBar:"⇥",RightArrowLeftArrow:"⇄",rightarrowtail:"↣",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVector:"⇂",RightDownVectorBar:"⥕",RightFloor:"⌋",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇄",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"↝",RightTee:"⊢",RightTeeArrow:"↦",RightTeeVector:"⥛",rightthreetimes:"⋌",RightTriangle:"⊳",RightTriangleBar:"⧐",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVector:"↾",RightUpVectorBar:"⥔",RightVector:"⇀",RightVectorBar:"⥓",ring:"˚",risingdotseq:"≓",rlarr:"⇄",rlhar:"⇌",rlm:"‏",rmoust:"⎱",rmoustache:"⎱",rnmid:"⫮",roang:"⟭",roarr:"⇾",robrk:"⟧",ropar:"⦆",ropf:"𝕣",Ropf:"ℝ",roplus:"⨮",rotimes:"⨵",RoundImplies:"⥰",rpar:")",rpargt:"⦔",rppolint:"⨒",rrarr:"⇉",Rrightarrow:"⇛",rsaquo:"›",rscr:"𝓇",Rscr:"ℛ",rsh:"↱",Rsh:"↱",rsqb:"]",rsquo:"’",rsquor:"’",rthree:"⋌",rtimes:"⋊",rtri:"▹",rtrie:"⊵",rtrif:"▸",rtriltri:"⧎",RuleDelayed:"⧴",ruluhar:"⥨",rx:"℞",sacute:"ś",Sacute:"Ś",sbquo:"‚",sc:"≻",Sc:"⪼",scap:"⪸",scaron:"š",Scaron:"Š",sccue:"≽",sce:"⪰",scE:"⪴",scedil:"ş",Scedil:"Ş",scirc:"ŝ",Scirc:"Ŝ",scnap:"⪺",scnE:"⪶",scnsim:"⋩",scpolint:"⨓",scsim:"≿",scy:"с",Scy:"С",sdot:"⋅",sdotb:"⊡",sdote:"⩦",searhk:"⤥",searr:"↘",seArr:"⇘",searrow:"↘",sect:"§",semi:";",seswar:"⤩",setminus:"∖",setmn:"∖",sext:"✶",sfr:"𝔰",Sfr:"𝔖",sfrown:"⌢",sharp:"♯",shchcy:"щ",SHCHcy:"Щ",shcy:"ш",SHcy:"Ш",ShortDownArrow:"↓",ShortLeftArrow:"←",shortmid:"∣",shortparallel:"∥",ShortRightArrow:"→",ShortUpArrow:"↑",shy:"­",sigma:"σ",Sigma:"Σ",sigmaf:"ς",sigmav:"ς",sim:"∼",simdot:"⩪",sime:"≃",simeq:"≃",simg:"⪞",simgE:"⪠",siml:"⪝",simlE:"⪟",simne:"≆",simplus:"⨤",simrarr:"⥲",slarr:"←",SmallCircle:"∘",smallsetminus:"∖",smashp:"⨳",smeparsl:"⧤",smid:"∣",smile:"⌣",smt:"⪪",smte:"⪬",smtes:"⪬︀",softcy:"ь",SOFTcy:"Ь",sol:"/",solb:"⧄",solbar:"⌿",sopf:"𝕤",Sopf:"𝕊",spades:"♠",spadesuit:"♠",spar:"∥",sqcap:"⊓",sqcaps:"⊓︀",sqcup:"⊔",sqcups:"⊔︀",Sqrt:"√",sqsub:"⊏",sqsube:"⊑",sqsubset:"⊏",sqsubseteq:"⊑",sqsup:"⊐",sqsupe:"⊒",sqsupset:"⊐",sqsupseteq:"⊒",squ:"□",square:"□",Square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",squarf:"▪",squf:"▪",srarr:"→",sscr:"𝓈",Sscr:"𝒮",ssetmn:"∖",ssmile:"⌣",sstarf:"⋆",star:"☆",Star:"⋆",starf:"★",straightepsilon:"ϵ",straightphi:"ϕ",strns:"¯",sub:"⊂",Sub:"⋐",subdot:"⪽",sube:"⊆",subE:"⫅",subedot:"⫃",submult:"⫁",subne:"⊊",subnE:"⫋",subplus:"⪿",subrarr:"⥹",subset:"⊂",Subset:"⋐",subseteq:"⊆",subseteqq:"⫅",SubsetEqual:"⊆",subsetneq:"⊊",subsetneqq:"⫋",subsim:"⫇",subsub:"⫕",subsup:"⫓",succ:"≻",succapprox:"⪸",succcurlyeq:"≽",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",succeq:"⪰",succnapprox:"⪺",succneqq:"⪶",succnsim:"⋩",succsim:"≿",SuchThat:"∋",sum:"∑",Sum:"∑",sung:"♪",sup:"⊃",Sup:"⋑",sup1:"¹",sup2:"²",sup3:"³",supdot:"⪾",supdsub:"⫘",supe:"⊇",supE:"⫆",supedot:"⫄",Superset:"⊃",SupersetEqual:"⊇",suphsol:"⟉",suphsub:"⫗",suplarr:"⥻",supmult:"⫂",supne:"⊋",supnE:"⫌",supplus:"⫀",supset:"⊃",Supset:"⋑",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",supsim:"⫈",supsub:"⫔",supsup:"⫖",swarhk:"⤦",swarr:"↙",swArr:"⇙",swarrow:"↙",swnwar:"⤪",szlig:"ß",Tab:"\t",target:"⌖",tau:"τ",Tau:"Τ",tbrk:"⎴",tcaron:"ť",Tcaron:"Ť",tcedil:"ţ",Tcedil:"Ţ",tcy:"т",Tcy:"Т",tdot:"⃛",telrec:"⌕",tfr:"𝔱",Tfr:"𝔗",there4:"∴",therefore:"∴",Therefore:"∴",theta:"θ",Theta:"Θ",thetasym:"ϑ",thetav:"ϑ",thickapprox:"≈",thicksim:"∼",ThickSpace:"  ",thinsp:" ",ThinSpace:" ",thkap:"≈",thksim:"∼",thorn:"þ",THORN:"Þ",tilde:"˜",Tilde:"∼",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",times:"×",timesb:"⊠",timesbar:"⨱",timesd:"⨰",tint:"∭",toea:"⤨",top:"⊤",topbot:"⌶",topcir:"⫱",topf:"𝕥",Topf:"𝕋",topfork:"⫚",tosa:"⤩",tprime:"‴",trade:"™",TRADE:"™",triangle:"▵",triangledown:"▿",triangleleft:"◃",trianglelefteq:"⊴",triangleq:"≜",triangleright:"▹",trianglerighteq:"⊵",tridot:"◬",trie:"≜",triminus:"⨺",TripleDot:"⃛",triplus:"⨹",trisb:"⧍",tritime:"⨻",trpezium:"⏢",tscr:"𝓉",Tscr:"𝒯",tscy:"ц",TScy:"Ц",tshcy:"ћ",TSHcy:"Ћ",tstrok:"ŧ",Tstrok:"Ŧ",twixt:"≬",twoheadleftarrow:"↞",twoheadrightarrow:"↠",uacute:"ú",Uacute:"Ú",uarr:"↑",uArr:"⇑",Uarr:"↟",Uarrocir:"⥉",ubrcy:"ў",Ubrcy:"Ў",ubreve:"ŭ",Ubreve:"Ŭ",ucirc:"û",Ucirc:"Û",ucy:"у",Ucy:"У",udarr:"⇅",udblac:"ű",Udblac:"Ű",udhar:"⥮",ufisht:"⥾",ufr:"𝔲",Ufr:"𝔘",ugrave:"ù",Ugrave:"Ù",uHar:"⥣",uharl:"↿",uharr:"↾",uhblk:"▀",ulcorn:"⌜",ulcorner:"⌜",ulcrop:"⌏",ultri:"◸",umacr:"ū",Umacr:"Ū",uml:"¨",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"⋃",UnionPlus:"⊎",uogon:"ų",Uogon:"Ų",uopf:"𝕦",Uopf:"𝕌",uparrow:"↑",Uparrow:"⇑",UpArrow:"↑",UpArrowBar:"⤒",UpArrowDownArrow:"⇅",updownarrow:"↕",Updownarrow:"⇕",UpDownArrow:"↕",UpEquilibrium:"⥮",upharpoonleft:"↿",upharpoonright:"↾",uplus:"⊎",UpperLeftArrow:"↖",UpperRightArrow:"↗",upsi:"υ",Upsi:"ϒ",upsih:"ϒ",upsilon:"υ",Upsilon:"Υ",UpTee:"⊥",UpTeeArrow:"↥",upuparrows:"⇈",urcorn:"⌝",urcorner:"⌝",urcrop:"⌎",uring:"ů",Uring:"Ů",urtri:"◹",uscr:"𝓊",Uscr:"𝒰",utdot:"⋰",utilde:"ũ",Utilde:"Ũ",utri:"▵",utrif:"▴",uuarr:"⇈",uuml:"ü",Uuml:"Ü",uwangle:"⦧",vangrt:"⦜",varepsilon:"ϵ",varkappa:"ϰ",varnothing:"∅",varphi:"ϕ",varpi:"ϖ",varpropto:"∝",varr:"↕",vArr:"⇕",varrho:"ϱ",varsigma:"ς",varsubsetneq:"⊊︀",varsubsetneqq:"⫋︀",varsupsetneq:"⊋︀",varsupsetneqq:"⫌︀",vartheta:"ϑ",vartriangleleft:"⊲",vartriangleright:"⊳",vBar:"⫨",Vbar:"⫫",vBarv:"⫩",vcy:"в",Vcy:"В",vdash:"⊢",vDash:"⊨",Vdash:"⊩",VDash:"⊫",Vdashl:"⫦",vee:"∨",Vee:"⋁",veebar:"⊻",veeeq:"≚",vellip:"⋮",verbar:"|",Verbar:"‖",vert:"|",Vert:"‖",VerticalBar:"∣",VerticalLine:"|",VerticalSeparator:"❘",VerticalTilde:"≀",VeryThinSpace:" ",vfr:"𝔳",Vfr:"𝔙",vltri:"⊲",vnsub:"⊂⃒",vnsup:"⊃⃒",vopf:"𝕧",Vopf:"𝕍",vprop:"∝",vrtri:"⊳",vscr:"𝓋",Vscr:"𝒱",vsubne:"⊊︀",vsubnE:"⫋︀",vsupne:"⊋︀",vsupnE:"⫌︀",Vvdash:"⊪",vzigzag:"⦚",wcirc:"ŵ",Wcirc:"Ŵ",wedbar:"⩟",wedge:"∧",Wedge:"⋀",wedgeq:"≙",weierp:"℘",wfr:"𝔴",Wfr:"𝔚",wopf:"𝕨",Wopf:"𝕎",wp:"℘",wr:"≀",wreath:"≀",wscr:"𝓌",Wscr:"𝒲",xcap:"⋂",xcirc:"◯",xcup:"⋃",xdtri:"▽",xfr:"𝔵",Xfr:"𝔛",xharr:"⟷",xhArr:"⟺",xi:"ξ",Xi:"Ξ",xlarr:"⟵",xlArr:"⟸",xmap:"⟼",xnis:"⋻",xodot:"⨀",xopf:"𝕩",Xopf:"𝕏",xoplus:"⨁",xotime:"⨂",xrarr:"⟶",xrArr:"⟹",xscr:"𝓍",Xscr:"𝒳",xsqcup:"⨆",xuplus:"⨄",xutri:"△",xvee:"⋁",xwedge:"⋀",yacute:"ý",Yacute:"Ý",yacy:"я",YAcy:"Я",ycirc:"ŷ",Ycirc:"Ŷ",ycy:"ы",Ycy:"Ы",yen:"¥",yfr:"𝔶",Yfr:"𝔜",yicy:"ї",YIcy:"Ї",yopf:"𝕪",Yopf:"𝕐",yscr:"𝓎",Yscr:"𝒴",yucy:"ю",YUcy:"Ю",yuml:"ÿ",Yuml:"Ÿ",zacute:"ź",Zacute:"Ź",zcaron:"ž",Zcaron:"Ž",zcy:"з",Zcy:"З",zdot:"ż",Zdot:"Ż",zeetrf:"ℨ",ZeroWidthSpace:"​",zeta:"ζ",Zeta:"Ζ",zfr:"𝔷",Zfr:"ℨ",zhcy:"ж",ZHcy:"Ж",zigrarr:"⇝",zopf:"𝕫",Zopf:"ℤ",zscr:"𝓏",Zscr:"𝒵",zwj:"‍",zwnj:"‌"},b={aacute:"á",Aacute:"Á",acirc:"â",Acirc:"Â",acute:"´",aelig:"æ",AElig:"Æ",agrave:"à",Agrave:"À",amp:"&",AMP:"&",aring:"å",Aring:"Å",atilde:"ã",Atilde:"Ã",auml:"ä",Auml:"Ä",brvbar:"¦",ccedil:"ç",Ccedil:"Ç",cedil:"¸",cent:"¢",copy:"©",COPY:"©",curren:"¤",deg:"°",divide:"÷",eacute:"é",Eacute:"É",ecirc:"ê",Ecirc:"Ê",egrave:"è",Egrave:"È",eth:"ð",ETH:"Ð",euml:"ë",Euml:"Ë",frac12:"½",frac14:"¼",frac34:"¾",gt:">",GT:">",iacute:"í",Iacute:"Í",icirc:"î",Icirc:"Î",iexcl:"¡",igrave:"ì",Igrave:"Ì",iquest:"¿",iuml:"ï",Iuml:"Ï",laquo:"«",lt:"<",LT:"<",macr:"¯",micro:"µ",middot:"·",nbsp:" ",not:"¬",ntilde:"ñ",Ntilde:"Ñ",oacute:"ó",Oacute:"Ó",ocirc:"ô",Ocirc:"Ô",ograve:"ò",Ograve:"Ò",ordf:"ª",ordm:"º",oslash:"ø",Oslash:"Ø",otilde:"õ",Otilde:"Õ",ouml:"ö",Ouml:"Ö",para:"¶",plusmn:"±",pound:"£",quot:'"',QUOT:'"',raquo:"»",reg:"®",REG:"®",sect:"§",shy:"­",sup1:"¹",sup2:"²",sup3:"³",szlig:"ß",thorn:"þ",THORN:"Þ",times:"×",uacute:"ú",Uacute:"Ú",ucirc:"û",Ucirc:"Û",ugrave:"ù",Ugrave:"Ù",uml:"¨",uuml:"ü",Uuml:"Ü",yacute:"ý",Yacute:"Ý",yen:"¥",yuml:"ÿ"},y={0:"�",128:"€",130:"‚",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ",137:"‰",138:"Š",139:"‹",140:"Œ",142:"Ž",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—",152:"˜",153:"™",154:"š",155:"›",156:"œ",158:"ž",159:"Ÿ"},w=[1,2,3,4,5,6,7,8,11,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,64976,64977,64978,64979,64980,64981,64982,64983,64984,64985,64986,64987,64988,64989,64990,64991,64992,64993,64994,64995,64996,64997,64998,64999,65e3,65001,65002,65003,65004,65005,65006,65007,65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111],_=String.fromCharCode,x={}.hasOwnProperty,E=function(e,t){return x.call(e,t)},A=function(e,t){if(!e)return t;var r,n={};for(r in t)n[r]=E(e,r)?e[r]:t[r];return n},D=function(e,t){var r="";return e>=55296&&e<=57343||e>1114111?(t&&C("character reference outside the permissible Unicode range"),"�"):E(y,e)?(t&&C("disallowed character reference"),y[e]):(t&&function(e,t){for(var r=-1,n=e.length;++r65535&&(r+=_((e-=65536)>>>10&1023|55296),e=56320|1023&e),r+=_(e))},T=function(e){return"&#x"+e.toString(16).toUpperCase()+";"},q=function(e){return"&#"+e+";"},C=function(e){throw Error("Parse error: "+e)},k=function(e,t){(t=A(t,k.options)).strict&&g.test(e)&&C("forbidden code point");var r=t.encodeEverything,n=t.useNamedReferences,i=t.allowUnsafeSymbols,o=t.decimal?q:T,s=function(e){return o(e.charCodeAt(0))};return r?(e=e.replace(l,(function(e){return n&&E(p,e)?"&"+p[e]+";":s(e)})),n&&(e=e.replace(/>\u20D2/g,">⃒").replace(/<\u20D2/g,"<⃒").replace(/fj/g,"fj")),n&&(e=e.replace(u,(function(e){return"&"+p[e]+";"})))):n?(i||(e=e.replace(d,(function(e){return"&"+p[e]+";"}))),e=(e=e.replace(/>\u20D2/g,">⃒").replace(/<\u20D2/g,"<⃒")).replace(u,(function(e){return"&"+p[e]+";"}))):i||(e=e.replace(d,s)),e.replace(a,(function(e){var t=e.charCodeAt(0),r=e.charCodeAt(1);return o(1024*(t-55296)+r-56320+65536)})).replace(c,s)};k.options={allowUnsafeSymbols:!1,encodeEverything:!1,strict:!1,useNamedReferences:!1,decimal:!1};var S=function(e,t){var r=(t=A(t,S.options)).strict;return r&&h.test(e)&&C("malformed character reference"),e.replace(m,(function(e,n,i,o,s,a,l,c,u){var p,d,f,h,g,m;return n?v[g=n]:i?(g=i,(m=o)&&t.isAttributeValue?(r&&"="==m&&C("`&` did not start a character reference"),e):(r&&C("named character reference was not terminated by a semicolon"),b[g]+(m||""))):s?(f=s,d=a,r&&!d&&C("character reference was not terminated by a semicolon"),p=parseInt(f,10),D(p,r)):l?(h=l,d=c,r&&!d&&C("character reference was not terminated by a semicolon"),p=parseInt(h,16),D(p,r)):(r&&C("named character reference was not terminated by a semicolon"),e)}))};S.options={isAttributeValue:!1,strict:!1};var L={version:"1.2.0",encode:k,decode:S,escape:function(e){return e.replace(d,(function(e){return f[e]}))},unescape:S};void 0===(n=function(){return L}.call(t,r,t,e))||(e.exports=n)}()},755:function(e,t){var r;!function(t,r){"use strict";"object"==typeof e.exports?e.exports=t.document?r(t,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return r(e)}:r(t)}("undefined"!=typeof window?window:this,(function(n,i){"use strict";var o=[],s=Object.getPrototypeOf,a=o.slice,l=o.flat?function(e){return o.flat.call(e)}:function(e){return o.concat.apply([],e)},c=o.push,u=o.indexOf,p={},d=p.toString,f=p.hasOwnProperty,h=f.toString,g=h.call(Object),m={},v=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType&&"function"!=typeof e.item},b=function(e){return null!=e&&e===e.window},y=n.document,w={type:!0,src:!0,nonce:!0,noModule:!0};function _(e,t,r){var n,i,o=(r=r||y).createElement("script");if(o.text=e,t)for(n in w)(i=t[n]||t.getAttribute&&t.getAttribute(n))&&o.setAttribute(n,i);r.head.appendChild(o).parentNode.removeChild(o)}function x(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?p[d.call(e)]||"object":typeof e}var E="3.7.1",A=/HTML$/i,D=function(e,t){return new D.fn.init(e,t)};function T(e){var t=!!e&&"length"in e&&e.length,r=x(e);return!v(e)&&!b(e)&&("array"===r||0===t||"number"==typeof t&&t>0&&t-1 in e)}function q(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}D.fn=D.prototype={jquery:E,constructor:D,length:0,toArray:function(){return a.call(this)},get:function(e){return null==e?a.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=D.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return D.each(this,e)},map:function(e){return this.pushStack(D.map(this,(function(t,r){return e.call(t,r,t)})))},slice:function(){return this.pushStack(a.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(D.grep(this,(function(e,t){return(t+1)%2})))},odd:function(){return this.pushStack(D.grep(this,(function(e,t){return t%2})))},eq:function(e){var t=this.length,r=+e+(e<0?t:0);return this.pushStack(r>=0&&r+~]|"+L+")"+L+"*"),M=new RegExp(L+"|>"),U=new RegExp(F),V=new RegExp("^"+O+"$"),$={ID:new RegExp("^#("+O+")"),CLASS:new RegExp("^\\.("+O+")"),TAG:new RegExp("^("+O+"|[*])"),ATTR:new RegExp("^"+j),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+L+"*(even|odd|(([+-]|)(\\d*)n|)"+L+"*(?:([+-]|)"+L+"*(\\d+)|))"+L+"*\\)|)","i"),bool:new RegExp("^(?:"+T+")$","i"),needsContext:new RegExp("^"+L+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+L+"*((?:-\\d)?\\d*)"+L+"*\\)|)(?=[^-]|$)","i")},z=/^(?:input|select|textarea|button)$/i,G=/^h\d$/i,W=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,Y=/[+~]/,X=new RegExp("\\\\[\\da-fA-F]{1,6}"+L+"?|\\\\([^\\r\\n\\f])","g"),K=function(e,t){var r="0x"+e.slice(1)-65536;return t||(r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320))},J=function(){le()},Q=de((function(e){return!0===e.disabled&&q(e,"fieldset")}),{dir:"parentNode",next:"legend"});try{g.apply(o=a.call(R.childNodes),R.childNodes),o[R.childNodes.length].nodeType}catch(e){g={apply:function(e,t){B.apply(e,a.call(t))},call:function(e){B.apply(e,a.call(arguments,1))}}}function Z(e,t,r,n){var i,o,s,a,c,u,f,h=t&&t.ownerDocument,b=t?t.nodeType:9;if(r=r||[],"string"!=typeof e||!e||1!==b&&9!==b&&11!==b)return r;if(!n&&(le(t),t=t||l,p)){if(11!==b&&(c=W.exec(e)))if(i=c[1]){if(9===b){if(!(s=t.getElementById(i)))return r;if(s.id===i)return g.call(r,s),r}else if(h&&(s=h.getElementById(i))&&Z.contains(t,s)&&s.id===i)return g.call(r,s),r}else{if(c[2])return g.apply(r,t.getElementsByTagName(e)),r;if((i=c[3])&&t.getElementsByClassName)return g.apply(r,t.getElementsByClassName(i)),r}if(!(E[e+" "]||d&&d.test(e))){if(f=e,h=t,1===b&&(M.test(e)||H.test(e))){for((h=Y.test(e)&&ae(t.parentNode)||t)==t&&m.scope||((a=t.getAttribute("id"))?a=D.escapeSelector(a):t.setAttribute("id",a=v)),o=(u=ue(e)).length;o--;)u[o]=(a?"#"+a:":scope")+" "+pe(u[o]);f=u.join(",")}try{return g.apply(r,h.querySelectorAll(f)),r}catch(t){E(e,!0)}finally{a===v&&t.removeAttribute("id")}}}return be(e.replace(N,"$1"),t,r,n)}function ee(){var e=[];return function r(n,i){return e.push(n+" ")>t.cacheLength&&delete r[e.shift()],r[n+" "]=i}}function te(e){return e[v]=!0,e}function re(e){var t=l.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function ne(e){return function(t){return q(t,"input")&&t.type===e}}function ie(e){return function(t){return(q(t,"input")||q(t,"button"))&&t.type===e}}function oe(e){return function(t){return"form"in t?t.parentNode&&!1===t.disabled?"label"in t?"label"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&Q(t)===e:t.disabled===e:"label"in t&&t.disabled===e}}function se(e){return te((function(t){return t=+t,te((function(r,n){for(var i,o=e([],r.length,t),s=o.length;s--;)r[i=o[s]]&&(r[i]=!(n[i]=r[i]))}))}))}function ae(e){return e&&void 0!==e.getElementsByTagName&&e}function le(e){var r,n=e?e.ownerDocument||e:R;return n!=l&&9===n.nodeType&&n.documentElement?(c=(l=n).documentElement,p=!D.isXMLDoc(l),h=c.matches||c.webkitMatchesSelector||c.msMatchesSelector,c.msMatchesSelector&&R!=l&&(r=l.defaultView)&&r.top!==r&&r.addEventListener("unload",J),m.getById=re((function(e){return c.appendChild(e).id=D.expando,!l.getElementsByName||!l.getElementsByName(D.expando).length})),m.disconnectedMatch=re((function(e){return h.call(e,"*")})),m.scope=re((function(){return l.querySelectorAll(":scope")})),m.cssHas=re((function(){try{return l.querySelector(":has(*,:jqfake)"),!1}catch(e){return!0}})),m.getById?(t.filter.ID=function(e){var t=e.replace(X,K);return function(e){return e.getAttribute("id")===t}},t.find.ID=function(e,t){if(void 0!==t.getElementById&&p){var r=t.getElementById(e);return r?[r]:[]}}):(t.filter.ID=function(e){var t=e.replace(X,K);return function(e){var r=void 0!==e.getAttributeNode&&e.getAttributeNode("id");return r&&r.value===t}},t.find.ID=function(e,t){if(void 0!==t.getElementById&&p){var r,n,i,o=t.getElementById(e);if(o){if((r=o.getAttributeNode("id"))&&r.value===e)return[o];for(i=t.getElementsByName(e),n=0;o=i[n++];)if((r=o.getAttributeNode("id"))&&r.value===e)return[o]}return[]}}),t.find.TAG=function(e,t){return void 0!==t.getElementsByTagName?t.getElementsByTagName(e):t.querySelectorAll(e)},t.find.CLASS=function(e,t){if(void 0!==t.getElementsByClassName&&p)return t.getElementsByClassName(e)},d=[],re((function(e){var t;c.appendChild(e).innerHTML="",e.querySelectorAll("[selected]").length||d.push("\\["+L+"*(?:value|"+T+")"),e.querySelectorAll("[id~="+v+"-]").length||d.push("~="),e.querySelectorAll("a#"+v+"+*").length||d.push(".#.+[+~]"),e.querySelectorAll(":checked").length||d.push(":checked"),(t=l.createElement("input")).setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),c.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&d.push(":enabled",":disabled"),(t=l.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||d.push("\\["+L+"*name"+L+"*="+L+"*(?:''|\"\")")})),m.cssHas||d.push(":has"),d=d.length&&new RegExp(d.join("|")),A=function(e,t){if(e===t)return s=!0,0;var r=!e.compareDocumentPosition-!t.compareDocumentPosition;return r||(1&(r=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!m.sortDetached&&t.compareDocumentPosition(e)===r?e===l||e.ownerDocument==R&&Z.contains(R,e)?-1:t===l||t.ownerDocument==R&&Z.contains(R,t)?1:i?u.call(i,e)-u.call(i,t):0:4&r?-1:1)},l):l}for(e in Z.matches=function(e,t){return Z(e,null,null,t)},Z.matchesSelector=function(e,t){if(le(e),p&&!E[t+" "]&&(!d||!d.test(t)))try{var r=h.call(e,t);if(r||m.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(e){E(t,!0)}return Z(t,l,null,[e]).length>0},Z.contains=function(e,t){return(e.ownerDocument||e)!=l&&le(e),D.contains(e,t)},Z.attr=function(e,r){(e.ownerDocument||e)!=l&&le(e);var n=t.attrHandle[r.toLowerCase()],i=n&&f.call(t.attrHandle,r.toLowerCase())?n(e,r,!p):void 0;return void 0!==i?i:e.getAttribute(r)},Z.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},D.uniqueSort=function(e){var t,r=[],n=0,o=0;if(s=!m.sortStable,i=!m.sortStable&&a.call(e,0),k.call(e,A),s){for(;t=e[o++];)t===e[o]&&(n=r.push(o));for(;n--;)S.call(e,r[n],1)}return i=null,e},D.fn.uniqueSort=function(){return this.pushStack(D.uniqueSort(a.apply(this)))},t=D.expr={cacheLength:50,createPseudo:te,match:$,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(X,K),e[3]=(e[3]||e[4]||e[5]||"").replace(X,K),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||Z.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&Z.error(e[0]),e},PSEUDO:function(e){var t,r=!e[6]&&e[2];return $.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":r&&U.test(r)&&(t=ue(r,!0))&&(t=r.indexOf(")",r.length-t)-r.length)&&(e[0]=e[0].slice(0,t),e[2]=r.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(X,K).toLowerCase();return"*"===e?function(){return!0}:function(e){return q(e,t)}},CLASS:function(e){var t=w[e+" "];return t||(t=new RegExp("(^|"+L+")"+e+"("+L+"|$)"))&&w(e,(function(e){return t.test("string"==typeof e.className&&e.className||void 0!==e.getAttribute&&e.getAttribute("class")||"")}))},ATTR:function(e,t,r){return function(n){var i=Z.attr(n,e);return null==i?"!="===t:!t||(i+="","="===t?i===r:"!="===t?i!==r:"^="===t?r&&0===i.indexOf(r):"*="===t?r&&i.indexOf(r)>-1:"$="===t?r&&i.slice(-r.length)===r:"~="===t?(" "+i.replace(I," ")+" ").indexOf(r)>-1:"|="===t&&(i===r||i.slice(0,r.length+1)===r+"-"))}},CHILD:function(e,t,r,n,i){var o="nth"!==e.slice(0,3),s="last"!==e.slice(-4),a="of-type"===t;return 1===n&&0===i?function(e){return!!e.parentNode}:function(t,r,l){var c,u,p,d,f,h=o!==s?"nextSibling":"previousSibling",g=t.parentNode,m=a&&t.nodeName.toLowerCase(),y=!l&&!a,w=!1;if(g){if(o){for(;h;){for(p=t;p=p[h];)if(a?q(p,m):1===p.nodeType)return!1;f=h="only"===e&&!f&&"nextSibling"}return!0}if(f=[s?g.firstChild:g.lastChild],s&&y){for(w=(d=(c=(u=g[v]||(g[v]={}))[e]||[])[0]===b&&c[1])&&c[2],p=d&&g.childNodes[d];p=++d&&p&&p[h]||(w=d=0)||f.pop();)if(1===p.nodeType&&++w&&p===t){u[e]=[b,d,w];break}}else if(y&&(w=d=(c=(u=t[v]||(t[v]={}))[e]||[])[0]===b&&c[1]),!1===w)for(;(p=++d&&p&&p[h]||(w=d=0)||f.pop())&&(!(a?q(p,m):1===p.nodeType)||!++w||(y&&((u=p[v]||(p[v]={}))[e]=[b,w]),p!==t)););return(w-=i)===n||w%n==0&&w/n>=0}}},PSEUDO:function(e,r){var n,i=t.pseudos[e]||t.setFilters[e.toLowerCase()]||Z.error("unsupported pseudo: "+e);return i[v]?i(r):i.length>1?(n=[e,e,"",r],t.setFilters.hasOwnProperty(e.toLowerCase())?te((function(e,t){for(var n,o=i(e,r),s=o.length;s--;)e[n=u.call(e,o[s])]=!(t[n]=o[s])})):function(e){return i(e,0,n)}):i}},pseudos:{not:te((function(e){var t=[],r=[],n=ve(e.replace(N,"$1"));return n[v]?te((function(e,t,r,i){for(var o,s=n(e,null,i,[]),a=e.length;a--;)(o=s[a])&&(e[a]=!(t[a]=o))})):function(e,i,o){return t[0]=e,n(t,null,o,r),t[0]=null,!r.pop()}})),has:te((function(e){return function(t){return Z(e,t).length>0}})),contains:te((function(e){return e=e.replace(X,K),function(t){return(t.textContent||D.text(t)).indexOf(e)>-1}})),lang:te((function(e){return V.test(e||"")||Z.error("unsupported lang: "+e),e=e.replace(X,K).toLowerCase(),function(t){var r;do{if(r=p?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(r=r.toLowerCase())===e||0===r.indexOf(e+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}})),target:function(e){var t=n.location&&n.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===c},focus:function(e){return e===function(){try{return l.activeElement}catch(e){}}()&&l.hasFocus()&&!!(e.type||e.href||~e.tabIndex)},enabled:oe(!1),disabled:oe(!0),checked:function(e){return q(e,"input")&&!!e.checked||q(e,"option")&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!t.pseudos.empty(e)},header:function(e){return G.test(e.nodeName)},input:function(e){return z.test(e.nodeName)},button:function(e){return q(e,"input")&&"button"===e.type||q(e,"button")},text:function(e){var t;return q(e,"input")&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:se((function(){return[0]})),last:se((function(e,t){return[t-1]})),eq:se((function(e,t,r){return[r<0?r+t:r]})),even:se((function(e,t){for(var r=0;rt?t:r;--n>=0;)e.push(n);return e})),gt:se((function(e,t,r){for(var n=r<0?r+t:r;++n1?function(t,r,n){for(var i=e.length;i--;)if(!e[i](t,r,n))return!1;return!0}:e[0]}function he(e,t,r,n,i){for(var o,s=[],a=0,l=e.length,c=null!=t;a-1&&(o[c]=!(s[c]=d))}}else f=he(f===s?f.splice(v,f.length):f),i?i(null,s,f,l):g.apply(s,f)}))}function me(e){for(var n,i,o,s=e.length,a=t.relative[e[0].type],l=a||t.relative[" "],c=a?1:0,p=de((function(e){return e===n}),l,!0),d=de((function(e){return u.call(n,e)>-1}),l,!0),f=[function(e,t,i){var o=!a&&(i||t!=r)||((n=t).nodeType?p(e,t,i):d(e,t,i));return n=null,o}];c1&&fe(f),c>1&&pe(e.slice(0,c-1).concat({value:" "===e[c-2].type?"*":""})).replace(N,"$1"),i,c0,o=e.length>0,s=function(s,a,c,u,d){var f,h,m,v=0,y="0",w=s&&[],_=[],x=r,E=s||o&&t.find.TAG("*",d),A=b+=null==x?1:Math.random()||.1,T=E.length;for(d&&(r=a==l||a||d);y!==T&&null!=(f=E[y]);y++){if(o&&f){for(h=0,a||f.ownerDocument==l||(le(f),c=!p);m=e[h++];)if(m(f,a||l,c)){g.call(u,f);break}d&&(b=A)}i&&((f=!m&&f)&&v--,s&&w.push(f))}if(v+=y,i&&y!==v){for(h=0;m=n[h++];)m(w,_,a,c);if(s){if(v>0)for(;y--;)w[y]||_[y]||(_[y]=C.call(u));_=he(_)}g.apply(u,_),d&&!s&&_.length>0&&v+n.length>1&&D.uniqueSort(u)}return d&&(b=A,r=x),w};return i?te(s):s}(s,o)),a.selector=e}return a}function be(e,r,n,i){var o,s,a,l,c,u="function"==typeof e&&e,d=!i&&ue(e=u.selector||e);if(n=n||[],1===d.length){if((s=d[0]=d[0].slice(0)).length>2&&"ID"===(a=s[0]).type&&9===r.nodeType&&p&&t.relative[s[1].type]){if(!(r=(t.find.ID(a.matches[0].replace(X,K),r)||[])[0]))return n;u&&(r=r.parentNode),e=e.slice(s.shift().value.length)}for(o=$.needsContext.test(e)?0:s.length;o--&&(a=s[o],!t.relative[l=a.type]);)if((c=t.find[l])&&(i=c(a.matches[0].replace(X,K),Y.test(s[0].type)&&ae(r.parentNode)||r))){if(s.splice(o,1),!(e=i.length&&pe(s)))return g.apply(n,i),n;break}}return(u||ve(e,d))(i,r,!p,n,!r||Y.test(e)&&ae(r.parentNode)||r),n}ce.prototype=t.filters=t.pseudos,t.setFilters=new ce,m.sortStable=v.split("").sort(A).join("")===v,le(),m.sortDetached=re((function(e){return 1&e.compareDocumentPosition(l.createElement("fieldset"))})),D.find=Z,D.expr[":"]=D.expr.pseudos,D.unique=D.uniqueSort,Z.compile=ve,Z.select=be,Z.setDocument=le,Z.tokenize=ue,Z.escape=D.escapeSelector,Z.getText=D.text,Z.isXML=D.isXMLDoc,Z.selectors=D.expr,Z.support=D.support,Z.uniqueSort=D.uniqueSort}();var F=function(e,t,r){for(var n=[],i=void 0!==r;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(i&&D(e).is(r))break;n.push(e)}return n},I=function(e,t){for(var r=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&r.push(e);return r},P=D.expr.match.needsContext,H=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function M(e,t,r){return v(t)?D.grep(e,(function(e,n){return!!t.call(e,n,e)!==r})):t.nodeType?D.grep(e,(function(e){return e===t!==r})):"string"!=typeof t?D.grep(e,(function(e){return u.call(t,e)>-1!==r})):D.filter(t,e,r)}D.filter=function(e,t,r){var n=t[0];return r&&(e=":not("+e+")"),1===t.length&&1===n.nodeType?D.find.matchesSelector(n,e)?[n]:[]:D.find.matches(e,D.grep(t,(function(e){return 1===e.nodeType})))},D.fn.extend({find:function(e){var t,r,n=this.length,i=this;if("string"!=typeof e)return this.pushStack(D(e).filter((function(){for(t=0;t1?D.uniqueSort(r):r},filter:function(e){return this.pushStack(M(this,e||[],!1))},not:function(e){return this.pushStack(M(this,e||[],!0))},is:function(e){return!!M(this,"string"==typeof e&&P.test(e)?D(e):e||[],!1).length}});var U,V=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(D.fn.init=function(e,t,r){var n,i;if(!e)return this;if(r=r||U,"string"==typeof e){if(!(n="<"===e[0]&&">"===e[e.length-1]&&e.length>=3?[null,e,null]:V.exec(e))||!n[1]&&t)return!t||t.jquery?(t||r).find(e):this.constructor(t).find(e);if(n[1]){if(t=t instanceof D?t[0]:t,D.merge(this,D.parseHTML(n[1],t&&t.nodeType?t.ownerDocument||t:y,!0)),H.test(n[1])&&D.isPlainObject(t))for(n in t)v(this[n])?this[n](t[n]):this.attr(n,t[n]);return this}return(i=y.getElementById(n[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):v(e)?void 0!==r.ready?r.ready(e):e(D):D.makeArray(e,this)}).prototype=D.fn,U=D(y);var $=/^(?:parents|prev(?:Until|All))/,z={children:!0,contents:!0,next:!0,prev:!0};function G(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}D.fn.extend({has:function(e){var t=D(e,this),r=t.length;return this.filter((function(){for(var e=0;e-1:1===r.nodeType&&D.find.matchesSelector(r,e))){o.push(r);break}return this.pushStack(o.length>1?D.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?u.call(D(e),this[0]):u.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(D.uniqueSort(D.merge(this.get(),D(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),D.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return F(e,"parentNode")},parentsUntil:function(e,t,r){return F(e,"parentNode",r)},next:function(e){return G(e,"nextSibling")},prev:function(e){return G(e,"previousSibling")},nextAll:function(e){return F(e,"nextSibling")},prevAll:function(e){return F(e,"previousSibling")},nextUntil:function(e,t,r){return F(e,"nextSibling",r)},prevUntil:function(e,t,r){return F(e,"previousSibling",r)},siblings:function(e){return I((e.parentNode||{}).firstChild,e)},children:function(e){return I(e.firstChild)},contents:function(e){return null!=e.contentDocument&&s(e.contentDocument)?e.contentDocument:(q(e,"template")&&(e=e.content||e),D.merge([],e.childNodes))}},(function(e,t){D.fn[e]=function(r,n){var i=D.map(this,t,r);return"Until"!==e.slice(-5)&&(n=r),n&&"string"==typeof n&&(i=D.filter(n,i)),this.length>1&&(z[e]||D.uniqueSort(i),$.test(e)&&i.reverse()),this.pushStack(i)}}));var W=/[^\x20\t\r\n\f]+/g;function Y(e){return e}function X(e){throw e}function K(e,t,r,n){var i;try{e&&v(i=e.promise)?i.call(e).done(t).fail(r):e&&v(i=e.then)?i.call(e,t,r):t.apply(void 0,[e].slice(n))}catch(e){r.apply(void 0,[e])}}D.Callbacks=function(e){e="string"==typeof e?function(e){var t={};return D.each(e.match(W)||[],(function(e,r){t[r]=!0})),t}(e):D.extend({},e);var t,r,n,i,o=[],s=[],a=-1,l=function(){for(i=i||e.once,n=t=!0;s.length;a=-1)for(r=s.shift();++a-1;)o.splice(r,1),r<=a&&a--})),this},has:function(e){return e?D.inArray(e,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return i=s=[],o=r="",this},disabled:function(){return!o},lock:function(){return i=s=[],r||t||(o=r=""),this},locked:function(){return!!i},fireWith:function(e,r){return i||(r=[e,(r=r||[]).slice?r.slice():r],s.push(r),t||l()),this},fire:function(){return c.fireWith(this,arguments),this},fired:function(){return!!n}};return c},D.extend({Deferred:function(e){var t=[["notify","progress",D.Callbacks("memory"),D.Callbacks("memory"),2],["resolve","done",D.Callbacks("once memory"),D.Callbacks("once memory"),0,"resolved"],["reject","fail",D.Callbacks("once memory"),D.Callbacks("once memory"),1,"rejected"]],r="pending",i={state:function(){return r},always:function(){return o.done(arguments).fail(arguments),this},catch:function(e){return i.then(null,e)},pipe:function(){var e=arguments;return D.Deferred((function(r){D.each(t,(function(t,n){var i=v(e[n[4]])&&e[n[4]];o[n[1]]((function(){var e=i&&i.apply(this,arguments);e&&v(e.promise)?e.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[n[0]+"With"](this,i?[e]:arguments)}))})),e=null})).promise()},then:function(e,r,i){var o=0;function s(e,t,r,i){return function(){var a=this,l=arguments,c=function(){var n,c;if(!(e=o&&(r!==X&&(a=void 0,l=[n]),t.rejectWith(a,l))}};e?u():(D.Deferred.getErrorHook?u.error=D.Deferred.getErrorHook():D.Deferred.getStackHook&&(u.error=D.Deferred.getStackHook()),n.setTimeout(u))}}return D.Deferred((function(n){t[0][3].add(s(0,n,v(i)?i:Y,n.notifyWith)),t[1][3].add(s(0,n,v(e)?e:Y)),t[2][3].add(s(0,n,v(r)?r:X))})).promise()},promise:function(e){return null!=e?D.extend(e,i):i}},o={};return D.each(t,(function(e,n){var s=n[2],a=n[5];i[n[1]]=s.add,a&&s.add((function(){r=a}),t[3-e][2].disable,t[3-e][3].disable,t[0][2].lock,t[0][3].lock),s.add(n[3].fire),o[n[0]]=function(){return o[n[0]+"With"](this===o?void 0:this,arguments),this},o[n[0]+"With"]=s.fireWith})),i.promise(o),e&&e.call(o,o),o},when:function(e){var t=arguments.length,r=t,n=Array(r),i=a.call(arguments),o=D.Deferred(),s=function(e){return function(r){n[e]=this,i[e]=arguments.length>1?a.call(arguments):r,--t||o.resolveWith(n,i)}};if(t<=1&&(K(e,o.done(s(r)).resolve,o.reject,!t),"pending"===o.state()||v(i[r]&&i[r].then)))return o.then();for(;r--;)K(i[r],s(r),o.reject);return o.promise()}});var J=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;D.Deferred.exceptionHook=function(e,t){n.console&&n.console.warn&&e&&J.test(e.name)&&n.console.warn("jQuery.Deferred exception: "+e.message,e.stack,t)},D.readyException=function(e){n.setTimeout((function(){throw e}))};var Q=D.Deferred();function Z(){y.removeEventListener("DOMContentLoaded",Z),n.removeEventListener("load",Z),D.ready()}D.fn.ready=function(e){return Q.then(e).catch((function(e){D.readyException(e)})),this},D.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--D.readyWait:D.isReady)||(D.isReady=!0,!0!==e&&--D.readyWait>0||Q.resolveWith(y,[D]))}}),D.ready.then=Q.then,"complete"===y.readyState||"loading"!==y.readyState&&!y.documentElement.doScroll?n.setTimeout(D.ready):(y.addEventListener("DOMContentLoaded",Z),n.addEventListener("load",Z));var ee=function(e,t,r,n,i,o,s){var a=0,l=e.length,c=null==r;if("object"===x(r))for(a in i=!0,r)ee(e,t,a,r[a],!0,o,s);else if(void 0!==n&&(i=!0,v(n)||(s=!0),c&&(s?(t.call(e,n),t=null):(c=t,t=function(e,t,r){return c.call(D(e),r)})),t))for(;a1,null,!0)},removeData:function(e){return this.each((function(){le.remove(this,e)}))}}),D.extend({queue:function(e,t,r){var n;if(e)return t=(t||"fx")+"queue",n=ae.get(e,t),r&&(!n||Array.isArray(r)?n=ae.access(e,t,D.makeArray(r)):n.push(r)),n||[]},dequeue:function(e,t){t=t||"fx";var r=D.queue(e,t),n=r.length,i=r.shift(),o=D._queueHooks(e,t);"inprogress"===i&&(i=r.shift(),n--),i&&("fx"===t&&r.unshift("inprogress"),delete o.stop,i.call(e,(function(){D.dequeue(e,t)}),o)),!n&&o&&o.empty.fire()},_queueHooks:function(e,t){var r=t+"queueHooks";return ae.get(e,r)||ae.access(e,r,{empty:D.Callbacks("once memory").add((function(){ae.remove(e,[t+"queue",r])}))})}}),D.fn.extend({queue:function(e,t){var r=2;return"string"!=typeof e&&(t=e,e="fx",r--),arguments.length\x20\t\r\n\f]*)/i,qe=/^$|^module$|\/(?:java|ecma)script/i;Ee=y.createDocumentFragment().appendChild(y.createElement("div")),(Ae=y.createElement("input")).setAttribute("type","radio"),Ae.setAttribute("checked","checked"),Ae.setAttribute("name","t"),Ee.appendChild(Ae),m.checkClone=Ee.cloneNode(!0).cloneNode(!0).lastChild.checked,Ee.innerHTML="",m.noCloneChecked=!!Ee.cloneNode(!0).lastChild.defaultValue,Ee.innerHTML="",m.option=!!Ee.lastChild;var Ce={thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ke(e,t){var r;return r=void 0!==e.getElementsByTagName?e.getElementsByTagName(t||"*"):void 0!==e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&q(e,t)?D.merge([e],r):r}function Se(e,t){for(var r=0,n=e.length;r",""]);var Le=/<|&#?\w+;/;function Ne(e,t,r,n,i){for(var o,s,a,l,c,u,p=t.createDocumentFragment(),d=[],f=0,h=e.length;f-1)i&&i.push(o);else if(c=me(o),s=ke(p.appendChild(o),"script"),c&&Se(s),r)for(u=0;o=s[u++];)qe.test(o.type||"")&&r.push(o);return p}var Oe=/^([^.]*)(?:\.(.+)|)/;function je(){return!0}function Re(){return!1}function Be(e,t,r,n,i,o){var s,a;if("object"==typeof t){for(a in"string"!=typeof r&&(n=n||r,r=void 0),t)Be(e,a,r,n,t[a],o);return e}if(null==n&&null==i?(i=r,n=r=void 0):null==i&&("string"==typeof r?(i=n,n=void 0):(i=n,n=r,r=void 0)),!1===i)i=Re;else if(!i)return e;return 1===o&&(s=i,i=function(e){return D().off(e),s.apply(this,arguments)},i.guid=s.guid||(s.guid=D.guid++)),e.each((function(){D.event.add(this,t,i,n,r)}))}function Fe(e,t,r){r?(ae.set(e,t,!1),D.event.add(e,t,{namespace:!1,handler:function(e){var r,n=ae.get(this,t);if(1&e.isTrigger&&this[t]){if(n)(D.event.special[t]||{}).delegateType&&e.stopPropagation();else if(n=a.call(arguments),ae.set(this,t,n),this[t](),r=ae.get(this,t),ae.set(this,t,!1),n!==r)return e.stopImmediatePropagation(),e.preventDefault(),r}else n&&(ae.set(this,t,D.event.trigger(n[0],n.slice(1),this)),e.stopPropagation(),e.isImmediatePropagationStopped=je)}})):void 0===ae.get(e,t)&&D.event.add(e,t,je)}D.event={global:{},add:function(e,t,r,n,i){var o,s,a,l,c,u,p,d,f,h,g,m=ae.get(e);if(oe(e))for(r.handler&&(r=(o=r).handler,i=o.selector),i&&D.find.matchesSelector(ge,i),r.guid||(r.guid=D.guid++),(l=m.events)||(l=m.events=Object.create(null)),(s=m.handle)||(s=m.handle=function(t){return void 0!==D&&D.event.triggered!==t.type?D.event.dispatch.apply(e,arguments):void 0}),c=(t=(t||"").match(W)||[""]).length;c--;)f=g=(a=Oe.exec(t[c])||[])[1],h=(a[2]||"").split(".").sort(),f&&(p=D.event.special[f]||{},f=(i?p.delegateType:p.bindType)||f,p=D.event.special[f]||{},u=D.extend({type:f,origType:g,data:n,handler:r,guid:r.guid,selector:i,needsContext:i&&D.expr.match.needsContext.test(i),namespace:h.join(".")},o),(d=l[f])||((d=l[f]=[]).delegateCount=0,p.setup&&!1!==p.setup.call(e,n,h,s)||e.addEventListener&&e.addEventListener(f,s)),p.add&&(p.add.call(e,u),u.handler.guid||(u.handler.guid=r.guid)),i?d.splice(d.delegateCount++,0,u):d.push(u),D.event.global[f]=!0)},remove:function(e,t,r,n,i){var o,s,a,l,c,u,p,d,f,h,g,m=ae.hasData(e)&&ae.get(e);if(m&&(l=m.events)){for(c=(t=(t||"").match(W)||[""]).length;c--;)if(f=g=(a=Oe.exec(t[c])||[])[1],h=(a[2]||"").split(".").sort(),f){for(p=D.event.special[f]||{},d=l[f=(n?p.delegateType:p.bindType)||f]||[],a=a[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),s=o=d.length;o--;)u=d[o],!i&&g!==u.origType||r&&r.guid!==u.guid||a&&!a.test(u.namespace)||n&&n!==u.selector&&("**"!==n||!u.selector)||(d.splice(o,1),u.selector&&d.delegateCount--,p.remove&&p.remove.call(e,u));s&&!d.length&&(p.teardown&&!1!==p.teardown.call(e,h,m.handle)||D.removeEvent(e,f,m.handle),delete l[f])}else for(f in l)D.event.remove(e,f+t[c],r,n,!0);D.isEmptyObject(l)&&ae.remove(e,"handle events")}},dispatch:function(e){var t,r,n,i,o,s,a=new Array(arguments.length),l=D.event.fix(e),c=(ae.get(this,"events")||Object.create(null))[l.type]||[],u=D.event.special[l.type]||{};for(a[0]=l,t=1;t=1))for(;c!==this;c=c.parentNode||this)if(1===c.nodeType&&("click"!==e.type||!0!==c.disabled)){for(o=[],s={},r=0;r-1:D.find(i,this,null,[c]).length),s[i]&&o.push(n);o.length&&a.push({elem:c,handlers:o})}return c=this,l\s*$/g;function Me(e,t){return q(e,"table")&&q(11!==t.nodeType?t:t.firstChild,"tr")&&D(e).children("tbody")[0]||e}function Ue(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function Ve(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function $e(e,t){var r,n,i,o,s,a;if(1===t.nodeType){if(ae.hasData(e)&&(a=ae.get(e).events))for(i in ae.remove(t,"handle events"),a)for(r=0,n=a[i].length;r1&&"string"==typeof h&&!m.checkClone&&Pe.test(h))return e.each((function(i){var o=e.eq(i);g&&(t[0]=h.call(this,i,o.html())),Ge(o,t,r,n)}));if(d&&(o=(i=Ne(t,e[0].ownerDocument,!1,e,n)).firstChild,1===i.childNodes.length&&(i=o),o||n)){for(a=(s=D.map(ke(i,"script"),Ue)).length;p0&&Se(s,!l&&ke(e,"script")),a},cleanData:function(e){for(var t,r,n,i=D.event.special,o=0;void 0!==(r=e[o]);o++)if(oe(r)){if(t=r[ae.expando]){if(t.events)for(n in t.events)i[n]?D.event.remove(r,n):D.removeEvent(r,n,t.handle);r[ae.expando]=void 0}r[le.expando]&&(r[le.expando]=void 0)}}}),D.fn.extend({detach:function(e){return We(this,e,!0)},remove:function(e){return We(this,e)},text:function(e){return ee(this,(function(e){return void 0===e?D.text(this):this.empty().each((function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)}))}),null,e,arguments.length)},append:function(){return Ge(this,arguments,(function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Me(this,e).appendChild(e)}))},prepend:function(){return Ge(this,arguments,(function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Me(this,e);t.insertBefore(e,t.firstChild)}}))},before:function(){return Ge(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this)}))},after:function(){return Ge(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)}))},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(D.cleanData(ke(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map((function(){return D.clone(this,e,t)}))},html:function(e){return ee(this,(function(e){var t=this[0]||{},r=0,n=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!Ie.test(e)&&!Ce[(Te.exec(e)||["",""])[1].toLowerCase()]){e=D.htmlPrefilter(e);try{for(;r=0&&(l+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-l-a-.5))||0),l+c}function ut(e,t,r){var n=Ke(e),i=(!m.boxSizingReliable()||r)&&"border-box"===D.css(e,"boxSizing",!1,n),o=i,s=Ze(e,t,n),a="offset"+t[0].toUpperCase()+t.slice(1);if(Ye.test(s)){if(!r)return s;s="auto"}return(!m.boxSizingReliable()&&i||!m.reliableTrDimensions()&&q(e,"tr")||"auto"===s||!parseFloat(s)&&"inline"===D.css(e,"display",!1,n))&&e.getClientRects().length&&(i="border-box"===D.css(e,"boxSizing",!1,n),(o=a in e)&&(s=e[a])),(s=parseFloat(s)||0)+ct(e,t,r||(i?"border":"content"),o,n,s)+"px"}function pt(e,t,r,n,i){return new pt.prototype.init(e,t,r,n,i)}D.extend({cssHooks:{opacity:{get:function(e,t){if(t){var r=Ze(e,"opacity");return""===r?"1":r}}}},cssNumber:{animationIterationCount:!0,aspectRatio:!0,borderImageSlice:!0,columnCount:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,scale:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeMiterlimit:!0,strokeOpacity:!0},cssProps:{},style:function(e,t,r,n){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,s,a=ie(t),l=Xe.test(t),c=e.style;if(l||(t=it(a)),s=D.cssHooks[t]||D.cssHooks[a],void 0===r)return s&&"get"in s&&void 0!==(i=s.get(e,!1,n))?i:c[t];"string"===(o=typeof r)&&(i=fe.exec(r))&&i[1]&&(r=ye(e,t,i),o="number"),null!=r&&r==r&&("number"!==o||l||(r+=i&&i[3]||(D.cssNumber[a]?"":"px")),m.clearCloneStyle||""!==r||0!==t.indexOf("background")||(c[t]="inherit"),s&&"set"in s&&void 0===(r=s.set(e,r,n))||(l?c.setProperty(t,r):c[t]=r))}},css:function(e,t,r,n){var i,o,s,a=ie(t);return Xe.test(t)||(t=it(a)),(s=D.cssHooks[t]||D.cssHooks[a])&&"get"in s&&(i=s.get(e,!0,r)),void 0===i&&(i=Ze(e,t,n)),"normal"===i&&t in at&&(i=at[t]),""===r||r?(o=parseFloat(i),!0===r||isFinite(o)?o||0:i):i}}),D.each(["height","width"],(function(e,t){D.cssHooks[t]={get:function(e,r,n){if(r)return!ot.test(D.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?ut(e,t,n):Je(e,st,(function(){return ut(e,t,n)}))},set:function(e,r,n){var i,o=Ke(e),s=!m.scrollboxSize()&&"absolute"===o.position,a=(s||n)&&"border-box"===D.css(e,"boxSizing",!1,o),l=n?ct(e,t,n,a,o):0;return a&&s&&(l-=Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-parseFloat(o[t])-ct(e,t,"border",!1,o)-.5)),l&&(i=fe.exec(r))&&"px"!==(i[3]||"px")&&(e.style[t]=r,r=D.css(e,t)),lt(0,r,l)}}})),D.cssHooks.marginLeft=et(m.reliableMarginLeft,(function(e,t){if(t)return(parseFloat(Ze(e,"marginLeft"))||e.getBoundingClientRect().left-Je(e,{marginLeft:0},(function(){return e.getBoundingClientRect().left})))+"px"})),D.each({margin:"",padding:"",border:"Width"},(function(e,t){D.cssHooks[e+t]={expand:function(r){for(var n=0,i={},o="string"==typeof r?r.split(" "):[r];n<4;n++)i[e+he[n]+t]=o[n]||o[n-2]||o[0];return i}},"margin"!==e&&(D.cssHooks[e+t].set=lt)})),D.fn.extend({css:function(e,t){return ee(this,(function(e,t,r){var n,i,o={},s=0;if(Array.isArray(t)){for(n=Ke(e),i=t.length;s1)}}),D.Tween=pt,pt.prototype={constructor:pt,init:function(e,t,r,n,i,o){this.elem=e,this.prop=r,this.easing=i||D.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=n,this.unit=o||(D.cssNumber[r]?"":"px")},cur:function(){var e=pt.propHooks[this.prop];return e&&e.get?e.get(this):pt.propHooks._default.get(this)},run:function(e){var t,r=pt.propHooks[this.prop];return this.options.duration?this.pos=t=D.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),r&&r.set?r.set(this):pt.propHooks._default.set(this),this}},pt.prototype.init.prototype=pt.prototype,pt.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=D.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){D.fx.step[e.prop]?D.fx.step[e.prop](e):1!==e.elem.nodeType||!D.cssHooks[e.prop]&&null==e.elem.style[it(e.prop)]?e.elem[e.prop]=e.now:D.style(e.elem,e.prop,e.now+e.unit)}}},pt.propHooks.scrollTop=pt.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},D.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},D.fx=pt.prototype.init,D.fx.step={};var dt,ft,ht=/^(?:toggle|show|hide)$/,gt=/queueHooks$/;function mt(){ft&&(!1===y.hidden&&n.requestAnimationFrame?n.requestAnimationFrame(mt):n.setTimeout(mt,D.fx.interval),D.fx.tick())}function vt(){return n.setTimeout((function(){dt=void 0})),dt=Date.now()}function bt(e,t){var r,n=0,i={height:e};for(t=t?1:0;n<4;n+=2-t)i["margin"+(r=he[n])]=i["padding"+r]=e;return t&&(i.opacity=i.width=e),i}function yt(e,t,r){for(var n,i=(wt.tweeners[t]||[]).concat(wt.tweeners["*"]),o=0,s=i.length;o1)},removeAttr:function(e){return this.each((function(){D.removeAttr(this,e)}))}}),D.extend({attr:function(e,t,r){var n,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return void 0===e.getAttribute?D.prop(e,t,r):(1===o&&D.isXMLDoc(e)||(i=D.attrHooks[t.toLowerCase()]||(D.expr.match.bool.test(t)?_t:void 0)),void 0!==r?null===r?void D.removeAttr(e,t):i&&"set"in i&&void 0!==(n=i.set(e,r,t))?n:(e.setAttribute(t,r+""),r):i&&"get"in i&&null!==(n=i.get(e,t))?n:null==(n=D.find.attr(e,t))?void 0:n)},attrHooks:{type:{set:function(e,t){if(!m.radioValue&&"radio"===t&&q(e,"input")){var r=e.value;return e.setAttribute("type",t),r&&(e.value=r),t}}}},removeAttr:function(e,t){var r,n=0,i=t&&t.match(W);if(i&&1===e.nodeType)for(;r=i[n++];)e.removeAttribute(r)}}),_t={set:function(e,t,r){return!1===t?D.removeAttr(e,r):e.setAttribute(r,r),r}},D.each(D.expr.match.bool.source.match(/\w+/g),(function(e,t){var r=xt[t]||D.find.attr;xt[t]=function(e,t,n){var i,o,s=t.toLowerCase();return n||(o=xt[s],xt[s]=i,i=null!=r(e,t,n)?s:null,xt[s]=o),i}}));var Et=/^(?:input|select|textarea|button)$/i,At=/^(?:a|area)$/i;function Dt(e){return(e.match(W)||[]).join(" ")}function Tt(e){return e.getAttribute&&e.getAttribute("class")||""}function qt(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(W)||[]}D.fn.extend({prop:function(e,t){return ee(this,D.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each((function(){delete this[D.propFix[e]||e]}))}}),D.extend({prop:function(e,t,r){var n,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&D.isXMLDoc(e)||(t=D.propFix[t]||t,i=D.propHooks[t]),void 0!==r?i&&"set"in i&&void 0!==(n=i.set(e,r,t))?n:e[t]=r:i&&"get"in i&&null!==(n=i.get(e,t))?n:e[t]},propHooks:{tabIndex:{get:function(e){var t=D.find.attr(e,"tabindex");return t?parseInt(t,10):Et.test(e.nodeName)||At.test(e.nodeName)&&e.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),m.optSelected||(D.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),D.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],(function(){D.propFix[this.toLowerCase()]=this})),D.fn.extend({addClass:function(e){var t,r,n,i,o,s;return v(e)?this.each((function(t){D(this).addClass(e.call(this,t,Tt(this)))})):(t=qt(e)).length?this.each((function(){if(n=Tt(this),r=1===this.nodeType&&" "+Dt(n)+" "){for(o=0;o-1;)r=r.replace(" "+i+" "," ");s=Dt(r),n!==s&&this.setAttribute("class",s)}})):this:this.attr("class","")},toggleClass:function(e,t){var r,n,i,o,s=typeof e,a="string"===s||Array.isArray(e);return v(e)?this.each((function(r){D(this).toggleClass(e.call(this,r,Tt(this),t),t)})):"boolean"==typeof t&&a?t?this.addClass(e):this.removeClass(e):(r=qt(e),this.each((function(){if(a)for(o=D(this),i=0;i-1)return!0;return!1}});var Ct=/\r/g;D.fn.extend({val:function(e){var t,r,n,i=this[0];return arguments.length?(n=v(e),this.each((function(r){var i;1===this.nodeType&&(null==(i=n?e.call(this,r,D(this).val()):e)?i="":"number"==typeof i?i+="":Array.isArray(i)&&(i=D.map(i,(function(e){return null==e?"":e+""}))),(t=D.valHooks[this.type]||D.valHooks[this.nodeName.toLowerCase()])&&"set"in t&&void 0!==t.set(this,i,"value")||(this.value=i))}))):i?(t=D.valHooks[i.type]||D.valHooks[i.nodeName.toLowerCase()])&&"get"in t&&void 0!==(r=t.get(i,"value"))?r:"string"==typeof(r=i.value)?r.replace(Ct,""):null==r?"":r:void 0}}),D.extend({valHooks:{option:{get:function(e){var t=D.find.attr(e,"value");return null!=t?t:Dt(D.text(e))}},select:{get:function(e){var t,r,n,i=e.options,o=e.selectedIndex,s="select-one"===e.type,a=s?null:[],l=s?o+1:i.length;for(n=o<0?l:s?o:0;n-1)&&(r=!0);return r||(e.selectedIndex=-1),o}}}}),D.each(["radio","checkbox"],(function(){D.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=D.inArray(D(e).val(),t)>-1}},m.checkOn||(D.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}));var kt=n.location,St={guid:Date.now()},Lt=/\?/;D.parseXML=function(e){var t,r;if(!e||"string"!=typeof e)return null;try{t=(new n.DOMParser).parseFromString(e,"text/xml")}catch(e){}return r=t&&t.getElementsByTagName("parsererror")[0],t&&!r||D.error("Invalid XML: "+(r?D.map(r.childNodes,(function(e){return e.textContent})).join("\n"):e)),t};var Nt=/^(?:focusinfocus|focusoutblur)$/,Ot=function(e){e.stopPropagation()};D.extend(D.event,{trigger:function(e,t,r,i){var o,s,a,l,c,u,p,d,h=[r||y],g=f.call(e,"type")?e.type:e,m=f.call(e,"namespace")?e.namespace.split("."):[];if(s=d=a=r=r||y,3!==r.nodeType&&8!==r.nodeType&&!Nt.test(g+D.event.triggered)&&(g.indexOf(".")>-1&&(m=g.split("."),g=m.shift(),m.sort()),c=g.indexOf(":")<0&&"on"+g,(e=e[D.expando]?e:new D.Event(g,"object"==typeof e&&e)).isTrigger=i?2:3,e.namespace=m.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+m.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=r),t=null==t?[e]:D.makeArray(t,[e]),p=D.event.special[g]||{},i||!p.trigger||!1!==p.trigger.apply(r,t))){if(!i&&!p.noBubble&&!b(r)){for(l=p.delegateType||g,Nt.test(l+g)||(s=s.parentNode);s;s=s.parentNode)h.push(s),a=s;a===(r.ownerDocument||y)&&h.push(a.defaultView||a.parentWindow||n)}for(o=0;(s=h[o++])&&!e.isPropagationStopped();)d=s,e.type=o>1?l:p.bindType||g,(u=(ae.get(s,"events")||Object.create(null))[e.type]&&ae.get(s,"handle"))&&u.apply(s,t),(u=c&&s[c])&&u.apply&&oe(s)&&(e.result=u.apply(s,t),!1===e.result&&e.preventDefault());return e.type=g,i||e.isDefaultPrevented()||p._default&&!1!==p._default.apply(h.pop(),t)||!oe(r)||c&&v(r[g])&&!b(r)&&((a=r[c])&&(r[c]=null),D.event.triggered=g,e.isPropagationStopped()&&d.addEventListener(g,Ot),r[g](),e.isPropagationStopped()&&d.removeEventListener(g,Ot),D.event.triggered=void 0,a&&(r[c]=a)),e.result}},simulate:function(e,t,r){var n=D.extend(new D.Event,r,{type:e,isSimulated:!0});D.event.trigger(n,null,t)}}),D.fn.extend({trigger:function(e,t){return this.each((function(){D.event.trigger(e,t,this)}))},triggerHandler:function(e,t){var r=this[0];if(r)return D.event.trigger(e,t,r,!0)}});var jt=/\[\]$/,Rt=/\r?\n/g,Bt=/^(?:submit|button|image|reset|file)$/i,Ft=/^(?:input|select|textarea|keygen)/i;function It(e,t,r,n){var i;if(Array.isArray(t))D.each(t,(function(t,i){r||jt.test(e)?n(e,i):It(e+"["+("object"==typeof i&&null!=i?t:"")+"]",i,r,n)}));else if(r||"object"!==x(t))n(e,t);else for(i in t)It(e+"["+i+"]",t[i],r,n)}D.param=function(e,t){var r,n=[],i=function(e,t){var r=v(t)?t():t;n[n.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==r?"":r)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!D.isPlainObject(e))D.each(e,(function(){i(this.name,this.value)}));else for(r in e)It(r,e[r],t,i);return n.join("&")},D.fn.extend({serialize:function(){return D.param(this.serializeArray())},serializeArray:function(){return this.map((function(){var e=D.prop(this,"elements");return e?D.makeArray(e):this})).filter((function(){var e=this.type;return this.name&&!D(this).is(":disabled")&&Ft.test(this.nodeName)&&!Bt.test(e)&&(this.checked||!De.test(e))})).map((function(e,t){var r=D(this).val();return null==r?null:Array.isArray(r)?D.map(r,(function(e){return{name:t.name,value:e.replace(Rt,"\r\n")}})):{name:t.name,value:r.replace(Rt,"\r\n")}})).get()}});var Pt=/%20/g,Ht=/#.*$/,Mt=/([?&])_=[^&]*/,Ut=/^(.*?):[ \t]*([^\r\n]*)$/gm,Vt=/^(?:GET|HEAD)$/,$t=/^\/\//,zt={},Gt={},Wt="*/".concat("*"),Yt=y.createElement("a");function Xt(e){return function(t,r){"string"!=typeof t&&(r=t,t="*");var n,i=0,o=t.toLowerCase().match(W)||[];if(v(r))for(;n=o[i++];)"+"===n[0]?(n=n.slice(1)||"*",(e[n]=e[n]||[]).unshift(r)):(e[n]=e[n]||[]).push(r)}}function Kt(e,t,r,n){var i={},o=e===Gt;function s(a){var l;return i[a]=!0,D.each(e[a]||[],(function(e,a){var c=a(t,r,n);return"string"!=typeof c||o||i[c]?o?!(l=c):void 0:(t.dataTypes.unshift(c),s(c),!1)})),l}return s(t.dataTypes[0])||!i["*"]&&s("*")}function Jt(e,t){var r,n,i=D.ajaxSettings.flatOptions||{};for(r in t)void 0!==t[r]&&((i[r]?e:n||(n={}))[r]=t[r]);return n&&D.extend(!0,e,n),e}Yt.href=kt.href,D.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:kt.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(kt.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Wt,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":D.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?Jt(Jt(e,D.ajaxSettings),t):Jt(D.ajaxSettings,e)},ajaxPrefilter:Xt(zt),ajaxTransport:Xt(Gt),ajax:function(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var r,i,o,s,a,l,c,u,p,d,f=D.ajaxSetup({},t),h=f.context||f,g=f.context&&(h.nodeType||h.jquery)?D(h):D.event,m=D.Deferred(),v=D.Callbacks("once memory"),b=f.statusCode||{},w={},_={},x="canceled",E={readyState:0,getResponseHeader:function(e){var t;if(c){if(!s)for(s={};t=Ut.exec(o);)s[t[1].toLowerCase()+" "]=(s[t[1].toLowerCase()+" "]||[]).concat(t[2]);t=s[e.toLowerCase()+" "]}return null==t?null:t.join(", ")},getAllResponseHeaders:function(){return c?o:null},setRequestHeader:function(e,t){return null==c&&(e=_[e.toLowerCase()]=_[e.toLowerCase()]||e,w[e]=t),this},overrideMimeType:function(e){return null==c&&(f.mimeType=e),this},statusCode:function(e){var t;if(e)if(c)E.always(e[E.status]);else for(t in e)b[t]=[b[t],e[t]];return this},abort:function(e){var t=e||x;return r&&r.abort(t),A(0,t),this}};if(m.promise(E),f.url=((e||f.url||kt.href)+"").replace($t,kt.protocol+"//"),f.type=t.method||t.type||f.method||f.type,f.dataTypes=(f.dataType||"*").toLowerCase().match(W)||[""],null==f.crossDomain){l=y.createElement("a");try{l.href=f.url,l.href=l.href,f.crossDomain=Yt.protocol+"//"+Yt.host!=l.protocol+"//"+l.host}catch(e){f.crossDomain=!0}}if(f.data&&f.processData&&"string"!=typeof f.data&&(f.data=D.param(f.data,f.traditional)),Kt(zt,f,t,E),c)return E;for(p in(u=D.event&&f.global)&&0==D.active++&&D.event.trigger("ajaxStart"),f.type=f.type.toUpperCase(),f.hasContent=!Vt.test(f.type),i=f.url.replace(Ht,""),f.hasContent?f.data&&f.processData&&0===(f.contentType||"").indexOf("application/x-www-form-urlencoded")&&(f.data=f.data.replace(Pt,"+")):(d=f.url.slice(i.length),f.data&&(f.processData||"string"==typeof f.data)&&(i+=(Lt.test(i)?"&":"?")+f.data,delete f.data),!1===f.cache&&(i=i.replace(Mt,"$1"),d=(Lt.test(i)?"&":"?")+"_="+St.guid+++d),f.url=i+d),f.ifModified&&(D.lastModified[i]&&E.setRequestHeader("If-Modified-Since",D.lastModified[i]),D.etag[i]&&E.setRequestHeader("If-None-Match",D.etag[i])),(f.data&&f.hasContent&&!1!==f.contentType||t.contentType)&&E.setRequestHeader("Content-Type",f.contentType),E.setRequestHeader("Accept",f.dataTypes[0]&&f.accepts[f.dataTypes[0]]?f.accepts[f.dataTypes[0]]+("*"!==f.dataTypes[0]?", "+Wt+"; q=0.01":""):f.accepts["*"]),f.headers)E.setRequestHeader(p,f.headers[p]);if(f.beforeSend&&(!1===f.beforeSend.call(h,E,f)||c))return E.abort();if(x="abort",v.add(f.complete),E.done(f.success),E.fail(f.error),r=Kt(Gt,f,t,E)){if(E.readyState=1,u&&g.trigger("ajaxSend",[E,f]),c)return E;f.async&&f.timeout>0&&(a=n.setTimeout((function(){E.abort("timeout")}),f.timeout));try{c=!1,r.send(w,A)}catch(e){if(c)throw e;A(-1,e)}}else A(-1,"No Transport");function A(e,t,s,l){var p,d,y,w,_,x=t;c||(c=!0,a&&n.clearTimeout(a),r=void 0,o=l||"",E.readyState=e>0?4:0,p=e>=200&&e<300||304===e,s&&(w=function(e,t,r){for(var n,i,o,s,a=e.contents,l=e.dataTypes;"*"===l[0];)l.shift(),void 0===n&&(n=e.mimeType||t.getResponseHeader("Content-Type"));if(n)for(i in a)if(a[i]&&a[i].test(n)){l.unshift(i);break}if(l[0]in r)o=l[0];else{for(i in r){if(!l[0]||e.converters[i+" "+l[0]]){o=i;break}s||(s=i)}o=o||s}if(o)return o!==l[0]&&l.unshift(o),r[o]}(f,E,s)),!p&&D.inArray("script",f.dataTypes)>-1&&D.inArray("json",f.dataTypes)<0&&(f.converters["text script"]=function(){}),w=function(e,t,r,n){var i,o,s,a,l,c={},u=e.dataTypes.slice();if(u[1])for(s in e.converters)c[s.toLowerCase()]=e.converters[s];for(o=u.shift();o;)if(e.responseFields[o]&&(r[e.responseFields[o]]=t),!l&&n&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),l=o,o=u.shift())if("*"===o)o=l;else if("*"!==l&&l!==o){if(!(s=c[l+" "+o]||c["* "+o]))for(i in c)if((a=i.split(" "))[1]===o&&(s=c[l+" "+a[0]]||c["* "+a[0]])){!0===s?s=c[i]:!0!==c[i]&&(o=a[0],u.unshift(a[1]));break}if(!0!==s)if(s&&e.throws)t=s(t);else try{t=s(t)}catch(e){return{state:"parsererror",error:s?e:"No conversion from "+l+" to "+o}}}return{state:"success",data:t}}(f,w,E,p),p?(f.ifModified&&((_=E.getResponseHeader("Last-Modified"))&&(D.lastModified[i]=_),(_=E.getResponseHeader("etag"))&&(D.etag[i]=_)),204===e||"HEAD"===f.type?x="nocontent":304===e?x="notmodified":(x=w.state,d=w.data,p=!(y=w.error))):(y=x,!e&&x||(x="error",e<0&&(e=0))),E.status=e,E.statusText=(t||x)+"",p?m.resolveWith(h,[d,x,E]):m.rejectWith(h,[E,x,y]),E.statusCode(b),b=void 0,u&&g.trigger(p?"ajaxSuccess":"ajaxError",[E,f,p?d:y]),v.fireWith(h,[E,x]),u&&(g.trigger("ajaxComplete",[E,f]),--D.active||D.event.trigger("ajaxStop")))}return E},getJSON:function(e,t,r){return D.get(e,t,r,"json")},getScript:function(e,t){return D.get(e,void 0,t,"script")}}),D.each(["get","post"],(function(e,t){D[t]=function(e,r,n,i){return v(r)&&(i=i||n,n=r,r=void 0),D.ajax(D.extend({url:e,type:t,dataType:i,data:r,success:n},D.isPlainObject(e)&&e))}})),D.ajaxPrefilter((function(e){var t;for(t in e.headers)"content-type"===t.toLowerCase()&&(e.contentType=e.headers[t]||"")})),D._evalUrl=function(e,t,r){return D.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(e){D.globalEval(e,t,r)}})},D.fn.extend({wrapAll:function(e){var t;return this[0]&&(v(e)&&(e=e.call(this[0])),t=D(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map((function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e})).append(this)),this},wrapInner:function(e){return v(e)?this.each((function(t){D(this).wrapInner(e.call(this,t))})):this.each((function(){var t=D(this),r=t.contents();r.length?r.wrapAll(e):t.append(e)}))},wrap:function(e){var t=v(e);return this.each((function(r){D(this).wrapAll(t?e.call(this,r):e)}))},unwrap:function(e){return this.parent(e).not("body").each((function(){D(this).replaceWith(this.childNodes)})),this}}),D.expr.pseudos.hidden=function(e){return!D.expr.pseudos.visible(e)},D.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},D.ajaxSettings.xhr=function(){try{return new n.XMLHttpRequest}catch(e){}};var Qt={0:200,1223:204},Zt=D.ajaxSettings.xhr();m.cors=!!Zt&&"withCredentials"in Zt,m.ajax=Zt=!!Zt,D.ajaxTransport((function(e){var t,r;if(m.cors||Zt&&!e.crossDomain)return{send:function(i,o){var s,a=e.xhr();if(a.open(e.type,e.url,e.async,e.username,e.password),e.xhrFields)for(s in e.xhrFields)a[s]=e.xhrFields[s];for(s in e.mimeType&&a.overrideMimeType&&a.overrideMimeType(e.mimeType),e.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest"),i)a.setRequestHeader(s,i[s]);t=function(e){return function(){t&&(t=r=a.onload=a.onerror=a.onabort=a.ontimeout=a.onreadystatechange=null,"abort"===e?a.abort():"error"===e?"number"!=typeof a.status?o(0,"error"):o(a.status,a.statusText):o(Qt[a.status]||a.status,a.statusText,"text"!==(a.responseType||"text")||"string"!=typeof a.responseText?{binary:a.response}:{text:a.responseText},a.getAllResponseHeaders()))}},a.onload=t(),r=a.onerror=a.ontimeout=t("error"),void 0!==a.onabort?a.onabort=r:a.onreadystatechange=function(){4===a.readyState&&n.setTimeout((function(){t&&r()}))},t=t("abort");try{a.send(e.hasContent&&e.data||null)}catch(e){if(t)throw e}},abort:function(){t&&t()}}})),D.ajaxPrefilter((function(e){e.crossDomain&&(e.contents.script=!1)})),D.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return D.globalEval(e),e}}}),D.ajaxPrefilter("script",(function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")})),D.ajaxTransport("script",(function(e){var t,r;if(e.crossDomain||e.scriptAttrs)return{send:function(n,i){t=D("